Sprinting should be in minetest by default

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Sprinting should be in minetest by default

by Joseph16 » Post

For ever since minetest has been a thing, we have never had sprinting in the default minetest game. I think this is lame, as sprinting is such a core requirement of gaming. There are many mods out there that add sprinting, but it's hard to decide which one. Also, only some are compatible with the many hunger mods. We need a standard sprinting function in minetest. It's also lame how we have to use the special key to run in the mods. I have my special key bounds to CTRL right now. We need sprinting in the game. As a built in core function. That's my sales pitch.
Last edited by Joseph16 on Wed Jul 17, 2019 15:06, edited 1 time in total.
Testin' mines since 1989

User avatar
Hugues Ross
Developer
Posts: 72
Joined: Mon May 06, 2019 22:52
GitHub: Df458
Location: Kitchens, Pantries, etc.
Contact:

Re: Sprinting should be in minetest_game!!

by Hugues Ross » Post

I agree completely.

Here's another reason to add sprinting, while we're at it: Minetest does a great job of making interesting terrain, but minetest_game doesn't offer any efficient means of traversal. As a result, exploring and finding interesting places without flight is harder than it should be. More ways to move quickly (like sprinting) would help a lot in this regard.

User avatar
benrob0329
Member
Posts: 1341
Joined: Thu Aug 06, 2015 22:39
GitHub: Benrob0329
IRC: benrob0329
In-game: benrob03
Location: Michigan
Contact:

Re: Sprinting should be in minetest_game!!

by benrob0329 » Post

It is, its called fast mode :P

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Re: Sprinting should be in minetest_game!!

by Joseph16 » Post

benrob0329 wrote:It is, its called fast mode :P
No, it’s not. Fast mode requires a special privilege. Also it’s not sprinting. And it’s really fast.
Testin' mines since 1989

User avatar
TenPlus1
Member
Posts: 3715
Joined: Mon Jul 29, 2013 13:38
In-game: TenPlus1
Contact:

Re: Sprinting should be in minetest_game!!

by TenPlus1 » Post

It's easier to add a mod like https://notabug.org/tenplus1/stamina that adds hunger and stamina combined.

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Re: Sprinting should be in minetest_game!!

by Joseph16 » Post

I have already done that, what I’m saying is it should be part of the default game. Also, when you hold the run key there is about a 1 second delay before you start running. That is really bad and has lead to my dying many times.
Testin' mines since 1989

User avatar
sorcerykid
Member
Posts: 1841
Joined: Fri Aug 26, 2016 15:36
GitHub: sorcerykid
In-game: Nemo
Location: Illinois, USA

Re: Sprinting should be in minetest_game!!

by sorcerykid » Post

The reason there's a one second delay is because there's no feedback provided by the engine when keys are pressed. Hence, mods are stuck having to constantly poll the state of keys in a globalstep. In truth, it would be fairly easy to add a callback mechanism for key state changes since these events are already captured in networkpackethandler.cpp. But as of now, no such callback mechanism exists.

Of course whatever solution is devised should be scalable as well as extensible. Is polling and tracking all keystates in a globalstep more efficient than repeatedly invoking an event notification hook? Both entail repetitive context switching. Assuming the difference is negligible, I think the latter implementation would be far superior from an architectural standpoint.

Astrobe
Member
Posts: 570
Joined: Sun Apr 01, 2018 10:46

Re: Sprinting should be in minetest_game!!

by Astrobe » Post

Joseph13 wrote:For ever since minetest has been a thing, we have never had sprinting in the default minetest game. I think this is lame, as sprinting is such a core requirement of gaming.
OMG we don't have a Core Requirement of Gaming, so unprofessional...

On a more serious note, if it is about mobility in MTG, the award-winning Hang Glider is a choice to be considered. Aside from the fact that flying is an even experience than "walking but faster" (or "swimming but faster"...), building it requires wool and using it requires climbing. This induces multiple gameplay elements: players have to start farming to build it, which in turn will make them look for and collect cotton seeds, and they might want to build stairways to climb faster on top of hills; maybe also build a tower there for extra range.

Astrobe
Member
Posts: 570
Joined: Sun Apr 01, 2018 10:46

Re: Sprinting should be in minetest_game!!

