Compare commits
3 Commits
2255cdd34b
...
49b3e9c0b4
Author | SHA1 | Date | |
---|---|---|---|
49b3e9c0b4 | |||
c346a34a29 | |||
6f9c15bedb |
@ -1,7 +1,13 @@
|
||||
* 2023-06-04 : mckaygerhard
|
||||
* dont relly on the legacy layer of default mod, detect if player api is present
|
||||
* remove any conflicts with lib_mount
|
||||
* fix fox behaviour, fix water dragon aim
|
||||
* fix wrong local non local variable for function scope only
|
||||
* sync with tenplus1 last changes, backport fixeds
|
||||
* 2022-01-23 : mckaygerhard
|
||||
* change namespace from dmobs to mobs_doomed
|
||||
* fixed depends
|
||||
* fixed damge by fire
|
||||
* fixed damage by fire
|
||||
* improvements over readme and information, added screenshot
|
||||
* Fixed a few nil error bugs from tenplus1 and more checks
|
||||
* 2021-03-30 : Poikilos
|
||||
|
@ -33,7 +33,7 @@ This mod is named `mobs_doomed` in this branch, and includes all the changes fro
|
||||
some improvements fixeds from mckaygerhard namespaced changes. Its the same from `dmobs` but plus all the
|
||||
recent changes and also fixeds, with renamed namespace to be named as `mobs_doomed`.
|
||||
|
||||
> Warning **This mod will added 10 megs of more media to yuor server game to need to downloaded by clients**
|
||||
> **Warning** **This mod will added 10 megs of more media to yuor server game so clients on mobile may sufering**
|
||||
|
||||
Please for more technical info about dragons read the [dragons.md](dragons.md) file.
|
||||
|
||||
|
17
api.lua
17
api.lua
@ -23,7 +23,7 @@
|
||||
|
||||
--from lib_mount (required by new functions)
|
||||
|
||||
|
||||
local p_api = minetest.get_modpath("player_api")
|
||||
local mobs_redo = false
|
||||
if mobs.mod and mobs.mod == "redo" then
|
||||
mobs_redo = true
|
||||
@ -43,7 +43,8 @@ local function force_detach(player)
|
||||
end
|
||||
player:set_detach()
|
||||
end
|
||||
default.player_attached[player:get_player_name()] = false
|
||||
if p_api then player_api.player_attached[player:get_player_name()] = false
|
||||
else default.player_attached[player:get_player_name()] = false end
|
||||
player:set_eye_offset({x=0, y=0, z=0}, {x=0, y=0, z=0})
|
||||
end
|
||||
|
||||
@ -56,9 +57,12 @@ function mobs_doomed.object_attach(entity, player, attach_at, eye_offset)
|
||||
player:set_properties({visual_size = {x=1, y=1}})
|
||||
|
||||
player:set_eye_offset(eye_offset, {x=0, y=0, z=0})
|
||||
default.player_attached[player:get_player_name()] = true
|
||||
if p_api then player_api.player_attached[player:get_player_name()] = true
|
||||
else default.player_attached[player:get_player_name()] = true end
|
||||
|
||||
minetest.after(0.2, function()
|
||||
default.player_set_animation(player, "sit" , 30)
|
||||
if p_api then player_api.set_animation(player, "sit" , 30)
|
||||
else default.player_set_animation(player, "sit" , 30) end
|
||||
end)
|
||||
--entity.object:set_yaw(player:get_look_yaw() - math.pi / 2)
|
||||
entity.object:set_yaw(player:get_look_horizontal() - (math.pi/2))
|
||||
@ -67,8 +71,13 @@ end
|
||||
function mobs_doomed.object_detach(entity, player, offset)
|
||||
entity.driver = nil
|
||||
player:set_detach()
|
||||
if p_api then
|
||||
player_api.player_attached[player:get_player_name()] = false
|
||||
player_api.set_animation(player, "stand" , 30)
|
||||
else
|
||||
default.player_attached[player:get_player_name()] = false
|
||||
default.player_set_animation(player, "stand" , 30)
|
||||
end
|
||||
player:set_eye_offset({x=0, y=0, z=0}, {x=0, y=0, z=0})
|
||||
local pos = player:get_pos()
|
||||
pos = {x = pos.x + offset.x, y = pos.y + 0.2 + offset.y, z = pos.z + offset.z}
|
||||
|
@ -6,3 +6,4 @@ bones?
|
||||
ethereal?
|
||||
caverealms?
|
||||
mobs_animal?
|
||||
player_api?
|
2
mod.conf
2
mod.conf
@ -1,4 +1,4 @@
|
||||
name = mobs_doomed
|
||||
depends = default, mobs, wool, farming
|
||||
optional_depends = bones, ethereal, caverealms, mobs_animal
|
||||
optional_depends = bones, ethereal, caverealms, mobs_animal, player_api
|
||||
description = MOBS for more monsters like dragons, orcs, ogres, elephans, etc
|
||||
|
Loading…
x
Reference in New Issue
Block a user