I'm in the making of my first game, Construct 2 is excellent but I have now stopped my development since I can't get pass a hurdle.
I am pretty far into my game and started using tilemaps to speed up my mapmaking a bit.
Here's my problem:
I use a big vertical sprite (laserHunting, 720 pixel in height) that with bullet behavior shoot across the screen and destroying everything it connects to which means everything on the map. This works great when using "on collision with" with other sprites. My problem is with tilemaps I can't get it to work.
The problem is the Y-value that I try to get with mytilemap.PositionToTileY(mySprite.Y) always adds up to zero.
If I set a fixed value in variable selectTileY it will destroy tiles but only tiles with the specific specify a Y-value.
THIS WORKS when I try.
This works with SelectTileY to 20 but I want to get Y from tilemapRed.PositionToTileY(laserhunting.Y) or something similar.
When trying to output tilemapRed.PositionToTileY(laserhunting.Y) to a spritefont it gives me the value 0 which I guess is my origin of the sprite, not where it collide. How can I get a Y-value where the sprite collide with the tile?
Thanks for a great product and hopefully someone can help me to go further.
Seems pictures can't load in forum, right click image and open in new window/tab and it should work.