On line 59/61 in scripts/prefabs/whip.lua, the else/end statements are switched:
if math.random() < chance then
snap.Transform:SetScale(3, 3, 3)
snap.SoundEmitter:PlaySound("dontstarve/common/whip_large")
inst:DoTaskInTime(0, supercrack)
end
snap.SoundEmitter:PlaySound("dontstarve/common/whip_small")
else
This should most likely read:
if math.random() < chance then
snap.Transform:SetScale(3, 3, 3)
snap.SoundEmitter:PlaySound("dontstarve/common/whip_large")
inst:DoTaskInTime(0, supercrack)
else
snap.SoundEmitter:PlaySound("dontstarve/common/whip_small")
end
Diff:
--- a/scripts/prefabs/whip.lua
+++ b/scripts/prefabs/whip.lua
@@ -56,9 +56,9 @@ local function onattack(inst, attacker, target)
snap.Transform:SetScale(3, 3, 3)
snap.SoundEmitter:PlaySound("dontstarve/common/whip_large")
inst:DoTaskInTime(0, supercrack)
- end
- snap.SoundEmitter:PlaySound("dontstarve/common/whip_small")
else
+ snap.SoundEmitter:PlaySound("dontstarve/common/whip_small")
+ end
end
end