by Astrobe » Post

sorcerykid wrote:The reason there's a one second delay is because there's no feedback provided by the engine when keys are pressed. Hence, mods are stuck having to constantly poll the state of keys in a globalstep. In truth, it would be fairly easy to add a callback mechanism for key state changes since these events are already captured in networkpackethandler.cpp. But as of now, no such callback mechanism exists.

Of course whatever solution is devised should be scalable as well as extensible. Is polling and tracking all keystates in a globalstep more efficient than repeatedly invoking an event notification hook? Both entail repetitive context switching. Assuming the difference is negligible, I think the latter implementation would be far superior from an architectural standpoint.
I think the callback solution is a bit more sensitive to lag: callbacks will be called at the end of a log spike and will give the state of the keys before the lag spike, while when polling you always get the freshest state. Also callbacks needs more management on both parts (engine and mod) and can be less convenient.

An intermediate solution could be that the game exposes the key states as a global read-only table. In the case of multiple mods wanting to read the keys, it removes the function call overhead and part of the GC pressure associated with the creation/collection of the key states table.

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Re: Sprinting should be in minetest_game!!

by Joseph16 » Post

I think a new keybind should be added for sprinting, then the engine just checks to see if the key is pressed just like the walking keys (W, S, A, D) and if so, increase the speed of the player to running speed. This should also be accessible to hunger mods so they can use up food faster if sprinting.
Testin' mines since 1989

User avatar
paramat
Developer
Posts: 3700
Joined: Sun Oct 28, 2012 00:05
GitHub: paramat
IRC: paramat
Location: UK

Re: Sprinting should be in minetest_game!!

by paramat » Post

Key 'E' already does this, and it's clientside too as it should be, one problem is that it sets speed to 'fast' speed, which is 20 n/s by default, too fast.
Ideally, flying should be at the set 'fast' speed, and sprinting uses uses a new physics setting 'sprint_speed'.
Anyway, to do this well needs work on the engine, the existing sprint mods have problems, i think we can do better.

Keep in mind that the default 'walk' speed of 4 n/s is very fast for 'walking', so it's already halfway to sprinting to compensate for lack of different speeds.

> It's also lame how we have to use the special key to run in the mods.

We're considering splitting the 'special' key into 2 keys, one for 'special', one for 'fast', as this solves another issue.

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Re: Sprinting should be in minetest_game!!

by Joseph16 » Post

Holy Moly, it’s paramat! Great to hear from you on this topic. So your saying that the walking speed should be slowed down and sprinting should be added?
Testin' mines since 1989

User avatar
runs
Member
Posts: 3225
Joined: Sat Oct 27, 2018 08:32

Re: Sprinting should be in minetest_game!!

by runs » Post

Sprinting is important, all open world games have this feature. It's not related to copycut but the basics.

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Re: Sprinting should be in minetest_game!!

by Joseph16 » Post

Yeah
Testin' mines since 1989

User avatar
sorcerykid
Member
Posts: 1841
Joined: Fri Aug 26, 2016 15:36
GitHub: sorcerykid
In-game: Nemo
Location: Illinois, USA

Re: Sprinting should be in minetest_game!!

by sorcerykid » Post

Astrobe wrote: I think the callback solution is a bit more sensitive to lag: callbacks will be called at the end of a log spike and will give the state of the keys before the lag spike, while when polling you always get the freshest state. Also callbacks needs more management on both parts (engine and mod) and can be less convenient.
I think it's actually the opposite. Polling would be more susceptible to lag, since the key states are only being checked during a globalstep callback (hence they are not captured in realtime). An event notification hook, in contrast could be invoked immediately from serverpackethandler.cpp in response to a PlayerPos packet.
Last edited by sorcerykid on Wed May 22, 2019 17:23, edited 1 time in total.

User avatar
sorcerykid
Member
Posts: 1841
Joined: Fri Aug 26, 2016 15:36
GitHub: sorcerykid
In-game: Nemo
Location: Illinois, USA

Re: Sprinting should be in minetest_game!!

by sorcerykid » Post

Here's an idea for one possible implementation to capture keystroke events. This of course is just a suggestion.

Code: Select all

