quilt-mappings
quilt-mappings copied to clipboard
SPEED vs WALK_SPEED
In #21 I suffixed some entity speed constants with SPEED
, while some existing constants (from Yarn) are suffixed with WALK_SPEED
. Which one should be used?
I would say SPEED
, imo it's descriptive enough, WALK_SPEED
is unnecessary when just SPEED
is descriptive enough
If there are different types of speed, I would preface with WALKING or RUNNING, etc.
I think that MOVEMENT_SPEED should be the default, as it tells what the speed is for, ie not some other state
That's true, are there different types of speed, like Oro mentioned above?
MOVEMENT_SPEED MOVE_SPEED or WALK_SPEED
See through goals or tasks you can actually adjust the speed of the entity depending on whether those are executed. Here, this would serve as mostly a constant but in the entity attribute builder, you also specify a speed constant for it to set a default speed so here id just suggest putting either of those. DEFAULT_SPEED could also work but in some entity classes it gets confusing speed wise due to poor optimization and mojank. So I'd just stick with what oro said, MOVEMENT_SPEED or MOVE_SPEED
When I mean mojank I mean literal dozens of speed variables lmfaooo
In many cases they will have speed vars which are just essentially repeating itself with the same value or just have dozens of variables serving purposes that could have been done with pretty much the same speed var? Speed has to be one of the most weird things with pathfinding sometimes
Entities don't run like the player does, depending on the goal they just increase speed drastically or decrease speed. They may also increase or decrease speed based on status effects etc.
So in a way yes they run but in a way no they don't for player entities there are special animations and are slightly handled differently depending on the players actions unlike how regular entities do it
just to throw another opinion in:
I like MOVEMENT_SPEED
, unless the entity has multiple ways of moving, in which case WALKING_SPEED
, RUNNING_SPEED
, etc are best. The reason I think the default should be MOVEMENT
is so that entities that do not walk (like fish and phantoms) can remain more consistent.