Re: TIB: Another question about my RPG...


[Prev][Next][Index][Thread]

Re: TIB: Another question about my RPG...




In a message dated 11/16/98 8:16:11 PM Central Standard Time, Tatsuo64@aol.com
writes:

> I know I ask a lot of questions, but I really want to do this RPG and I've
>  never done much in the way of graphics.  Heres my problem today(sigh)...
>  I've decided to use strings to save my levels, using the sub(  command to
>  write a piece of it onto the screen: sub(Str1,1,16).  Keep in mind I use an
>  83.  I don't understand how to interact where my character is in 
> relationship
>  to what's on screen.  Like right now, I want to make a certain spot on the
>  screen bring up a fight when the character steps on it.  Thanks to anyone 
> who
>  can help.  
>  Tatsuo

Assuming you want to have more than one fight square, you could easily make a
two by (num fight squares) matrix with the first col as the x coordinate and
the second as the y coordinate of thefight.  Better still you could have a
three by (num of ''special squares'') and have the third col be a number to
tell you if it's a fight or an item or whatever.  Once you have this you check
if the (x,y) of the player equals one of the (x,y) in the matrix.  On second
thought, it would be best to have a two col matrix and then you could use a
for loop to search one by two submatrices (a single (x,y)) and find if any
equal the player's current pos.  Then a list could take the place of the third
col.  Hope this doesn't confuse you; if it does just write back with
questions.
Paul J Chase II