PDA

View Full Version : tile detection


LilbrojX
06-06-2001, 07:37 AM
I'm confoosed.... I'm making this tight status npc, that has status effects and everything! but I need to know wut the scrpit is for tile detection... a lil help? thanks all :D

KJS
06-06-2001, 07:40 AM
in the search on this messageboard
do a search for
board

board is the array you have to use for updating the tiles on a level....
I am not sure how to use it off the top of my head but there are a few good examples on this forum if you just do a search for it

LilbrojX
06-06-2001, 07:43 AM
thx kjl:D

grim_squeaker_x
06-06-2001, 06:10 PM
Well basically:
board[x+64*y] (where x and y are the x and y locations of the tile) will return what kind of tlie the tile is...
To change it you can for example use:
board[x+64*y]=tilex+16*tiley; (tilex and tiley can be checked when placing new tiles, it'll appear under the place where pics1.png is drawn if you've got tiles open, just keep your mouse pointer over a tile in that pics1.png and the tilex and tiley should appear)
Then to make the change visible you'd need to do:
updateboard x,y,width height;
And I have such a feeling I'm causing more confusion now then you had before.

T-Squad
06-07-2001, 08:42 PM
bah...im disapointed W-Dragoon, you shouldve asked me ;-)

board[int(x)+64*int(y)]==tilex+tiley*16

just use that...dont worry about what it does ;-) just fill in the blanks...you can use the for if statements and all those other nice things, and for replacing tiles...if you replace a tile you must use

updateboard x,y,width,height

W-Dragoon if you cant figure it out send me the script and i will finish it...