Jump to content

Doors... And possibly chests


Gradivus
 Share

Recommended Posts

I've enclosed a copy of my (incomplete) chapter events, and a picture of the map for the chapter. I have two units appear in the bottom left room on turn 2, one of which is a thief, with a lockpick. The option "Door" comes up, the sound plays, but the door remains unlocked. I have also been unable to get by the broken wall in the upper right portion of the map, even if I "break" it.

Am I missing out on something big here?

Prolougue Events OF.txt

Prologue Mapscrn.BMP

Link to comment
Share on other sites

org 0xC9C9CC+(4*0x0E)

is 0x0E the right event ref?

TileMap(0x00,0x03,0x14,0x01,0x01,SmallDoor)

are those the right co-ordinates (3,20)? Just making sure you accounted for the hex part

Also, walls need tile-changes too. Also remember not to just change the one tile that's being broken, but also to change the tiles around the breakable wall to the appropriate tiles (keep in mind how walls look when the door is open and not-opened, and any floor shading that might be present).

and the EA isn't giving out any errors, is it?

Link to comment
Share on other sites

Thanks, now I have a few more questions.

I don't exactly understand what to put in the spot where I put 0x0E, I just copied what Arch put in his tutorial. How do you determine what to put there?

For the TileMap(0x00,0x03,0x14,0x01,0x01,SmallDoor), would the second and third values be the x and y points, making the door at 3,14? If not, how did you get 3,20?

Where I have labelled "SmallDoor" in the string above, what would I put for a broken wall? How would I change how much "HP" it has?

And the EA was not giving out any errors.

Thanks for your help, I apologize for my lack of knowledge.

Link to comment
Share on other sites

0x14 is not the same as 14. The 0x prefix indicates a hexidecimal value (base 16), which means that 1 is actually counting as +16 to the value.

14 in hex would be 0x0E, which I believe is what you want. [EDIT: corrected hex number. Doh!]

Edited by Meteor
Link to comment
Share on other sites

According to Arch's tutorial, it says this. TileMap(TCN,X1,Y1,L1,L2,TilePointer) In his video, he says that X1 is the X co-ordinate of the door, and Y1 is the Y co-ordinate. For a door he had at 7,3, he had the X1 value as 0x07, and the Y1 value as 0x03. Or did he do something that I was unaware of?

Edited by Gradivus
Link to comment
Share on other sites

Read the tutorial >_> 2nd and 3rd bytes are X and Y co-ordinates of the top-left tile to change, yes. It is NOT necessarily the tile where the door or location event is.

