Discuss Scratch

cookienucleaire
Scratcher
15 posts

Problem with collisions in platformer

So I am working on a scrolling platformer project using Griffpatch's amazing YouTube tutorials and I'm at ep 3. Everything was working fine before but not anymore. At 16:08 in the tutorial (https://www.youtube.com/watch?v=ZJ7q3jLRSWs&list=PLy4zsTUHwGJIc90UaTKd-wpIH12FCSoLh&index=3), he shows how it should work but my player still only collides with the blocks at his center. I went back in the tutorial multiple times to find what I did wrong, but couldn't find the error. Here is my unfinished project: https://scratch.mit.edu/projects/1133884765/

Can someone help me find the problem? Thanks!!
ispretty
Scratcher
100+ posts

Problem with collisions in platformer

cookienucleaire wrote:

So I am working on a scrolling platformer project using Griffpatch's amazing YouTube tutorials and I'm at ep 3. Everything was working fine before but not anymore. At 16:08 in the tutorial (https://www.youtube.com/watch?v=ZJ7q3jLRSWs&list=PLy4zsTUHwGJIc90UaTKd-wpIH12FCSoLh&index=3), he shows how it should work but my player still only collides with the blocks at his center. I went back in the tutorial multiple times to find what I did wrong, but couldn't find the error. Here is my unfinished project: https://scratch.mit.edu/projects/1133884765/

Can someone help me find the problem? Thanks!!
I'm pretty sure the problem is that your “get tile at x: (x) y: (y)” script is using orange (x) and (y) blocks instead of the pink ones.

So instead of this:
definegettileatx:xy:ysettile grid xtofloorofx/32settile grid ytofloorofy/32. . .

It should be this:
definegettileatx:xy:ysettile grid xtofloorofx/32settile grid ytofloorofy/32. . .
cookienucleaire
Scratcher
15 posts

Problem with collisions in platformer

It was indeed that, thank you so much!

Powered by DjangoBB