From e460f1072cb35b6960c8aa18683c74e6bf4a98e7 Mon Sep 17 00:00:00 2001 From: wsor <24964441+wsor4035@users.noreply.github.com> Date: Wed, 24 Mar 2021 00:05:04 -0400 Subject: [PATCH] make fish not sink, die in air, still not mvp functional --- mods/fl_wildlife/fl_brains/fish_brain.lua | 9 +++++++-- mods/fl_wildlife/fl_mobs/riverfish.lua | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/mods/fl_wildlife/fl_brains/fish_brain.lua b/mods/fl_wildlife/fl_brains/fish_brain.lua index 3a1a1be..3dddd2e 100644 --- a/mods/fl_wildlife/fl_brains/fish_brain.lua +++ b/mods/fl_wildlife/fl_brains/fish_brain.lua @@ -15,7 +15,12 @@ function fl_brains.fish_brain(self) end if mobkit.timer(self,1) then - mobkit.animate(self,"walk") - mobkit.hq_aqua_roam(self,10,1) + if not self.isinliquid then + fl_wildlife.flash_color(self) + mobkit.hurt(self,1) + else + mobkit.animate(self,"walk") + mobkit.hq_aqua_roam(self,10,1) + end end end \ No newline at end of file diff --git a/mods/fl_wildlife/fl_mobs/riverfish.lua b/mods/fl_wildlife/fl_mobs/riverfish.lua index a2bb68a..fb4fa00 100644 --- a/mods/fl_wildlife/fl_mobs/riverfish.lua +++ b/mods/fl_wildlife/fl_mobs/riverfish.lua @@ -19,7 +19,7 @@ minetest.register_entity("fl_wildlife:riverfish", { get_staticdata = mobkit.statfunc, --who knows, no documentation (probably save entity data) --mobkit properties - buoyancy = 1.0, --how it works in water + buoyancy = 0.99, --how it works in water max_speed = 2, --how fast it can go jump_height = 1.1, --jumping height? not sure how this is different from mte stepheight view_range = 24, --how far it can see