Robuck
Experienced Member
Hello,
I don’t know how well I can explain this, but I will try. I am fairly new to programming, and I’m making a small text graphics roguelike game. So far I have the movement and stuff set up, but my biggest hurdle is collisions. I had the idea to log the players position into a “memory” variable, so that whenever the player is in a spot he shouldn’t be, it sets is position to the one in memory. This works great! But it is very tedious to write out an if command to check if the player is colliding with something for almost every space that I need. My idea is to just draw out the map, and check if the spot the player is about to jump to is a wall, and of course send him back if it is. Basically I need a command that can check what character is at a specific point, using the text coordinate system. Is this something that is possible? What command should I use? Any info or advice would be appreciated.
Thanks,
Mark Robuck
I don’t know how well I can explain this, but I will try. I am fairly new to programming, and I’m making a small text graphics roguelike game. So far I have the movement and stuff set up, but my biggest hurdle is collisions. I had the idea to log the players position into a “memory” variable, so that whenever the player is in a spot he shouldn’t be, it sets is position to the one in memory. This works great! But it is very tedious to write out an if command to check if the player is colliding with something for almost every space that I need. My idea is to just draw out the map, and check if the spot the player is about to jump to is a wall, and of course send him back if it is. Basically I need a command that can check what character is at a specific point, using the text coordinate system. Is this something that is possible? What command should I use? Any info or advice would be appreciated.
Thanks,
Mark Robuck