LunaLua with Link

This is the place for discussion and support for LunaLua and related modifications and libraries.

Moderator: Userbase Moderators

Forum rules
Before you make a topic/post, consider the following:
-Is there a topic for this already?
-Is your post on topic/appropriate?
-Are you posting in the right forum/following the forum rules?
Devan2002
Chain Chomp
Chain Chomp
Posts: 304
Joined: Sun Oct 02, 2016 9:46 am

LunaLua with Link

Postby Devan2002 » Sun Nov 26, 2017 1:27 am

How would someone make it so that if Link dashes and hits a wall (whether it's the top half or bottom half) he bounces off it, creating the bonk noise (while in the hurt frame when bouncing back)?

The0x539
Eerie
Eerie
Posts: 751
Joined: Fri Jan 22, 2016 8:02 pm

Re: LunaLua with Link

Postby The0x539 » Sun Nov 26, 2017 1:40 am

keep track of last tick's speedX
if current speedX is zero and last frame's was not, and player is pushing against a wall, set speedX to minus last tick's speedX

Devan2002
Chain Chomp
Chain Chomp
Posts: 304
Joined: Sun Oct 02, 2016 9:46 am

Re: LunaLua with Link

Postby Devan2002 » Sun Nov 26, 2017 2:02 am

The0x539 wrote:keep track of last tick's speedX
if current speedX is zero and last frame's was not, and player is pushing against a wall, set speedX to minus last tick's speedX
This would also include several things, like changing the frame of Link to the hurt animation until he stops falling, it plays a sound effect, and Link moves up a few pixels.

The0x539
Eerie
Eerie
Posts: 751
Joined: Fri Jan 22, 2016 8:02 pm

Re: LunaLua with Link

Postby The0x539 » Sun Nov 26, 2017 9:22 am

sounds like you have a decent idea how to do those things


Return to “LunaLua”

Who is online

Users browsing this forum: No registered users and 2 guests

SMWCentralTalkhausMario Fan Games GalaxyKafukaMarioWikiSMBXEquipoEstelari