Jump to content
  • 0

What is causing chests to already be open in dungeons?


giadrosich
 Share

Question

Okay. I'm getting chests that are already open for some reason in my rom. I've been doing a route test checking to make sure everything is in the right place, ect. But in Jabu-Jabu and in Bottom of the Well, I've run across the dungeon item chest that is already open. I started this file on a fresh new rom with the modifications, did nothing on the first file but make a name, started the second file and went straight to the chest without doing anything.

 

What the heck is going on?

 

In the video I only show bottom of the well, but the same thing happens in Jabu.

 

In the well, you are supposed to get the Megaton Hammer, and in Jabu you're supposed to get the hookshot. They just aren't there.

 

Is there something wrong with the coding? I've double checked the chests and even tried to spawn a new hookshot chest in Jabu, but it spawned already open. I have no idea what's going on or how to fix it. :/


Here is a video of starting the file and getting to the chest.

 

http://www.youtube.com/watch?v=Pw3VO2vyIFk Skip to 5:31 if you don't want to see the long shenanigans to get into the well.

 

Edit: I'm using chest actor 000A and variable B1A0 because you have to spawn it by hitting the switch at the bottom of the well.

Link to comment
Share on other sites

Recommended Posts

  • 0

Took a look at my program that reads actor information off of the rom and cross referenced it to my scene flag data, so this is just an educated guess01B4's variable seems to have two partsXXYYXX may be the flag the block binds toYY i don't know but it's commonly set to 01

Link to comment
Share on other sites

  • 0

Switches Explanation

 

Say you wanted to attach a transparent platform with a timer to a switch flag of 0x38. Say you wanted the switch that that switch flag is tied to to be a eye switch ("that that", "to to" haha...).

 

Setting up the switch...

 

Actor Number: 0x012A

Variable Format: XXZY

 

XX = Switch Flag

Z = Switch Mechanics

Y = Switch Style

 

'XX' is easy to explain; it's our two digit switch flag (0x38).

 

'Z' is probably the trickiest part of the variable. Each "digit" in hexidecimal is made up of 4 bits. I'm talking about binary bits. This means values of only 1 and 0. So think of Z as being broken up into 4 checkboxes:

 

[][][][]

 

Whenever we fill a checkbox, we replace it with a 1. Whenever we leave a checkbox empty, we replace it with a 0. Here is the significance of each checkbox (starting with the leftmost bit):

 

1 = Switch is frozen in ice

2 = Unknown. Just leave unchecked

3 = Switch activates when not stood on (floor and rusted only)

4 = Switch can be turned on and off

 

Say we wanted our our switch to be frozen and it could be turned on and off. The 'Z' aspect of the variable would have a binary representation of 1001. The hexidecimal conversion of 1001 is 0x9. In case you aren't familiar with how to convert from binary to hexidecimal, here's a conversion chart:

 

0000 = 0x0

0001 = 0x1

0010 = 0x2

0011 = 0x3

0100 = 0x4

0101 = 0x5

0110 = 0x6

0111 = 0x7

1000 = 0x8

1001 = 0x9

1010 = 0xA

1011 = 0xB

1100 = 0xC

1101 = 0xD

1110 = 0xE

1111 = 0xF

 

... But in our case, we don't want our switch to have any special mechanics or external properties so we leave Z as 0x0. Don't know why I bothered explaining that...

 

'Y' is easy to understand. It's the type of switch that you'll be using. Here's a list of values:

 

0 = Floor switch

1 = Rusted switch

2 = Eye switch

3 = Crystal switch

4 = Targetable crystal switch

 

We want an eye switch, so we'll set 'Y' to be equal to 2.

 

In the end, we would end upwith this as our switch variable: 0x3802

 

Make sure that the special object 0x0003 (gameplay_dangeon_keep) is loaded by checking the 0x07 scene header command.

 

Now, it's time to explain the transparent platform (with a timer) actor... We will be using two actors. One actor is for the transparent platform and the other is for the timer. If we didn't want a timer then we would only use the transparent platform actor.

 

Setting up the transparent platform...

 

Actor Number: 0x01B4

Actor Variable: XX01

 

'XX' would be the switch flag (0x38). Our variable would end up as: 0x3801

 

Setting up the timer...

 

Actor Number: 0x01B4

Actor Variable: XX02

 

'XX' would be the switch flag (0x38). Our variable would end up as: 0x3802

 

Both the transparent platform and its timer use object 0x01B4 so make sure that it is loaded.

 

In the end, our setup would work like this... When our switch will go off, our timer will start, and then our platforms will be visible and solid.

 

Sources:

http://wiki.spinout182.com/w/Maps_and_Scenes

 

http://wiki.spinout182.com/w/Modification_and_Addition_of_Switches#Basic_Switch

 

http://wiki.spinout182.com/w/Modification_and_Addition_of_Switches#Transparent_Platform_Timer

 

http://wiki.spinout182.com/w/Modification_and_Addition_of_Switches#Transparent_Platform

  • Like 1
Link to comment
Share on other sites

  • 0

I got the switch to work out perfectly with your explanation, Jason, thank you! I had to get my husband to explain binary code to me, and I finally "sort of" get it.

 

Thanks for the simple and detailed instructions on how you came to your conclusion, that helped a lot.

 

One more simple question, with the variable of 3801 on the transparent platform, can one change the last two digits or just the last digit to make sure it doesn't line up with anything else in the dungeon appearing? Such as changing it to 3804, 3805, ect.

Link to comment
Share on other sites

  • 0

The 38 portion of the variable is what binds your platform to a specific switch flag (in this case, a room local flag), and what you really have to make sure doesn't conflict with any switches. The 01 only probably changes some property of the actor itself, so setting it to 2 or 5 may not make it load correctly.

Link to comment
Share on other sites

  • 0

mzx is right when he says that you only have to keep an eye on the 'XX' portion of the variable. Switch flags are the only thing you need to pay attention to in dungeons to make sure that aren't already being used in another room or switch in the dungeon. In our case we used a local switch flag that clears ever single time you exit a room which uses it. This means that we can use it in more than one room as long as two rooms who use that switch flag aren't right next to each other (meaning you can't walk into one room which uses that switch flag from a room that uses the same switch flag); this also applies to any type of switch flag.

 

http://wiki.spinout182.com/w/Modification_and_Addition_of_Switches#Switch_Flags

  • Like 1
Link to comment
Share on other sites

 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.