"SmallDoor" is just a name to a pointer to tiles. For a breakable wall, you could call it whatever (e.g. BreakableWall) and have a list of tiles for that area of the map that has to change (you'd change it to an open wall, of course). Just remember that if the area being changed isn't 1 tile, change the 3rd and 4th bytes accordingly (which control how large horizontally (X) and vertically (Y) the area is, respectively).

(0x03,0x14) is another way of saying (3,20). You can use MS calculator or google to convert from decimal (base 10) to hexadecimal (base 16).

And, as a general rule, don't copy examples and expect them to work. Ever. Examples are just to show you how something works, and are for a specific case, and it's highly unlikely that case is the same as yours. Just saying to make it easier on yourself, no offense or anything.

I apologize for my lack of knowledge.

lol, IMO (not that anyone asked), that's not something to apologize for, unless you don't try and fix that lack of knowledge since we aren't born knowing everything

EDIT: Responding to the above post that I missed^

hopefully I cleared up Arch's mistake, X co-ordinate is of top-left tile, which may or may not be the door, depending on how big the area of your tile change is (same for Y)

0x07 = 7, 0x03 = 3, but 0x10 != 10, I guess you assumed that all hexadecimal is is adding the '0x' because he didn't use co-ordinates that had numbers greater than 10 in decimal, but nah, 0x0A = 10, and 0x10 = 16, and if you can't convert in your head, then use MS calc or google or something else, like I said. ^_^

Edited by Luffy
Link to comment
Share on other sites

Thanks a lot, you cleared up the whole hexadecimal thing for me. I finally understand.

is 0x0E the right event ref?

As stupid as this sounds, how do you find the event ref? That may be the final problem, I'll enclose my updated txt files so you can see what i've done wrong.

Prolougue Events OF.txt

tilesprologue.txt

Edited by Gradivus
Link to comment
Share on other sites

Go into Nightmare and the Chapter Data Editor.

Remember where you found the 0x06 (or whatever) that points to the events for the chapter? Look for something like that, except it will say "Chapter __ Tile Changes" or whatever.

Link to comment
Share on other sites

In the Chapter Data Editor? I couldn't find anything that resembled Chapter Tiles Changes, unless you are referring to the Triggerable Map changes. Any value except 0x0E causes the game to crash before loading the prologue, so I believe that is right, I just don't know why :/

Link to comment
Share on other sites

0x0E Ch.2 Map Changes

Yes, that's right. Map changes, tile changes, same thing. "Triggerable" just means that the tile changes are caused (triggered) by some event (like the 'door' or 'chest' codes...).

Hope that clears things up.

Link to comment
Share on other sites

So, wait, how come I have to use the code for the Ch.2 Map changes for the Prologue? Is it because originally, the Prologue and Chapter 1 have no doors/breakable walls/chests? Or do I have to replace chapter 2's Map?

And for whatever reason, it still will not work.

[spoiler=Events]

//Made by markyjoe1990 of Youtube

//Modified by Nintenlord

#define DISABLE_TUTORIALS

#include EAstdlib.event

EventPointerTable(0x06,Pointers)

org 0xD80000

Pointers:

POIN Turn_events

POIN Character_events

POIN Location_events

POIN Misc_events

POIN BallistaData BallistaData

POIN Bad Bad Bad Bad

POIN Good Good Good Good

POIN Opening_event Ending_event

Bad:

UNIT Batta Paladin 0x00 Level(4,Enemy,True) [12,2] [12,2] [silverSpear,Vulnerary]

[0x00,0x00,0x00,0x00]

UNIT Bandit Knight 0x87 Level(3,Enemy,True) [12,14] [12,14] [steelSpear]

[0x00,0x00,0x00,0x00]

UNIT Bandit Archer 0x87 Level(3,Enemy,True) [22,16] [22,16] [steelBow]

[0x00,0x00,0x00,0x00]

UNIT Bandit Cavalier 0x87 Level(3,Enemy,True) [20,9] [20,9] [steelSpear]

[0x00,0x00,0x00,0x00]

UNIT Bandit Cavalier 0x87 Level(5,Enemy,True) [22,9] [22,9] [steelSpear,Javelin]

[0x00,0x00,0x00,0x00]

UNIT Bandit Knight 0x87 Level(3,Enemy,True) [19,3] [19,3] [steelSpear]

[0x00,0x00,0x00,0x00]

UNIT Bandit Knight 0x87 Level(3,Enemy,True) [21,3] [21,3] [steelSpear]

[0x00,0x00,0x00,0x00]

UNIT Bandit Archer 0x87 Level(2,Enemy,True) [12,8] [12,8] [ironBow]

[0x00,0x00,0x00,0x00]

UNIT Bandit Knight 0x87 Level(5,Enemy,True) [12,3] [12,5] [silverSpear,ShortSpear]

[0x00,0x00,0x00,0x08]

UNIT Empty

Good:

UNIT Hector HectorLord 0x00 Level(1,Ally,False) [12,15] [12,15] [ironAxe,Vulnerary]

[0x00,0x00,0x00,0x00]

UNIT Empty

Reinforcements:

UNIT Kent_t Cavalier 0x00 Level(3,Ally,False) [2,16] [2,16]

[KillingEdge,Javelin,IronSpear,Vulnerary] [0x00,0x00,0x00,0x00]

UNIT Matthew Thief 0x00 Level(2,Ally,False) [3,16] [3,15]

[steelSword,LanceReaver,LockPick,WolfBeil] [0x00,0x00,0x00,0x00]

UNIT Empty

EnemyReinforcements:

UNIT Bandit Cavalier 0x87 Level(5,Enemy,True) [11,19] [11,19] [ironSpear]

[0x00,0x00,0x00,0x00]

UNIT Bandit Cavalier 0x87 Level(7,Enemy,True) [12,19] [12,19] [silverSpear]

[0x00,0x00,0x00,0x00]

UNIT Bandit Cavalier 0x87 Level(5, Enemy,True) [13,19] [13,19] [ironSpear]

[0x00,0x00,0x00,0x00]

UNIT Empty

Turn_events:

TURN 0x00 Opening_event [01,00] 0x0 0x00

TURN 0x00 Turn2 [02,00] 0x0 0x00

TURN 0x00 Turn5 [05,00] 0x8 0x00

CODE $00

Character_events:

CODE $00

Location_events:

Door(3,14)

Door(3,5)

Door(12,6)

Chest(Elixir,4,2)

Chest(HandAxe,2,2)

CODE $00

Misc_events:

CauseGameOverIfLordDies

CODE $00

Opening_event:

CURF [12,15]

FADI 10

BACG 0x12

FADU 10

TEX1 0x0800

REMA

LOU1 Good

ENUN

MOVE Hector [12,17]

ENUN

LOU1 Bad

ENUN

TEX1 0x0801

REMA

ENDA

Turn2:

MUS1 0x0042

LOU1 Reinforcements

ENUN

TEX1 0x0802

REMA

ENDA

Turn5:

LOU1 EnemyReinforcements

ENUN

ENDA

Ending_event:

//MNCH 0x??

//STAL 1

//_0x1

//ENDA

BallistaData:

BLST

[spoiler=TileChanges]

//Prologue Map Changes

#define TileMap(TCN,X1,X2,L1,L2,TilePointer) "CODE TCN X1 X2 L1; CODE L2 0x00 0x00 0x00; POIN TilePointer"

org 0xC9C9CC+(4*0x0E)

POIN TileChanges

org 0xD801A0

TileChanges:

TileMap(0x00,0x03,0x0E,0x01,0x01,SmallDoor)

TileMap(0x01,0x03,0x05,0x01,0x01,SmallDoor)

TileMap(0x02,0x0C,0x06,0x01,0x01,SmallDoor1)

TileMap(0x03,0x04,0x02,0x01,0x01,ChestOpened)

TileMap(0x04,0x02,0x02,0x01,0x01,ChestOpened)

CODE $FF

CODE $00

CODE $00

SmallDoor:

CODE 0x80 0x07 0x00 0x00

CODE $00

SmallDoor1:

CODE 0x00 0x07 0x00 0x00

CODE $00

ChestOpened:

CODE 0x04 0x00 0x00 0x00

CODE $00

MESSAGE Map changes end at offset currentOffset

I believe I have done everything right, but it still will not work. There has to be something wrong somewhere in the above code, I just don't know what it is. I would be greatly appreciated if someone could find the mistake.

Link to comment
Share on other sites

Your doors are 1x1 but you coded them as 1x2

Could be an issue, since I'm pretty sure 0x00 0x00 is another tile

Scratch that, EVERYTHING you coed is only 1x1(doors and chests) and they are all coded as 1x2. try fixing that and see what you get.

These aren't vertical doors right? They are coded differently btw

Edited by Hero of Time
Link to comment
Share on other sites

I just assumed you were on chapter 2, but yeah, as you said, p/ch1 don't have map changes, so you just have to use the next one in the list. However, that also means you have to update the triggerable map changes byte in the Chapter Data Editor, or else the game wont know which map changes to do.

Which, by the way, might be part of your problem, if it's not the only problem left altogether

(btw, IIRC the EA doesn't like those line breaks in the middle of UNIT data, isn't it giving errors? or am I remembering wrong?)

Link to comment
Share on other sites

@ Hero of Time, when you said coded 1x2, do you mean the bolded part below? Or am I just misunderstanding you? All the doors are horizontal, as shown in the map in the OP

SmallDoor:

CODE 0x80 0x07 0x00 0x00

CODE $00

@ Luffy, you mean change the triggerable map changes in the Chapter Data Editor of Nightmare for the Prologue, to 0x0E, right? And those line breaks aren't actually there, they just showed up when I copied/pasted for some reason. No errors.

Edited by Gradivus
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...