I need help making a script for jumping on and killing enemies

So basically I am coding a sonic game, I have programmed the enemies movements and Sonic’s. my only issue is that I need a way to kill the enemy, can someone give me suggestions or try to fix please?

Game page: https://makecode.com/_Lgp0a8PEk5Ds

but i hope you like it although it wont change level

this is reallly good :smiley: you should look at my sonic game and maybe we could collaborate to make a reallly cool sonic game. i like the animations and the enemies look perfect as well as the trees background ad flowers

here is mine ,kinda seems like a downgrade of yours

Thank you! also yeah we should collab! I looked at your game and it looks amazing with the title cards and such. By the way, do you have a way on helping me code a way to kill enemies?

Yes so basically you go on the when sprite if a player overlapped the enemy and within that block you have an if statement wich has if then sonic sprites vy(velocity y)=0 then change life or use my ring loss thing so it gets hurts and then for the if else then you put destroy other sprite so basically if you jump on the enemy it’ll die but if it goes into you you get hurt

But for collaborating do you think that I could delete all my work on mine so the pallete is kept then start a new with new discussed Game stuff and I convert some if your tiles onto my game and we can use the gif converter to use sonic mania sprites and try and make slopes and loops and that and use certain parts of each other’s to make an ultimate accurate sonic game

So basically like transport all of our stuff into one game but some stuff different

Sorry for loads of posts but I think that we should maybe make a next level of chemical plant zone and that and also how did you make the music cause I used the rtttl extension for mine

Yes we could, but it may be a little difficult, considering I don’t know how to transfer code. But we can take turns adding new scripts and sharing new builds so that we can build upon what we have so far. Originally my game was a mini version of sonic 1. Also yes the music was done by me, using a piano note guide.

Ahh ok I’m not too sure on how to transfer code either I think you just go onto JavaScript copy it and paste it but you have to have the same variables kinda and that

And just wondering would you want to base this game on the neo geo pocket sonic as thatsbwhat I used my sonic animations from but if you want to keep your sonic animations I know how to make it like where your sonic could follow my taller sprite like tails does sorta like a sonic generations thing

Hmm, well we can revamp the neo Geo sprites, like add tweaks or improvements, but I like my green hill tilesets, and I added a waterfall tilesets which looks cool :slight_smile:

I do like your green hill zone tile set maybe we could merge both our tiles together

okay, lets try :D, i currently have a new build of my game (but its laggy)

Same I completely restarted mine and it looks so epic

May I see?

search sonic 2 remake on the forum and there it is :slight_smile: