FE_Builder_GBA -- If you have any questions, attach report7z

I wasn’t sure of everything you were doing so I just wrote my own version of the event. Hope this helps.

MiwM0ncPFT

Unfortunately, SilentGiveItem cannot give an item stored in memory slot 3, so the annoying “Got an Iron Sword” pops up. I do this to compare the durability of a fresh item compared to how many uses yours has. I also don’t know of a way to check the cost of an item with events, so this is simply hard coded to charge 8 gold per durability of the item it repairs. Hopefully this is still useful, though.

Repair weapon event

400D071E0DB11708	//Get [Unit:0x7 Andre]'s [Status:0x1E Item 1] of unit
2006C300	//SADD[PackedMemorySlot:0xC3 Slot3=SlotC+Slot0]
4F32550000000000	//Load one Player unit [Character:0x55 Jorah] with it's default parameters at [X:0][Y:0], unit will dissapear at end of events(SPAWN_CUTSCENE_ALLY)
400501000100000027345500	//Causes unit condition to be turned on[Unit:0x55 Jorah][Condition:0x1 Hide](UNCM)
20375500	//GIVEITEMTO[Character:0x55 Jorah](GIVE_ITEM)
400D551F0DB11708	//Get [Unit:0x55 Jorah]'s [Status:0x1F Item 1 piece] of unit
2006C200	//Copy memory slot C to memory slot 2(MOV VAL_2,VAL_C / SADD)
400D071F0DB11708	//Get [Unit:0x7 Andre]'s [Status:0x1F Item 1 piece] of unit
2006C100	//Copy memory slot C to memory slot 1(MOV VAL_1,VAL_C / SADD)
21062101	//SSUB[PackedMemorySlot:0x121 Slot1=Slot2-Slot1]
4005020008000000	//SVAL[MemorySlot:0x2 Slot2][Value_to_store:0x8]
22062401	//SMUL[PackedMemorySlot:0x124 Slot4=Slot2*Slot1]
28190000	//Checks your gold balance(CHECK_MONEY)
450C50970C000400	//BLT (If [MemorySlotX:0xC Result] <  [MemorySlotY:0x4 Slot4], Then Jump to [Conditional ID:0x9750], Else execute following)
400D04009DAF1708	//Convert [MemorySlot:0x4 Slot4] value to string
201A0000201B5A1E201D0000221B0000	//Dialog (conversation)[conversation text:0x1E5A Pay G  to repair?](TEXTSTART+TEXTSHOW+TEXTEND+REMA)
4005070001000000410C00900C000700	//Imm BNE (If Result != [Value:0x1], Then Jump to [Conditional ID:0x9000], Else execute following)
400D551F0DB11708	//Get [Unit:0x55 Jorah]'s [Status:0x1F Item 1 piece] of unit
2006C200	//Copy memory slot C to memory slot 2(MOV VAL_2,VAL_C / SADD)
400D071F1DA15109	//Set [Unit:0x7 Andre]'s [Status:0x1F Item 1 piece] to SVAL2(LOW)
20064300	//SADD[PackedMemorySlot:0x43 Slot3=Slot4+Slot0]
22370000	//GIVETOSLOT3(LOW)
20090090	//GOTO[Conditional ID:0x9000]
20085097	//LABEL[Conditional ID:0x9750]
201A0000201B591E201D0000221B0000	//Dialog (conversation)[conversation text:0x1E59 Hey! These money are](TEXTSTART+TEXTSHOW+TEXTEND+REMA)
20080090	//LABEL[Conditional ID:0x9000]
2E345500	//[Character:0x55 Jorah]Erase (kill) unit without death SFX(DISA_IF)
2802070020010000	//Event end(also serves as a section to no fade)(EVBIT_T+ENDA)

Copy this into a .txt file and import it with febuilder.

Edit: Realized I forgot to actually charge the player.

Also I see that you have a store in your transport unit. Sme has an ASM hack for this if you prefer.

[ASM] Shop Unit (FE8)

3 Likes