Jump to content

A character is causing the game to restart on move.


RandomSwordmaster
 Share

Recommended Posts

Trying to make a romhack, except that both of my characters causes the game to restart if they attempt to move to any location. Anybody know what might be causing this?

I'm not sure if it will help, but here's my event code.

#define DISABLE_TUTORIALS
#include EAstdlib.event
ORG $1002B50
Pointers:
POIN Turn_events
POIN Character_events
POIN Location_events
POIN Misc_events
POIN TrapData TrapData
POIN Bad Bad Bad Bad
POIN Good Good Good Good
POIN Opening_event Ending_event
Location_events:
END_MAIN
Bad:
UNIT 0x6D Paladin 0x6D 0x0C [9,15] [7,6] [ironSpear,0x0,0x0,0x0] [0x00,0x00,0x00,0x00]
UNIT 0x52 Cavalier 0x6D 0x0C [9,15] [8,6] [ironSword,0x0,0x0,0x0] [0x00,0x00,0x00,0x00]
UNIT 0x52 Cavalier 0x6D 0x0C [9,15] [8,5] [ironSword,0x0,0x0,0x0] [0x00,0x00,0x00,0x00]
UNIT 0x52 Cavalier 0x6D 0x0C [9,15] [8,13] [ironSword,0x0,0x0,0x0] [0x00,0x00,0x00,0x00]
UNIT 0x52 Cavalier 0x6D 0x14 [10,15] [8,12] [ironAxe,0x0,0x0,0x0] [0x00,0x00,0x00,0x00]
UNIT 0x6E Cavalier 0x6D 0x14 [10,15] [8,11] [ironAxe,0x0,0x0,0x0] [0x00,0x00,0x00,0x00]
UNIT Kent Cavalier 0x6D 0x0C [10,15] [11,12] [ironSword,0x0,0x0,0x0] [0x00,0x00,0x00,0x00]
UNIT
Good:
UNIT Eliwood Archer Eliwood 0x08 [17,12] [17,12] [ironBow,Vulnerary,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT Hector Mercenary Eliwood 0x10 [15,12] [15,12] [ironSword,Vulnerary,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT
villagers:
UNIT 0x0A 0x47 0x0A 0x0A [7,5] [7,5] [0x00,0x00,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT 0x0A 0x47 0x0A 0x0A [8,5] [8,5] [0x00,0x00,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT 0x0A 0x47 0x0A 0x0A [7,13] [7,13] [0x00,0x00,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT 0x0A 0x47 0x0A 0x0A [7,11] [7,11] [0x00,0x00,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT 0x0A 0x47 0x0A 0x0A [12,12] [12,12] [0x00,0x00,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT
OtherGuys:
UNIT Serra Cleric Eliwood 0x0A [12,12] [11,13] [Heal,Vulnerary,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT Matthew Thief Eliwood 0x0A [12,12] [12,13] [ironSword,LockPick,0x00,0x00] [0x00,0x00,0x00,0x00]
UNIT Marcus Paladin Eliwood 0x1B [12,12] [12,13] [0x00,0x00,0x00,0x00] [0x00,0x00,0x00,0x00]
Turn_events:
OpeningTurnEvent(Opening_event)
END_MAIN
Character_events:
VillageEventItem(0x09F8,0x02,SteelBow)
VillageEventItem(0x09F9,0x02,LanceReaver)
CHAR 0x1F KentRecruit Eliwood Kent $00000000
END_MAIN
Misc_events:
CauseGameOverIfLordDies
END_MAIN
KentRecruit:
TEX1 0x09FA
TurnAlly(Kent)
ENUF 0x1F
ENDA
Opening_event:
LOU1 villagers Good
ENUN
CAM1 [12,11]
CURF [17,12]
FIGH Eliwood Hector TrainingBattle $00000000
FADI 16
BACG 0x04
FADU 16
TEX1 0x09F6
REMA
LOU1 Bad
FIGH 0x6D 0x0A ScriptedNPC $00000000
DISA [7,5]
KILL [8,5]
DISA [8,5]
KILL [7,13]
DISA [7,13]
KILL [7,11]
DISA [7,11]
KILL [12,12]
DISA [12,12]
TEX1 0x9F7
ENUN
MOVE Eliwood [15,10]
ENUN
MOVE [8,11] [14,12]
ENUN
REMA
FIGH 0x6E Hector PreBattle $00000000
ENDA
TrainingBattle:
AttackerMiss(0x00)
BLDT
ScriptedNPC:
AttackerCritical(50,0x00)
BLDT
PreBattle:
AttackerMiss(0x00)
BLDT
Ending_event:
LOMA 0x01 [12,11]
LOU1 OtherGuys
MOVE Eliwood [13,14] 0x50
ENUN
MOVE Hector [11,14] 0x50
ENUN
FADI 16
BACG 0x04
FADU 16
TEX1 0x9F5
IFEV 0x50 0x1F
TEX1 0x9F4
ENIF 0x50
REMA
MoveToChapter(0x02)
ENDA
TrapData:
ENDTRAP
MESSAGE Events end at offset currentOffset
//The map for this chapter is at offset: ????????

Here's a test patch showcasing the problem: https://www.dropbox.com/s/hojdjy3l4stve7u/testpatch.ups?dl=0
Edited by RandomSwordmaster
Link to comment
Share on other sites

Oh thanks, didn't notice that. It isn't affecting the problem though, as OtherGuys isn't supposed to spawn until the end of the chapter, and I haven't gotten to that point yet.

And apparently, the game also restarts whenever Eliwood trys to do anything as well.

Edited by RandomSwordmaster
Link to comment
Share on other sites

Character_events:

VillageEventItem(0x09F8,0x02,SteelBow)
VillageEventItem(0x09F9,0x02,LanceReaver)
The villages are not set up correctly. The villages need an event id, offset, and coordinates. The VillageEventItem macro goes under the offsets. (Correct me if I'm not using correct terminology ¯\_(ツ)_/¯)
I'm not sure which village is supposed to be where, so I just went with the assumption that the steel bow village is the left open village, and the lancereaver village is the right open village. I put the following between Character_events and Misc_events (order doesn't matter, but it's what I'm used to):
Location_events:
Village(0x06,SteelBowVillage,2,4)
Village(0x07,LancereaverVillage,11,4)
END_MAIN
Then, I put the following after the battles, but before Ending_event:
SteelBowVillage:
VillageEventItem(0x09F8,0x02,SteelBow)
 
LancereaverVillage:
VillageEventItem(0x09F9,0x02,Lancereaver)

After doing those changes, I didn't have the issue you seemed to be having.

Oh, and I made some modifications (specifically, I used UNCR char cond) to Opening_event so that any units grayed out were not by the time the player gets control . Use them if you want

or something

Opening_event:
LOU1 villagers Good
ENUN
CAM1 [12,11]
CURF [17,12]
FIGH Eliwood Hector TrainingBattle $00000000
UNCR Eliwood GrayedOut
FADI 16
BACG 0x04
FADU 16
TEX1 0x09F6
REMA
LOU1 Bad
FIGH 0x6D 0x0A ScriptedNPC $00000000
UNCR 0x6D GrayedOut
DISA [7,5]
KILL [8,5]
DISA [8,5]
KILL [7,13]
DISA [7,13]
KILL [7,11]
DISA [7,11]
KILL [12,12]
DISA [12,12]
TEX1 0x9F7
ENUN
MOVE Eliwood [15,10]
ENUN
MOVE [8,11] [14,12]
ENUN
REMA
FIGH 0x6E Hector PreBattle $00000000
UNCR 0x6E GrayedOut
ENDA
Edited by Aura Wolf
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...