Advertisement
TheMG2

Position stuff and teleport mechanics

Oct 31st, 2015
133
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.78 KB | None | 0 0
  1. When I was messing around with memory, I was having trouble finding a singular "character position" address. It seemed different addresses controlled different things, and they were not necessarily dependent on each other. You could seemingly alter your position when individual addresses were frozen. In addition, if you poke certain ones, they might readjust after you move again.
  2.  
  3. I'm starting to think there is not necessarily a master position address. Instead, the game looks at various pieces of and adjusts other pieces as necessary. For example your position as it relates to placing your sprite might be one thing, your position as it relates to the camera and screen positions could be something else, and your position as it relates to collision be yet another thing. I think your hitbox and other things are also pieces. They do interact with each other, but it isn't so simple as controlling one lets you control the rest. Even if you change one address manually, the others can revert that depending on what actions you take.
  4.  
  5. I believe this not only holds to your character, this holds to enemies and objects as well.
  6.  
  7. When you attach the launcher projectile to an object or enemy you can drag, two addresses are set to zero. When you start to drag it, these addresses are set to the position of what you are dragging. I believe this basically controls where the enemy you are dragging is. If you let go of the launcher button or if the object is blocked by a wall or something, the addresses are set to zero and everything is normal. However, if the object hits you, the values of the addresses are NOT set back to zero. I'm guessing that this cancels the drag in a way that the developers didn't think of.
  8.  
  9. When you do the teleport glitch, it simulates what happens when you drag an enemy into you and thus modifies their position... Or so I thought. Now I realize that it changes only specific components of position and which components depends on the enemy or object and how you're running into them. Sometimes their collision gets teleported with their sprite. Other times it doesn't. Sometimes how you interact with the object is moved with it. Other times it's just the sprite that has moved. A pretty key characteristic of teleporting anything is the sprite changing location. I believe how the other components of position interact with this component is how things behave when teleported. Why does it vary? I don't know. I just know that it does.
  10.  
  11. It seems that when an enemy starts to move after teleporting, some of their addresses get corrected and it gets sent back to where it came from. I think the boulders don't because you interacting with their hitbox controls their collision.
  12.  
  13. In summary, there are multiple components of position, and how these components interact determine teleport behavior.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement