Collision detection problems
spaceneedle
PRO Posts: 93
I followed the tutorial exactly in regards to gravity for platform games, however, I have noticed two problems:
When i drop the player actor onto the platform, the player stands at least 32 pixels above the platform...as if he is floating. I have tried different images, blank images, etc. and all have produced the same result. Is there some sort of default collision fuzz that I am missing that causes an object to "hit" 32 pixels away?
The children from a replicated actor does not inherit any collision detection rules. IE, in a platform game, the player can stand on the parent but none of the children objects. He falls right through.
I am making use of replication as I am using a 16x16 tile-based graphic set.
When i drop the player actor onto the platform, the player stands at least 32 pixels above the platform...as if he is floating. I have tried different images, blank images, etc. and all have produced the same result. Is there some sort of default collision fuzz that I am missing that causes an object to "hit" 32 pixels away?
The children from a replicated actor does not inherit any collision detection rules. IE, in a platform game, the player can stand on the parent but none of the children objects. He falls right through.
I am making use of replication as I am using a 16x16 tile-based graphic set.
Comments
If your platform graphic is 16x16, make sure that the platform is 16x16 (double-click on the Actor and check its properties.
I have never used the Replicate behavior, but be careful of using too many actors in a Scene.
If a platform is 8 "tiles" long, instead of having 8 separate actors, you can simply stretch 1 Actor to be that length. Just set his Graphic properties to "tiled", and make sure it is the correct size.
Thanks for the tiling tip. Hopefully GS will support true tiling features in the future so game maps are easier to generate.