Final Fantasy Hacktics

Modding => Event Editing => Topic started by: Kuraudo Sutoraifu on August 02, 2015, 08:52:30 pm

Title: Error when compiling an event ('x' is not a valid integer value)
Post by: Kuraudo Sutoraifu on August 02, 2015, 08:52:30 pm
Hey all,

Its been quite some time since I've done any work here, and I'm relearning event editing. I've run into a snag. When I try to compile this event, I get this error - 'x' is not a valid integer value. I assumed this meant I had 'x' set as a value somewhere in my commands, but I've been over it a few times know. If it is there, I've become codeblind to it. If it is some other silly mistake I am making, I'd appreciate some coaching on that.

Here is the event:
Offset(x00008000)

LoadEVTCHR(x01,x07,x00)
WaitForInstruction(x34,x00)
SaveEVTCHR(x01)
UnitPresent(x07,x00,x01)
Weather(x02,x01)
Camera(+00800,-00135,+01415,+00302,+03584,-01024,+04096,+00128)
Wait(00210)
UnitAnim(x00,x00,x02,x00,x00)
DisplayMessage(x10,x11,x0001,x02,x00,x00,+00000,+00000,+00000,x01)
WaitForInstruction(x01,x00)
RotateUnit(x01,x01,x01,x00,x05,x00)
WaitRotateUnit(x01,x00)
DisplayMessage(x10,x12,x0002,x01,x00,x00,+00000,+00000,+00000,x01)
WaitForInstruction(x01,x00)
DisplayMessage(x10,x11,x0003,x02,x00,x00,+00000,+00000,+00000,x01)
WaitForInstruction(x01,x00)
DisplayMessage(x10,x12,x0004,x01,x00,x00,+00000,+00000,+00000,x01)
WaitForInstruction(x01,x00)
BgSound(x12,+127,+127,x01,200)
Effect(x0043,x07,x04,x06,x00)
Wait(00060)
EffectStart()
TeleportIn(x07,x00)
BgSound(x12,+127,+127,x01,200)
EffectEnd()
Focus(X07,x00,x07,x00,x00)
WaitForInstruction(x04,x00)
WaitForInstruction(x41,x00)
DisplayMessage(x10,x12,x0004,x01,x00,x00,+00000,+00000,+00000,x01)
WaitForInstruction(x01,x00)
UnitAnim(x00,x00,x02,x00,x00)
UnitAnim(xID,x00,x6c,x02,x00)
UnitAnim(xID,x00,x71,x02,x00)
EventEnd()

//INSTRUCTION SECTION END -  TEXT START
//Message x01
{font:08}Viktor{br}
{font:00}Finally.{br}
{br}
{font:08}Viktor{br}
{font:00}The battle is done.{end}

//Message x02
{font:08}Markain{br}
{font:00}Why is there no joy in your voice, man?{br}
We won!{br}
{font:08}Markain{br}
{font:00}The Lucavi cower back to Limberry,{br}
back to thier master Duma's skirts!{end}

//Message x03
{font:08}Viktor{br}
{font:00}I...  I grow weary of the fight.  Will{br}
our lives always be war? We've barely{br}
{font:08}Viktor{br}
{font:00}the time to wash the blood from our{br}
hands before we head to battle again.{br}

//Message x04
{font:08}Markain{br}
{font:00}Soon, my friend, we'll st...{end}

//Message x05
{font:08}Duma{br}
{font:00}Ahhhhh! Viktor Giltea. I thought{br}
that was your shining armor glinting{br}
{font:08}Duma{br}
{font:00}in the distance. A pleasure to{br}
to finally meet you.{end}

//Message x06
{font:08}Viktor{br}
{font:00}Grrrrrgghhhgglle!!!{end}

//Message x07
{font:08}Duma{br}
{font:00}Yes. I've a few choice words for{br}
you, too. But alas, your action force my{br}
{font:08}Duma{br}
{font:00}brevity.  Goodbye, Viktor.{end}
Title: Re: Error when compiling an event ('x' is not a valid integer value)
Post by: Jumza on August 02, 2015, 09:05:58 pm
Are you using the new or old CONFIG.INI file? I see you're using some of the old command structure, so if you've updated that would be the problem.
Title: Re: Error when compiling an event ('x' is not a valid integer value)
Post by: 3lric on August 02, 2015, 10:14:35 pm
Change:

Effect(x0043,x07,x04,x06,x00)

to

Effect(x0043,x07,004,006,x00)


Also, I'd be surprised if the event actually showed, since you don't seem to have a Reveal command in there.

(If you are using the new config, you'll need to change the UnitAnim commands as well)
Title: Re: Error when compiling an event ('x' is not a valid integer value)
Post by: Kuraudo Sutoraifu on August 02, 2015, 10:33:05 pm
Yeah, I just started getting back into this and I have updated most everything, but I guess I missed the config.ini, I'll do that then. This was an event that I was in the middle of writing about two years ago. I just trying to plug it into the game to see where I was at.

Thank for your help, peoples.
Title: Re: Error when compiling an event ('x' is not a valid integer value)
Post by: 3lric on August 02, 2015, 10:38:21 pm
No worries, when you get the new config.ini, make sure to look at the event conditions on the wiki to make sure your commands are up to date (As i mentioned, the UnitAnim will need to be fixed, but there might be others)

Otherwise you'll get that error again.

EDIT: Xif brought up another good point. The last 2 commands before the EventEnd() don't have an ID for them. What EVTCHR are you trying to call?
Title: Re: Error when compiling an event ('x' is not a valid integer value)
Post by: Kuraudo Sutoraifu on August 03, 2015, 06:09:04 pm
Honestly, I don't remember what EVTCHR I was trying to pull up. That's why I was just gonna plug the event in and see what came out, and hope whatever there was would jog my memory. I got the general idea of what scene I was writing from the text at the bottom, but I'm still a little lost. I'm actually surprised at how much is coming back to me which is a good sign, but I'm still looking at the code thinking "I wrote this?".

My Config.ini has been updated, but I think I might just rewrite the entire event, since it's not too long.
Title: Re: Error when compiling an event ('x' is not a valid integer value)
Post by: Xifanie on August 04, 2015, 12:27:38 am
That's what I would recommend, because that script is heavily broken. I would personally start over from scratch.