Modeldef error Missing string (unexpected end of file)

Thu Jul 22, 2021 11:40 pm

Hi, I've been trying to set models up in a mod I've been working on but have run into the script error "Missing string (unexpected end of file)" when trying to it and have no idea what it means by that/how to fix and can't seem to find a solution that worked when searching through the zdoom forums or the doomwolrd forums.

if it helps here is the Modeldef

Code:
Model Sword
{
    Path "Models/Sword
    Model 0 "Sword.md3"
    Skin 0 "Sword.png"
    Scale 1.0 1.0 1.0

    FrameIndex TEST A 0 0
    FrameIndex AAAA B 0 1
    FrameIndex AAAA C 0 2
    FrameIndex AAAA D 0 3
    FrameIndex AAAA E 0 4
    FrameIndex AAAA F 0 5
    FrameIndex AAAA G 0 6
    FrameIndex AAAA H 0 7
    FrameIndex AAAA I 0 8
    FrameIndex AAAA J 0 9
    FrameIndex AAAA K 0 10
    FrameIndex AAAA L 0 11
    FrameIndex AAAA M 0 12
    FrameIndex AAAA N 0 13
    FrameIndex AAAA O 0 14
    FrameIndex AAAA P 0 15
    FrameIndex AAAA Q O 16
    FrameIndex AAAA R 0 17
    FrameIndex AAAA S 0 17
    FrameIndex AAAA T 0 18
    FrameIndex AAAA U 0 19
}


and here is the zscript code for the weapon that the models are attached to.

Code:
Class Sword : Weapon
{
    Default {
        Weapon.SelectionOrder  3600;
        Weapon.Kickback 100;
        Tag "$TAG_SWORD" ;
    }
    States {
    Ready:
        TEST A 1 A_WeaponReady;
        Loop;
    Deselect:
        AAAA K 3;
        AAAA J 3;
        AAAA I 3;
        AAAA H 3;
        AAAA G 3;
        AAAA F 3;
        AAAA E 3;
        AAAA D 3;
        AAAA C 3;
        AAAA B 3 A_Lower;
    Select:
        AAAA B 3 A_Raise;
        AAAA C 3;
        AAAA D 3;
        AAAA E 3;
        AAAA F 3;
        AAAA G 3;
        AAAA H 3;
        AAAA I 3;
        AAAA J 3;
        AAAA K 3;
    Fire:
        AAAA L 3;
        AAAA M 3;
        AAAA N 3;
        AAAA O 3;
        AAAA P 3;
        AAAA Q 3;
        AAAA R 3;
        AAAA S 3;
        AAAA T 3;
        AAAA U 3 A_CustomPunch(50,TRUE,0);
        AAAA T 3;
        AAAA S 3;
        AAAA R 3;
        AAAA Q 3;
        AAAA P 3;
        AAAA O 3;
        AAAA N 3;
        AAAA M 3;
        AAAA L 3;
    }
}


Thanks in advance

Edit: I forgot to mention that the error occurred with the modeldef, not the sword zscript, sorry if it was worded vaguely.

Re: Modeldef error Missing string (unexpected end of file)

Fri Jul 23, 2021 2:56 am

Your model path has an unclosed string:
Code:
Path "Models/Sword

which is causing it to misinterpret the rest of the file.

Re: Modeldef error Missing string (unexpected end of file)

Fri Jul 23, 2021 9:18 am

no worries, that seems to have fixed it, thanks.