minetest.register_inputcontrol( "key_aux", {
     on_pressed = function ( player, key_states ) ... end,
     on_released = function ( player, key_states ) ... end,
     on_repeat = function ( player, key_states ) ... end,
}

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Re: Sprinting should be in minetest_game!!

by Joseph16 » Post

I don’t know what any of this means but If it means sprinting in Minetest then I like it
Testin' mines since 1989

User avatar
paramat
Developer
Posts: 3700
Joined: Sun Oct 28, 2012 00:05
GitHub: paramat
IRC: paramat
Location: UK

Re: Sprinting should be in minetest_game!!

by paramat » Post

> as sprinting is such a core requirement of gaming.

Well ... it isn't. It's completely possible to have a good game that doesn't have sprinting, because games vary so much.

> Sprinting is important, all open world games have this feature.

Whether it's important or not depends on the intentions of the computer game, so it can't be described as universally important.
Also of course, not all open world games have sprinting. Even if all of them did, that in no way means 'Game X' should, because it may not be right for 'Game X'. All that matters is whether it's right for 'Game X'.

But i understand you like the feature and would like to see it included as default, which it could be in future with some engine work.

User avatar
Linuxdirk
Member
Posts: 3216
Joined: Wed Sep 17, 2014 11:21
In-game: Linuxdirk
Location: Germany
Contact:

Re: Sprinting should be in minetest_game!!

by Linuxdirk » Post

paramat wrote:Also of course, not all open world games have sprinting.
[citation needed]
paramat wrote:But i understand you like the feature and would like to see it included as default, which it could be in future with some engine work.
What engine work is that? Simple Lua mods can implement sprinting already.

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Re: Sprinting should be in minetest_game!!

by Joseph16 » Post

Yes, lua mods can add sprinting. But they use globalstep, so they are subject to server lag and ping, unlike pressing W to go forward there is a delay sometimes, and plus’s there are so many running mods it’s hard to choose.
Testin' mines since 1989

User avatar
jas
Member
Posts: 593
Joined: Mon Jul 24, 2017 18:15
IRC: Freenode
Location: IRC

Re: Sprinting should be in minetest_game!!

by jas » Post

I haven't tested it on a remote server yet, but I made Yet Another Sprinting Mod as a CSM/SSM pair where the polling happens client-side, thus removing the burden of checking for client's key presses server-side.

User avatar
Wuzzy
Member
Posts: 4786
Joined: Mon Sep 24, 2012 15:01
GitHub: Wuzzy2
IRC: Wuzzy
In-game: Wuzzy
Contact:

Re: Sprinting should be in minetest_game!!

by Wuzzy » Post

No, this has no chance of getting included into Minetest Game because it would actually improve it.

Seriously, just let go of Minetest Game. Minetest Game is a failed project, it's time to give up and instead focus on other projects. I don't get this obsession of Minetest Game, don't you see this project has been stagnating for years now?

User avatar
Joseph16
Member
Posts: 310
Joined: Tue Dec 06, 2016 05:35
In-game: smb3

Re: Sprinting should be in minetest_game!!

by Joseph16 » Post

I didn’t mean Minetest_game really I meant the Minetest engine itself. I’ll rename the post.
Testin' mines since 1989

User avatar
paramat
Developer
Posts: 3700
Joined: Sun Oct 28, 2012 00:05
GitHub: paramat
IRC: paramat
Location: UK

Re: Sprinting should be in minetest_game!!

by paramat » Post

> Minetest Game is a failed project,

> don't you see this project has been stagnating for years now?

It's weird how the reality is the opposite of what some perceive. MTG has greatly improved over the last few years in terms of features and quality, especially since Ezhh/Shara joined the core devs. The only issue is that dev is slow, that's not stagnation.

Oddly, the better MTG gets the more people complain about it.

However yes i encourage more focus on new games.

User avatar
Linuxdirk
Member
Posts: 3216
Joined: Wed Sep 17, 2014 11:21
In-game: Linuxdirk
Location: Germany
Contact:

Re: Sprinting should be in minetest_game!!

by Linuxdirk » Post

paramat wrote:Oddly, the better MTG gets the more people complain about it.
So maybe your opinion and the complainers opinions on “better” are different.

Post Reply

Who is online

Users browsing this forum: No registered users and 7 guests