Death issue in Platformer

Post Reply
KoolDoob
Posts: 25
Joined: Wed Sep 11, 2019 5:55 pm
Location: France

Death issue in Platformer

Post by KoolDoob » Wed Sep 11, 2019 6:07 pm

Hi guys! I recently start to make a platform game with nes maker and I hope it's the right place to ask my question.

I want my character to be dead when I jump out of a plateform. When I do this jump, my character switch to the bottom screen instead of dying and I don't know why.

Thanks for helping :)
User avatar
dale_coop
Posts: 4100
Joined: Fri Feb 16, 2018 7:05 am
Location: France

Re: Death issue in Platformer

Post by dale_coop » Wed Sep 11, 2019 6:46 pm

An easy one: you could put "death" tiles everywhere on the bottom of the screen?

Or modify the "Handle Bottom Bounds" script (in "Project Settings > Script Settings"), to execute a script with only:

Code: Select all

	;; the player dies..
	JSR HandlePlayerDeath
Or a script with only:

Code: Select all

	;; the player loses a life, and start again
	JSR LoseLife
-----
Sorry about my poor english
All I need: A Damn Fine Cup of Coffee
My games: PRESS START GAME / UNDERGROUND ADVENTURE / UNDERGROUND ADVENTURE (Arcade version - Byte-Off-2019)
KoolDoob
Posts: 25
Joined: Wed Sep 11, 2019 5:55 pm
Location: France

Re: Death issue in Platformer

Post by KoolDoob » Wed Sep 11, 2019 7:57 pm

quand tu parles de "death" tiles tu parles de pics qui tuent instantanément par exemple ?

Et pour ce qui est de modifier "Handle Bottom Bounds", je doit tout supprimer et écrire ce que tu m'a envoyé ou bien changer qu'une partie du code ?
Ma question peut paraître bête mais je ne sais pas à quel endroit écrire ce que tu m'a donné.

Merci :)
Attachments
Saut2.PNG
Après le saut
Saut2.PNG (18.45 KiB) Viewed 78 times
Saut1.PNG
Avant le saut
Saut1.PNG (37 KiB) Viewed 78 times
User avatar
dale_coop
Posts: 4100
Joined: Fri Feb 16, 2018 7:05 am
Location: France

Re: Death issue in Platformer

Post by dale_coop » Wed Sep 11, 2019 11:14 pm

Je ne savais pas que tu parlais français.

Oui, la solution simple: tu pourrais mettre des tiles "death", comme les pics de la démo. Il suffirait d'en faire des transparents mais de type "10 - death".

Sinon l'autre, consiste à modifier (ou plutôt ici, remplacer) le script qui est actuellement assigné à l'élément "Handle Bottom Bounds" dans la fenêtre "Project Settings > Script Settings".
Pour cela, tu dupliques le script original par exemple, et tu remplaces son contenu par ce que je t'ai écris dans on précédent message:

Code: Select all

	;; the player loses a life, and start again
	JSR LoseLife
-----
Sorry about my poor english
All I need: A Damn Fine Cup of Coffee
My games: PRESS START GAME / UNDERGROUND ADVENTURE / UNDERGROUND ADVENTURE (Arcade version - Byte-Off-2019)
KoolDoob
Posts: 25
Joined: Wed Sep 11, 2019 5:55 pm
Location: France

Re: Death issue in Platformer

Post by KoolDoob » Thu Sep 12, 2019 8:09 am

Ok merci beaucoup j'ai pu trouver une solution !
User avatar
dale_coop
Posts: 4100
Joined: Fri Feb 16, 2018 7:05 am
Location: France

Re: Death issue in Platformer

Post by dale_coop » Thu Sep 12, 2019 11:43 am

C'est cool!
-----
Sorry about my poor english
All I need: A Damn Fine Cup of Coffee
My games: PRESS START GAME / UNDERGROUND ADVENTURE / UNDERGROUND ADVENTURE (Arcade version - Byte-Off-2019)
Post Reply