Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

VX: is there a way to identify a particular tile graphic?

Hi. Im on rpg maker VX. Lets say I want to know if $game_player is on top of a tile that is a 'rock' graphic. Is there a way to identify this?

Thank You
 
There is, it's not exactly an easy one though, so if you're doing this more frequently, you may want to write a method for that. Also, I'm sorry I can only be rough here, but I'm not having any maker resources at hand at work (where I am atm), so hopefully, I can help you (or whoever wants to answer as well) out at least somewhat.

First, you have to access the Table (as in, object of Table class... as far as I recall, three-dimensional) that stores the tile data - in other words, the Tilemap. Once you got that, cross-check the values in that Table with your avatar's coordinates on the map, and you have the tile ID. That looks somewhat like '0x23' (aString) or something like that, aka something you again have to cross-check with a value. So, let's say you figured out that your rock tile has the ID '0x23', do a conditional to check for that.

I'm sorry for not being able to get more specific, but it should help somewhat.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top