server crash when def.wield_scale is not a number value #3971
Labels
No Label
#P1 CRITICAL
#P2: HIGH
#P3: elevated
#P4 priority: medium
#P6: low
#Review
annoying
API
bug
code quality
combat
commands
compatibility
configurability
contribution inside
controls
core feature
creative mode
delayed for engine release
documentation
duplicate
enhancement
environment
feature request
gameplay
graphics
ground content conflict
GUI/HUD
help wanted
incomplete feature
invalid / won't fix
items
looking for contributor
mapgen
meta
mineclone2+
Minecraft >= 1.13
Minecraft >= 1.17
missing feature
mobile
mobs
mod support
model needed
multiplayer
Needs adoption
needs discussion
needs engine change
needs more information
needs research
nodes
non-mob entities
performance
player
possible close
redstone
release notes
schematics
Skyblock
sounds
Testing / Retest
tools
translation
unconfirmed
mcl5
mcla
Media missing
No Milestone
No project
No Assignees
5 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: VoxeLibre/VoxeLibre#3971
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
MineClone2 version:
master branch commit
3d7155c1b9
What happened?
A server crash
Steps to reproduce
Bug related with:
MineClone2/MineClone2#3961
MineClone2/MineClone2#3914
MineClone2/MineClone2#3913
MineClone2/MineClone2#3915
crash when
def.wield_scale
is not a number valueserver crash attempt to index field 'wield_scale' (a number value)to server crash when def.wield_scale is nilserver crash when def.wield_scale is nilto server crash when def.wield_scale is not a number valueWhat item are you trying to wield here? def.wield_scale should be a vector and is across the code base. Somehow it looks like your wield scale on the definition is a number, not a vector, and I cannot see an example in the code that looks like this is the case for.
Without further information for this, it would be very hard to investigate further.
Wield_scale, per the definition in the Minetest API is a Vector3.
Trying to force it to a single number will cause everything to break, not just mineclone. The reason that it's a vector 3 and not a single float, is that when it is wielded, it's a 3D object.
So, I am left wondering why it is that you want it to be a single float number?
That one has nothing to do with what you are reporting. Unless you show me how that is relevant, continuing to "contribute" useless comments and incorrect code will be seen as spam.
I only report real crashes that happen to me
I'm trying to help
If my PR is werong just close it
I understand, and I genuinely appreciate you reporting them. But, it should be a vector3. I think the real issue here is that the error message was misleading.
That issue should be closed or not? Should we also close issues #4048, #3976 and #3973 (issues related to fake players)?
Why would it be?
As we didn't get an answer on what item had an issue with wield_scale, I'm assuming it's a custom item and a data issue. Without further information, it's impossible to really proceed with this one. We should close it until more information surfaces.
Closing.
wield_scale
must be a vector and not a single number under MTE 5.6.1 Lua API, so for whatever we support, a single number there is invalid.