mirror of
https://codeberg.org/tenplus1/mob_horse.git
synced 2024-11-14 14:30:18 +01:00
tweak on_sound example
This commit is contained in:
parent
868e5a88f4
commit
ac8cb2ec70
5
init.lua
5
init.lua
|
@ -211,9 +211,8 @@ mobs:register_mob("mob_horse:horse", {
|
|||
end,
|
||||
--[[
|
||||
on_sound = function(self, def)
|
||||
-- loudness ranges from (0.0 = cannot hear, to 1.0 = next to sound)
|
||||
if def.loudness > 0.8 then -- if loud enough startle horse into jumping
|
||||
self.object:set_velocity({x=0, y=5, z=0})
|
||||
self.object:set_velocity({x = 0, y = 5, z = 0})
|
||||
end
|
||||
end
|
||||
]]
|
||||
|
@ -340,4 +339,4 @@ if minetest.get_modpath("lucky_block") then
|
|||
})
|
||||
end
|
||||
|
||||
print("[MOD] Mob Horse loaded")
|
||||
print("[MOD] Mobs Redo Horse loaded")
|
||||
|
|
Loading…
Reference in New Issue
Block a user