ec2
, assuming that this number exists only once inside of the matrix...
cause that
y would u need to extract a number from a matrix?
Collision detection I assume.
exactly! :)
so... anyone knows?
still, y would u need collusion detection in battle system? unless the character moves, then just assign the char (x,y) variables like in walking engine?
on a side note: one solution would be to also make a string version of the matrix, then use the command instring(.
He has multiple characters moving around the screen in his battle engine and I'm assuming he's using this so they don't run into eachother. I don't really have any ideas.
QuoteBegin-tenniskid493+8 January 2006, 0:28-->QUOTE (tenniskid493 @ 8 January 2006, 0:28) |
He has multiple characters moving around the screen in his battle engine and I'm assuming he's using this so they don't run into eachother. |
That
ok, now i understand, here's one method u can use to get location of certain stuff. When u create the matrix used for battle, also create a string version of that matrix. For instance:
[[1,1,1,1]]
[[1,0,0,1]]
[[1,0,0,1]]
[[1,1,1,1]]
a string version could be "1111"+"1001"+"1001"+"1111"
if a number is over nine, just use a letter to represent it. Now when u want to find specific location of a certain number, just use instring(str1,"(object)",1. This will give the location in string of the object ur looking for. Now just convert that number into (x,y) coordinates of matrix. hope i helped ;)
Yay, thx dragon__lance!
*startsexperimenting*