1161
Updates / Re: Nominations - October 2010
« on: October 31, 2010, 08:51:15 pm »
Yeah, sure. If you want.
Wow I've been nominated. I'm so motivated to get Gismor done now as a thanks to whoever nominated Chiming Bell again so I can release the next boss screenshots
Thanks to whoever nominated my project
Do you have all the creation information defined in the creation event of a room or in a script.
About the keys. It is important that you make a distinction between keys as a reward and as collectibles. Rewards are given by chests and NPC's. During creation it is already checked whether the chest has been opened or not. And when Link opens the chest the chest increases the number of carried keys and sets the appropriate achievement flag (this is what I meant with index). With pots and enemies, they are told when to drop the key. At this moment they check if the key has been retrieved and if not they drop a collectible object that is the key and pass the respective achievement flag. Once Link actually picks up the collectible key the achievement flag is set by the collectible key. Or at least that is how I think about it.
Well, it is difficult to put in GM code, because I don't know exactly what your code is. Thus I'll do it in semi pseudo code But you have the following:
x -> is the number of the current dungeon.
dungeon[x,0] -> number of keys still available to Link
dungeon[x,1] -> temporary status indications that only last as long as Link visits this room cluster.
dungeon[x,2]-[x,4] -> the permanent status of the dungeon.
This is the code to execute a dungeon achievement with the dungeon number and indexCode: Text
flag = ( index div 53 ) + 2 flag_index = index mod 53 dungeon[x,flag] = setFlag(dungeon[x,flag], flag_index); // Set flag already checks whether it is already set or not.
flag = ( index div 53 ) + 2I assume the first two positions have a special function like keeping track of how many variables are effectively stored.
// Small chest info
Chest_Last = 9;
Chest_Opened[0] = 0; Chest_Floor[0] = 4; Chest_X[0] = 48; Chest_Y[0] = 60; Chest_Master[0] = 0;
Chest_Opened[1] = 0; Chest_Floor[1] = 4; Chest_X[1] = 30; Chest_Y[1] = 46; Chest_Master[1] = 0;
Chest_Opened[2] = 0; Chest_Floor[2] = 4; Chest_X[2] = 88; Chest_Y[2] = 46; Chest_Master[2] = 0;
Chest_Opened[3] = 0; Chest_Floor[3] = 4; Chest_X[3] = 72; Chest_Y[3] = 14; Chest_Master[3] = 0;
Chest_Opened[4] = 0; Chest_Floor[4] = 5; Chest_X[4] = 87; Chest_Y[4] = 14; Chest_Master[4] = 0;
Chest_Opened[5] = 0; Chest_Floor[5] = 4; Chest_X[5] = 46; Chest_Y[5] = 12; Chest_Master[5] = 0;
Chest_Opened[6] = 0; Chest_Floor[6] = 3; Chest_X[6] = 71; Chest_Y[6] = 23; Chest_Master[6] = 0;
Chest_Opened[7] = 0; Chest_Floor[7] = 5; Chest_X[7] = 95; Chest_Y[7] = 14; Chest_Master[7] = 0;
Chest_Opened[8] = 0; Chest_Floor[8] = 4; Chest_X[8] = 58; Chest_Y[8] = 43; Chest_Master[8] = 1;
Chest_Opened[9] = 0; Chest_Floor[9] = 3; Chest_X[9] = 34; Chest_Y[9] = 61; Chest_Master[9] = 1;
The first variable tells how many chests exist (for this area). This is mainly done for the creation of the map since you need to know how long you array is. In your solution this is constant so it's no issue, but I can image though that you won't want to loop through 53 possible chests when you only have one.This is code that is executed when Link is opening a chest. Note that each chest has a variable denoting the index of the permanent status and a variable to denote whether it is opened or not:Code: [Select]if !chest.opened
chest.opened = true
give Link the contents and if the contents is a small key dungeon[x,0] += 1
setDungeonAchievement(x, chest.index)
Opening a door is similar. It also has a variable opened and an index. Off course when the door is opened by a switch or dungeon puzzle you don't need to bother with checking keys.Code: [Select]if !door.opened and dungeon[x,0] > 0
door.opened = true
setDungeonAchievement(x, door.index)
decrease the number of small keys dungeon[x,0] -= 1
if !getDungeonAchievement(x, chest.index)
give Link the contents and if the contents is a small key dungeon[x,0] += 1
setDungeonAchievement(x, chest.index)
When you've opened the chest just delete it while leaving the masking. Or turn it invisible, depending on your preference in masking.if !getDungeonAchievement(x, door.index) and dungeon[x,0] > 0
setDungeonAchievement(x, door.index)
decrease the number of small keys dungeon[x,0] -= 1
I don't know what every array is used for with your code and how much objects play a role in your code and maintain status values about themselves. But I do know that a door that is already opened, cannot take a key again and a chest that has already been opened, a pot that has already given a key cannot provide a key. Thus you don't need to check how many keys are still left or keys that are already spent, because either the chest or door has not been opened.
My point is that with true false status indications, using a single number as a boolean array would be better than having long arrays. It saves in used memory, although PC's have already a lot of memory. When saving this data to a file you only need to save a few numbers instead of an entire array.
What I was thinking about permanent stuff is to use a 2D matrix where each row represents a dungeon. The first variable in the row is the number of keys that are collected and not used. You don't really need to use a variable of keys not collected or keys already used, because the flag for the key collection event or the door open is either set or not set. Just like defeating the boss, mini boss, getting the master key, getting the compass, blowing holes, small chest and defeating special enemies and pots for keys. I just think that some boolean variables can be done more generic.
Am I safe to assume that only one tileset is needed per area? Could do things like flipping tiles within the editor. Since tiles can be scaled.
// Dungeon map
for (i=0; i<11; i+=1) {Dungeon_Map_Floors[i] = 0};
Dungeon_Map_Floors[3] = 1;
Dungeon_Map_Floors[4] = 1;
Dungeon_Map_Floors[5] = 1;
// Hero position
Dungeon_Map_Hero_Floor = 0;
Dungeon_Map_Hero_Room = 0;
Dungeon_Map_Hero_X = 0;
Dungeon_Map_Hero_Y = 0;
Dungeon_Map_Hero_Sprite = 0;
// Boss position
Dungeon_Map_Boss_Floor = 3;
Dungeon_Map_Boss_Room = 1;
// Part of item menu
Equipment_C1 = 0;
Equipment_C2 = 0;
Equipment_C3 = 0;
// Number of keys + Collectable keys
Key_Value = 0;
for (i=0; i<=3; i+=1) {Key[i]=0}; // 0 = not collected / 1 = collected
// Small chest info
Chest_Last = 9;
Chest_Opened[0] = 0; Chest_Floor[0] = 4; Chest_X[0] = 48; Chest_Y[0] = 60; Chest_Master[0] = 0;
Chest_Opened[1] = 0; Chest_Floor[1] = 4; Chest_X[1] = 30; Chest_Y[1] = 46; Chest_Master[1] = 0;
Chest_Opened[2] = 0; Chest_Floor[2] = 4; Chest_X[2] = 88; Chest_Y[2] = 46; Chest_Master[2] = 0;
Chest_Opened[3] = 0; Chest_Floor[3] = 4; Chest_X[3] = 72; Chest_Y[3] = 14; Chest_Master[3] = 0;
Chest_Opened[4] = 0; Chest_Floor[4] = 5; Chest_X[4] = 87; Chest_Y[4] = 14; Chest_Master[4] = 0;
Chest_Opened[5] = 0; Chest_Floor[5] = 4; Chest_X[5] = 46; Chest_Y[5] = 12; Chest_Master[5] = 0;
Chest_Opened[6] = 0; Chest_Floor[6] = 3; Chest_X[6] = 71; Chest_Y[6] = 23; Chest_Master[6] = 0;
Chest_Opened[7] = 0; Chest_Floor[7] = 5; Chest_X[7] = 95; Chest_Y[7] = 14; Chest_Master[7] = 0;
Chest_Opened[8] = 0; Chest_Floor[8] = 4; Chest_X[8] = 58; Chest_Y[8] = 43; Chest_Master[8] = 1;
Chest_Opened[9] = 0; Chest_Floor[9] = 3; Chest_X[9] = 34; Chest_Y[9] = 61; Chest_Master[9] = 1;
// Locked Doors
for (i=0; i<=7; i+=1) {Locked_Door[i]=1}; // 0 = open / 1 = closed
// Dungeon resetable values:
// > Conditional Doors
// > Pressure Plates
// > Crash Switches
// > Temp_Dungeon_Condition
// > Fragile Floors
script_Reset_Variables_Dungeon_1();
// Dungeon entrances on map
Last_Entrance_Index = 0;
Entrance_Direction[0] = 90; Entrance_Floor[0] = 5; Entrance_X[0] = 58; Entrance_Y[0] = 100;
// Room info floor B2
Last_Room_Index[3] = 8;
for (i=0; i<=Last_Room_Index[3]; i+=1) {Room_Visible[3,i]=0}; // used for dungeon map
for (i=0; i<=Last_Room_Index[3]; i+=1) {Room_Visit_Count[3,i]=0}; // used for respawning enemies
Room_Sprite_X[3,0]=0; Room_Sprite_Y[3,0]=24; Room_Sprite_W[3,0]=8; Room_Sprite_H[3,0]=8; Room_Sprite_Location_X[3,0]=4+8*3+4; Room_Sprite_Location_Y[3,0]=4+8*7; Room_Xa[3,0]=0; Room_Ya[3,0]=0; Room_Xb[3,0]=320; Room_Yb[3,0]=320;
Room_Sprite_X[3,1]=8; Room_Sprite_Y[3,1]=40; Room_Sprite_W[3,1]=8; Room_Sprite_H[3,1]=8; Room_Sprite_Location_X[3,1]=4+8*3+4; Room_Sprite_Location_Y[3,1]=4+8*8; Room_Xa[3,1]=0; Room_Ya[3,1]=320; Room_Xb[3,1]=320; Room_Yb[3,1]=640;
Room_Sprite_X[3,2]=0; Room_Sprite_Y[3,2]=88; Room_Sprite_W[3,2]=8; Room_Sprite_H[3,2]=8; Room_Sprite_Location_X[3,2]=4+8*3+4; Room_Sprite_Location_Y[3,2]=4+8*9; Room_Xa[3,2]=0; Room_Ya[3,2]=640; Room_Xb[3,2]=320; Room_Yb[3,2]=960;
Room_Sprite_X[3,3]=8; Room_Sprite_Y[3,3]=88; Room_Sprite_W[3,3]=8; Room_Sprite_H[3,3]=8; Room_Sprite_Location_X[3,3]=4+8*4+4; Room_Sprite_Location_Y[3,3]=4+8*9; Room_Xa[3,3]=320; Room_Ya[3,3]=640; Room_Xb[3,3]=640; Room_Yb[3,3]=960;
Room_Sprite_X[3,4]=0; Room_Sprite_Y[3,4]=80; Room_Sprite_W[3,4]=8; Room_Sprite_H[3,4]=8; Room_Sprite_Location_X[3,4]=4+8*5+4; Room_Sprite_Location_Y[3,4]=4+8*9; Room_Xa[3,4]=640; Room_Ya[3,4]=640; Room_Xb[3,4]=960; Room_Yb[3,4]=960;
Room_Sprite_X[3,5]=0; Room_Sprite_Y[3,5]=16; Room_Sprite_W[3,5]=8; Room_Sprite_H[3,5]=8; Room_Sprite_Location_X[3,5]=4+8*6+4; Room_Sprite_Location_Y[3,5]=4+8*9; Room_Xa[3,5]=960; Room_Ya[3,5]=640; Room_Xb[3,5]=1280; Room_Yb[3,5]=960;
Room_Sprite_X[3,6]=32; Room_Sprite_Y[3,6]=0; Room_Sprite_W[3,6]=16; Room_Sprite_H[3,6]=8; Room_Sprite_Location_X[3,6]=4+8*6; Room_Sprite_Location_Y[3,6]=4+8*4+4; // AL -- under construction
Room_Sprite_X[3,7]=32; Room_Sprite_Y[3,7]=24; Room_Sprite_W[3,7]=16; Room_Sprite_H[3,7]=8; Room_Sprite_Location_X[3,7]=4+8*8; Room_Sprite_Location_Y[3,7]=4+8*1; Room_Xa[3,7]=320; Room_Ya[3,7]=0; Room_Xb[3,7]=960; Room_Yb[3,7]=320;
Room_Sprite_X[3,8]=32; Room_Sprite_Y[3,8]=32; Room_Sprite_W[3,8]=16; Room_Sprite_H[3,8]=8; Room_Sprite_Location_X[3,8]=4+8*8; Room_Sprite_Location_Y[3,8]=4+8*2; Room_Xa[3,8]=320; Room_Ya[3,8]=320; Room_Xb[3,8]=960; Room_Yb[3,8]=640;
// Room info floor B1
Last_Room_Index[4] = 29;
for (i=0; i<=Last_Room_Index[4]; i+=1) {Room_Visible[4,i]=0}; // used for dungeon map
for (i=0; i<=Last_Room_Index[4]; i+=1) {Room_Visit_Count[4,i]=0}; // used for respawning enemies
Room_Sprite_X[4,0]=0; Room_Sprite_Y[4,0]=8; Room_Sprite_W[4,0]=8; Room_Sprite_H[4,0]=8; Room_Sprite_Location_X[4,0]=4+8*6+4; Room_Sprite_Location_Y[4,0]=4+8*11; Room_Xa[4,0]=1120; Room_Ya[4,0]=3520; Room_Xb[4,0]=1440; Room_Yb[4,0]=3840;
Room_Sprite_X[4,1]=48; Room_Sprite_Y[4,1]=16; Room_Sprite_W[4,1]=16; Room_Sprite_H[4,1]=16; Room_Sprite_Location_X[4,1]=4+8*6; Room_Sprite_Location_Y[4,1]=4+8*9; Room_Xa[4,1]=1050; Room_Ya[4,1]=2880; Room_Xb[4,1]=1510; Room_Yb[4,1]=3520;
Room_Sprite_X[4,2]=48; Room_Sprite_Y[4,2]=32; Room_Sprite_W[4,2]=16; Room_Sprite_H[4,2]=16; Room_Sprite_Location_X[4,2]=4+8*6; Room_Sprite_Location_Y[4,2]=4+8*6; Room_Xa[4,2]=960; Room_Ya[4,2]=1920; Room_Xb[4,2]=1600; Room_Yb[4,2]=2560;
Room_Sprite_X[4,3]=48; Room_Sprite_Y[4,3]=32; Room_Sprite_W[4,3]=16; Room_Sprite_H[4,3]=16; Room_Sprite_Location_X[4,3]=4+8*6; Room_Sprite_Location_Y[4,3]=4+8*4; Room_Xa[4,3]=960; Room_Ya[4,3]=1280; Room_Xb[4,3]=1600; Room_Yb[4,3]=1920;
Room_Sprite_X[4,4]=24; Room_Sprite_Y[4,4]=16; Room_Sprite_W[4,4]=8; Room_Sprite_H[4,4]=16; Room_Sprite_Location_X[4,4]=4+8*5; Room_Sprite_Location_Y[4,4]=4+8*6; Room_Xa[4,4]=640; Room_Ya[4,4]=1920; Room_Xb[4,4]=960; Room_Yb[4,4]=2560;
Room_Sprite_X[4,5]=16; Room_Sprite_Y[4,5]=32; Room_Sprite_W[4,5]=8; Room_Sprite_H[4,5]=16; Room_Sprite_Location_X[4,5]=4+8*5; Room_Sprite_Location_Y[4,5]=4+8*4; Room_Xa[4,5]=640; Room_Ya[4,5]=1280; Room_Xb[4,5]=960; Room_Yb[4,5]=1920;
Room_Sprite_X[4,6]=024; Room_Sprite_Y[4,6]=0; Room_Sprite_W[4,6]=8; Room_Sprite_H[4,6]=16; Room_Sprite_Location_X[4,6]=4+8*8; Room_Sprite_Location_Y[4,6]=4+8*4; Room_Xa[4,6]=1600; Room_Ya[4,6]=1280; Room_Xb[4,6]=1920; Room_Yb[4,6]=1920;
Room_Sprite_X[4,7]=0; Room_Sprite_Y[4,7]=48; Room_Sprite_W[4,7]=8; Room_Sprite_H[4,7]=8; Room_Sprite_Location_X[4,7]=4+8*8; Room_Sprite_Location_Y[4,7]=4+8*6; Room_Xa[4,7]=1600; Room_Ya[4,7]=1920; Room_Xb[4,7]=1920; Room_Yb[4,7]=2240;
Room_Sprite_X[4,8]=0; Room_Sprite_Y[4,8]=40; Room_Sprite_W[4,8]=8; Room_Sprite_H[4,8]=8; Room_Sprite_Location_X[4,8]=4+8*8; Room_Sprite_Location_Y[4,8]=4+8*7; Room_Xa[4,8]=1600; Room_Ya[4,8]=2240; Room_Xb[4,8]=1920; Room_Yb[4,8]=2560;
Room_Sprite_X[4,9]=8; Room_Sprite_Y[4,9]=80; Room_Sprite_W[4,9]=8; Room_Sprite_H[4,9]=8; Room_Sprite_Location_X[4,9]=4+8*10; Room_Sprite_Location_Y[4,9]=4+8*4; Room_Xa[4,9]=2240; Room_Ya[4,9]=1280; Room_Xb[4,9]=2560; Room_Yb[4,9]=1600;
Room_Sprite_X[4,10]=8; Room_Sprite_Y[4,10]=72; Room_Sprite_W[4,10]=8; Room_Sprite_H[4,10]=8; Room_Sprite_Location_X[4,10]=4+8*10; Room_Sprite_Location_Y[4,10]=4+8*5; Room_Xa[4,10]=2240; Room_Ya[4,10]=1600; Room_Xb[4,10]=2560; Room_Yb[4,10]=1920;
Room_Sprite_X[4,11]=8; Room_Sprite_Y[4,11]=8; Room_Sprite_W[4,11]=8; Room_Sprite_H[4,11]=8; Room_Sprite_Location_X[4,11]=4+8*10; Room_Sprite_Location_Y[4,11]=4+8*6; Room_Xa[4,11]=2240; Room_Ya[4,11]=1920; Room_Xb[4,11]=2560; Room_Yb[4,11]=2240;
Room_Sprite_X[4,12]=0; Room_Sprite_Y[4,12]=64; Room_Sprite_W[4,12]=8; Room_Sprite_H[4,12]=8; Room_Sprite_Location_X[4,12]=4+8*10; Room_Sprite_Location_Y[4,12]=4+8*7; Room_Xa[4,12]=2240; Room_Ya[4,12]=2240; Room_Xb[4,12]=2560; Room_Yb[4,12]=2560;
Room_Sprite_X[4,13]=64; Room_Sprite_Y[4,13]=0; Room_Sprite_W[4,13]=8; Room_Sprite_H[4,13]=36; Room_Sprite_Location_X[4,13]=4+8*9; Room_Sprite_Location_Y[4,13]=4+8*4-2; Room_Xa[4,13]=1920; Room_Ya[4,13]=1280; Room_Xb[4,13]=2240; Room_Yb[4,13]=2560;
Room_Sprite_X[4,14]=64; Room_Sprite_Y[4,14]=36; Room_Sprite_W[4,14]=8; Room_Sprite_H[4,14]=36; Room_Sprite_Location_X[4,14]=4+8*4; Room_Sprite_Location_Y[4,14]=4+8*4-2; Room_Xa[4,14]=320; Room_Ya[4,14]=1280; Room_Xb[4,14]=640; Room_Yb[4,14]=2560;
Room_Sprite_X[4,15]=24; Room_Sprite_Y[4,15]=16; Room_Sprite_W[4,15]=8; Room_Sprite_H[4,15]=16; Room_Sprite_Location_X[4,15]=4+8*3; Room_Sprite_Location_Y[4,15]=4+8*6; Room_Xa[4,15]=0; Room_Ya[4,15]=1920; Room_Xb[4,15]=320; Room_Yb[4,15]=2560;
Room_Sprite_X[4,16]=8; Room_Sprite_Y[4,16]=48; Room_Sprite_W[4,16]=8; Room_Sprite_H[4,16]=8; Room_Sprite_Location_X[4,16]=4+8*3; Room_Sprite_Location_Y[4,16]=4+8*5; Room_Xa[4,16]=0; Room_Ya[4,16]=1600; Room_Xb[4,16]=320; Room_Yb[4,16]=1920;
Room_Sprite_X[4,17]=8; Room_Sprite_Y[4,17]=24; Room_Sprite_W[4,17]=8; Room_Sprite_H[4,17]=8; Room_Sprite_Location_X[4,17]=4+8*3; Room_Sprite_Location_Y[4,17]=4+8*4; Room_Xa[4,17]=0; Room_Ya[4,17]=1280; Room_Xb[4,17]=320; Room_Yb[4,17]=1600;
Room_Sprite_X[4,18]=0; Room_Sprite_Y[4,18]=104; Room_Sprite_W[4,18]=48; Room_Sprite_H[4,18]=8; Room_Sprite_Location_X[4,18]=4+8*4; Room_Sprite_Location_Y[4,18]=4+8*3; Room_Xa[4,18]=320; Room_Ya[4,18]=960; Room_Xb[4,18]=2240; Room_Yb[4,18]=1280;
Room_Sprite_X[4,19]=0; Room_Sprite_Y[4,19]=96; Room_Sprite_W[4,19]=48; Room_Sprite_H[4,19]=8; Room_Sprite_Location_X[4,19]=4+8*4; Room_Sprite_Location_Y[4,19]=4+8*8; Room_Xa[4,19]=320; Room_Ya[4,19]=2560; Room_Xb[4,19]=2240; Room_Yb[4,19]=2880;
Room_Sprite_X[4,20]=32; Room_Sprite_Y[4,20]=8; Room_Sprite_W[4,20]=16; Room_Sprite_H[4,20]=8; Room_Sprite_Location_X[4,20]=4+8*8; Room_Sprite_Location_Y[4,20]=4+8*2; Room_Xa[4,20]=1600; Room_Ya[4,20]=640; Room_Xb[4,20]=2240; Room_Yb[4,20]=960;
Room_Sprite_X[4,21]=0; Room_Sprite_Y[4,21]=24; Room_Sprite_W[4,21]=8; Room_Sprite_H[4,21]=8; Room_Sprite_Location_X[4,21]=4+8*8; Room_Sprite_Location_Y[4,21]=4+8*1; Room_Xa[4,21]=1600; Room_Ya[4,21]=320; Room_Xb[4,21]=1920; Room_Yb[4,21]=640;
Room_Sprite_X[4,22]=0; Room_Sprite_Y[4,22]=24; Room_Sprite_W[4,22]=8; Room_Sprite_H[4,22]=8; Room_Sprite_Location_X[4,22]=4+8*9; Room_Sprite_Location_Y[4,22]=4+8*1; Room_Xa[4,22]=1920; Room_Ya[4,22]=320; Room_Xb[4,22]=2240; Room_Yb[4,22]=640;
Room_Sprite_X[4,23]=32; Room_Sprite_Y[4,23]=16; Room_Sprite_W[4,23]=16; Room_Sprite_H[4,23]=8; Room_Sprite_Location_X[4,23]=4+8*4; Room_Sprite_Location_Y[4,23]=4+8*2; Room_Xa[4,23]=320; Room_Ya[4,23]=640; Room_Xb[4,23]=960; Room_Yb[4,23]=960;
Room_Sprite_X[4,24]=0; Room_Sprite_Y[4,24]=72; Room_Sprite_W[4,24]=8; Room_Sprite_H[4,24]=8; Room_Sprite_Location_X[4,24]=4+8*4; Room_Sprite_Location_Y[4,24]=4+8*1; Room_Xa[4,24]=320; Room_Ya[4,24]=320; Room_Xb[4,24]=640; Room_Yb[4,24]=640;
Room_Sprite_X[4,25]=16; Room_Sprite_Y[4,25]=48; Room_Sprite_W[4,25]=8; Room_Sprite_H[4,25]=16; Room_Sprite_Location_X[4,25]=4+8*5; Room_Sprite_Location_Y[4,25]=4+8*0; Room_Xa[4,25]=640; Room_Ya[4,25]=0; Room_Xb[4,25]=960+24; Room_Yb[4,25]=640;
Room_Sprite_X[4,26]=32; Room_Sprite_Y[4,26]=8; Room_Sprite_W[4,26]=16; Room_Sprite_H[4,26]=8; Room_Sprite_Location_X[4,26]=4+8*6; Room_Sprite_Location_Y[4,26]=4+8*2; Room_Xa[4,26]=960; Room_Ya[4,26]=640; Room_Xb[4,26]=1600; Room_Yb[4,26]=960;
Room_Sprite_X[4,27]=24; Room_Sprite_Y[4,27]=32; Room_Sprite_W[4,27]=8; Room_Sprite_H[4,27]=16; Room_Sprite_Location_X[4,27]=4+8*7; Room_Sprite_Location_Y[4,27]=4+8*0; Room_Xa[4,27]=1280; Room_Ya[4,27]=0; Room_Xb[4,27]=1600; Room_Yb[4,27]=640;
Room_Sprite_X[4,28]=0; Room_Sprite_Y[4,28]=24; Room_Sprite_W[4,28]=8; Room_Sprite_H[4,28]=8; Room_Sprite_Location_X[4,28]=4+8*6; Room_Sprite_Location_Y[4,28]=4+8*1; Room_Xa[4,28]=960; Room_Ya[4,28]=320; Room_Xb[4,28]=1280; Room_Yb[4,28]=640;
Room_Sprite_X[4,29]=0; Room_Sprite_Y[4,29]=16; Room_Sprite_W[4,29]=8; Room_Sprite_H[4,29]=8; Room_Sprite_Location_X[4,29]=4+8*8; Room_Sprite_Location_Y[4,29]=4+8*0; Room_Xa[4,29]=1600; Room_Ya[4,29]=0; Room_Xb[4,29]=1920; Room_Yb[4,29]=320;
// Room info floor F1
Last_Room_Index[5] = 5;
for (i=0; i<=Last_Room_Index[5]; i+=1) {Room_Visible[5,i]=0}; // used for dungeon map
for (i=0; i<=Last_Room_Index[5]; i+=1) {Room_Visit_Count[5,i]=0}; // used for respawning enemies
Room_Sprite_X[5,0]=8; Room_Sprite_Y[5,0]=64; Room_Sprite_W[5,0]=8; Room_Sprite_H[5,0]=8; Room_Sprite_Location_X[5,0]=4+8*9; Room_Sprite_Location_Y[5,0]=4+8*1; Room_Xa[5,0]=0; Room_Ya[5,0]=0; Room_Xb[5,0]=320; Room_Yb[5,0]=320;
Room_Sprite_X[5,1]=0; Room_Sprite_Y[5,1]=64; Room_Sprite_W[5,1]=8; Room_Sprite_H[5,1]=8; Room_Sprite_Location_X[5,1]=4+8*10; Room_Sprite_Location_Y[5,1]=4+8*1; Room_Xa[5,1]=320; Room_Ya[5,1]=0; Room_Xb[5,1]=640; Room_Yb[5,1]=320;
Room_Sprite_X[5,2]=0; Room_Sprite_Y[5,2]=64; Room_Sprite_W[5,2]=8; Room_Sprite_H[5,2]=8; Room_Sprite_Location_X[5,2]=4+8*11; Room_Sprite_Location_Y[5,2]=4+8*1; Room_Xa[5,2]=640; Room_Ya[5,2]=0; Room_Xb[5,2]=960; Room_Yb[5,2]=320;
Room_Sprite_X[5,3]=32; Room_Sprite_Y[5,3]=0; Room_Sprite_W[5,3]=16; Room_Sprite_H[5,3]=8; Room_Sprite_Location_X[5,3]=4+8*6; Room_Sprite_Location_Y[5,3]=4+8*11; Room_Xa[5,3]=0; Room_Ya[5,3]=960; Room_Xb[5,3]=640; Room_Yb[5,3]=1280;
Room_Sprite_X[5,4]=24; Room_Sprite_Y[5,4]=48; Room_Sprite_W[5,4]=8; Room_Sprite_H[5,4]=16; Room_Sprite_Location_X[5,4]=4+8*7; Room_Sprite_Location_Y[5,4]=4+8*6; // AS -- under construction
Room_Sprite_X[5,5]=48; Room_Sprite_Y[5,5]=48; Room_Sprite_W[5,5]=16; Room_Sprite_H[5,5]=16; Room_Sprite_Location_X[5,5]=4+8*6; Room_Sprite_Location_Y[5,5]=4+8*4; // I -- under construction
// Is digging possible in this room
for (i=0; i<=Last_Room_Index[3]; i+=1) {Diggable[3,i]=0};
for (i=0; i<=Last_Room_Index[4]; i+=1) {Diggable[4,i]=0};
for (i=0; i<=Last_Room_Index[5]; i+=1) {Diggable[5,i]=0};
// Permanent dungeon conditions
for (i=0; i<=2; i+=1) {Permanent_Dungeon_Condition[i]=0};
// [0]: 0/1 = chest in room 21 [B1] has (not yet) appeared
// [1]: 0/1 = stairs in room 1 [F1] have (not yet) appeared
// [2]: 0/1 = master chest in room 3 [F1] has (not yet) been opened yet
// Breakable walls
for (i=0; i<=1; i+=1) {Breakable_Wall[i]=0}; // (0 = invisible / 1 = visible / 2 = broken)
// Tiledata
Translate_Room_Index[floor#, room#] = room2#
Room_Tile_Bg_X[room2#, tile#] = ##
Room_Tile_Bg_Y[room2#, tile#] = ##
Room_Tile_Bg_W[room2#, tile#] = ##
Room_Tile_Bg_H[room2#, tile#] = ##
Room_Tile_X[room2#, tile#] = ##
Room_Tile_Y[room2#, tile#] = ##
Room_Tile_Depth[room2#, tile#] = ##
Room_Tile_Finished[floor#, room#] = ##
Gamemaker can only handle two dimensional arrays so I'll have to use a workaround. Which is where the translation comes in. Basically tiles are stored per room in the area level.// TESTCASE: tile creation
for (argument[13] = 0; argument[13] < 320/8*9; argument[13] += 1)
{
for (argument[14] = 0; argument[14] < 320/8; argument[14] += 1)
{
tile_add(tileset_Dungeon_01,0,0,8,8,900,900,-99999);
};
};