Platformer-like Movement (airdashing, doublejump etc)

User avatar
ProfanedBane
New member
 
Posts: 3
Joined: Sun Feb 11, 2018 00:10
GitHub: ProfanedBane
IRC: ProfanedBane

Platformer-like Movement (airdashing, doublejump etc)

by ProfanedBane » Sun Feb 11, 2018 00:48

Hey, babby's first mod here so it's gonna be rough around the edges, any feedback/contributions are welcome!

This mod aims to add in the framework for platformer-like movement, examples of this would be airdashing, double jumping, wall climbing, wall jumping -and so on.

The plan is to hardcode in all the movement types as to test their logic/performance, then expand this mod into a kind of API that other mods can work off of, in such a way that say a mod could add a craftable "winged boots" item that when worn let's you double jump.

Current Progress:
  • Release v0.1 - Airdashing
    • Airdash prototype is functional.
    • Press your 'aux' keybind to airdash 10 blocks, it has a cooldown of 1 second.
    • In theory™ it should check the area you're dashing to is valid, and change the destination accordingly.
    • Issues include:
      • Airdashing while looking upwards moves the destination one block higher than it should be.
      • Pathfinding isn't 100% accurate so certain reasonable dashes aren't executed correctly.
      • Non solid blocks other than Air can impede a dash.

As of right now only the airdash prototype is active, and SHOULD be stable/bugfree™ enough to play the game normally with, but I'm not 100% on that.

CURRENT RELEASE: https://github.com/ProfanedBane/minemov ... .1-dashing
GITHUB: https://github.com/ProfanedBane/minemovement/
CODE LICENSE: AGPLv3 (could be subject to change if need be)

VIDEOS:
Airdash Demo - https://youtu.be/imI2iWYBnSY
 

User avatar
D00Med
Member
 
Posts: 941
Joined: Sat Feb 07, 2015 22:49
Location: Australia...somewhere
GitHub: D00Med

Re: Platformer-like Movement (airdashing, doublejump etc)

by D00Med » Sun Feb 11, 2018 08:19

This looks really cool!
Looking forward to future updates.
 

User avatar
ProfanedBane
New member
 
Posts: 3
Joined: Sun Feb 11, 2018 00:10
GitHub: ProfanedBane
IRC: ProfanedBane

Re: Platformer-like Movement (airdashing, doublejump etc)

by ProfanedBane » Mon Feb 12, 2018 04:19

Thanks, hopefully I can pull off all that I have planned for this, it appears the API wasn't really built for modifying player behavior like I intend so I gotta do a ton of hacky workarounds.
 

User avatar
D00Med
Member
 
Posts: 941
Joined: Sat Feb 07, 2015 22:49
Location: Australia...somewhere
GitHub: D00Med

Re: Platformer-like Movement (airdashing, doublejump etc)

by D00Med » Mon Feb 12, 2018 07:05

Yes it's difficult.
I had a quick look at the code, don't understand any of it.
But I do have a tip, if you get stuck with moving the player in a certain way, you could try to just attach them to an entity and move that instead.
I was going to make something like this using that method. But what you've done looks a lot better.
 

User avatar
SonosFuer
Member
 
Posts: 104
Joined: Sun Jul 09, 2017 00:32
GitHub: apachano
IRC: SonosFuer
In-game: SonosFuer

Re: Platformer-like Movement (airdashing, doublejump etc)

by SonosFuer » Mon Feb 12, 2018 17:42

Sweet mod, would be really fun in a pvp server.

It would be cool if there were an optional dependency for stamina to replace the 1 second cool down. So maybe it used 5 of your stamina points when you dash?
Working on a content database for minetest mods, servers, and etc Check it out and give me feedback at https://forum.minetest.net/viewtopic.php?f=14&t=18137
 

User avatar
ProfanedBane
New member
 
Posts: 3
Joined: Sun Feb 11, 2018 00:10
GitHub: ProfanedBane
IRC: ProfanedBane

Re: Platformer-like Movement (airdashing, doublejump etc)

by ProfanedBane » Tue Feb 13, 2018 00:00

D00Med wrote:Yes it's difficult.
I had a quick look at the code, don't understand any of it.
But I do have a tip, if you get stuck with moving the player in a certain way, you could try to just attach them to an entity and move that instead.
I was going to make something like this using that method. But what you've done looks a lot better.

Yeah I really gotta improve readability, basically I just do a few line of sight checks then perform a teleport if the location is valid, with some interpolated sub-teleports to make it seem smooth.
Is there a mod/api someone made for the entity attachment stuff? I've heard it's not that good to do as is since only one entity can be in play, causing potential mod compatibility problems.
Doing stuff like wallclimbing etc is gonna be hellish if the attaching entity thing isn't an option, I don't think the game-timers are precise enough to pull it off with hacky use of gravity etc like I'm testing out with double jump.

SonosFuer wrote:Sweet mod, would be really fun in a pvp server.

It would be cool if there were an optional dependency for stamina to replace the 1 second cool down. So maybe it used 5 of your stamina points when you dash?

Hopefully I can get it to a point that server admins can balance it for pvp needs, right now I'm just trying to get it functional but I have a config file for everything planned eventually.
Linking it into mods like that would be ez pz I think, once I get the config file in I'll see about adding some optional dependencies for that kinda stuff.
 

User avatar
Stix
Member
 
Posts: 1379
Joined: Fri Aug 04, 2017 14:19
Location: USA
IRC: nil
In-game: Stix [+alts]

Re: Platformer-like Movement (airdashing, doublejump etc)

by Stix » Fri May 11, 2018 22:09

is this project dead?
Hey, what can i say? I'm the bad guy.
Next release of your favorite game? "Bugfixes" --Wuzzy
[OLD]The new Minetest-offtopic can be found here: https://minetestoftopic.createaforum.com/index.php
 


Return to WIP Mods



Who is online

Users browsing this forum: gpcf and 4 guests