From 43e19ede49a6614639bafd43d26bb1606f1b875e Mon Sep 17 00:00:00 2001 From: Maksim Gamarnik Date: Thu, 19 May 2016 21:35:02 +0300 Subject: [PATCH] New mobs_redo and update railcart, beds --- games/default/files/beds/spawns.lua | 6 +- .../crafting/textures/crafting_hotbar.png | Bin 463 -> 441 bytes .../files/fire/textures/fire_flint_steel.png | Bin 295 -> 279 bytes .../flowers/textures/flowers_oxeye_daisy.png | Bin 426 -> 425 bytes games/default/files/hud/README.txt | 1 - games/default/files/hud/builtin.lua | 13 - games/default/files/hud/init.lua | 4 - games/default/files/mobs/README.txt | 67 - games/default/files/mobs/chicken.lua | 120 - games/default/files/mobs/init.lua | 32 - games/default/files/mobs/models/mobs_rat.b3d | Bin 6956 -> 0 bytes games/default/files/mobs/npc.lua | 3 - games/default/files/mobs/pig.lua | 63 - games/default/files/mobs/rat.lua | 60 - games/default/files/mobs/sheep.lua | 142 -- .../files/mobs/sounds/mobs_fireball.ogg | Bin 22342 -> 0 bytes games/default/files/mobs/sounds/mobs_rat.ogg | Bin 11134 -> 0 bytes .../files/mobs/sounds/mobs_wolf_attack.ogg | Bin 9125 -> 0 bytes games/default/files/mobs/spawner.lua | 157 -- .../files/mobs/textures/mob_spawner.png | Bin 106 -> 0 bytes .../default/files/mobs/textures/mobs_bear.png | Bin 558 -> 0 bytes .../files/mobs/textures/mobs_blood.png | Bin 205 -> 0 bytes .../files/mobs/textures/mobs_bunny_brown.png | Bin 940 -> 0 bytes .../files/mobs/textures/mobs_bunny_grey.png | Bin 689 -> 0 bytes .../files/mobs/textures/mobs_bunny_white.png | Bin 775 -> 0 bytes .../files/mobs/textures/mobs_chick.png | Bin 860 -> 0 bytes .../files/mobs/textures/mobs_chicken.png | Bin 2703 -> 0 bytes .../mobs/textures/mobs_chicken_black.png | Bin 1622 -> 0 bytes .../files/mobs/textures/mobs_cooked_rat.png | Bin 144 -> 0 bytes .../default/files/mobs/textures/mobs_dog.png | Bin 592 -> 0 bytes .../default/files/mobs/textures/mobs_rat.png | Bin 365 -> 0 bytes .../default/files/mobs/textures/mobs_rat2.png | Bin 364 -> 0 bytes .../mobs/textures/mobs_rat_inventory.png | Bin 393 -> 0 bytes .../default/files/mobs/textures/mobs_wolf.png | Bin 621 -> 0 bytes games/default/files/mobs/zombie.lua | 76 - .../files/{mobs => mobs_animal}/bear.lua | 53 +- .../files/{mobs => mobs_animal}/bunny.lua | 20 +- games/default/files/mobs_animal/chicken.lua | 253 +++ .../files/{mobs => mobs_animal}/cow.lua | 41 +- games/default/files/mobs_animal/depends.txt | 2 + .../files/{mobs => mobs_animal}/dog.lua | 66 +- games/default/files/mobs_animal/init.lua | 17 + .../files/{mobs => mobs_animal}/kitten.lua | 32 +- .../{mobs => mobs_animal}/models/mobs_bear.x | 0 .../models/mobs_bunny.b3d | Bin .../models/mobs_chicken.x | 0 .../{mobs => mobs_animal}/models/mobs_cow.x | 0 .../models/mobs_kitten.b3d | Bin .../{mobs => mobs_animal}/models/mobs_pig.x | 0 .../models/mobs_sheep.b3d | Bin .../models/mobs_sheep_shaved.b3d | Bin .../{mobs => mobs_animal}/models/mobs_wolf.x | 0 games/default/files/mobs_animal/pig.lua | 63 + games/default/files/mobs_animal/rat.lua | 8 + games/default/files/mobs_animal/readme.md | 36 + games/default/files/mobs_animal/sheep.lua | 196 ++ .../sounds/mobs_bear.ogg | Bin .../sounds/mobs_bear_angry.ogg | Bin .../sounds/mobs_chicken.ogg | Bin .../{mobs => mobs_animal}/sounds/mobs_cow.ogg | Bin .../sounds/mobs_kitten.ogg | Bin .../{mobs => mobs_animal}/sounds/mobs_pig.ogg | Bin .../sounds/mobs_pig_angry.ogg | Bin .../sounds/mobs_sheep.ogg | Bin .../sounds/mobs_sheep_angry.ogg | Bin .../files/mobs_animal/textures/mobs_bear.png | Bin 0 -> 1096 bytes .../textures/mobs_bucket_milk.png | Bin .../mobs_animal/textures/mobs_bunny_brown.png | Bin 0 -> 233 bytes .../textures/mobs_bunny_evil.png | Bin .../mobs_animal/textures/mobs_bunny_grey.png | Bin 0 -> 230 bytes .../textures/mobs_bunny_inv.png | Bin .../mobs_animal/textures/mobs_bunny_white.png | Bin 0 -> 230 bytes .../textures/mobs_cheese.png | Bin .../textures/mobs_cheeseblock.png | Bin .../mobs_animal/textures/mobs_chicken.png | Bin 0 -> 902 bytes .../textures/mobs_chicken_black.png | Bin 0 -> 902 bytes .../textures/mobs_chicken_cooked.png | Bin .../textures/mobs_chicken_egg.png | Bin .../textures/mobs_chicken_egg_fried.png | Bin .../textures/mobs_chicken_inv.png | Bin .../textures/mobs_chicken_raw.png | Bin .../textures/mobs_cow.png | Bin .../files/mobs_animal/textures/mobs_cow2.png | Bin 0 -> 4158 bytes .../files/mobs_animal/textures/mobs_dog.png | Bin 0 -> 767 bytes .../textures/mobs_kitten_ginger.png | Bin .../textures/mobs_kitten_inv.png | Bin .../textures/mobs_kitten_sandy.png | Bin .../textures/mobs_kitten_splotchy.png | Bin .../textures/mobs_kitten_striped.png | Bin .../textures/mobs_pig.png | Bin .../textures/mobs_pork_cooked.png | Bin .../textures/mobs_pork_raw.png | Bin .../textures/mobs_sheep_black.png | Bin .../textures/mobs_sheep_blue.png | Bin .../textures/mobs_sheep_brown.png | Bin .../textures/mobs_sheep_cyan.png | Bin .../textures/mobs_sheep_dark_green.png | Bin .../textures/mobs_sheep_dark_grey.png | Bin .../textures/mobs_sheep_green.png | Bin .../textures/mobs_sheep_grey.png | Bin .../textures/mobs_sheep_magenta.png | Bin .../textures/mobs_sheep_orange.png | Bin .../textures/mobs_sheep_pink.png | Bin .../textures/mobs_sheep_red.png | Bin .../textures/mobs_sheep_shaved.png | Bin .../textures/mobs_sheep_violet.png | Bin .../textures/mobs_sheep_white.png | Bin .../textures/mobs_sheep_yellow.png | Bin .../files/mobs_animal/textures/mobs_wolf.png | Bin 0 -> 915 bytes games/default/files/mobs_monster/depends.txt | 2 + games/default/files/mobs_monster/init.lua | 8 + .../models/mobs_spider.x | 2 +- .../models/mobs_zombie.x} | 0 games/default/files/mobs_monster/readme.md | 38 + .../files/{mobs => mobs_monster}/skeleton.lua | 24 +- .../sounds/mobs_spider.ogg | Bin .../sounds/mobs_zombie.1.ogg | Bin .../sounds/mobs_zombie.2.ogg | Bin .../sounds/mobs_zombie.3.ogg | Bin .../sounds/mobs_zombie_attack.ogg | Bin .../sounds/mobs_zombie_death.ogg | Bin .../sounds/mobs_zombie_hit.ogg | Bin .../files/{mobs => mobs_monster}/spider.lua | 36 +- .../textures/mobs_cobweb.png | Bin .../textures/mobs_rotten_flesh.png | Bin .../textures/mobs_skeleton.png | Bin .../textures/mobs_spider.png | Bin .../textures/mobs_zombie.png | Bin .../textures/zombie_head.png | Bin games/default/files/mobs_monster/zombie.lua | 79 + .../default/files/{mobs => mobs_redo}/api.lua | 1959 +++++++++-------- .../files/{mobs => mobs_redo}/crafts.lua | 4 +- .../files/{mobs => mobs_redo}/depends.txt | 0 games/default/files/mobs_redo/init.lua | 8 + .../files/{mobs => mobs_redo}/license.txt | 14 +- games/default/files/mobs_redo/mod.conf | 1 + games/default/files/mobs_redo/readme.MD | 59 + .../sounds/default_punch.ogg | Bin .../textures/mobs_chicken_cooked.png | Bin 0 -> 364 bytes .../mobs_redo/textures/mobs_chicken_egg.png | Bin 0 -> 216 bytes .../textures/mobs_chicken_egg_overlay.png | Bin 0 -> 137 bytes .../mobs_redo/textures/mobs_chicken_raw.png | Bin 0 -> 401 bytes .../textures/mobs_leather.png | Bin .../textures/mobs_magic_lasso.png | Bin .../textures/mobs_meat.png | Bin .../textures/mobs_meat_raw.png | Bin .../textures/mobs_nametag.png | Bin .../textures/mobs_shears.png | Bin games/default/files/playerplus/init.lua | 232 +- .../railtrack/textures/carts_rail_brk.png | Bin 437 -> 436 bytes .../railtrack/textures/carts_rail_swt.png | Bin 437 -> 435 bytes .../textures/carts_rail_t_junction_brk.png | Bin 375 -> 374 bytes .../textures/carts_rail_t_junction_swt.png | Bin 370 -> 369 bytes .../railtrack/textures/railtrack_fixer.png | Bin 185 -> 180 bytes 154 files changed, 2126 insertions(+), 1871 deletions(-) delete mode 100644 games/default/files/mobs/README.txt delete mode 100644 games/default/files/mobs/chicken.lua delete mode 100644 games/default/files/mobs/init.lua delete mode 100644 games/default/files/mobs/models/mobs_rat.b3d delete mode 100644 games/default/files/mobs/npc.lua delete mode 100644 games/default/files/mobs/pig.lua delete mode 100644 games/default/files/mobs/rat.lua delete mode 100644 games/default/files/mobs/sheep.lua delete mode 100644 games/default/files/mobs/sounds/mobs_fireball.ogg delete mode 100644 games/default/files/mobs/sounds/mobs_rat.ogg delete mode 100644 games/default/files/mobs/sounds/mobs_wolf_attack.ogg delete mode 100644 games/default/files/mobs/spawner.lua delete mode 100644 games/default/files/mobs/textures/mob_spawner.png delete mode 100644 games/default/files/mobs/textures/mobs_bear.png delete mode 100644 games/default/files/mobs/textures/mobs_blood.png delete mode 100644 games/default/files/mobs/textures/mobs_bunny_brown.png delete mode 100644 games/default/files/mobs/textures/mobs_bunny_grey.png delete mode 100644 games/default/files/mobs/textures/mobs_bunny_white.png delete mode 100644 games/default/files/mobs/textures/mobs_chick.png delete mode 100644 games/default/files/mobs/textures/mobs_chicken.png delete mode 100644 games/default/files/mobs/textures/mobs_chicken_black.png delete mode 100644 games/default/files/mobs/textures/mobs_cooked_rat.png delete mode 100644 games/default/files/mobs/textures/mobs_dog.png delete mode 100644 games/default/files/mobs/textures/mobs_rat.png delete mode 100644 games/default/files/mobs/textures/mobs_rat2.png delete mode 100644 games/default/files/mobs/textures/mobs_rat_inventory.png delete mode 100644 games/default/files/mobs/textures/mobs_wolf.png delete mode 100644 games/default/files/mobs/zombie.lua rename games/default/files/{mobs => mobs_animal}/bear.lua (61%) rename games/default/files/{mobs => mobs_animal}/bunny.lua (81%) create mode 100644 games/default/files/mobs_animal/chicken.lua rename games/default/files/{mobs => mobs_animal}/cow.lua (76%) create mode 100644 games/default/files/mobs_animal/depends.txt rename games/default/files/{mobs => mobs_animal}/dog.lua (61%) create mode 100644 games/default/files/mobs_animal/init.lua rename games/default/files/{mobs => mobs_animal}/kitten.lua (62%) rename games/default/files/{mobs => mobs_animal}/models/mobs_bear.x (100%) rename games/default/files/{mobs => mobs_animal}/models/mobs_bunny.b3d (100%) rename games/default/files/{mobs => mobs_animal}/models/mobs_chicken.x (100%) rename games/default/files/{mobs => mobs_animal}/models/mobs_cow.x (100%) rename games/default/files/{mobs => mobs_animal}/models/mobs_kitten.b3d (100%) rename games/default/files/{mobs => mobs_animal}/models/mobs_pig.x (100%) rename games/default/files/{mobs => mobs_animal}/models/mobs_sheep.b3d (100%) rename games/default/files/{mobs => mobs_animal}/models/mobs_sheep_shaved.b3d (100%) rename games/default/files/{mobs => mobs_animal}/models/mobs_wolf.x (100%) create mode 100644 games/default/files/mobs_animal/pig.lua create mode 100644 games/default/files/mobs_animal/rat.lua create mode 100644 games/default/files/mobs_animal/readme.md create mode 100644 games/default/files/mobs_animal/sheep.lua rename games/default/files/{mobs => mobs_animal}/sounds/mobs_bear.ogg (100%) rename games/default/files/{mobs => mobs_animal}/sounds/mobs_bear_angry.ogg (100%) rename games/default/files/{mobs => mobs_animal}/sounds/mobs_chicken.ogg (100%) rename games/default/files/{mobs => mobs_animal}/sounds/mobs_cow.ogg (100%) rename games/default/files/{mobs => mobs_animal}/sounds/mobs_kitten.ogg (100%) rename games/default/files/{mobs => mobs_animal}/sounds/mobs_pig.ogg (100%) rename games/default/files/{mobs => mobs_animal}/sounds/mobs_pig_angry.ogg (100%) rename games/default/files/{mobs => mobs_animal}/sounds/mobs_sheep.ogg (100%) rename games/default/files/{mobs => mobs_animal}/sounds/mobs_sheep_angry.ogg (100%) create mode 100644 games/default/files/mobs_animal/textures/mobs_bear.png rename games/default/files/{mobs => mobs_animal}/textures/mobs_bucket_milk.png (100%) create mode 100644 games/default/files/mobs_animal/textures/mobs_bunny_brown.png rename games/default/files/{mobs => mobs_animal}/textures/mobs_bunny_evil.png (100%) create mode 100644 games/default/files/mobs_animal/textures/mobs_bunny_grey.png rename games/default/files/{mobs => mobs_animal}/textures/mobs_bunny_inv.png (100%) create mode 100644 games/default/files/mobs_animal/textures/mobs_bunny_white.png rename games/default/files/{mobs => mobs_animal}/textures/mobs_cheese.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_cheeseblock.png (100%) create mode 100644 games/default/files/mobs_animal/textures/mobs_chicken.png create mode 100644 games/default/files/mobs_animal/textures/mobs_chicken_black.png rename games/default/files/{mobs => mobs_animal}/textures/mobs_chicken_cooked.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_chicken_egg.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_chicken_egg_fried.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_chicken_inv.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_chicken_raw.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_cow.png (100%) create mode 100644 games/default/files/mobs_animal/textures/mobs_cow2.png create mode 100644 games/default/files/mobs_animal/textures/mobs_dog.png rename games/default/files/{mobs => mobs_animal}/textures/mobs_kitten_ginger.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_kitten_inv.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_kitten_sandy.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_kitten_splotchy.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_kitten_striped.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_pig.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_pork_cooked.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_pork_raw.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_black.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_blue.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_brown.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_cyan.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_dark_green.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_dark_grey.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_green.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_grey.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_magenta.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_orange.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_pink.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_red.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_shaved.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_violet.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_white.png (100%) rename games/default/files/{mobs => mobs_animal}/textures/mobs_sheep_yellow.png (100%) create mode 100644 games/default/files/mobs_animal/textures/mobs_wolf.png create mode 100644 games/default/files/mobs_monster/depends.txt create mode 100644 games/default/files/mobs_monster/init.lua rename games/default/files/{mobs => mobs_monster}/models/mobs_spider.x (99%) rename games/default/files/{mobs/models/zombie.x => mobs_monster/models/mobs_zombie.x} (100%) create mode 100644 games/default/files/mobs_monster/readme.md rename games/default/files/{mobs => mobs_monster}/skeleton.lua (52%) rename games/default/files/{mobs => mobs_monster}/sounds/mobs_spider.ogg (100%) rename games/default/files/{mobs => mobs_monster}/sounds/mobs_zombie.1.ogg (100%) rename games/default/files/{mobs => mobs_monster}/sounds/mobs_zombie.2.ogg (100%) rename games/default/files/{mobs => mobs_monster}/sounds/mobs_zombie.3.ogg (100%) rename games/default/files/{mobs => mobs_monster}/sounds/mobs_zombie_attack.ogg (100%) rename games/default/files/{mobs => mobs_monster}/sounds/mobs_zombie_death.ogg (100%) rename games/default/files/{mobs => mobs_monster}/sounds/mobs_zombie_hit.ogg (100%) rename games/default/files/{mobs => mobs_monster}/spider.lua (74%) rename games/default/files/{mobs => mobs_monster}/textures/mobs_cobweb.png (100%) rename games/default/files/{mobs => mobs_monster}/textures/mobs_rotten_flesh.png (100%) rename games/default/files/{mobs => mobs_monster}/textures/mobs_skeleton.png (100%) rename games/default/files/{mobs => mobs_monster}/textures/mobs_spider.png (100%) rename games/default/files/{mobs => mobs_monster}/textures/mobs_zombie.png (100%) rename games/default/files/{mobs => mobs_monster}/textures/zombie_head.png (100%) create mode 100644 games/default/files/mobs_monster/zombie.lua rename games/default/files/{mobs => mobs_redo}/api.lua (64%) rename games/default/files/{mobs => mobs_redo}/crafts.lua (99%) rename games/default/files/{mobs => mobs_redo}/depends.txt (100%) create mode 100644 games/default/files/mobs_redo/init.lua rename games/default/files/{mobs => mobs_redo}/license.txt (80%) create mode 100644 games/default/files/mobs_redo/mod.conf create mode 100644 games/default/files/mobs_redo/readme.MD rename games/default/files/{mobs => mobs_redo}/sounds/default_punch.ogg (100%) create mode 100644 games/default/files/mobs_redo/textures/mobs_chicken_cooked.png create mode 100644 games/default/files/mobs_redo/textures/mobs_chicken_egg.png create mode 100644 games/default/files/mobs_redo/textures/mobs_chicken_egg_overlay.png create mode 100644 games/default/files/mobs_redo/textures/mobs_chicken_raw.png rename games/default/files/{mobs => mobs_redo}/textures/mobs_leather.png (100%) rename games/default/files/{mobs => mobs_redo}/textures/mobs_magic_lasso.png (100%) rename games/default/files/{mobs => mobs_redo}/textures/mobs_meat.png (100%) rename games/default/files/{mobs => mobs_redo}/textures/mobs_meat_raw.png (100%) rename games/default/files/{mobs => mobs_redo}/textures/mobs_nametag.png (100%) rename games/default/files/{mobs => mobs_redo}/textures/mobs_shears.png (100%) diff --git a/games/default/files/beds/spawns.lua b/games/default/files/beds/spawns.lua index f3980a7a0..48b8a6694 100644 --- a/games/default/files/beds/spawns.lua +++ b/games/default/files/beds/spawns.lua @@ -41,10 +41,12 @@ function beds.save_spawns() if not beds.spawn then return end + local data = {} local output = io.open(org_file, "w") - for i, v in pairs(beds.spawn) do - output:write(v.x .. " " .. v.y .. " " .. v.z .. " " .. i .. "\n") + for k, v in pairs(beds.spawn) do + table.insert(data, string.format("%.1f %.1f %.1f %s\n", v.x, v.y, v.z, k)) end + output:write(table.concat(data)) io.close(output) end diff --git a/games/default/files/crafting/textures/crafting_hotbar.png b/games/default/files/crafting/textures/crafting_hotbar.png index 79893b2359385dddcea88ad6dda6a40f302e82e1..805cd4953ddd7dd1e9f9c6299144a208083d7c6a 100644 GIT binary patch delta 340 zcmX@lypwrCUcH&8i(^Q|t+#g+`wlsXw0~TA@KI7HOXoX}XSU)YmF^zue8R z=z(Whm~w-2ZrrVP$!R9hrc9)BhKfkGWTdq@LSYF7L=H8WKP~;=SY7!dTy9Y2B0M zjP0aWI9)L*IiAyBrFGw}UL|XHes@kko7VkfQg(-pY=13Z6yjx?Rd8aZox@cBqrXqr ZHrD6pUF%*HD%!{Z1fH&bF6*2UngF?;j&T40 delta 362 zcmdnVe4cqiUcHZ}i(^PdToMD*>6t7CG-jM(U}BnM%-IxZ&^WQNF|gp-89t^2ku!5N zH4YqDVYykkmqCJ6)>yrTw2WOdRNL=i)a&$B;cDpt6?vDdAO#~z!c3Gu2 zHLcQ3FSoSY@LS@<8o_lM%u*q@oj*2aO-RgCjutdo!SLq7M&5dd0EyO%Pv?1QZ*2az zHbJD9QRT*gpieEAx^LCz{e3EyZc{Y<-t{llmfUi8LyG;jnq~u8wTr#3N50_@)e2b= z@K?pDl?%*TNDd=80H`f1Vpr5Pzo$ACUjlMNFTb_omYsW>mwVNg(A^&!Lo*c&4v8LY z(#jRJo502hbh*un56yuLoLc83GhG@2FIYDISRlo#mGt?31|JJUj^4HI3wO?3WB>wB LS3j3^P6CGe<{9 ze}8|To}Rh6xzp3ra6aCN00001bW%=J06^y0W&i*Hq)9|URCr!vAP%IZp$ag~oT-2! zpfPjiBoqZ5m;z}X2}lB&9c>I5C;~GS7?@B5Kn5tF3ouY5fPXNQ1>IUN0aS;vtO`VR zy4P}qz|2V?1?9m42=9Xw00j^M1X55MY={U#kb+Q<01SW>goYXmzy&}GPzB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Oj`UOq*i0a_nAGN;Ne|P=K4_&xsTp#+se&eKNntzuiRm9E0x4o>d_Mbhg>tkkg z2diYkX0Pe`eA=^vRd}VLy#Cbs>eu(U6;(vaam(5@s$PEf$x-4zv5^VRy(#aHN#07L z(b8Kkzkl1Sb3tCPIZ$x?xu}Xl<2LW%`XMb};F>?V9SUBSe|qvUEBo5F)`rVnEcWO4 zvp1-Ib2ga3H5&6%#(?9(wyX&cAE~mf7Weswx z*AwZl)t6)GL4U=y^>_Ufhn84htUTkczqWqTqurHbF4yYI+U$?~S+&yj)3~Z{)1O@J zpXM(;zHNKlnv`N*Kk|iNJonf3hvP-nlO-?km)D1!{%ZX-E_U^cYc0Rbj59IVWov-@&r0!pS_VW42^P{Zu z&2&C1f79<1&!;c9wm1I1@qF_&YhLd8XzEX$ucrAA$N4n*&tA*)`*#uN+s*q8jQbOV z^D*euCNJyzTfZoruf+kIyd#G9OD_CH>1yzKFrN$a#gEj(Zagyf)Pw3mp%8P%c&zMc z2sME4*j(m}n?X&XCeSNR&bS5C914S4Ld+Srfm%bYAU<fq#z`52uK-J>BsA!p9GD-;9aLAj@!lQWKmdO+QwI45UpL0%{x;=@|zj1!?>LJ3e$ zh&kilP!iM&>f_{$`$PSpzR&ITpb1XScoH-bN`+p7m@|GIngUIRraC#}H=s0V8Z_O>8P9@dLNlP* zPR@8PGzUtD<~cdz1yBYwANq}xGhPfWf)+wcoSgA8C=*%=Eq8LpE1)-_ENCUfobhUC z6_gF-I633Dpj>DTwARTPZ-CZA>!6KJ&UiEQHna)a;^d6CLBEBzLhm>^qr2YMf3&iDZIJ7_=jfs->n1bqk{gbq77<73cK=m>P&$r{{bScM>YTe diff --git a/games/default/files/mobs/npc.lua b/games/default/files/mobs/npc.lua deleted file mode 100644 index 82951ae75..000000000 --- a/games/default/files/mobs/npc.lua +++ /dev/null @@ -1,3 +0,0 @@ -mobs:register_mob("mobs:npc", { - lifetimer = 1, -}) \ No newline at end of file diff --git a/games/default/files/mobs/pig.lua b/games/default/files/mobs/pig.lua deleted file mode 100644 index 701ad718f..000000000 --- a/games/default/files/mobs/pig.lua +++ /dev/null @@ -1,63 +0,0 @@ --- Warthog(Boar) by KrupnoPavel (MIT) --- Changed to Boar and tweaked by Kaadmy (WTFPL) and MoNTE48 (LGPLv3) -mobs:register_mob("mobs:pig", { - type = "animal", - passive = false, - attack_type = "dogfight", - group_attack = true, - reach = 2, - damage = 2, - hp_min = 5, - hp_max = 15, - armor = 100, - collisionbox = {-0.4, -1, -0.4, 0.4, 0.1, 0.4}, - visual = "mesh", - mesh = "mobs_pig.x", - textures = { - {"mobs_pig.png"}, - }, - makes_footstep_sound = true, - sounds = { - random = "mobs_pig", - attack = "mobs_pig_angry", - death = "mobs_pig_angry", - }, - walk_velocity = 2, - run_velocity = 3, - jump = true, - follow = {"default:apple", "farming:potato"}, - view_range = 10, - drops = { - {name = "mobs:pork_raw", - chance = 1, min = 1, max = 1}, - {name = "mobs:pork_raw", - chance = 2, min = 1, max = 1}, - {name = "mobs:pork_raw", - chance = 2, min = 1, max = 1}, - }, - water_damage = 1, - lava_damage = 5, - light_damage = 0, - fear_height = 2, - animation = { - speed_normal = 20, - stand_start = 0, - stand_end = 60, - walk_start = 61, - walk_end = 80, - punch_start = 90, - punch_end = 110, - }, - on_rightclick = function(self, clicker) - mobs:feed_tame(self, clicker, 8, true, true) - mobs:capture_mob(self, clicker, 0, 5, 50, false, nil) - end, -}) - -mobs:spawn_specific("mobs:pig", - {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, - {"air"}, - 0, 20, 0, 5000, 1, -31000, 31000 - ) - -mobs:register_egg("mobs:pig", "Pig", "wool_pink.png", 1) diff --git a/games/default/files/mobs/rat.lua b/games/default/files/mobs/rat.lua deleted file mode 100644 index dd400441b..000000000 --- a/games/default/files/mobs/rat.lua +++ /dev/null @@ -1,60 +0,0 @@ - --- Rat by PilzAdam - -mobs:register_mob("mobs:rat", { - type = "animal", - passive = true, - hp_min = 1, - hp_max = 4, - armor = 100, - collisionbox = {-0.25, -1, -0.25, 0.25, -0.8, 0.25}, - visual = "mesh", - mesh = "mobs_rat.b3d", - textures = { - {"mobs_rat.png"}, - {"mobs_rat2.png"}, - }, - makes_footstep_sound = false, - sounds = { - random = "mobs_rat", - }, - drops = { - {name = "mobs:rat_meat", - chance = 1, min = 1, max = 1}, - }, - walk_velocity = 1, - run_velocity = 2, - runaway = true, - jump = true, - water_damage = 0, - lava_damage = 4, - light_damage = 0, - fear_height = 2, -}) - -mobs:spawn_specific("mobs:rat", - {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, - {"air"}, - 0, 20, 0, 4000, 1, -31000, 31000 - ) - -mobs:register_egg("mobs:rat", "Rat", "mobs_rat_inventory.png", 0) - -minetest.register_craftitem("mobs:rat_cooked", { - description = "Cooked Rat", - inventory_image = "mobs_cooked_rat.png", - on_use = minetest.item_eat(3), -}) - -minetest.register_craftitem("mobs:rat_meat", { - description = "Meat Rat", - inventory_image = "mobs_rat_inventory.png", - on_use = minetest.item_eat(1), -}) - -minetest.register_craft({ - type = "cooking", - output = "mobs:rat_cooked", - recipe = "mobs:rat", - cooktime = 5, -}) \ No newline at end of file diff --git a/games/default/files/mobs/sheep.lua b/games/default/files/mobs/sheep.lua deleted file mode 100644 index 4a21076a6..000000000 --- a/games/default/files/mobs/sheep.lua +++ /dev/null @@ -1,142 +0,0 @@ -local all_colours = { - "grey", "black", "red", "yellow", "green", "cyan", "blue", "magenta", - "white", "orange", "violet", "brown", "pink", "dark_grey", "dark_green" -} - --- Sheep by PilzAdam - -for _, col in ipairs(all_colours) do - - mobs:register_mob("mobs:sheep_"..col, { - type = "animal", - passive = true, - hp_min = 6, - hp_max = 10, - armor = 100, - collisionbox = {-0.4, -1, -0.4, 0.4, 0.3, 0.4}, - visual = "mesh", - mesh = "mobs_sheep.b3d", - textures = { - {"mobs_sheep_"..col..".png"}, - }, - gotten_texture = {"mobs_sheep_shaved.png"}, - gotten_mesh = "mobs_sheep_shaved.b3d", - makes_footstep_sound = true, - sounds = { - random = "mobs_sheep", - damage = "mobs_sheep_angry", - death = "mobs_sheep_angry", - }, - walk_velocity = 1, - jump = true, - drops = { - {name = "mobs:meat_raw", - chance = 1, min = 1, max = 2}, - {name = "wool:"..col, - chance = 1, min = 1, max = 1}, - }, - water_damage = 1, - lava_damage = 5, - light_damage = 0, - fear_height = 2, - animation = { - speed_normal = 15, - speed_run = 15, - stand_start = 0, - stand_end = 80, - walk_start = 81, - walk_end = 100, - }, - follow = {"farming:wheat", "default:grass_5"}, - view_range = 8, - replace_rate = 10, - replace_what = {"default:grass_3", "default:grass_4", "default:grass_5", "farming:wheat_8"}, - replace_with = "air", - replace_offset = -1, - on_rightclick = function(self, clicker) - local shpcolor = string.split(self.name,"_")[2] - if shpcolor =="dark" then - shpcolor = shpcolor.."_"..string.split(self.name,"_")[3] - end - - --are we feeding? - if mobs:feed_tame(self, clicker, 8, true, true) then - --if full grow fuzz - if self.gotten == false then - self.object:set_properties({ - textures = {"mobs_sheep_"..shpcolor..".png"}, - mesh = "mobs_sheep.b3d", - }) - end - return - end - - local item = clicker:get_wielded_item() - local itemname = item:get_name() - - --are we giving a haircut> - if itemname == "mobs:shears" then - if self.gotten == false and self.child == false then - self.gotten = true -- shaved - if minetest.get_modpath("wool") then - local pos = self.object:getpos() - pos.y = pos.y + 0.5 - local obj = minetest.add_item(pos, ItemStack("wool:"..shpcolor.." "..math.random(1,3))) - if obj then - obj:setvelocity({ - x = math.random(-1,1), - y = 5, - z = math.random(-1,1) - }) - end - item:add_wear(650) -- 100 uses - clicker:set_wielded_item(item) - end - self.object:set_properties({ - textures = {"mobs_sheep_shaved.png"}, - mesh = "mobs_sheep_shaved.b3d", - }) - end - return - end - - local name = clicker:get_player_name() - - --are we coloring? - if itemname:find("dye:") then - if self.gotten == false and self.child == false and self.tamed == true and name == self.owner then - local col = string.split(itemname,":")[2] - for _,c in pairs(all_colours) do - if c == col then - local pos = self.object:getpos() - self.object:remove() - local mob = minetest.add_entity(pos, "mobs:sheep_"..col) - local ent = mob:get_luaentity() - ent.owner = name - ent.tamed = true - -- take item - if not minetest.setting_getbool("creative_mode") then - item:take_item() - clicker:set_wielded_item(item) - end - break - end - end - end - return - end - - --are we capturing? - mobs:capture_mob(self, clicker, 0, 5, 60, false, nil) - end - }) - - mobs:register_egg("mobs:sheep_"..col, "Sheep ("..col..")", "wool_"..col..".png", 1) - -end - -mobs:spawn_specific("mobs:sheep_white", - {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, - {"air"}, - 0, 20, 0, 5000, 1, -31000, 31000 - ) \ No newline at end of file diff --git a/games/default/files/mobs/sounds/mobs_fireball.ogg b/games/default/files/mobs/sounds/mobs_fireball.ogg deleted file mode 100644 index bdc4ac21f73d35b865ae6295067d0730a88bb6e8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 22342 zcmeFZcUV(R_b9qU?@}X84ZS5wXfH*4LzONq5P~3t8miJ11P#>?iZtmcy@Ui4X(Ebr zrKv~fm&vvRMX{r-O`+01{Y zQU*t0@Mryxo(l7W1>tc{zZZa+!_-ufs;cU0nlMF^D4($C^Zq_zK1z)Fgu#zPsBgr1 z&oCc-Q!AK5M5H%96s8Sf{WGJIp^*~=-~dMeB>6-?;!vL9KtB&_~P3C*X8Sy@AJRE zQ2q~<0Tc+!2j?UooRc-NmwgZhXa5c1hX9CEls$YPOygv@#)I(V;B_*>cqq?m?6cK@ ze<6W^b^t&jB?rz)4uR0HM@)oiI*04egj>&mpkP4ce_i5#(+ju}sWRXE00M`4mgjG< z5Ws0gD>#gJ{;UKJAXdDF6+bEdG^WE>{HDA?xMZRy)v-jOqoJ_mHwJ?qiM;}GsWe

18YCLOFxWpGTQzt`Jh0&dCrOsmLckZ_`P!&03`AMrs99yev|SaDz45UDGw_) zkE)Hp88=GbBi%JxAHNX~5~O0dCP>8@tt;2V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kgF-rjel3S z-B>p*7|oh_cZeRlOWEpl+!Imk&yvRHv0DujibAz4Zg~}RYNlq()Z$o3%pdZ_6{muu zER5F;f9*FpaN#2qR$_)qNUlbwTHk6drk|hPGLc*sZV<=#$we9uKa1V?Y2!BjNuQHj zvzC%?Mt%7`IJ8~Q<{L-4uou2xO-=9`q7w)N)m>|>4mjq9I}AVF3{yg_=`h%NB^M;C z%*>*6L0SNyd+^smY!T6we9Ej+KUKOZ+2pvpFjST#Yzq`yRndvIs-t@dm0D;flBmkJ zRbhA#h>$w{HCCU7nAKF?9Sju?Q#sBqMbrcZ_^Sar8>XW)nQnNRekoN zXK)+HkKPCaJyT$!quWWMWAW1!96b@j|6+av#XX$LZY7Hzi8-0`GNhH{{^pij4W#UK zGog&z$0kOm(cXB>WYjgyiv8zJjiJo}-^X3U8lgDBzlY2)FipD9(P4kd3IduKxR_)# zT*xAo&~izPx`%x{6GpwehnQNTM3S>nk~32x3jC}F%Z+)N+wvM7A&x~nUz(v}Yg5lf z&(u`9PhG$LPqpv1tes>C!~@BH*}1Z3awntPE2MluBpBy;M})uFd1s$2J*Zs{@*j8< BusQ$$ diff --git a/games/default/files/mobs/sounds/mobs_rat.ogg b/games/default/files/mobs/sounds/mobs_rat.ogg deleted file mode 100644 index 0e992671eff640aa945e4a46a3dd228426b15e68..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 11134 zcmb7qbzGFs_wPeUNl8fy2*?sjNJ>dbiYzQC-7T?%NJ@7sjfAk2qzDK~D2+7i(jbzO zA`Jrf0YBgG{eJHs_jm8S=9xXunVECu%$)bkndi0Y*4CN;Ch$-C6FKB~Mb-ieGZ>5* z9?q_2wr*Dp47swa9{~8Jj&c3_5kvi|=fBfc&#Ri#pE!jiHkbdI60rWt;Q_04ZC}{j zS9i5$aS33W)y4qu03d)xmAXA(C>{m?qyUgx zCY<8a-E=hP6IlF&!YBNSS}c1q^fJ5wq_&%iXnnqcJU6C?7L)*h4Fo{&GF-pQt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JGL2itNK0GIbNVHoR|x-cGDUXl<{M4$0vT;`=8zd41)bB6(~9Iy*3I*tdPqVw zJnSwo)5|lZ*Ud2JtIz8s1xU$Hv)+Ro6~Y`q>K zvE7T0+yRMmo2_XS>@*~!9v8`fjyODngHY8)SaT`LmP&efz|i<$HgnMG))vvq>gwv9 z>iLH#EQ->Fop%>lpQ^ve*zR1mYELtFM~Hf0S7NTLFw+)#GtA&%^$k9$nKzoB<2Er0 fk_h`;gEO|qfC2mMxwJq92%985GWGNGGs65|KIF#9 diff --git a/games/default/files/mobs/sounds/mobs_wolf_attack.ogg b/games/default/files/mobs/sounds/mobs_wolf_attack.ogg deleted file mode 100644 index 4b06f51544df60e7380e28979d192284b8d71d95..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9125 zcmaiZ2|Uza_y1??WXqN{BgBZZXOwISgJc*x$-c{4k(#nZG{o4(^0kdEgJhRI`rZg}9PPF?U&e#;9=of0a(sQ$}JS-Pq~A z<7Hhh2dJx)wc!bSs3ufWTtZv|tWaTn8^?RT_IB>R4i0ucFd}yd`RQVqimD+5paMrE zw4tr&foK!}Fam&;0E|A?UK57LW(Yq@#A*WQ{*zi_%n@EYae>G5PTUG!d1JJ_M zn5-pD=RUXtyAZ}J9qx2nE*DDqQg0Sc-TdRCjeAa6j*ELAOpuDsgd6}hqolzX!h$3= z)?s|1>|pbP+pB{wH^qxaBrp9rjbsNjNLz9xJNCBxN?sO5epR?^K;?{B*&sq&V#Ls< zsE)$ov3DPQIpyz$`s5r?a4#wp9JY)qR7Cb+u$)9Mkk#q2pa2>?CZPVBMe{97_gn7X zj{>^iMD>_uK1!+S8|a|G;%i~#XE)~OJLVT?k{DuE6=+fwVm2OPu^)1eJ@oJTGjL{~ zSWk`)g#hXN@c1vV%nO{E^YBd4;Lt)6z?P^ID0R#QSWK2?j=gh{Q*wpln+mt?Qqk^G z+LI{&1e`)F=}x$u|EJoU#M}MvRmrhK1W*EX+3v~R?kS*#6lnJnr99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RmhtBbPAYr}7R9pua%Hm3m4qlM~;!K^iTc5$nE*DSTuRw#zW zZ^qxwu&*Dw`l`^KIx7`pFc1W3Ps&NW^{(Kp+wqyn;G_)yYYr>`C3Ds~&&+Ja9bx@h zmCC@EgcY}E2>=st@ZtRK~!s?O@{A`r-rmcgtET<0T!3ZO5J}QRiVA|Aa-i)PtmCSrmXoo_Juz7$+ zPGowsKJaU}GZkkeIY}xwJfOnO4TyG_G|0OuZX1i(9l*di6 zCXUbn=dbq68CYtOkMiys20n1g+)uKauSCi2usq8F%-V%1-8-8TFYe3)C9ggG9t#LDm*MY%#7_{ zr(W!;bU&|VNG3CVG%~F=ECBwS)aGmhod5F^VyWo^VNhEQqli0tZv?p^OZ#iQm`=-b zvGVNF(5FS`d)!tObaVIRP(>_UG#!6_jq;mKR!$XvzdN)>Iy!p(_z@1S8Y`Eg5H9jE zOPMzj8HNj)V@-WTuV*k0V{(1az_Q7~_U(zR5b&-<{Mg`0k*BKgFJj>TJ=2;Gc zFdswdNLk~}FW)ke2LOLr-|w3B{RzcS%PP*ayqLiUzI8Yld9>tnmA*)7UuV(Xm=Mp8 z#-86!If@b5O8i)Ak zM&}z|H`Efjp0t^oPr7icYFR8wprT$NLOHfGV7`-m6JQ+SRej1bLISufNUV$Pa_^I+ RD;6j^qlH^#4*s~({vXIvPDKC! diff --git a/games/default/files/mobs/spawner.lua b/games/default/files/mobs/spawner.lua deleted file mode 100644 index 762f1204e..000000000 --- a/games/default/files/mobs/spawner.lua +++ /dev/null @@ -1,157 +0,0 @@ --- mob spawner - -local spawner_default = "mobs:pumba 10 15 0 0" - -minetest.register_node("mobs:spawner", { - tiles = {"mob_spawner.png"}, - drawtype = "glasslike", - paramtype = "light", - walkable = true, - description = "Mob Spawner", - groups = {cracky = 1}, - - on_construct = function(pos) - - local meta = minetest.get_meta(pos) - - -- text entry formspec - meta:set_string("formspec", "field[text;Mob MinLight MaxLight Amount PlayerDist;${command}]") - meta:set_string("infotext", "Spawner Not Active (enter settings)") - meta:set_string("command", spawner_default) - end, - - on_right_click = function(pos, placer) - - if minetest.is_protected(pos, placer:get_player_name()) then - return - end - --- local meta = minetest.get_meta(pos) - end, - - on_receive_fields = function(pos, formname, fields, sender) - - if not fields.text or fields.text == "" then - return - end - - local meta = minetest.get_meta(pos) - local comm = fields.text:split(" ") - local name = sender:get_player_name() - - if minetest.is_protected(pos, name) then - minetest.record_protection_violation(pos, name) - return - end - - local mob = comm[1] -- mob to spawn - local mlig = tonumber(comm[2]) -- min light - local xlig = tonumber(comm[3]) -- max light - local num = tonumber(comm[4]) -- total mobs in area - local pla = tonumber(comm[5])-- player distance (0 to disable) - - if mob and mob ~= "" and mobs.spawning_mobs[mob] == true - and num and num >= 0 and num <= 10 - and mlig and mlig >= 0 and mlig <= 15 - and xlig and xlig >= 0 and xlig <= 15 - and pla and pla >=0 and pla <= 20 then - - meta:set_string("command", fields.text) - meta:set_string("infotext", "Spawner Active (" .. mob .. ")") - - else - minetest.chat_send_player(name, "Mob Spawner settings failed!") - end - end, -}) - --- spawner abm -minetest.register_abm({ - nodenames = {"mobs:spawner"}, - interval = 10, - chance = 4, - catch_up = false, - - action = function(pos, node, active_object_count, active_object_count_wider) - - -- check objects inside 9x9 area around spawner - local objs = minetest.get_objects_inside_radius(pos, 9) - - -- get meta and command - local meta = minetest.get_meta(pos) - local comm = meta:get_string("command"):split(" ") - - -- get settings from command - local mob = comm[1] - local mlig = tonumber(comm[2]) - local xlig = tonumber(comm[3]) - local num = tonumber(comm[4]) - local pla = tonumber(comm[5]) or 0 - - -- if amount is 0 then do nothing - if num == 0 then - return - end - - local count = 0 - local ent = nil - - -- count mob objects of same type in area - for k, obj in pairs(objs) do - - ent = obj:get_luaentity() - - if ent and ent.name == mob then - count = count + 1 - end - end - - -- is there too many of same type? - if count >= num then - return - end - - -- spawn mob if player detected and in range - if pla > 0 then - - local in_range = 0 - local objs = minetest.get_objects_inside_radius(pos, pla) - - for _,oir in pairs(objs) do - - if oir:is_player() then - - in_range = 1 - - break - end - end - - -- player not found - if in_range == 0 then - return - end - end - - -- find air blocks within 5 nodes of spawner - local air = minetest.find_nodes_in_area( - {x = pos.x - 5, y = pos.y, z = pos.z - 5}, - {x = pos.x + 5, y = pos.y, z = pos.z + 5}, - {"air"}) - - -- spawn in random air block - if air and #air > 0 then - - local pos2 = air[math.random(#air)] - local lig = minetest.get_node_light(pos2) or 0 - - pos2.y = pos2.y + 0.5 - - -- only if light levels are within range - if lig >= mlig and lig <= xlig then - minetest.add_entity(pos2, mob) - end - end - - end -}) \ No newline at end of file diff --git a/games/default/files/mobs/textures/mob_spawner.png b/games/default/files/mobs/textures/mob_spawner.png deleted file mode 100644 index fbb3da49ea258337d9f329e6ebed9e1cde570201..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 106 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!D3?x-;bCrM;TYyi9E09+5%h?i;vJ=Q+ED7=p yW^j0RBMrzA@^o| diff --git a/games/default/files/mobs/textures/mobs_bear.png b/games/default/files/mobs/textures/mobs_bear.png deleted file mode 100644 index f78810eed3f2fb0bad2d1bc1778e10da3aa6e5bf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 558 zcmV+}0@3}6P)i0Y^zhK~#8NebU!%!axu}QSQtZcX|n=_uljWzZNoD2@}9qew$;B%l7Dw zPT-*22TnN2DQ2MPUH~YLZomwjG|F<`M{i5_W(~;AVgV zgKYqiz#x#pMF0i)57NB~K~Y4uSBSy4_nfa!00SJM$@GwnyqG`2sMojow9>5dviX|= z6rhkcR8aM40b!GfFjb{#flL%tGEkc{t*CJJsSV)7?B)$#Q2Inn%t!wfe@ZcvA470o1vUqPu5B};8?0ssI207*qoM6N<$f(#AE!~g&Q diff --git a/games/default/files/mobs/textures/mobs_blood.png b/games/default/files/mobs/textures/mobs_blood.png deleted file mode 100644 index d2ea7b60194d040ba193f470595f75ebe64580d0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 205 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!73?$#)eFPGa4)6(atzcl7$G~uzf#LuE|CMld zWaR(#>!ZF+@&zhmDGBlm2GR_hC#THGm!B(iKiBq_cf`8w=O6L!IUx4-)_=VjAPYTR{an^LB{Ts5ZW~Du diff --git a/games/default/files/mobs/textures/mobs_bunny_brown.png b/games/default/files/mobs/textures/mobs_bunny_brown.png deleted file mode 100644 index f272bae50f06a752e646ca6fa2a5ee62c97114c9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 940 zcmV;d15^BoP)9lw}Du^fLXqPRJnpvw1ir_gj~dhS-FW`#)nkDh+n~o zTFi!4$%m15VHY0{W! z&YN%3nsCaTc-)$2*_nISoNUOTm)xOo*`jyOqm=2NZsVbC$fl3XrikOBbke4P;ih)v zsCeh9bkDDu?y7d(uZGLHug|%u_OgA=y|~Z7z3|xEW@@ap0007~Nkluww; z6o5bA06Q~luP^r9%g^ZqZ=|Bck9R-~kMHl8bRfJ%PRGM3;h-|teS8Pjai;>)On z;ph6h>{d!TRJ6~|olb+nd?`k)4d6feRpbNzoJHr3o#J@_@FghQ*anYSIm3kW;X7V# z789lK4?jM^^Uq*)UXVZ>IUVV?Pm1j4PUI8d86eswC(_A@vy$Phn7=;q&Fd2oXvcC! z$efaOm%2Q{b76CaE~tUzO0m*nO>wm`I{@67CC|SimsYkM`$g8*IPJS@4#4>GqBe{G zrDj|8rx5eEr-yY+>Dw^83zX2G-JgWeUuo8=%)pdRflSs(aS(DqXE(Sq?np6Hu>37i zqj#+BLv2~J$b)O$xM3H1;)_7KZ%3%k&2f1N_CRbKoJIrybNfairRY+1kX2iDZjN!v zf{#gp!VAb7WId%wgRWl7V-TaXVKkZITu>NxjUcVz(=d*+2;=6qpvB`J&$hg`{A>1h z(EB*DSyA42vw#qHcTJv7KkvO(M;ebN09Zz6T%PRYwC!((dV+ytt!dOuLmU)isMV)l#M1 z#7sy(`evJ@x%+K#pWnBXub6??NwUe2s}o}2NaL~JU#{~X`MXtu)^U|h_H&!h#C|~f z#MkA*X(X6Y!clF>-6f&XYNk%_KGhm%^dlY~ zP_DqHUdD2FCHQ#Cc?+1MQY(a&1}IOWeHkky>uXSqn`0{qsRV@C)a`$8zK;??sbDSu O00000ffzqFb38o( zkP{k#OtN|^4)`xwkFClAzvS*5AP+Z|++ zRh}_o10#Tro$R^;gH+}e$u6avpRl(3iEOyWU4S+@lP=@jL ze4YDT?>@7#u1t978)z`R4^tESxyKQ%R0Ea)09I~axAP34sa+Yw21gSZ*dveF8!oC6 zU*n_z0AxA_aS!I%M`68XjmKSF+cc&@!`%Wc-%XMNNC^O7WYNn6_k4xe+@pu$*y2k+ zza;cnvu{vMRJ$;%VnccFBHiEJf9@F(isskzPDI2P!Bg?<@ni79JyYV z=59(c~K$9$>hAwxg%l{s(OmtD>O XpA=;yyV53S00000NkvXXu0mjfx`8Oo diff --git a/games/default/files/mobs/textures/mobs_bunny_white.png b/games/default/files/mobs/textures/mobs_bunny_white.png deleted file mode 100644 index df232a531c02420a12e08a28832a34950ceb1020..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 775 zcmV+i1Ni)jP)F*E|M2JR@9X{R@Bi}i{rvs?OkJfy0007FNkl%RbAo2fSh7b=BJD#|^&#jQYs0jO+W3@(>*yw^okr78L zMSq_0f#}n{kL5m4E_j84z|wy)-J*5o1U&m|SuVf&baOFe!5fc8Fg*Ic(@!ls^_7d^ zxQOJslY13I{Xab#>pURegPjPhUMx`x$c#C*Mrvow=p4seW-Kt`Z11V~M&{L{eX#COyU8!+?ykvX4WbgQd~4J}VD@lstS9WQKm5$JuoISw4f?Kg*1T z-p?6DFj@xKv+{MXx5YAlKYP3XC|k7v;kCp>tp4-#6!1~D&I1;Jlths(#_}|H2T zoEY5QW165Gj3oS&f4G5&cDo(X(Fr$fHennt@V))jD*)!ijM|7j`E@;sK-E;e0xv2+ zwG(^tg((ESweP(GH4A?csHYN0)y)h<62JnCx_&tdR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#5 zAf{qaLgON$*9@3NHVY6%I07J05fjn!ddKFufT-vo<=0n|G%Kjc>+;(t{vtTtW(Oq;|;>)2a_ zGY}XQMG5KDIbB3Z0C?a4D{VZ1+}9w>j3Jf7J^`d2dB30N{fNYti9oQs@~y>_xf)Fq;9KTv|Ff1E55E z__Q<_L}~a3fbuM`W<-!>VGD@C6>q1x>xT5xB6UPsjmxwg2LSXBb?u=BF{`k6AcPMB zF(l+IJwAsKfw}`M$Eja#8PbP)Ij+l#3WdfFKmrili2{J;@B7Xm293^z^8kj90E!0Z z%kfEFJ6HPk1E5A7Fi_Sf7$_q6LQEw9`)i0<{=u USlH)XDF6Tf07*qoM6N<$g4mVGf&c&j diff --git a/games/default/files/mobs/textures/mobs_cooked_rat.png b/games/default/files/mobs/textures/mobs_cooked_rat.png deleted file mode 100644 index 7ba9fe2b3ce7f5b7b08d76a820a8d5632064331c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 144 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!93?!50ihlx9oB=)|u0YyXjiJGTAwQ!o7|3BP z3GxeOaCmkj4ahO|ba4!+h)Z^05ED2!l}Y8sGDgm2C)n87j&0#|Sayv|Vc||8oy!a= m>5Uzs3QoK(29^puj0{d`9A{^6)^-C8VDNPHb6Mw<&;$Uq{v(J0 diff --git a/games/default/files/mobs/textures/mobs_dog.png b/games/default/files/mobs/textures/mobs_dog.png deleted file mode 100644 index 43362a96ce59974a19f6808032f68aa3927a80c4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 592 zcmV-W0rRV%705~Jsyit zD5+vHv1c^8Y&R7Q2GW#i+o^_dK_QV;Dz|DjMJN>4pLlaaB6>z6*`t2EZ8vyEBff4o z_UhsH?dB^P4C~OoWjh|mbv^v}^`BfWPAwPDj9!>nEz_24tz2AXygc+8Zncn}cHt}j?jkJ?|x2LRM?aDpf30lTmz_G6v)aq@Z*18A$!RzgS zb5FluwH07I9$&Z%uv*;(RyQ^4i4l^~Cg`ictA&KcCV(EW7-@JmA`zRw`rE`PNg_5U zqJ`&=rhYsG5jd3K7Kp}lzWWo7DOnCc6G=)M zQh#?aG12zFnhNg%3@>;hfur#U75obJ_n8N9h%`(fUVzqS0}$&BU0)A?;XHtIsBG=$ z@dmi;blpjJ@}}#~z8k8%@B3{!MJ9hNGQ=kXcxkz_H&YZ&OZgUkb5tJK^?j zj5j)<2m64Us%R$g(-{hg@`*(O6OroR+JL)pz?BE;&f^7|PH|vpmG3+-{-FG)z|rR5 z1s-VejR{g;FA#w_&IQ(JF%*cv3Nv_Mjdvut1}A|CykUk03BQ=a13su-AOa1Z@deNO z6h4s;L||)r1vDf?{<{x19zyr9^!fQeV6pn=z7 zzIaC?>mKeW0S6)!*wO+T*@|v7zV=!O6x9v+aOSX}*M$bXSE3z_BG)#spM5R%%s`-n zv6fZ5AXZf;Q9*!N`$Jr#)&nl)Mu`&-`1GFeJapi>af6wE<)5@3`8Owz0R6_`>FVdQ I&MBb@095gbY5)KL diff --git a/games/default/files/mobs/textures/mobs_rat_inventory.png b/games/default/files/mobs/textures/mobs_rat_inventory.png deleted file mode 100644 index c8acc7969e5dfcf584b2294e8ebeee11d3ac02a8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 393 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!63?wyl`GbK}OMp*^tBj0{y`7zdy}g^OtGSt( ztgNh(l9GXefxDZVwzjsZiHWI+sk*wlxw*NKp`ojbtGv9tx|*7Yo4cKjt)+#9riP}E zx3?dIQ@C%qnVFfErly^(t(l1_#7v+d&>U|sFQ8s`S2v(hKrKMUK)Zk{f#&OI>)2Y` z%vZc01$2*WNsu4NUAV#HFehuE>~v2T$B>FR)6?yIha7mAFWlI&Wz8n@eaYwl|F;)9 z7OdntEm_68=#atIO~Q_|cQd{`%$Lb)*Y&mFP7b5QgREzNjy{GkyF|7AwA+;pV#vz2@yZ8Nqd^No|@hE+O@u5+22@qTa~w4 vi`44vY((o0zFewOyJ(Ja&ytb=g_)nF<1Kj=!yEsA0-C|o)z4*}Q$iB}!Z&o4 diff --git a/games/default/files/mobs/textures/mobs_wolf.png b/games/default/files/mobs/textures/mobs_wolf.png deleted file mode 100644 index 128ca6f814d3b1a132b21d0e3d2fc3a53ffe4c79..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 621 zcmV-z0+RiSP)#J$^hmQ&UrDW@cPmT%e$!n3$Mk zVq#%nU}9ooGBPq)R#qAs8iIm?T3T94N=i&iOLACORZ~-Sb#*Q-E^KUUKtMqC_4WJv z`^V%SdjJ3dQ%OWYRCr#6(&et>Fc3iDoEh6eD043_Gc&{cKhpNvimXVR_Wbo{%_MTd ziH?FDg>SXQD7p2Wg zBZLwVU=9|-1WG8^5P=XA5f;|cL_j7MYsv8U1r{YGWB;o?;DZ1Vzu++zfV2F$2fPtj zE@2)dmtOk~BE}VCV|x0o><5t;D&*7Lvk0a>^HMaQs>400000NkvXX Hu0mjfSmg&O diff --git a/games/default/files/mobs/zombie.lua b/games/default/files/mobs/zombie.lua deleted file mode 100644 index fbc8ddf37..000000000 --- a/games/default/files/mobs/zombie.lua +++ /dev/null @@ -1,76 +0,0 @@ -mobs:register_mob("mobs:zombie", { - type = "monster", - visual = "mesh", - mesh = "zombie.x", - textures = { - {"mobs_zombie.png"}, - }, - collisionbox = {-0.25, -1, -0.3, 0.25, 0.75, 0.3}, - animation = { - speed_normal = 10, speed_run = 15, - stand_start = 0, stand_end = 79, - walk_start = 168, walk_end = 188, - run_start = 168, run_end = 188 - }, - makes_footstep_sound = true, - sounds = { - random = "mobs_zombie.1", - war_cry = "mobs_zombie.3", - attack = "mobs_zombie.2", - damage = "mobs_zombie_hit", - death = "mobs_zombie_death", - }, - hp_min = 15, - hp_max = 25, - armor = 100, - knock_back = 1, - light_damage = 1, - lava_damage = 10, - fear_height = 2, - damage = 2, - reach = 2, - attack_type = "dogfight", - group_attack = true, - view_range = 15, - walk_chance = 75, - walk_velocity = 0.5, - run_velocity = 0.5, - jump = false, - drops = { - {name = "mobs:rotten_flesh", chance = 1, min = 1, max = 3,} - }, - }) - - --name, nodes, neighbors, min_light, max_light, interval, chance, active_object_count, min_height, max_height - mobs:spawn_specific("mobs:zombie", - {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass", "default:cobble", "default:mossycobble"}, - {"air"}, - 0, 7, 0, 4000, 1, -31000, 31000 - ) - mobs:register_egg("mobs:zombie", "Zombie", "zombie_head.png", 0) - --- rotten flesh - minetest.register_craftitem("mobs:rotten_flesh", { - description = "Rotten Flesh", - inventory_image = "mobs_rotten_flesh.png", - on_use = minetest.item_eat(1), - }) - --- spawner block - minetest.register_node("mobs:zombie_spawner", { - description = "Zombie Spawner", - tiles = {"zombie_head.png"}, - is_ground_content = false, - groups = {cracky=3, stone=1, mob_spawner=1}, - sounds = default.node_sound_stone_defaults({ - dug = {name="mobs_zombie_death", gain=0.25} - }) - }) - minetest.register_abm({ - nodenames = {"mobs:zombie_spawner"}, - interval = 60.0, - chance = 1, - action = function(pos, node, active_object_count, active_object_count_wider) - minetest.add_entity(pos, "mobs:zombie") - end - }) \ No newline at end of file diff --git a/games/default/files/mobs/bear.lua b/games/default/files/mobs_animal/bear.lua similarity index 61% rename from games/default/files/mobs/bear.lua rename to games/default/files/mobs_animal/bear.lua index 54e16698b..47b19e768 100644 --- a/games/default/files/mobs/bear.lua +++ b/games/default/files/mobs_animal/bear.lua @@ -1,5 +1,5 @@ -- bear - mobs:register_mob("mobs:bear", { +mobs:register_mob("mobs_animal:bear", { type = "npc", visual = "mesh", mesh = "mobs_bear.x", @@ -7,12 +7,12 @@ {"mobs_bear.png"}, }, collisionbox = {-0.5, -0.01, -0.5, 0.5, 1.49, 0.5}, - animation = { - speed_normal = 15, speed_run = 24, - stand_start = 0, stand_end = 30, - walk_start = 35, walk_end = 65, - run_start = 105, run_end = 135, - punch_start = 70, punch_end = 100 + animation = { + speed_normal = 15, speed_run = 24, + stand_start = 0, stand_end = 30, + walk_start = 35, walk_end = 65, + run_start = 105, run_end = 135, + punch_start = 70, punch_end = 100 }, makes_footstep_sound = true, sounds = { @@ -20,14 +20,14 @@ attack = "mobs_bear_angry", }, reach = 2, - hp_min= 10, - hp_max = 15, + hp_min = 8, + hp_max = 12, armor = 100, knock_back = 1, lava_damage = 10, fall_damage = 5, fear_height = 2, - damage = 6, + damage = 4, reach = 3, attack_type = "dogfight", attacks_monsters = true, @@ -35,8 +35,8 @@ stepheight = 1.1, jump = false, drops = { - {name = "mobs:meat_raw", chance = 1, min = 3, max = 6}, - {name = "mobs:leather", chance = 1, min = 1, max = 2} + {name = "mobs:meat_raw", chance = 1, min = 2, max = 4}, + {name = "mobs:leather", chance = 1, min = 1, max = 2} }, follow = {"mobs:honey", "farming:raspberries", "farming:blueberries", "farming_plus:strawberry_item", "bushes:strawberry", "bushes:blackberry", "bushes:blueberry", "bushes:raspberry", @@ -46,7 +46,7 @@ "bushes:strawberry_bush", "bushes:blackberry_bush", "bushes:blueberry_bush", "bushes:raspberry_bush", "bushes:gooseberry_bush", "bushes:mixed_berry_bush"}, replace_with = "air", - on_rightclick = function(self, clicker) + on_rightclick = function (self, clicker) if mobs:feed_tame(self, clicker, 10, true) then return end @@ -69,16 +69,17 @@ end }) - local l_spawn_elevation_min = minetest.setting_get("water_level") - if l_spawn_elevation_min then - l_spawn_elevation_min = l_spawn_elevation_min - 10 - else - l_spawn_elevation_min = -10 - end - --name, nodes, neighbors, min_light, max_light, interval, chance, active_object_count, min_height, max_height - mobs:spawn_specific("mobs:bear", - {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, - {"air"}, - 5, 20, 0, 6000, 1, 1, 31000 - ) - mobs:register_egg("mobs:bear", "Bear", "wool_brown.png", 1) \ No newline at end of file +local l_spawn_elevation_min = minetest.setting_get("water_level") +if l_spawn_elevation_min then + l_spawn_elevation_min = l_spawn_elevation_min - 10 +else + l_spawn_elevation_min = -10 +end + +mobs:register_spawn("mobs_animal:bear", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 4000, 1, 31000, true) + +mobs:register_egg("mobs_animal:bear", "Bear", "wool_brown.png", 1) + +-- compatibility +mobs:alias_mob("mobs:bear", "mobs_animal:bear") \ No newline at end of file diff --git a/games/default/files/mobs/bunny.lua b/games/default/files/mobs_animal/bunny.lua similarity index 81% rename from games/default/files/mobs/bunny.lua rename to games/default/files/mobs_animal/bunny.lua index 980d205b8..298754b19 100644 --- a/games/default/files/mobs/bunny.lua +++ b/games/default/files/mobs_animal/bunny.lua @@ -1,7 +1,7 @@ -- Bunny by ExeterDad -mobs:register_mob("mobs:bunny", { +mobs:register_mob("mobs_animal:bunny", { type = "animal", passive = true, reach = 1, @@ -40,7 +40,7 @@ mobs:register_mob("mobs:bunny", { punch_end = 24, }, follow = {"farming:carrot", "farming_plus:carrot_item"}, - view_range = 10, + view_range = 8, replace_rate = 10, replace_what = {"farming:carrot_7", "farming:carrot_8", "farming_plus:carrot"}, replace_with = "air", @@ -59,8 +59,8 @@ mobs:register_mob("mobs:bunny", { if not minetest.setting_getbool("creative_mode") then item:take_item() clicker:set_wielded_item(item) - end - + end + self.object:set_properties({ textures = {"mobs_bunny_evil.png"}, }) @@ -73,15 +73,15 @@ mobs:register_mob("mobs:bunny", { mobs:capture_mob(self, clicker, 30, 50, 80, false, nil) end, + attack_type = "dogfight", damage = 5, }) +mobs:register_spawn("mobs_animal:bunny", + {"default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 0, 3000, 2, 31000, true) -mobs:spawn_specific("mobs:bunny", - {"default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, - {"air"}, - 0, 20, 0, 4000, 1, 1, 31000 - ) +mobs:register_egg("mobs_animal:bunny", "Bunny", "mobs_bunny_inv.png", 0) -mobs:register_egg("mobs:bunny", "Bunny", "mobs_bunny_inv.png", 0) \ No newline at end of file +-- compatibility +mobs:alias_mob("mobs:bunny", "mobs_animal:bunny") diff --git a/games/default/files/mobs_animal/chicken.lua b/games/default/files/mobs_animal/chicken.lua new file mode 100644 index 000000000..f60691d72 --- /dev/null +++ b/games/default/files/mobs_animal/chicken.lua @@ -0,0 +1,253 @@ + +-- Chicken by JK Murray + +mobs:register_mob("mobs_animal:chicken", { + type = "animal", + passive = true, + hp_min = 3, + hp_max = 6, + armor = 100, + collisionbox = {-0.3, -0.75, -0.3, 0.3, 0.1, 0.3}, + visual = "mesh", + mesh = "mobs_chicken.x", + -- seems a lot of textures but this fixes the problem with the model + textures = { + {"mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png", + "mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png"}, + }, + child_texture = { + {"mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png", + "mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png", "mobs_chicken.png"}, + }, + makes_footstep_sound = true, + sounds = { + random = "mobs_chicken", + }, + walk_velocity = 1, + run_velocity = 3, + runaway = true, + jump = true, + drops = { + {name = "mobs:chicken_raw", chance = 1, min = 1, max = 1}, + }, + water_damage = 1, + lava_damage = 5, + light_damage = 0, + fall_damage = 0, + fall_speed = -8, + fear_height = 5, + animation = { + speed_normal = 15, + stand_start = 0, + stand_end = 1, -- 20 + walk_start = 20, + walk_end = 40, + }, + follow = {"farming:seed_wheat", "farming:seed_cotton"}, + view_range = 5, + + on_rightclick = function(self, clicker) + + if mobs:feed_tame(self, clicker, 8, true, true) then + return + end + + mobs:capture_mob(self, clicker, 30, 50, 80, false, nil) + end, + + do_custom = function(self) + + if not self.child + and math.random(1, 500) == 1 then + + local pos = self.object:getpos() + + minetest.add_item(pos, "mobs:egg") + + minetest.sound_play("default_place_node_hard", { + pos = pos, + gain = 1.0, + max_hear_distance = 5, + }) + end + end, +}) + +mobs:register_spawn("mobs_animal:chicken", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 3000, 1, 31000, true) + +mobs:register_egg("mobs_animal:chicken", "Chicken", "mobs_chicken_inv.png", 0) + +-- compatibility +mobs:alias_mob("mobs:chicken", "mobs_animal:chicken") + +-- egg entity + +mobs:register_arrow("mobs_animal:egg_entity", { + visual = "sprite", + visual_size = {x=.5, y=.5}, + textures = {"mobs_chicken_egg.png"}, + velocity = 6, + + hit_player = function(self, player) + player:punch(self.object, 1.0, { + full_punch_interval = 1.0, + damage_groups = {fleshy = 1}, + }, nil) + end, + + hit_mob = function(self, player) + player:punch(self.object, 1.0, { + full_punch_interval = 1.0, + damage_groups = {fleshy = 1}, + }, nil) + end, + + hit_node = function(self, pos, node) + + local num = math.random(1, 5) + + if num == 1 then + + pos.y = pos.y + 1 + + local nod = minetest.get_node_or_nil(pos) + + if not nod + or not minetest.registered_nodes[nod.name] + or minetest.registered_nodes[nod.name].walkable == true then + return + end + + local mob = minetest.add_entity(pos, "mobs_animal:chicken") + local ent2 = mob:get_luaentity() + + mob:set_properties({ + textures = ent2.child_texture[1], + visual_size = { + x = ent2.base_size.x / 2, + y = ent2.base_size.y / 2 + }, + collisionbox = { + ent2.base_colbox[1] / 2, + ent2.base_colbox[2] / 2, + ent2.base_colbox[3] / 2, + ent2.base_colbox[4] / 2, + ent2.base_colbox[5] / 2, + ent2.base_colbox[6] / 2 + }, + }) + + ent2.child = true + ent2.tamed = true + ent2.owner = self.playername + end + end +}) + +-- egg throwing item + +local egg_GRAVITY = 9 +local egg_VELOCITY = 19 + +-- shoot egg +local mobs_shoot_egg = function (item, player, pointed_thing) + + local playerpos = player:getpos() + + minetest.sound_play("default_place_node_hard", { + pos = playerpos, + gain = 1.0, + max_hear_distance = 5, + }) + + local obj = minetest.add_entity({ + x = playerpos.x, + y = playerpos.y +1.5, + z = playerpos.z + }, "mobs_animal:egg_entity") + + local ent = obj:get_luaentity() + local dir = player:get_look_dir() + + ent.velocity = egg_VELOCITY -- needed for api internal timing + ent.switch = 1 -- needed so that egg doesn't despawn straight away + + obj:setvelocity({ + x = dir.x * egg_VELOCITY, + y = dir.y * egg_VELOCITY, + z = dir.z * egg_VELOCITY + }) + + obj:setacceleration({ + x = dir.x * -3, + y = -egg_GRAVITY, + z = dir.z * -3 + }) + + -- pass player name to egg for chick ownership + local ent2 = obj:get_luaentity() + ent2.playername = player:get_player_name() + + item:take_item() + + return item +end + +-- egg +minetest.register_node(":mobs:egg", { + description = "Chicken Egg", + tiles = {"mobs_chicken_egg.png"}, + inventory_image = "mobs_chicken_egg.png", + visual_scale = 0.7, + drawtype = "plantlike", + wield_image = "mobs_chicken_egg.png", + paramtype = "light", + walkable = false, + is_ground_content = true, + sunlight_propagates = true, + selection_box = { + type = "fixed", + fixed = {-0.2, -0.5, -0.2, 0.2, 0, 0.2} + }, + groups = {snappy = 2, dig_immediate = 3}, + after_place_node = function(pos, placer, itemstack) + if placer:is_player() then + minetest.set_node(pos, {name = "mobs:egg", param2 = 1}) + end + end, + on_use = mobs_shoot_egg +}) + +-- fried egg +minetest.register_craftitem(":mobs:chicken_egg_fried", { +description = "Fried Egg", + inventory_image = "mobs_chicken_egg_fried.png", + on_use = minetest.item_eat(2), +}) + +minetest.register_craft({ + type = "cooking", + recipe = "mobs:egg", + output = "mobs:chicken_egg_fried", +}) + +-- raw chicken +minetest.register_craftitem(":mobs:chicken_raw", { +description = "Raw Chicken", + inventory_image = "mobs_chicken_raw.png", + on_use = minetest.item_eat(2), +}) + +-- cooked chicken +minetest.register_craftitem(":mobs:chicken_cooked", { +description = "Cooked Chicken", + inventory_image = "mobs_chicken_cooked.png", + on_use = minetest.item_eat(6), +}) + +minetest.register_craft({ + type = "cooking", + recipe = "mobs:chicken_raw", + output = "mobs:chicken_cooked", +}) diff --git a/games/default/files/mobs/cow.lua b/games/default/files/mobs_animal/cow.lua similarity index 76% rename from games/default/files/mobs/cow.lua rename to games/default/files/mobs_animal/cow.lua index 8a23666b7..43e0f17ac 100644 --- a/games/default/files/mobs/cow.lua +++ b/games/default/files/mobs_animal/cow.lua @@ -1,18 +1,21 @@ --- Cow by Krupnovpavel -mobs:register_mob("mobs:cow", { + +-- Cow by Krupnopavel (additional texture by JurajVajda) + +mobs:register_mob("mobs_animal:cow", { type = "animal", passive = false, attack_type = "dogfight", reach = 2, - damage = 4, - hp_min = 10, - hp_max = 15, + damage = 2, + hp_min = 8, + hp_max = 12, armor = 100, collisionbox = {-0.8, -0.01, -0.8, 0.8, 1.3, 0.8}, visual = "mesh", mesh = "mobs_cow.x", textures = { {"mobs_cow.png"}, + {"mobs_cow2.png"}, }, makes_footstep_sound = true, sounds = { @@ -22,10 +25,8 @@ mobs:register_mob("mobs:cow", { run_velocity = 2, jump = true, drops = { - {name = "mobs:meat_raw", - chance = 1, min = 1, max = 3}, - {name = "mobs:leather", - chance = 1, min = 0, max = 2}, + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + {name = "mobs:leather", chance = 1, min = 0, max = 2}, }, water_damage = 1, lava_damage = 5, @@ -45,7 +46,7 @@ mobs:register_mob("mobs:cow", { follow = "farming:wheat", view_range = 7, replace_rate = 10, - replace_what = {"farming:wheat_8"}, + replace_what = {"default:grass_3", "default:grass_4", "default:grass_5", "farming:wheat_8"}, replace_with = "air", fear_height = 2, on_rightclick = function(self, clicker) @@ -92,16 +93,16 @@ mobs:register_mob("mobs:cow", { end, }) -mobs:spawn_specific("mobs:cow", - {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, - {"air"}, - 5, 20, 0, 6000, 1, 1, 31000 - ) +mobs:register_spawn("mobs_animal:cow", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 4000, 1, 31000, true) -mobs:register_egg("mobs:cow", "Cow", "default_grass.png", 1) +mobs:register_egg("mobs_animal:cow", "Cow", "default_grass.png", 1) + +-- compatibility +mobs:alias_mob("mobs:cow", "mobs_animal:cow") -- bucket of milk -minetest.register_craftitem("mobs:bucket_milk", { +minetest.register_craftitem(":mobs:bucket_milk", { description = "Bucket of Milk", inventory_image = "mobs_bucket_milk.png", stack_max = 1, @@ -109,7 +110,7 @@ minetest.register_craftitem("mobs:bucket_milk", { }) -- cheese wedge -minetest.register_craftitem("mobs:cheese", { +minetest.register_craftitem(":mobs:cheese", { description = "Cheese", inventory_image = "mobs_cheese.png", on_use = minetest.item_eat(4), @@ -124,7 +125,7 @@ minetest.register_craft({ }) -- cheese block -minetest.register_node("mobs:cheeseblock", { +minetest.register_node(":mobs:cheeseblock", { description = "Cheese Block", tiles = {"mobs_cheeseblock.png"}, is_ground_content = false, @@ -146,4 +147,4 @@ minetest.register_craft({ recipe = { {'mobs:cheeseblock'}, } -}) \ No newline at end of file +}) diff --git a/games/default/files/mobs_animal/depends.txt b/games/default/files/mobs_animal/depends.txt new file mode 100644 index 000000000..cc0339808 --- /dev/null +++ b/games/default/files/mobs_animal/depends.txt @@ -0,0 +1,2 @@ +default +mobs diff --git a/games/default/files/mobs/dog.lua b/games/default/files/mobs_animal/dog.lua similarity index 61% rename from games/default/files/mobs/dog.lua rename to games/default/files/mobs_animal/dog.lua index cffa2454a..e63880838 100644 --- a/games/default/files/mobs/dog.lua +++ b/games/default/files/mobs_animal/dog.lua @@ -1,8 +1,6 @@ -if mobs.mod and mobs.mod == "redo" then - -- wolf - mobs:register_mob("mobs:wolf", { +mobs:register_mob("mobs_animal:wolf", { type = "animal", visual = "mesh", mesh = "mobs_wolf.x", @@ -11,18 +9,18 @@ if mobs.mod and mobs.mod == "redo" then }, collisionbox = {-0.4, -0.01, -0.4, 0.4, 1, 0.4}, animation = { - speed_normal = 20, speed_run = 30, - stand_start = 10, stand_end = 20, - walk_start = 75, walk_end = 100, - run_start = 100, run_end = 130, - punch_start = 135, punch_end = 155 + speed_normal = 20, speed_run = 30, + stand_start = 10, stand_end = 20, + walk_start = 75, walk_end = 100, + run_start = 100, run_end = 130, + punch_start = 135, punch_end = 155 }, makes_footstep_sound = true, sounds = { war_cry = "mobs_wolf_attack" }, reach = 2, - hp_min = 6, + hp_min = 8, hp_max = 10, armor = 100, lava_damage = 5, @@ -36,10 +34,10 @@ if mobs.mod and mobs.mod == "redo" then run_velocity = 3, stepheight = 1.1, follow = "mobs:meat_raw", - on_rightclick = function(self, clicker) + on_rightclick = function (self, clicker) if mobs:feed_tame(self, clicker, 2, false) then if self.food == 0 then - local mob = minetest.add_entity(self.object:getpos(), "mobs:dog") + local mob = minetest.add_entity(self.object:getpos(), "mobs_animal:dog") local ent = mob:get_luaentity() ent.owner = clicker:get_player_name() ent.following = clicker @@ -52,22 +50,20 @@ if mobs.mod and mobs.mod == "redo" then end }) - local l_spawn_elevation_min = minetest.setting_get("water_level") - if l_spawn_elevation_min then - l_spawn_elevation_min = l_spawn_elevation_min - 5 - else - l_spawn_elevation_min = -5 - end - --name, nodes, neighbors, min_light, max_light, interval, chance, active_object_count, min_height, max_height - mobs:spawn_specific("mobs:wolf", - {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, - {"air"}, - 0, 20, 0, 6000, 1, 1, 31000 - ) - mobs:register_egg("mobs:wolf", "Wolf", "wool_grey.png", 1) +local l_spawn_elevation_min = minetest.setting_get("water_level") +if l_spawn_elevation_min then + l_spawn_elevation_min = l_spawn_elevation_min - 5 +else + l_spawn_elevation_min = -5 +end + +mobs:register_spawn("mobs_animal:wolf", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 0, 4000, 1, 31000, true) + +mobs:register_egg("mobs_animal:wolf", "Wolf", "wool_grey.png", 1) -- Dog - mobs:register_mob("mobs:dog", { +mobs:register_mob("mobs_animal:dog", { type = "npc", visual = "mesh", mesh = "mobs_wolf.x", @@ -76,11 +72,11 @@ if mobs.mod and mobs.mod == "redo" then }, collisionbox = {-0.4, -0.01, -0.4, 0.4, 1, 0.4}, animation = { - speed_normal = 20, speed_run = 30, - stand_start = 10, stand_end = 20, - walk_start = 75, walk_end = 100, - run_start = 100, run_end = 130, - punch_start = 135, punch_end = 155 + speed_normal = 20, speed_run = 30, + stand_start = 10, stand_end = 20, + walk_start = 75, walk_end = 100, + run_start = 100, run_end = 130, + punch_start = 135, punch_end = 155 }, makes_footstep_sound = true, sounds = { @@ -100,8 +96,8 @@ if mobs.mod and mobs.mod == "redo" then walk_velocity = 2, run_velocity = 4, stepheight = 1.1, - follow = "mobs:raw_meat", - on_rightclick = function(self, clicker) + follow = "mobs_animal:raw_meat", + on_rightclick = function (self, clicker) if mobs:feed_tame(self, clicker, 6, true) then return end @@ -124,6 +120,8 @@ if mobs.mod and mobs.mod == "redo" then end }) - mobs:register_egg("mobs:dog", "Dog", "wool_brown.png", 1) +mobs:register_egg("mobs_animal:dog", "Dog", "wool_brown.png", 1) -end \ No newline at end of file +-- compatibility +mobs:alias_mob("mobs:wolf", "mobs_animal:wolf") +mobs:alias_mob("mobs:dog", "mobs_animal:dog") \ No newline at end of file diff --git a/games/default/files/mobs_animal/init.lua b/games/default/files/mobs_animal/init.lua new file mode 100644 index 000000000..d3af2341e --- /dev/null +++ b/games/default/files/mobs_animal/init.lua @@ -0,0 +1,17 @@ + +local path = minetest.get_modpath("mobs_animal") + +-- Animals + +dofile(path .. "/chicken.lua") -- JKmurray +dofile(path .. "/cow.lua") -- KrupnoPavel +dofile(path .. "/sheep.lua") -- PilzAdam +dofile(path .. "/bunny.lua") -- ExeterDad +dofile(path .. "/kitten.lua") -- Jordach/BFD +dofile(path .. "/dog.lua") -- KrupnoPavel +dofile(path .. "/pig.lua") -- KrupnoPavel +dofile(path .. "/bear.lua") -- KrupnoPavel + +-- Removed +dofile(path .. "/rat.lua") -- Jordach/BFD + diff --git a/games/default/files/mobs/kitten.lua b/games/default/files/mobs_animal/kitten.lua similarity index 62% rename from games/default/files/mobs/kitten.lua rename to games/default/files/mobs_animal/kitten.lua index c3e54720f..fcb5121fe 100644 --- a/games/default/files/mobs/kitten.lua +++ b/games/default/files/mobs_animal/kitten.lua @@ -1,11 +1,10 @@ -- Kitten by Jordach / BFD -mobs:register_mob("mobs:kitten", { +mobs:register_mob("mobs_animal:kitten", { type = "animal", passive = true, - reach = 2, - hp_min = 5, + hp_min = 8, hp_max = 10, armor = 100, collisionbox = {-0.3, -0.3, -0.3, 0.3, 0.1, 0.3}, @@ -26,10 +25,9 @@ mobs:register_mob("mobs:kitten", { run_velocity = 2, runaway = true, jump = false, - drops = { - {name = "farming:string", - chance = 1, min = 1, max = 1}, - }, + --drops = { + -- {name = "farming:string", chance = 1, min = 1, max = 1}, + --}, water_damage = 1, lava_damage = 5, fear_height = 3, @@ -40,22 +38,22 @@ mobs:register_mob("mobs:kitten", { walk_start = 0, walk_end = 96, }, - follow = {"mobs:rat"}, + follow = {"mobs:rat", "default:fish_raw"}, view_range = 8, on_rightclick = function(self, clicker) - + if mobs:feed_tame(self, clicker, 4, true, true) then return end - + mobs:capture_mob(self, clicker, 50, 50, 90, false, nil) end }) - --name, nodes, neighbors, min_light, max_light, interval, chance, active_object_count, min_height, max_height - mobs:spawn_specific("mobs:kitten", - {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, - {"air"}, - 5, 20, 0, 5000, 1, 1, 31000 - ) -mobs:register_egg("mobs:kitten", "Kitten", "mobs_kitten_inv.png", 0) \ No newline at end of file +mobs:register_spawn("mobs_animal:kitten", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 5000, 1, 31000, true) + +mobs:register_egg("mobs_animal:kitten", "Kitten", "mobs_kitten_inv.png", 0) + +-- compatibility +mobs:alias_mob("mobs:kitten", "mobs_animal:kitten") diff --git a/games/default/files/mobs/models/mobs_bear.x b/games/default/files/mobs_animal/models/mobs_bear.x similarity index 100% rename from games/default/files/mobs/models/mobs_bear.x rename to games/default/files/mobs_animal/models/mobs_bear.x diff --git a/games/default/files/mobs/models/mobs_bunny.b3d b/games/default/files/mobs_animal/models/mobs_bunny.b3d similarity index 100% rename from games/default/files/mobs/models/mobs_bunny.b3d rename to games/default/files/mobs_animal/models/mobs_bunny.b3d diff --git a/games/default/files/mobs/models/mobs_chicken.x b/games/default/files/mobs_animal/models/mobs_chicken.x similarity index 100% rename from games/default/files/mobs/models/mobs_chicken.x rename to games/default/files/mobs_animal/models/mobs_chicken.x diff --git a/games/default/files/mobs/models/mobs_cow.x b/games/default/files/mobs_animal/models/mobs_cow.x similarity index 100% rename from games/default/files/mobs/models/mobs_cow.x rename to games/default/files/mobs_animal/models/mobs_cow.x diff --git a/games/default/files/mobs/models/mobs_kitten.b3d b/games/default/files/mobs_animal/models/mobs_kitten.b3d similarity index 100% rename from games/default/files/mobs/models/mobs_kitten.b3d rename to games/default/files/mobs_animal/models/mobs_kitten.b3d diff --git a/games/default/files/mobs/models/mobs_pig.x b/games/default/files/mobs_animal/models/mobs_pig.x similarity index 100% rename from games/default/files/mobs/models/mobs_pig.x rename to games/default/files/mobs_animal/models/mobs_pig.x diff --git a/games/default/files/mobs/models/mobs_sheep.b3d b/games/default/files/mobs_animal/models/mobs_sheep.b3d similarity index 100% rename from games/default/files/mobs/models/mobs_sheep.b3d rename to games/default/files/mobs_animal/models/mobs_sheep.b3d diff --git a/games/default/files/mobs/models/mobs_sheep_shaved.b3d b/games/default/files/mobs_animal/models/mobs_sheep_shaved.b3d similarity index 100% rename from games/default/files/mobs/models/mobs_sheep_shaved.b3d rename to games/default/files/mobs_animal/models/mobs_sheep_shaved.b3d diff --git a/games/default/files/mobs/models/mobs_wolf.x b/games/default/files/mobs_animal/models/mobs_wolf.x similarity index 100% rename from games/default/files/mobs/models/mobs_wolf.x rename to games/default/files/mobs_animal/models/mobs_wolf.x diff --git a/games/default/files/mobs_animal/pig.lua b/games/default/files/mobs_animal/pig.lua new file mode 100644 index 000000000..4a061723f --- /dev/null +++ b/games/default/files/mobs_animal/pig.lua @@ -0,0 +1,63 @@ +-- Warthog(Boar) by KrupnoPavel (MIT) +-- Changed to Boar and tweaked by Kaadmy (WTFPL) and MoNTE48 (LGPLv3) +mobs:register_mob("mobs_animal:pig", { + type = "animal", + passive = false, + attack_type = "dogfight", + group_attack = true, + reach = 2, + damage = 2, + hp_min = 5, + hp_max = 15, + armor = 100, + collisionbox = {-0.4, -1, -0.4, 0.4, 0.1, 0.4}, + visual = "mesh", + mesh = "mobs_pig.x", + textures = { + {"mobs_pig.png"}, + }, + makes_footstep_sound = true, + sounds = { + random = "mobs_pig", + attack = "mobs_pig_angry", + }, + walk_velocity = 2, + run_velocity = 3, + jump = true, + follow = {"default:apple", "farming:potato"}, + view_range = 5, + drops = { + {name = "mobs:pork_raw", + chance = 1, min = 1, max = 1}, + {name = "mobs:pork_raw", + chance = 2, min = 1, max = 1}, + {name = "mobs:pork_raw", + chance = 2, min = 1, max = 1}, + }, + water_damage = 1, + lava_damage = 5, + light_damage = 0, + fear_height = 2, + animation = { + speed_normal = 20, + stand_start = 0, + stand_end = 60, + walk_start = 61, + walk_end = 80, + punch_start = 90, + punch_end = 110, + }, + on_rightclick = function (self, clicker) + mobs:feed_tame(self, clicker, 8, true, true) + mobs:capture_mob(self, clicker, 0, 5, 50, false, nil) + end, + }) + +mobs:register_spawn("mobs_animal:pig", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 4000, 1, 31000, true) + + +mobs:register_egg("mobs_animal:pig", "Pig", "wool_pink.png", 1) + +-- compatibility +mobs:alias_mob("mobs:pig", "mobs_animal:pig") \ No newline at end of file diff --git a/games/default/files/mobs_animal/rat.lua b/games/default/files/mobs_animal/rat.lua new file mode 100644 index 000000000..9f73cd146 --- /dev/null +++ b/games/default/files/mobs_animal/rat.lua @@ -0,0 +1,8 @@ +mobs:register_mob("mobs_animal:rat", { + lifetimer = 1, + }) + +-- compatibility +mobs:alias_mob("mobs:rat", "mobs_animal:rat") +mobs:alias_mob("mobs:rat_meat", "mobs:meat_raw") +mobs:alias_mob("mobs:rat_cooked", "mobs:meat") \ No newline at end of file diff --git a/games/default/files/mobs_animal/readme.md b/games/default/files/mobs_animal/readme.md new file mode 100644 index 000000000..f91de5579 --- /dev/null +++ b/games/default/files/mobs_animal/readme.md @@ -0,0 +1,36 @@ + +ANIMAL MOBS + +Bee + +- Tends to buzz around flowers and gives honey when killed, you can also right-click a bee to pick it up and place in inventory. 3x bee's in a row can craft a beehive. + +Bunny + +- Bunnies appear in green grass areas (prairie biome in ethereal) and can be tamed with 4 carrots. Can also be picked up and placed in inventory and gives 1-2 meat when killed. + +Chicken + +- Found in green areas (bamboo biome in ethereal) and lays eggs on flat ground, Can be picked up and placed in inventory and gives 1-2 raw chicken when killed. Feed 8x wheat seed to breed. + +Cow + +- Wanders around eating grass/wheat and can be right-clicked with empty bucket to get milk. Cows will defend themselves when hit and can be right-clicked with 8x wheat to tame and breed. + +Kitten + +- Found on green grass these cute cats walk around and can be picked up and placed in inventory as pets or right-clicked with 4x raw fish (found in ethereal) and tamed. + +Rat + +- Typically found around stone they can be picked up and cooked for eating. + +Sheep + +- Green grass and wheat munchers that can be clipped using shears to give 1-3 wool. Feed sheep 8x wheat to regrow wool, tame and breed. Will drop 1-3 meat when killed. + +Warthog + +- Warthogs unlike pigs defend themselves when hit and give 1-3 raw pork when killed, they can also be right-clicked with 8x apples to tame or breed. + +Note: After breeding animals need to rest for 4 minutes, baby animals take 4 minutes to grow up and feeding them helps them grow quicker... diff --git a/games/default/files/mobs_animal/sheep.lua b/games/default/files/mobs_animal/sheep.lua new file mode 100644 index 000000000..1879cbc0d --- /dev/null +++ b/games/default/files/mobs_animal/sheep.lua @@ -0,0 +1,196 @@ + +local all_colours = { + {"black", "Black" }, + {"blue", "Blue" }, + {"brown", "Brown" }, + {"cyan", "Cyan" }, + {"dark_green", "Dark Green"}, + {"dark_grey", "Dark Grey" }, + {"green", "Green" }, + {"grey", "Grey" }, + {"magenta", "Magenta" }, + {"orange", "Orange" }, + {"pink", "Pink" }, + {"red", "Red" }, + {"violet", "Violet" }, + {"white", "White" }, + {"yellow", "Yellow" }, +} + +-- Sheep by PilzAdam + +for _, col in pairs(all_colours) do + + mobs:register_mob("mobs_animal:sheep_"..col[1], { + type = "animal", + passive = true, + hp_min = 6, + hp_max = 10, + armor = 100, + collisionbox = {-0.4, -1, -0.4, 0.4, 0.3, 0.4}, + visual = "mesh", + mesh = "mobs_sheep.b3d", + textures = { + {"mobs_sheep_" .. col[1] .. ".png"}, + }, + gotten_texture = {"mobs_sheep_shaved.png"}, + gotten_mesh = "mobs_sheep_shaved.b3d", + makes_footstep_sound = true, + sounds = { + random = "mobs_sheep", + damage = "mobs_sheep_angry", + }, + walk_velocity = 1, + run_velocity = 2, + runaway = true, + jump = true, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 2}, + {name = "wool:"..col[1], chance = 1, min = 1, max = 1}, + }, + water_damage = 1, + lava_damage = 5, + light_damage = 0, + animation = { + speed_normal = 15, + speed_run = 15, + stand_start = 0, + stand_end = 80, + walk_start = 81, + walk_end = 100, + }, + follow = {"farming:wheat", "default:grass_5"}, + view_range = 8, + replace_rate = 10, + replace_what = {"default:grass_3", "default:grass_4", "default:grass_5", "farming:wheat_8"}, + replace_with = "air", + replace_offset = -1, + fear_height = 3, + + on_rightclick = function(self, clicker) + + --are we feeding? + if mobs:feed_tame(self, clicker, 8, true, true) then + + --if full grow fuzz + if self.gotten == false then + + self.object:set_properties({ + textures = {"mobs_sheep_"..col[1]..".png"}, + mesh = "mobs_sheep.b3d", + }) + end + + return + end + + local item = clicker:get_wielded_item() + local itemname = item:get_name() + + --are we giving a haircut> + if itemname == "mobs:shears" then + + if self.gotten ~= false + and self.child ~= false + and not minetest.get_modpath("wool") then + return + end + + self.gotten = true -- shaved + + local obj = minetest.add_item( + self.object:getpos(), + ItemStack( "wool:" .. col[1] .. " " .. math.random(1, 3) ) + ) + + if obj then + + obj:setvelocity({ + x = math.random(-1, 1), + y = 5, + z = math.random(-1, 1) + }) + end + + item:add_wear(650) -- 100 uses + + clicker:set_wielded_item(item) + + self.object:set_properties({ + textures = {"mobs_sheep_shaved.png"}, + mesh = "mobs_sheep_shaved.b3d", + }) + + return + end + + local name = clicker:get_player_name() + + --are we coloring? + if itemname:find("dye:") then + + if self.gotten == false + and self.child == false + and self.tamed == true + and name == self.owner then + + local colr = string.split(itemname, ":")[2] + + for _,c in pairs(all_colours) do + + if c[1] == colr then + + local pos = self.object:getpos() + + self.object:remove() + + local mob = minetest.add_entity(pos, "mobs_animal:sheep_" .. colr) + local ent = mob:get_luaentity() + + ent.owner = name + ent.tamed = true + + -- take item + if not minetest.setting_getbool("creative_mode") then + item:take_item() + clicker:set_wielded_item(item) + end + + break + end + end + end + + return + end + + --are we capturing? + mobs:capture_mob(self, clicker, 0, 5, 60, false, nil) + end + }) + + mobs:register_egg("mobs_animal:sheep_"..col[1], col[2] .. " Sheep", "wool_"..col[1]..".png", 1) + + -- compatibility + mobs:alias_mob("mobs:sheep_" .. col[1], "mobs_animal:sheep_" .. col[1]) + +end + +mobs:register_spawn("mobs_animal:sheep_white", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 12000, 1, 31000, true) + +mobs:register_spawn("mobs_animal:sheep_grey", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 12000, 1, 31000, true) + +mobs:register_spawn("mobs_animal:sheep_dark_grey", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 12000, 1, 31000, true) + +mobs:register_spawn("mobs_animal:sheep_black", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 12000, 1, 31000, true) + +mobs:register_spawn("mobs_animal:sheep_brown", + {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 5, 12000, 1, 31000, true) + + +-- compatibility +mobs:alias_mob("mobs:sheep", "mobs_animal:sheep_white") diff --git a/games/default/files/mobs/sounds/mobs_bear.ogg b/games/default/files/mobs_animal/sounds/mobs_bear.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_bear.ogg rename to games/default/files/mobs_animal/sounds/mobs_bear.ogg diff --git a/games/default/files/mobs/sounds/mobs_bear_angry.ogg b/games/default/files/mobs_animal/sounds/mobs_bear_angry.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_bear_angry.ogg rename to games/default/files/mobs_animal/sounds/mobs_bear_angry.ogg diff --git a/games/default/files/mobs/sounds/mobs_chicken.ogg b/games/default/files/mobs_animal/sounds/mobs_chicken.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_chicken.ogg rename to games/default/files/mobs_animal/sounds/mobs_chicken.ogg diff --git a/games/default/files/mobs/sounds/mobs_cow.ogg b/games/default/files/mobs_animal/sounds/mobs_cow.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_cow.ogg rename to games/default/files/mobs_animal/sounds/mobs_cow.ogg diff --git a/games/default/files/mobs/sounds/mobs_kitten.ogg b/games/default/files/mobs_animal/sounds/mobs_kitten.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_kitten.ogg rename to games/default/files/mobs_animal/sounds/mobs_kitten.ogg diff --git a/games/default/files/mobs/sounds/mobs_pig.ogg b/games/default/files/mobs_animal/sounds/mobs_pig.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_pig.ogg rename to games/default/files/mobs_animal/sounds/mobs_pig.ogg diff --git a/games/default/files/mobs/sounds/mobs_pig_angry.ogg b/games/default/files/mobs_animal/sounds/mobs_pig_angry.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_pig_angry.ogg rename to games/default/files/mobs_animal/sounds/mobs_pig_angry.ogg diff --git a/games/default/files/mobs/sounds/mobs_sheep.ogg b/games/default/files/mobs_animal/sounds/mobs_sheep.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_sheep.ogg rename to games/default/files/mobs_animal/sounds/mobs_sheep.ogg diff --git a/games/default/files/mobs/sounds/mobs_sheep_angry.ogg b/games/default/files/mobs_animal/sounds/mobs_sheep_angry.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_sheep_angry.ogg rename to games/default/files/mobs_animal/sounds/mobs_sheep_angry.ogg diff --git a/games/default/files/mobs_animal/textures/mobs_bear.png b/games/default/files/mobs_animal/textures/mobs_bear.png new file mode 100644 index 0000000000000000000000000000000000000000..a9a8f26c421f210d7f8b2ea48566f2ec575849d8 GIT binary patch literal 1096 zcmV-O1h@N%P)XMlt|s4iI@)0QK|qZV?qOApk-y05l~48yXWI764s309HN#jZgqQDgZqz0B=A5 zQ#k;7U5ZSE>K57LKFRyb@0Cq=Ecesh)LOYF929}2qYYAHvpu?00}lI*scQ7Qh)*w#TFd` zk}^4CS!H#d~`DyzfvQ5|qnAT%=w0jnBgrm}|50QvYs_JtB7oVZc` z7RDgBMi{+Dw~$~R1O}m;-vSig16;&VN|`Ac!3+>6eBsGNPB{kH-L0q8u1w6;g_2&7 zmh*`kA4v6qr9MO=2W+>6^35H&DFCK>901vCPNdHVg02ra3tJuD;TOCg_c#X-D>>kB zI6GsqHJxW?qw@*Ak9*w8YnX{B-QA_L>&H{(v+LC<0Pf2HJ0hxpaaRMt3G8Q`ZXOTJ zr>oTg0T|^8(hdv<#N!?ZfDzb_(*!XmQ@#NC#u4U0MA}L$d8~Gz(nn^q?y6sM&sT|Z z+~XXeIp5NlKZ4*9Fx5b&!ScAr6@b@`rz779WQ62^dIgFiZ5_B0gnT6?2>D#zzz85B zZ51ouYb~IfFg+Pjt#YD&LWH(g@6_E2c4-cDML*slZ@U{*rfsp_8`;VWS za{m!wrXx84fV9ClH^8#rx^YJ$J-5trr%kA>gQ169yte8>jR5c8ry~8E*6W+~6d(t4 zfc?$o^ME(YoL}zu>kl7VfWBD>SYNIOfEVb~r+mkk128861lh{IVrE^1Pyk z00lq+DBTQ$5FpbmKmrAloYMlR{=oZZ-*C5R{Re9E{zBkaJ4lH$j3B4Y7Vrm#J0;6 zz*Pp=GzT_&Z7VT7e}(;iOk^hRiKwl_QU!S}Q3D`&U{-A_F+n+X2>1$usgTeHb=yR@n9CC{i*}1yZSDh67 z$=2nhHdU6b>r%@MS*{rlDQ^^V8O~W)b1XZMaQz`TO)#}e)S)qyBIuO{an^LB{Ts5Tw6|2 literal 0 HcmV?d00001 diff --git a/games/default/files/mobs/textures/mobs_bunny_inv.png b/games/default/files/mobs_animal/textures/mobs_bunny_inv.png similarity index 100% rename from games/default/files/mobs/textures/mobs_bunny_inv.png rename to games/default/files/mobs_animal/textures/mobs_bunny_inv.png diff --git a/games/default/files/mobs_animal/textures/mobs_bunny_white.png b/games/default/files/mobs_animal/textures/mobs_bunny_white.png new file mode 100644 index 0000000000000000000000000000000000000000..0be9d9078c71488ac699531c18e0f55901a30a7b GIT binary patch literal 230 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnF3?v&v(vJfv(Ey(i*T*m4oWFT*%i%MB{`{T4 z;mZHjrv-&H_a65%11jk8ba4!+h)X@Ov6sm~faTz}54Rf_)LI24V;B-1Os*Hnh}Y-Y zcBbi+!PRBf>-ZId*dP##k6)NH33O$59x-_>FftZX6W2By!$Ds!MY;eVHVR4=KJO*nN6D?`D-+X cWQWx-aNX93;Hh8z2k0&aPgg&ebxsLQ03zL2%K!iX literal 0 HcmV?d00001 diff --git a/games/default/files/mobs/textures/mobs_cheese.png b/games/default/files/mobs_animal/textures/mobs_cheese.png similarity index 100% rename from games/default/files/mobs/textures/mobs_cheese.png rename to games/default/files/mobs_animal/textures/mobs_cheese.png diff --git a/games/default/files/mobs/textures/mobs_cheeseblock.png b/games/default/files/mobs_animal/textures/mobs_cheeseblock.png similarity index 100% rename from games/default/files/mobs/textures/mobs_cheeseblock.png rename to games/default/files/mobs_animal/textures/mobs_cheeseblock.png diff --git a/games/default/files/mobs_animal/textures/mobs_chicken.png b/games/default/files/mobs_animal/textures/mobs_chicken.png new file mode 100644 index 0000000000000000000000000000000000000000..d32206af24c8af0964c724c382bda1b8084d7c1d GIT binary patch literal 902 zcmV;119|+3P)+7bb zrktFd=#neEyu7`=y^fBK&d$!-+S-_ym;e9(goK2jpPzesd-Sas+1c62$;r33x9I5T z%*@Q$006B30D9K`NB{r;40KXXQvd(}00000000000RNE~rT_o}v`IukRCr$Pm+Nlg zFc3x=+ev`hxpTkuw)_5%xbtN&1iGcIp+rbIlHHwSgGI^ zL`=4)-G5^oKrAC764w^MdtHymaom-Fik+&5!(f4wsj7mJF{~U{+GtiX)7>CaQ4;_;=6h&D|xbT|Ce-(U}0z&jezi!UX_Yz!_PF_!j1Cv=)KjtJp_Dz?eg@Y~K=43g5!31puxgYh?^y zUoErQyfT+;G#Cs9PfvjYrgH&v6hJT*jwUKdV80|V8bJVr3LK%11&HL+3lUNdUA3rqinh+JW-J3_s8D>j-aH*3M?jhV6E_Yzw@7D9)x9k+6_T4T7YBt{QSn?Ihiy&^YVh~ zQ3dP)977=2(eWTcK!5~2BMeJGICx|MTtRXe5r=32m9@BnNPU%}YtjDPdt*vXhTk1;Qds6=-ZI4E$n7l@)@0n;tr3-kiLKrhe>^a8y= cFVGA81D9*}o!M;d)Bpeg07*qoM6N<$g1*L_SpWb4 literal 0 HcmV?d00001 diff --git a/games/default/files/mobs_animal/textures/mobs_chicken_black.png b/games/default/files/mobs_animal/textures/mobs_chicken_black.png new file mode 100644 index 0000000000000000000000000000000000000000..d32206af24c8af0964c724c382bda1b8084d7c1d GIT binary patch literal 902 zcmV;119|+3P)+7bb zrktFd=#neEyu7`=y^fBK&d$!-+S-_ym;e9(goK2jpPzesd-Sas+1c62$;r33x9I5T z%*@Q$006B30D9K`NB{r;40KXXQvd(}00000000000RNE~rT_o}v`IukRCr$Pm+Nlg zFc3x=+ev`hxpTkuw)_5%xbtN&1iGcIp+rbIlHHwSgGI^ zL`=4)-G5^oKrAC764w^MdtHymaom-Fik+&5!(f4wsj7mJF{~U{+GtiX)7>CaQ4;_;=6h&D|xbT|Ce-(U}0z&jezi!UX_Yz!_PF_!j1Cv=)KjtJp_Dz?eg@Y~K=43g5!31puxgYh?^y zUoErQyfT+;G#Cs9PfvjYrgH&v6hJT*jwUKdV80|V8bJVr3LK%11&HL+3lUNdUA3rqinh+JW-J3_s8D>j-aH*3M?jhV6E_Yzw@7D9)x9k+6_T4T7YBt{QSn?Ihiy&^YVh~ zQ3dP)977=2(eWTcK!5~2BMeJGICx|MTtRXe5r=32m9@BnNPU%}YtjDPdt*vXhTk1;Qds6=-ZI4E$n7l@)@0n;tr3-kiLKrhe>^a8y= cFVGA81D9*}o!M;d)Bpeg07*qoM6N<$g1*L_SpWb4 literal 0 HcmV?d00001 diff --git a/games/default/files/mobs/textures/mobs_chicken_cooked.png b/games/default/files/mobs_animal/textures/mobs_chicken_cooked.png similarity index 100% rename from games/default/files/mobs/textures/mobs_chicken_cooked.png rename to games/default/files/mobs_animal/textures/mobs_chicken_cooked.png diff --git a/games/default/files/mobs/textures/mobs_chicken_egg.png b/games/default/files/mobs_animal/textures/mobs_chicken_egg.png similarity index 100% rename from games/default/files/mobs/textures/mobs_chicken_egg.png rename to games/default/files/mobs_animal/textures/mobs_chicken_egg.png diff --git a/games/default/files/mobs/textures/mobs_chicken_egg_fried.png b/games/default/files/mobs_animal/textures/mobs_chicken_egg_fried.png similarity index 100% rename from games/default/files/mobs/textures/mobs_chicken_egg_fried.png rename to games/default/files/mobs_animal/textures/mobs_chicken_egg_fried.png diff --git a/games/default/files/mobs/textures/mobs_chicken_inv.png b/games/default/files/mobs_animal/textures/mobs_chicken_inv.png similarity index 100% rename from games/default/files/mobs/textures/mobs_chicken_inv.png rename to games/default/files/mobs_animal/textures/mobs_chicken_inv.png diff --git a/games/default/files/mobs/textures/mobs_chicken_raw.png b/games/default/files/mobs_animal/textures/mobs_chicken_raw.png similarity index 100% rename from games/default/files/mobs/textures/mobs_chicken_raw.png rename to games/default/files/mobs_animal/textures/mobs_chicken_raw.png diff --git a/games/default/files/mobs/textures/mobs_cow.png b/games/default/files/mobs_animal/textures/mobs_cow.png similarity index 100% rename from games/default/files/mobs/textures/mobs_cow.png rename to games/default/files/mobs_animal/textures/mobs_cow.png diff --git a/games/default/files/mobs_animal/textures/mobs_cow2.png b/games/default/files/mobs_animal/textures/mobs_cow2.png new file mode 100644 index 0000000000000000000000000000000000000000..8952befaf249c2b4c4b36c24f79ba0349c98008e GIT binary patch literal 4158 zcmV-E5W(+>P)KPV1RG8J`KFgPO)M=A_LCl5w04^%Z5S3MnNO(tnfCTdM5ZBHp~P%3XxD{@pW zb5$;MRxdjy5_wrIcv>@jT{eDRGKpt2h-W&BX*O|FEnr0@ds{DnU^8%1ENM+FV@xDS zFAz~T7;952Xiz9F9}QbTAYnxxTt*~tSTA;0D@QOEcUdxdTQp!wD0*Bqd|WV2H5O+} zD}P@zeqT5;9}k0KFoI$=fnqy@V>X6lF@zQ#27|O)F+jCN?J(gk(2OH5(Wa z3TIF*G#?0!YdDc^JC$-j4hIG)AQEp;C2dtLW=bSTF&A`KHdr|uNih*`S1wyS7)mo3 zJ|htm3js|u6>m%^V?rJ!7zkTM9a=>rfnY5zCKrZaHD5#|9~l%D4h1YE7Gp;tbx|!Y z8wq4dE^t&c7Z3=NYB`Qkjo4jmB;AQT8PBMYF3ZW|K>bx|izI~iX@9(!Ur zhhQ*zS2#H?8yFZ6R5cP)Iv{3GEgc&WieoY%9ut6PJ~S#9fLkzlUNBla9aBCXgIp{p z9}rwUA1WIMRyP{Y8i{cL01bLcL_t(|UM*K+*Y(P_%xs3nvdzb~?dP>^+uOG7W82rZ ze$dT2d(Y%UlF_q9S1MKA5p>VSG0W0=iYg1qNMyDbdxa39$RRL70Ip}*6l)a6ycdRd zB=@A8C5xgrap))Rz1ZrZkYI$vJNTxrf2 zssa|p)WbS(4?+UbVwPiH^Jq~Cp%A&*%r;7mZ1Vq)30x!uL^Ys5ZO_7(hz9#He3i`lrS_6Po9uUgtg6ffA`yQ2V!mFVU+m0g+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|`m0~P{q_g{{rKaLKebXDou8=H{H|mw=l|2~ z^4e-?X{9-M&5L@r6|=7gSximc5{TYAdBCr)Oc$!{e!fuJx%yVeT*q{-nNRPgW*|gB!sNic7#0v4>}Zr$JJXr*Mti;b z3vy$qGNULsj;Fv7SHc2b04L}gj>d)#?p!JLol6Y=Xy{x>F_?-#mMu=HhiM2)E})>z!Xh9Y5dz!(QhU8` zyU+6Ukbo_s_w?@DcRcl{UAs3njw&b=V$5JJ#Wu#=cBtzTq!KIUcsdkWE9WyEOH+QX ze@M~@3-Uk&k;mQLa2YWm9z9a_>z8twuCSZ>4EHMcqUL|(%k!OqjHZMHkue0K zg|Wvq$94!~YDfhFz&Pd__juUEE(-jMscjP}V2mYQ`+k0Y;+Y}h5?3$?D8OvVA)Gs5 z35p?=F&B^lGU3FtIksd%A{NHnv(HEfff(o_RaX3!CUFt^e-NX2#+}J$8UO$Q07*qo IM6N<$f&^Aq-T(jq literal 0 HcmV?d00001 diff --git a/games/default/files/mobs_animal/textures/mobs_dog.png b/games/default/files/mobs_animal/textures/mobs_dog.png new file mode 100644 index 0000000000000000000000000000000000000000..fee015b277812e9a8c1845220da6cde5f4aac0c7 GIT binary patch literal 767 zcmVdcWtCl9UxS;un3tQZzt`5+-2eaoTg#YE0007(NklxQvc&?|5uQbYD4?XRmp-R~>=vqzq0P(x+~ch5K7-Se%| zF65zPD5aq7b9;SxH(X!dN}JOOkaPd#>3jF%>2sSMXzwU7O8*U5 z{sC|vtkwf=UMephQ64fhZ~&d`)fa2|$Vk zNC8m+`S$U5LZC?X9BN3$I|y;3!p}iI&H*1_ xL)vN<=O73Mf&wP)4XJdzHWr=8Hi2nZmfqbQHX^oAEu5W9RPfTVYA1PT@b8c#n|NsBa5NBQh00Qet zL_t(|Ud7eta@;Ts1YiRoRj#@_wY>jRW&uJ6$~>JE`$u+;!^}DRiA7`I$$FTX7PAg8 zUk8R^I}oM!z-|X%T_BE5jTyjO1or+{qL-Kb-Z6}E9jH$L{RwbUSFk~dB>)hjIUt*s z&;rvIg!v=DfD{1!h8+ZOe_ycgn-7t+9{KS?^ziWH2RV)k@IL|&o}MlM>bLs=MD{z2 zUg+&>WM4olAQylIV-Y}qAtT}d(g+-vum(h-j=NX4Abp7l4v`jCAiVs1LDhx>UT&Ab zbRA&XYZ?GE&jDTl&>r_A3;+s-5yGt#L{Eb$fGBb}s4oD13l1pJJedn%;hM3kO%Ax= zz4{;Q0H@>em@XkoC|W-SF#Z2{vLOXe>1dw-GyxDoLi?;)~!~qqEwVtyA zm_Rt`KoF+R57B_qhahE|zARffwg3g-YRX;L<%-6aa)ZzyzI>V0eEM5Q6Vn zCz8^m1wiB^yPX&if;yR5)M1$Mg0;ZuBuE3KOa|oaq~+=%o=!Um283V$V9q&J{p)9d zEzAM5wcjI>Aw+-W5F@Bj&jf^2pzS~islV&-N!DLa03pQu5rC3yeyz_)1H>ZMAJ0?+ z9|^y{{$GGGJ_qn80c07F-Xg4bYDw{zZ$Mh$O9TK52oZErQX+s~BHot6;ReuK%5PKy z0Fen3AOH??pdh4zhyh|iu7P=;pBsQ+`3gjVR0EB0pa69KhDiqjFI#};fE|njgGNY+ z8Zbo{GTnm6>RQOFT;0D!a5ZCAh1uQfS0la@fc>*Y|F>b*_Gl1DXHVp6`)Yn+Q z2gP^?2$xKUC|qBoFJK7}w8hVP;XU9G&}{(ty%Zwe1EOp10h%q)`>Ijv7v2K^!VZ+1 p1i%--Vzp@nFyj#83>=Ue_zM8OG!eb55wrjR002ovPDHLkV1fafe`Wvx literal 0 HcmV?d00001 diff --git a/games/default/files/mobs_monster/depends.txt b/games/default/files/mobs_monster/depends.txt new file mode 100644 index 000000000..cc0339808 --- /dev/null +++ b/games/default/files/mobs_monster/depends.txt @@ -0,0 +1,2 @@ +default +mobs diff --git a/games/default/files/mobs_monster/init.lua b/games/default/files/mobs_monster/init.lua new file mode 100644 index 000000000..8617721a6 --- /dev/null +++ b/games/default/files/mobs_monster/init.lua @@ -0,0 +1,8 @@ + +local path = minetest.get_modpath("mobs_monster") + +-- Monsters + +dofile(path .. "/spider.lua") -- AspireMint +dofile(path.."/zombie.lua") -- Blockmen +dofile(path.."/skeleton.lua") -- Blockmen diff --git a/games/default/files/mobs/models/mobs_spider.x b/games/default/files/mobs_monster/models/mobs_spider.x similarity index 99% rename from games/default/files/mobs/models/mobs_spider.x rename to games/default/files/mobs_monster/models/mobs_spider.x index a8fbe07e3..19f17871f 100644 --- a/games/default/files/mobs/models/mobs_spider.x +++ b/games/default/files/mobs_monster/models/mobs_spider.x @@ -6100,4 +6100,4 @@ AnimationSet Global { 90;3; 0.000000, 0.000000, 0.000000;;; } } -} // End of AnimationSet Global \ No newline at end of file +} // End of AnimationSet Global diff --git a/games/default/files/mobs/models/zombie.x b/games/default/files/mobs_monster/models/mobs_zombie.x similarity index 100% rename from games/default/files/mobs/models/zombie.x rename to games/default/files/mobs_monster/models/mobs_zombie.x diff --git a/games/default/files/mobs_monster/readme.md b/games/default/files/mobs_monster/readme.md new file mode 100644 index 000000000..043b25aff --- /dev/null +++ b/games/default/files/mobs_monster/readme.md @@ -0,0 +1,38 @@ + +MONSTER MOBS + +Dirt Monster + +- Spawning at night on green grass (or grey in ethereal) these mobs wander around looking for a player to eat. Drops 1-5 dirt when killed. + +Dungeon Master + +- Spawning below -70 underground DM's have a tendency to hurl fire balls at unsuspecting players and can cause major damage, but get too close and he will switch to dogfight attack. Can drop mese or diamond when killed. + +Lava Flan + +- Cute as they may look lava flan wallow in their namesake (no, not flans) and get curious about players who wander by, forgetting that they can burn you and cause damage. They have a 1 in 5 chance of dropping lava orb when killed. + +Mese Monster + +- These mobs are territorial and spawn below -20 and will fire mese shards at passers by, so best avoided. Will drop mese when killed. + +Oerkki + +- Found in dark areas like most monsters Oerkki wander the caverns stealing away torches on the ground and attacking anyone found in that area. 1 in 3 chance of dropping obsidian. + +Sand Monster + +- The hot deserts are home to these guys who spawn at any time of the day to attack players. They drop 3-5 desert sand when killed. + +Spider + +- Found in dark holes inside desertstone (crystal biomes in ethereal), spiders wait for prey to amble past and strike. They are mostly docile during the day though unless hit. Will drop string when killed. + +Stone Monster + +- Found underground in dark caves these mobs seem to be zombie-like in fashion with a tendency to rush a player in the area. can drop torch, iron or coal when killed. + +Tree Monster + +- Found atop tree's at night time they drop down and look for food in the form of players. Can drop saplings and sometimes an apple or three. diff --git a/games/default/files/mobs/skeleton.lua b/games/default/files/mobs_monster/skeleton.lua similarity index 52% rename from games/default/files/mobs/skeleton.lua rename to games/default/files/mobs_monster/skeleton.lua index 27637954f..e446e8949 100644 --- a/games/default/files/mobs/skeleton.lua +++ b/games/default/files/mobs_monster/skeleton.lua @@ -1,16 +1,16 @@ -mobs:register_mob("mobs:skeleton", { +mobs:register_mob("mobs_monster:skeleton", { type = "monster", visual = "mesh", - mesh = "zombie.x", + mesh = "mobs_zombie.x", textures = { {"mobs_skeleton.png"}, }, collisionbox = {-0.25, -1, -0.3, 0.25, 0.75, 0.3}, animation = { - speed_normal = 10, speed_run = 15, - stand_start = 0, stand_end = 79, - walk_start = 168, walk_end = 188, - run_start = 168, run_end = 188 + speed_normal = 10, speed_run = 15, + stand_start = 0, stand_end = 79, + walk_start = 168, walk_end = 188, + run_start = 168, run_end = 188 }, makes_footstep_sound = true, sounds = { @@ -41,10 +41,8 @@ mobs:register_mob("mobs:skeleton", { }, }) - --name, nodes, neighbors, min_light, max_light, interval, chance, active_object_count, min_height, max_height - mobs:spawn_specific("mobs:skeleton", - {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass", "default:cobble", "default:mossycobble"}, - {"air"}, - 0, 7, 0, 4000, 1, -31000, 31000 - ) - --mobs:register_egg("mobs:skeleton", "Zombie", "zombie_head.png", 0) \ No newline at end of file +mobs:register_spawn("mobs_monster:skeleton", + {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass", "default:cobble", "default:mossycobble"}, 10, 0, 5000, 1, 31000, false) + +-- compatibility +mobs:alias_mob("mobs:skeleton", "mobs_monster:skeleton") \ No newline at end of file diff --git a/games/default/files/mobs/sounds/mobs_spider.ogg b/games/default/files/mobs_monster/sounds/mobs_spider.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_spider.ogg rename to games/default/files/mobs_monster/sounds/mobs_spider.ogg diff --git a/games/default/files/mobs/sounds/mobs_zombie.1.ogg b/games/default/files/mobs_monster/sounds/mobs_zombie.1.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_zombie.1.ogg rename to games/default/files/mobs_monster/sounds/mobs_zombie.1.ogg diff --git a/games/default/files/mobs/sounds/mobs_zombie.2.ogg b/games/default/files/mobs_monster/sounds/mobs_zombie.2.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_zombie.2.ogg rename to games/default/files/mobs_monster/sounds/mobs_zombie.2.ogg diff --git a/games/default/files/mobs/sounds/mobs_zombie.3.ogg b/games/default/files/mobs_monster/sounds/mobs_zombie.3.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_zombie.3.ogg rename to games/default/files/mobs_monster/sounds/mobs_zombie.3.ogg diff --git a/games/default/files/mobs/sounds/mobs_zombie_attack.ogg b/games/default/files/mobs_monster/sounds/mobs_zombie_attack.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_zombie_attack.ogg rename to games/default/files/mobs_monster/sounds/mobs_zombie_attack.ogg diff --git a/games/default/files/mobs/sounds/mobs_zombie_death.ogg b/games/default/files/mobs_monster/sounds/mobs_zombie_death.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_zombie_death.ogg rename to games/default/files/mobs_monster/sounds/mobs_zombie_death.ogg diff --git a/games/default/files/mobs/sounds/mobs_zombie_hit.ogg b/games/default/files/mobs_monster/sounds/mobs_zombie_hit.ogg similarity index 100% rename from games/default/files/mobs/sounds/mobs_zombie_hit.ogg rename to games/default/files/mobs_monster/sounds/mobs_zombie_hit.ogg diff --git a/games/default/files/mobs/spider.lua b/games/default/files/mobs_monster/spider.lua similarity index 74% rename from games/default/files/mobs/spider.lua rename to games/default/files/mobs_monster/spider.lua index 5f099b181..13de4d1b9 100644 --- a/games/default/files/mobs/spider.lua +++ b/games/default/files/mobs_monster/spider.lua @@ -1,7 +1,8 @@ -- Spider by AspireMint (fishyWET (CC-BY-SA 3.0 license for texture) -mobs:register_mob("mobs:spider", { +mobs:register_mob("mobs_monster:spider", { + docile_by_day = true, type = "monster", passive = false, attack_type = "dogfight", @@ -27,14 +28,12 @@ mobs:register_mob("mobs:spider", { jump = true, view_range = 15, floats = 0, - drops = { - {name = "farming:string", - chance = 1, min = 1, max = 2}, - }, +-- drops = { +-- {name = "farming:string", +-- chance = 1, min = 1, max = 2}, }, water_damage = 5, - lava_damage = 5, - light_damage = 1, - fear_height = 2, + lava_damage = 5, + light_damage = 0, animation = { speed_normal = 15, speed_run = 15, @@ -48,21 +47,20 @@ mobs:register_mob("mobs:spider", { punch_end = 90, }, }) - - mobs:spawn_specific("mobs:spider", - {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass", "default:cobble", "default:mossycobble"}, - {"air"}, - 0, 7, 0, 5000, 1, -31000, 31000 - ) -mobs:register_egg("mobs:spider", "Spider", "mobs_cobweb.png", 1) +mobs:register_spawn("mobs_monster:spider", + {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass", "default:cobble", "default:mossycobble"}, 13, 0, 6000, 1, 31000) + +mobs:register_egg("mobs_monster:spider", "Spider", "mobs_cobweb.png", 1) + +-- compatibility +mobs:alias_mob("mobs:spider", "mobs_monster:spider") -- cobweb -minetest.register_node("mobs:cobweb", { +minetest.register_node(":mobs:cobweb", { description = "Cobweb", drawtype = "plantlike", visual_scale = 1.1, - stack_max = 64, tiles = {"mobs_cobweb.png"}, inventory_image = "mobs_cobweb.png", paramtype = "light", @@ -74,7 +72,7 @@ minetest.register_node("mobs:cobweb", { liquid_renewable = false, liquid_range = 0, walkable = false, - groups = {snappy = 1, liquid = 3}, + groups = {snappy = 1}, --drop = "farming:cotton", sounds = default.node_sound_leaves_defaults(), }) @@ -86,4 +84,4 @@ minetest.register_craft({ {"", "farming:string", ""}, {"farming:string", "", "farming:string"}, } -}) \ No newline at end of file +}) diff --git a/games/default/files/mobs/textures/mobs_cobweb.png b/games/default/files/mobs_monster/textures/mobs_cobweb.png similarity index 100% rename from games/default/files/mobs/textures/mobs_cobweb.png rename to games/default/files/mobs_monster/textures/mobs_cobweb.png diff --git a/games/default/files/mobs/textures/mobs_rotten_flesh.png b/games/default/files/mobs_monster/textures/mobs_rotten_flesh.png similarity index 100% rename from games/default/files/mobs/textures/mobs_rotten_flesh.png rename to games/default/files/mobs_monster/textures/mobs_rotten_flesh.png diff --git a/games/default/files/mobs/textures/mobs_skeleton.png b/games/default/files/mobs_monster/textures/mobs_skeleton.png similarity index 100% rename from games/default/files/mobs/textures/mobs_skeleton.png rename to games/default/files/mobs_monster/textures/mobs_skeleton.png diff --git a/games/default/files/mobs/textures/mobs_spider.png b/games/default/files/mobs_monster/textures/mobs_spider.png similarity index 100% rename from games/default/files/mobs/textures/mobs_spider.png rename to games/default/files/mobs_monster/textures/mobs_spider.png diff --git a/games/default/files/mobs/textures/mobs_zombie.png b/games/default/files/mobs_monster/textures/mobs_zombie.png similarity index 100% rename from games/default/files/mobs/textures/mobs_zombie.png rename to games/default/files/mobs_monster/textures/mobs_zombie.png diff --git a/games/default/files/mobs/textures/zombie_head.png b/games/default/files/mobs_monster/textures/zombie_head.png similarity index 100% rename from games/default/files/mobs/textures/zombie_head.png rename to games/default/files/mobs_monster/textures/zombie_head.png diff --git a/games/default/files/mobs_monster/zombie.lua b/games/default/files/mobs_monster/zombie.lua new file mode 100644 index 000000000..6e5eb6a7f --- /dev/null +++ b/games/default/files/mobs_monster/zombie.lua @@ -0,0 +1,79 @@ +mobs:register_mob("mobs_monster:zombie", { + type = "monster", + visual = "mesh", + mesh = "mobs_zombie.x", + textures = { + {"mobs_zombie.png"}, + }, + collisionbox = {-0.25, -1, -0.3, 0.25, 0.75, 0.3}, + animation = { + speed_normal = 10, speed_run = 15, + stand_start = 0, stand_end = 79, + walk_start = 168, walk_end = 188, + run_start = 168, run_end = 188 + }, + makes_footstep_sound = true, + sounds = { + random = "mobs_zombie.1", + war_cry = "mobs_zombie.3", + attack = "mobs_zombie.2", + damage = "mobs_zombie_hit", + death = "mobs_zombie_death", + }, + hp_min = 15, + hp_max = 25, + armor = 100, + knock_back = 1, + light_damage = 1, + lava_damage = 10, + fear_height = 2, + damage = 2, + reach = 2, + attack_type = "dogfight", + group_attack = true, + view_range = 15, + walk_chance = 75, + walk_velocity = 0.5, + run_velocity = 0.5, + jump = false, + drops = { + {name = "mobs_monster:rotten_flesh", + chance = 1, min = 1, max = 3,} + }, + }) + +mobs:register_spawn("mobs_monster:zombie", + {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass", "default:cobble", "default:mossycobble"}, 10, 0, 5000, 1, 31000, false) + +mobs:register_egg("mobs_monster:zombie", "Zombie", "zombie_head.png", 0) + +-- compatibility +mobs:alias_mob("mobs:zombie", "mobs_monster:zombie") +mobs:alias_mob("mobs:rotten_flesh", "mobs_monster:rotten_flesh") +mobs:alias_mob("mobs:zombie_spawner", "mobs_monster:zombie_spawner") + +-- rotten flesh +minetest.register_craftitem("mobs_monster:rotten_flesh", { + description = "Rotten Flesh", + inventory_image = "mobs_rotten_flesh.png", + on_use = minetest.item_eat(1), + }) + +-- spawner block +minetest.register_node("mobs_monster:zombie_spawner", { + description = "Zombie Spawner", + tiles = {"zombie_head.png"}, + is_ground_content = false, + groups = {cracky = 3, stone = 1, mob_spawner = 1}, + sounds = default.node_sound_stone_defaults({ + dug = {name = "mobs_zombie_death", gain = 0.25} + }) + }) +minetest.register_abm({ + nodenames = {"mobs_monster:zombie_spawner"}, + interval = 60.0, + chance = 1, + action = function (pos, node, active_object_count, active_object_count_wider) + minetest.add_entity(pos, "mobs_monster:zombie") + end + }) \ No newline at end of file diff --git a/games/default/files/mobs/api.lua b/games/default/files/mobs_redo/api.lua similarity index 64% rename from games/default/files/mobs/api.lua rename to games/default/files/mobs_redo/api.lua index 537f1f015..3eed3720f 100644 --- a/games/default/files/mobs/api.lua +++ b/games/default/files/mobs_redo/api.lua @@ -1,11 +1,14 @@ --- Mobs Api (17th February 2016) + +-- Mobs Api (8th May 2016) + mobs = {} mobs.mod = "redo" -- Load settings local damage_enabled = minetest.setting_getbool("enable_damage") local peaceful_only = minetest.setting_getbool("only_peaceful_mobs") -local disable_blood = minetest.setting_getbool("mobs_disable_blood") +--local disable_blood = minetest.setting_getbool("mobs_disable_blood") +local disable_blood = true local creative = minetest.setting_getbool("creative_mode") local spawn_protected = tonumber(minetest.setting_get("mobs_spawn_protected")) or 1 local remove_far = minetest.setting_getbool("remove_far_mobs") @@ -20,6 +23,16 @@ local stuck_path_timeout = 10 -- how long will mob follow path before giving up local pi = math.pi local square = math.sqrt +local atan = function(x) + + if x ~= x then + --error("atan bassed NaN") + print ("atan based NaN") + return 0 + else + return math.atan(x) + end +end do_attack = function(self, player) @@ -67,17 +80,18 @@ set_animation = function(self, type) self.animation.current = self.animation.current or "" + self.animation.speed_normal = self.animation.speed_normal or 15 + if type == "stand" and self.animation.current ~= "stand" then if self.animation.stand_start - and self.animation.stand_end - and self.animation.speed_normal then + and self.animation.stand_end then self.object:set_animation({ x = self.animation.stand_start, y = self.animation.stand_end}, - self.animation.speed_normal, 0) + (self.animation.speed_stand or self.animation.speed_normal), 0) self.animation.current = "stand" end @@ -86,13 +100,12 @@ set_animation = function(self, type) and self.animation.current ~= "walk" then if self.animation.walk_start - and self.animation.walk_end - and self.animation.speed_normal then + and self.animation.walk_end then self.object:set_animation({ x = self.animation.walk_start, y = self.animation.walk_end}, - self.animation.speed_normal, 0) + (self.animation.speed_walk or self.animation.speed_normal), 0) self.animation.current = "walk" end @@ -101,13 +114,12 @@ set_animation = function(self, type) and self.animation.current ~= "run" then if self.animation.run_start - and self.animation.run_end - and self.animation.speed_run then + and self.animation.run_end then self.object:set_animation({ x = self.animation.run_start, y = self.animation.run_end}, - self.animation.speed_run, 0) + (self.animation.speed_run or self.animation.speed_normal), 0) self.animation.current = "run" end @@ -116,31 +128,86 @@ set_animation = function(self, type) and self.animation.current ~= "punch" then if self.animation.punch_start - and self.animation.punch_end - and self.animation.speed_normal then + and self.animation.punch_end then self.object:set_animation({ x = self.animation.punch_start, y = self.animation.punch_end}, - self.animation.speed_normal, 0) + (self.animation.speed_punch or self.animation.speed_normal), 0) self.animation.current = "punch" end + elseif type == "punch2" + and self.animation.current ~= "punch2" then + + if self.animation.punch2_start + and self.animation.punch2_end then + + self.object:set_animation({ + x = self.animation.punch2_start, + y = self.animation.punch2_end}, + (self.animation.speed_punch2 or self.animation.speed_normal), 0) + + self.animation.current = "punch2" + end + elseif type == "shoot" + and self.animation.current ~= "shoot" then + + if self.animation.shoot_start + and self.animation.shoot_end then + + self.object:set_animation({ + x = self.animation.shoot_start, + y = self.animation.shoot_end}, + (self.animation.speed_shoot or self.animation.speed_normal), 0) + + self.animation.current = "shoot" + end end end +-- check line of sight for walkers and swimmers alike +function line_of_sight_water(self, pos1, pos2, stepsize) + + local s, pos_w = minetest.line_of_sight(pos1, pos2, stepsize) + + -- normal walking and flying mobs can see you through air + if s == true then + return true + end + + -- swimming mobs can see you through water + if s == false + and self.fly + and self.fly_in == "default:water_source" then + + local nod = minetest.get_node(pos_w).name + + if nod == "default:water_source" + or nod == "default:water_flowing" then + + return true + end + end + + return false + +end + -- particle effects -function effect(pos, amount, texture, max_size) +function effect(pos, amount, texture, max_size, radius) + + radius = radius or 2 minetest.add_particlespawner({ amount = amount, time = 0.25, minpos = pos, maxpos = pos, - minvel = {x = -0, y = -2, z = -0}, - maxvel = {x = 2, y = 2, z = 2}, - minacc = {x = -4, y = -4, z = -4}, - maxacc = {x = 4, y = 4, z = 4}, + minvel = {x = -radius, y = -radius, z = -radius}, + maxvel = {x = radius, y = radius, z = radius}, + minacc = {x = -radius, y = -radius, z = -radius}, + maxacc = {x = radius, y = radius, z = radius}, minexptime = 0.1, maxexptime = 1, minsize = 0.5, @@ -177,27 +244,30 @@ end -- check if mob is dead or only hurt function check_for_death(self) - -- return if no change - local hp = self.object:get_hp() - - if hp == self.health then - return false + -- has health actually changed? + if self.health == self.old_health then + return end - -- still got some health? play hurt sound - if hp > 0 then + self.old_health = self.health - self.health = hp + -- still got some health? play hurt sound + if self.health > 0 then if self.sounds.damage then minetest.sound_play(self.sounds.damage,{ object = self.object, - gain = 1.0, + gain = 0.7, max_hear_distance = self.sounds.distance }) end + -- make sure health isn't higher than max + if self.health > self.hp_max then + self.health = self.hp_max + end + update_tag(self) return false @@ -231,7 +301,7 @@ function check_for_death(self) minetest.sound_play(self.sounds.death,{ object = self.object, - gain = 1.0, + gain = 0.7, max_hear_distance = self.sounds.distance }) end @@ -285,6 +355,24 @@ local function is_at_cliff(self) return false end +-- get node but use fallback for nil or unknown +local function node_ok(pos, fallback) + + fallback = fallback or "default:dirt" + + local node = minetest.get_node_or_nil(pos) + + if not node then + return minetest.registered_nodes[fallback] + end + + if minetest.registered_nodes[node.name] then + return node + end + + return minetest.registered_nodes[fallback] +end + -- environmental damage (water, lava, fire, light) do_env_damage = function(self) @@ -310,18 +398,20 @@ do_env_damage = function(self) and self.time_of_day < 0.8 and (minetest.get_node_light(pos) or 0) > 12 then - self.object:set_hp(self.object:get_hp() - self.light_damage) + self.health = self.health - self.light_damage - effect(pos, 5, "mobs_blood.png") + effect(pos, 5, "hud_heart_fg.png") end + -- what is mob standing in? + pos.y = pos.y + self.collisionbox[2] + 0.1 -- foot level + self.standing_in = node_ok(pos, "air").name + --print ("standing in " .. self.standing_in) + if self.water_damage ~= 0 or self.lava_damage ~= 0 then - pos.y = pos.y + self.collisionbox[2] + 0.1 -- foot level - - local nod = node_ok(pos, "air") ; --print ("standing in "..nod.name) - local nodef = minetest.registered_nodes[nod.name] + local nodef = minetest.registered_nodes[self.standing_in] pos.y = pos.y + 1 @@ -329,7 +419,7 @@ do_env_damage = function(self) if self.water_damage ~= 0 and nodef.groups.water then - self.object:set_hp(self.object:get_hp() - self.water_damage) + self.health = self.health - self.water_damage effect(pos, 5, "hud_air_fg.png") end @@ -337,10 +427,10 @@ do_env_damage = function(self) -- lava or fire if self.lava_damage ~= 0 and (nodef.groups.lava - or nod.name == "fire:basic_flame" - or nod.name == "fire:permanent_flame") then + or self.standing_in == "fire:basic_flame" + or self.standing_in == "fire:permanent_flame") then - self.object:set_hp(self.object:get_hp() - self.lava_damage) + self.health = self.health - self.lava_damage effect(pos, 5, "fire_basic_flame.png") end @@ -349,7 +439,7 @@ do_env_damage = function(self) check_for_death(self) end --- jump if facing a solid node (not fences) +-- jump if facing a solid node (not fences or gates) do_jump = function(self) if self.fly @@ -389,8 +479,9 @@ do_jump = function(self) --print ("in front:", nod.name, pos.y + 0.5) - if minetest.registered_items[nod.name].walkable + if (minetest.registered_items[nod.name].walkable and not nod.name:find("fence") + and not nod.name:find("gate")) or self.walk_chance == 0 then local v = self.object:getvelocity() @@ -405,7 +496,7 @@ do_jump = function(self) minetest.sound_play(self.sounds.jump, { object = self.object, - gain = 1.0, + gain = 0.7, max_hear_distance = self.sounds.distance }) end @@ -440,28 +531,22 @@ function entity_physics(pos, radius) dist = math.max(1, get_distance(pos, obj_pos)) local damage = math.floor((4 / dist) * radius) - obj:set_hp(obj:get_hp() - damage) + local ent = obj:get_luaentity() + + if obj:is_player() then + obj:set_hp(obj:get_hp() - damage) + + else --if ent.health then + + obj:punch(obj, 1.0, { + full_punch_interval = 1.0, + damage_groups = {fleshy = damage}, + }, nil) + + end end end --- get node but use fallback for nil or unknown -function node_ok(pos, fallback) - - fallback = fallback or "default:dirt" - - local node = minetest.get_node_or_nil(pos) - - if not node then - return minetest.registered_nodes[fallback] - end - - if minetest.registered_nodes[node.name] then - return node - end - - return minetest.registered_nodes[fallback] -end - -- should mob follow what I'm holding ? function follow_holding(self, clicker) @@ -487,6 +572,7 @@ function follow_holding(self, clicker) return false end +-- find two animals of same type and breed if nearby and horny local function breed(self) -- child take 240 seconds before growing into adult @@ -536,7 +622,7 @@ local function breed(self) local pos = self.object:getpos() - effect({x = pos.x, y = pos.y + 1, z = pos.z}, 4, "mobs_blood.png") + --effect({x = pos.x, y = pos.y + 1, z = pos.z}, 4, "heart.png") local ents = minetest.get_objects_inside_radius(pos, 3) local num = 0 @@ -620,6 +706,7 @@ local function breed(self) end end +-- find and replace what mob is looking for (grass, wheat etc.) function replace(self, pos) if self.replace_rate @@ -820,533 +907,260 @@ function smart_mobs(self, s, p, dist, dtime) end end --- register mob function -function mobs:register_mob(name, def) +-- monster find someone to attack +local monster_attack = function(self) -minetest.register_entity(name, { + if self.type ~= "monster" + or not damage_enabled + or self.state == "attack" + or day_docile(self) then + return + end - stepheight = def.stepheight or 0.6, - name = name, - type = def.type, - attack_type = def.attack_type, - fly = def.fly, - fly_in = def.fly_in or "air", - owner = def.owner or "", - order = def.order or "", - on_die = def.on_die, - do_custom = def.do_custom, - jump_height = def.jump_height or 6, - jump_chance = def.jump_chance or 0, - drawtype = def.drawtype, -- DEPRECATED, use rotate instead - rotate = math.rad(def.rotate or 0), -- 0=front, 90=side, 180=back, 270=side2 - lifetimer = def.lifetimer or 180, -- 3 minutes - hp_min = def.hp_min or 5, - hp_max = def.hp_max or 10, - physical = true, - collisionbox = def.collisionbox, - visual = def.visual, - visual_size = def.visual_size or {x = 1, y = 1}, - mesh = def.mesh, - makes_footstep_sound = def.makes_footstep_sound or false, - view_range = def.view_range or 5, - walk_velocity = def.walk_velocity or 1, - run_velocity = def.run_velocity or 2, - damage = def.damage or 0, - light_damage = def.light_damage or 0, - water_damage = def.water_damage or 0, - lava_damage = def.lava_damage or 0, - fall_damage = def.fall_damage or 1, - fall_speed = def.fall_speed or -10, -- must be lower than -2 (default: -10) - drops = def.drops or {}, - armor = def.armor, - on_rightclick = def.on_rightclick, - arrow = def.arrow, - shoot_interval = def.shoot_interval, - sounds = def.sounds or {}, - animation = def.animation, - follow = def.follow, - jump = def.jump or true, - walk_chance = def.walk_chance or 50, - attacks_monsters = def.attacks_monsters or false, - group_attack = def.group_attack or false, - --fov = def.fov or 120, - passive = def.passive or false, - recovery_time = def.recovery_time or 0.5, - knock_back = def.knock_back or 3, - blood_amount = def.blood_amount or 5, - blood_texture = def.blood_texture or "mobs_blood.png", - shoot_offset = def.shoot_offset or 0, - floats = def.floats or 1, -- floats in water by default - replace_rate = def.replace_rate, - replace_what = def.replace_what, - replace_with = def.replace_with, - replace_offset = def.replace_offset or 0, - timer = 0, - env_damage_timer = 0, -- only used when state = "attack" - tamed = false, - pause_timer = 0, - horny = false, - hornytimer = 0, - child = false, - gotten = false, - health = 0, - reach = def.reach or 3, - htimer = 0, - child_texture = def.child_texture, - docile_by_day = def.docile_by_day or false, - time_of_day = 0.5, - fear_height = def.fear_height or 0, - runaway = def.runaway, - runaway_timer = 0, - pathfinding = def.pathfinding, + local s = self.object:getpos() + local p, sp, dist + local player, type, obj, min_player = nil, nil, nil, nil + local min_dist = self.view_range + 1 - on_step = function(self, dtime) + for _,oir in pairs(minetest.get_objects_inside_radius(s, self.view_range)) do - local pos = self.object:getpos() - local yaw = self.object:getyaw() or 0 + if oir:is_player() then - -- when lifetimer expires remove mob (except npc and tamed) - if self.type ~= "npc" - and not self.tamed - and self.state ~= "attack" then - - self.lifetimer = self.lifetimer - dtime - - if self.lifetimer <= 0 then - - -- only despawn away from player - local objs = minetest.get_objects_inside_radius(pos, 10) - - for _,oir in pairs(objs) do - - if oir:is_player() then - - self.lifetimer = 20 - - return - end - end - - minetest.log("action", - "lifetimer expired, removed " .. self.name) - - effect(pos, 15, "mobs_blood.png") - - self.object:remove() - - return - end - end - - if not self.fly then - - -- floating in water (or falling) - local v = self.object:getvelocity() - - -- going up then apply gravity - if v.y > 0.1 then - - self.object:setacceleration({ - x = 0, - y = self.fall_speed, - z = 0 - }) - end - - -- in water then float up - if minetest.registered_nodes[node_ok(pos).name].groups.liquid then -- water then - - if self.floats == 1 then - - self.object:setacceleration({ - x = 0, - y = -self.fall_speed / (math.max(1, v.y) ^ 2), - z = 0 - }) - end - else - -- fall downwards - self.object:setacceleration({ - x = 0, - y = self.fall_speed, - z = 0 - }) - - -- fall damage - if self.fall_damage == 1 - and self.object:getvelocity().y == 0 then - - local d = self.old_y - self.object:getpos().y - - if d > 5 then - - self.object:set_hp(self.object:get_hp() - math.floor(d - 5)) - - effect(pos, 10, "mobs_blood.png") - - if check_for_death(self) then - return - end - end - - self.old_y = self.object:getpos().y - end - end - end - - -- knockback timer - if self.pause_timer > 0 then - - self.pause_timer = self.pause_timer - dtime - - if self.pause_timer < 1 then - self.pause_timer = 0 - end - - return - end - - -- attack timer - self.timer = self.timer + dtime - - if self.state ~= "attack" then - - if self.timer < 1 then - return - end - - self.timer = 0 - end - - -- never go over 100 - if self.timer > 100 then - self.timer = 1 - end - - -- node replace check (cow eats grass etc.) - replace(self, pos) - - -- mob plays random sound at times - if self.sounds.random - and math.random(1, 100) == 1 then - - minetest.sound_play(self.sounds.random, { - object = self.object, - max_hear_distance = self.sounds.distance - }) - end - - -- environmental damage timer (every 1 second) - self.env_damage_timer = self.env_damage_timer + dtime - - if (self.state == "attack" and self.env_damage_timer > 1) - or self.state ~= "attack" then - - self.env_damage_timer = 0 - - do_env_damage(self) - - -- custom function (defined in mob lua file) - if self.do_custom then - self.do_custom(self) - end - end - - -- find someone to attack - if self.type == "monster" - and damage_enabled - and self.state ~= "attack" - and not day_docile(self) then - - local s = self.object:getpos() - local p, sp, dist - local player = nil - local type = nil - local obj = nil - local min_dist = self.view_range + 1 - local min_player = nil - - for _,oir in pairs(minetest.get_objects_inside_radius(s, self.view_range)) do - - if oir:is_player() then - - player = oir - type = "player" - else - obj = oir:get_luaentity() - - if obj then - player = obj.object - type = obj.type - end - end - - if type == "player" - or type == "npc" then - - s = self.object:getpos() - p = player:getpos() - sp = s - - -- aim higher to make looking up hills more realistic - p.y = p.y + 1 - sp.y = sp.y + 1 - - dist = get_distance(p, s) - - if dist < self.view_range then - -- field of view check goes here - - -- choose closest player to attack - if minetest.line_of_sight(sp, p, 2) == true - and dist < min_dist then - min_dist = dist - min_player = player - end - end - end - end - - -- attack player - if min_player then - do_attack(self, min_player) - end - end - - -- npc, find closest monster to attack - local min_dist = self.view_range + 1 - local min_player = nil - - if self.type == "npc" - and self.attacks_monsters - and self.state ~= "attack" then - - local s = self.object:getpos() - local obj = nil - - for _, oir in pairs(minetest.get_objects_inside_radius(s, self.view_range)) do - - obj = oir:get_luaentity() - - if obj - and obj.type == "monster" then - - -- attack monster - p = obj.object:getpos() - - dist = get_distance(p, s) - - if dist < min_dist then - min_dist = dist - min_player = obj.object - end - end - end - - if min_player then - do_attack(self, min_player) - end - end - - -- breed and grow children - breed(self) - - -- find player to follow - if (self.follow ~= "" - or self.order == "follow") - and not self.following - and self.state ~= "attack" - and self.state ~= "runaway" then - - local s, p, dist - - for _,player in pairs(minetest.get_connected_players()) do - - s = self.object:getpos() - p = player:getpos() - dist = get_distance(p, s) - - if dist < self.view_range then - self.following = player - break - end - end - end - - if self.type == "npc" - and self.order == "follow" - and self.state ~= "attack" - and self.owner ~= "" then - - -- npc stop following player if not owner - if self.following - and self.owner - and self.owner ~= self.following:get_player_name() then - self.following = nil - end + player = oir + type = "player" else - -- stop following player if not holding specific item - if self.following - and self.following:is_player() - and follow_holding(self, self.following) == false then + obj = oir:get_luaentity() + + if obj then + player = obj.object + type = obj.type + end + end + + if type == "player" + or type == "npc" then + + s = self.object:getpos() + p = player:getpos() + sp = s + + -- aim higher to make looking up hills more realistic + p.y = p.y + 1 + sp.y = sp.y + 1 + + dist = get_distance(p, s) + + if dist < self.view_range then + -- field of view check goes here + + -- choose closest player to attack + --if minetest.line_of_sight(sp, p, 2) == true + if line_of_sight_water(self, sp, p, 2) == true + and dist < min_dist then + min_dist = dist + min_player = player + end + end + end + end + + -- attack player + if min_player then + do_attack(self, min_player) + end +end + +-- npc, find closest monster to attack +local npc_attack = function(self) + + if self.type ~= "npc" + or not self.attacks_monsters + or self.state == "attack" then + return + end + + local s = self.object:getpos() + local min_dist = self.view_range + 1 + local obj, min_player = nil, nil + + for _, oir in pairs(minetest.get_objects_inside_radius(s, self.view_range)) do + + obj = oir:get_luaentity() + + if obj + and obj.type == "monster" then + + p = obj.object:getpos() + + dist = get_distance(p, s) + + if dist < min_dist then + min_dist = dist + min_player = obj.object + end + end + end + + if min_player then + do_attack(self, min_player) + end +end + +-- follow player if owner or holding item, if fish outta water then flop +local follow_flop = function(self) + + -- find player to follow + if (self.follow ~= "" + or self.order == "follow") + and not self.following + and self.state ~= "attack" + and self.state ~= "runaway" then + + local s, p, dist + + for _,player in pairs(minetest.get_connected_players()) do + + s = self.object:getpos() + p = player:getpos() + dist = get_distance(p, s) + + if dist < self.view_range then + self.following = player + break + end + end + end + + if self.type == "npc" + and self.order == "follow" + and self.state ~= "attack" + and self.owner ~= "" then + + -- npc stop following player if not owner + if self.following + and self.owner + and self.owner ~= self.following:get_player_name() then + self.following = nil + end + else + -- stop following player if not holding specific item + if self.following + and self.following:is_player() + and follow_holding(self, self.following) == false then + self.following = nil + end + + end + + -- follow that thing + if self.following then + + local s = self.object:getpos() + local p + + if self.following:is_player() then + + p = self.following:getpos() + + elseif self.following.object then + + p = self.following.object:getpos() + end + + if p then + + local dist = get_distance(p, s) + + -- dont follow if out of range + if dist > self.view_range then self.following = nil - end + else + local vec = { + x = p.x - s.x, + y = p.y - s.y, + z = p.z - s.z + } - end + if vec.x ~= 0 + and vec.z ~= 0 then - -- follow that thing - if self.following then + yaw = (atan(vec.z / vec.x) + pi / 2) - self.rotate - local s = self.object:getpos() - local p - - if self.following:is_player() then - - p = self.following:getpos() - - elseif self.following.object then - - p = self.following.object:getpos() - end - - if p then - - local dist = get_distance(p, s) - - -- dont follow if out of range - if dist > self.view_range then - self.following = nil - else - local vec = { - x = p.x - s.x, - y = p.y - s.y, - z = p.z - s.z - } - - if vec.x ~= 0 - and vec.z ~= 0 then - - yaw = (math.atan(vec.z / vec.x) + pi / 2) - self.rotate - - if p.x > s.x then - yaw = yaw + pi - end - - self.object:setyaw(yaw) + if p.x > s.x then + yaw = yaw + pi end - -- anyone but standing npc's can move along - if dist > self.reach - and self.order ~= "stand" then - - if (self.jump - and get_velocity(self) <= 0.5 - and self.object:getvelocity().y == 0) - or (self.object:getvelocity().y == 0 - and self.jump_chance > 0) then - - do_jump(self) - end - - set_velocity(self, self.walk_velocity) - - if self.walk_chance ~= 0 then - set_animation(self, "walk") - end - else - set_velocity(self, 0) - set_animation(self, "stand") - end - - return - end - end - end - - if self.state == "stand" then - - if math.random(1, 4) == 1 then - - local lp = nil - local s = self.object:getpos() - - if self.type == "npc" then - - local o = minetest.get_objects_inside_radius(self.object:getpos(), 3) - - for _,o in pairs(o) do - - if o:is_player() then - lp = o:getpos() - break - end - end + self.object:setyaw(yaw) end - -- look at any players nearby, otherwise turn randomly - if lp then + -- anyone but standing npc's can move along + if dist > self.reach + and self.order ~= "stand" then - local vec = { - x = lp.x - s.x, - y = lp.y - s.y, - z = lp.z - s.z - } + if (self.jump + and get_velocity(self) <= 0.5 + and self.object:getvelocity().y == 0) + or (self.object:getvelocity().y == 0 + and self.jump_chance > 0) then - if vec.x ~= 0 - and vec.z ~= 0 then - - yaw = (math.atan(vec.z / vec.x) + pi / 2) - self.rotate - - if lp.x > s.x then - yaw = yaw + pi - end + do_jump(self) end - else - yaw = (math.random(0, 360) - 180) / 180 * pi - end - - self.object:setyaw(yaw) - end - - set_velocity(self, 0) - set_animation(self, "stand") - - -- npc's ordered to stand stay standing - if self.type ~= "npc" - or self.order ~= "stand" then - - if self.walk_chance ~= 0 - and math.random(1, 100) <= self.walk_chance - and is_at_cliff(self) == false then set_velocity(self, self.walk_velocity) - self.state = "walk" - set_animation(self, "walk") + + if self.walk_chance ~= 0 then + set_animation(self, "walk") + end + else + set_velocity(self, 0) + set_animation(self, "stand") end - end - - elseif self.state == "walk" then - - local s = self.object:getpos() - local lp = minetest.find_node_near(s, 1, {"group:water"}) - - -- water swimmers cannot move out of water - if self.fly - and self.fly_in == "default:water_source" - and not lp then - - --print ("out of water") - - set_velocity(self, 0) - - -- change to undefined state so nothing more happens - self.state = "flop" - set_animation(self, "stand") return end + end + end - -- if water nearby then turn away + -- water swimmers flop when on land + if self.fly + and self.fly_in == "default:water_source" + and self.standing_in ~= self.fly_in then + + self.state = "flop" + self.object:setvelocity({x = 0, y = -5, z = 0}) + + set_animation(self, "stand") + + return + end +end + +-- execute current state (stand, walk, run, attacks) +local do_states = function(self, dtime) + + local yaw = 0 + + if self.state == "stand" then + + if math.random(1, 4) == 1 then + + local lp = nil + local s = self.object:getpos() + + if self.type == "npc" then + + local o = minetest.get_objects_inside_radius(self.object:getpos(), 3) + + for _,o in pairs(o) do + + if o:is_player() then + lp = o:getpos() + break + end + end + end + + -- look at any players nearby, otherwise turn randomly if lp then local vec = { @@ -1358,73 +1172,120 @@ minetest.register_entity(name, { if vec.x ~= 0 and vec.z ~= 0 then - yaw = math.atan(vec.z / vec.x) + 3 * pi / 2 - self.rotate + yaw = (atan(vec.z / vec.x) + pi / 2) - self.rotate if lp.x > s.x then yaw = yaw + pi end - - self.object:setyaw(yaw) end - - -- otherwise randomly turn - elseif math.random(1, 100) <= 30 then - + else yaw = (math.random(0, 360) - 180) / 180 * pi + end + + self.object:setyaw(yaw) + end + + set_velocity(self, 0) + set_animation(self, "stand") + + -- npc's ordered to stand stay standing + if self.type ~= "npc" + or self.order ~= "stand" then + + if self.walk_chance ~= 0 + and math.random(1, 100) <= self.walk_chance + and is_at_cliff(self) == false then + + set_velocity(self, self.walk_velocity) + self.state = "walk" + set_animation(self, "walk") + end + end + + elseif self.state == "walk" then + + local s = self.object:getpos() + local lp = minetest.find_node_near(s, 1, {"group:water"}) + + -- if water nearby then turn away + if lp then + + local vec = { + x = lp.x - s.x, + y = lp.y - s.y, + z = lp.z - s.z + } + + if vec.x ~= 0 + and vec.z ~= 0 then + + yaw = atan(vec.z / vec.x) + 3 * pi / 2 - self.rotate + + if lp.x > s.x then + yaw = yaw + pi + end self.object:setyaw(yaw) end - -- stand for great fall in front - local temp_is_cliff = is_at_cliff(self) + -- otherwise randomly turn + elseif math.random(1, 100) <= 30 then - -- jump when walking comes to a halt - if temp_is_cliff == false - and self.jump - and get_velocity(self) <= 0.5 - and self.object:getvelocity().y == 0 then + local yaw = (math.random(0, 360) - 180) / 180 * pi - do_jump(self) - end + self.object:setyaw(yaw) + end - if temp_is_cliff - or math.random(1, 100) <= 30 then + -- stand for great fall in front + local temp_is_cliff = is_at_cliff(self) - set_velocity(self, 0) - self.state = "stand" - set_animation(self, "stand") - else - set_velocity(self, self.walk_velocity) - set_animation(self, "walk") - end + -- jump when walking comes to a halt + if temp_is_cliff == false + and self.jump + and get_velocity(self) <= 0.5 + and self.object:getvelocity().y == 0 then - -- runaway when punched - elseif self.state == "runaway" then + do_jump(self) + end - self.runaway_timer = self.runaway_timer + 1 + if temp_is_cliff + or math.random(1, 100) <= 30 then - -- stop after 3 seconds or when at cliff - if self.runaway_timer > 3 - or is_at_cliff(self) then - self.runaway_timer = 0 - set_velocity(self, 0) - self.state = "stand" - set_animation(self, "stand") - else - set_velocity(self, self.run_velocity) - set_animation(self, "walk") - end + set_velocity(self, 0) + self.state = "stand" + set_animation(self, "stand") + else + set_velocity(self, self.walk_velocity) + set_animation(self, "walk") + end - -- jump when walking comes to a halt - if self.jump - and get_velocity(self) <= 0.5 - and self.object:getvelocity().y == 0 then + -- runaway when punched + elseif self.state == "runaway" then - do_jump(self) - end + self.runaway_timer = self.runaway_timer + 1 - -- attack routines (explode, dogfight, shoot, dogshoot) - elseif self.state == "attack" then + -- stop after 3 seconds or when at cliff + if self.runaway_timer > 3 + or is_at_cliff(self) then + self.runaway_timer = 0 + set_velocity(self, 0) + self.state = "stand" + set_animation(self, "stand") + else + set_velocity(self, self.run_velocity) + set_animation(self, "walk") + end + + -- jump when walking comes to a halt + if self.jump + and get_velocity(self) <= 0.5 + and self.object:getvelocity().y == 0 then + + do_jump(self) + end + + -- attack routines (explode, dogfight, shoot, dogshoot) + elseif self.state == "attack" then -- calculate distance from mob and enemy local s = self.object:getpos() @@ -1460,7 +1321,7 @@ minetest.register_entity(name, { if vec.x ~= 0 and vec.z ~= 0 then - yaw = math.atan(vec.z / vec.x) + pi / 2 - self.rotate + yaw = atan(vec.z / vec.x) + pi / 2 - self.rotate if p.x > s.x then yaw = yaw + pi @@ -1495,6 +1356,8 @@ minetest.register_entity(name, { set_animation(self, "run") else set_velocity(self, 0) + set_animation(self, "punch") + self.timer = self.timer + dtime self.blinktimer = (self.blinktimer or 0) + dtime @@ -1514,9 +1377,10 @@ minetest.register_entity(name, { if self.timer > 3 then local pos = self.object:getpos() + local radius = self.explosion_radius or 1 -- hurt player/mobs caught in blast area - entity_physics(pos, 3) + entity_physics(pos, radius) -- dont damage anything if area protected or next to water if minetest.find_node_near(pos, 1, {"group:water"}) @@ -1526,21 +1390,21 @@ minetest.register_entity(name, { minetest.sound_play(self.sounds.explode, { object = self.object, - gain = 1.0, + gain = 0.7, max_hear_distance = 16 }) end self.object:remove() - effect(pos, 15, "mobs_blood.png", 5) + effect(pos, 15, "hud_air_fg.png", 5) return end pos.y = pos.y - 1 - mobs:explosion(pos, 2, 0, 1, self.sounds.explode) + mobs:explosion(pos, radius, 0, 1, self.sounds.explode) self.object:remove() @@ -1637,7 +1501,7 @@ minetest.register_entity(name, { if vec.x ~= 0 and vec.z ~= 0 then - yaw = (math.atan(vec.z / vec.x) + pi / 2) - self.rotate + yaw = (atan(vec.z / vec.x) + pi / 2) - self.rotate if p.x > s.x then yaw = yaw + pi @@ -1688,34 +1552,52 @@ minetest.register_entity(name, { self.path.following = false -- not stuck anymore set_velocity(self, 0) - set_animation(self, "punch") - if self.timer > 1 then + if not self.custom_attack then - self.timer = 0 + if self.timer > 1 then - local p2 = p - local s2 = s + self.timer = 0 - p2.y = p2.y + 1.5 - s2.y = s2.y + 1.5 - - if minetest.line_of_sight(p2, s2) == true then - - -- play attack sound - if self.sounds.attack then - - minetest.sound_play(self.sounds.attack, { - object = self.object, - max_hear_distance = self.sounds.distance - }) + if self.double_melee_attack + and math.random(1, 2) == 1 then + set_animation(self, "punch") + else + set_animation(self, "punch2") end - -- punch player - self.attack:punch(self.object, 1.0, { - full_punch_interval = 1.0, - damage_groups = {fleshy = self.damage} - }, nil) + local p2 = p + local s2 = s + + p2.y = p2.y + 1.5 + s2.y = s2.y + 1.5 + + --if minetest.line_of_sight(p2, s2) == true then + if line_of_sight_water(self, p2, s2) == true then + + -- play attack sound + if self.sounds.attack then + + minetest.sound_play(self.sounds.attack, { + object = self.object, + max_hear_distance = self.sounds.distance + }) + end + + -- punch player + self.attack:punch(self.object, 1.0, { + full_punch_interval = 1.0, + damage_groups = {fleshy = self.damage} + }, nil) + end + end + else -- call custom attack every second + if self.custom_attack + and self.timer > 1 then + + self.timer = 0 + + self.custom_attack(self, p) end end end @@ -1736,7 +1618,7 @@ minetest.register_entity(name, { if vec.x ~= 0 and vec.z ~= 0 then - yaw = (math.atan(vec.z / vec.x) + pi / 2) - self.rotate + yaw = (atan(vec.z / vec.x) + pi / 2) - self.rotate if p.x > s.x then yaw = yaw + pi @@ -1752,7 +1634,7 @@ minetest.register_entity(name, { and math.random(1, 100) <= 60 then self.timer = 0 - set_animation(self, "punch") + set_animation(self, "shoot") -- play shoot attack sound if self.sounds.shoot_attack then @@ -1770,250 +1652,585 @@ minetest.register_entity(name, { local obj = minetest.add_entity(p, self.arrow) local ent = obj:get_luaentity() local amount = (vec.x * vec.x + vec.y * vec.y + vec.z * vec.z) ^ 0.5 - local v = ent.velocity + local v = ent.velocity or 1 -- or set to default ent.switch = 1 -- offset makes shoot aim accurate vec.y = vec.y + self.shoot_offset - vec.x = vec.x * v / amount - vec.y = vec.y * v / amount - vec.z = vec.z * v / amount + vec.x = vec.x * (v / amount) + vec.y = vec.y * (v / amount) + vec.z = vec.z * (v / amount) obj:setvelocity(vec) end end + end +end - end -- END if self.state == "attack" - end, +-- falling and fall damage +local falling = function(self, pos) - on_punch = function(self, hitter, tflp, tool_capabilities, dir) + if self.fly then + return + end - -- direction error check - dir = dir or {x = 0, y = 0, z = 0} + -- floating in water (or falling) + local v = self.object:getvelocity() - -- weapon wear - local weapon = hitter:get_wielded_item() - local punch_interval = 1.4 + -- going up then apply gravity + if v.y > 0.1 then - if tool_capabilities then - punch_interval = tool_capabilities.full_punch_interval or 1.4 - end + self.object:setacceleration({ + x = 0, + y = self.fall_speed, + z = 0 + }) + end - if weapon:get_definition() - and weapon:get_definition().tool_capabilities then + -- in water then float up + if minetest.registered_nodes[node_ok(pos).name].groups.liquid then - weapon:add_wear(math.floor((punch_interval / 75) * 9000)) - hitter:set_wielded_item(weapon) - end + if self.floats == 1 then - -- weapon sounds - if weapon:get_definition().sounds ~= nil then - - local s = math.random(0, #weapon:get_definition().sounds) - - minetest.sound_play(weapon:get_definition().sounds[s], { - object = hitter, - max_hear_distance = 8 - }) - else - minetest.sound_play("default_punch", { - object = hitter, - max_hear_distance = 5 + self.object:setacceleration({ + x = 0, + y = -self.fall_speed / (math.max(1, v.y) ^ 2), + z = 0 }) end + else + -- fall downwards + self.object:setacceleration({ + x = 0, + y = self.fall_speed, + z = 0 + }) - -- exit here if dead - if check_for_death(self) then - return - end + -- fall damage + if self.fall_damage == 1 + and self.object:getvelocity().y == 0 then - -- blood_particles - if self.blood_amount > 0 - and not disable_blood then + local d = self.old_y - self.object:getpos().y - local pos = self.object:getpos() + if d > 5 then - pos.y = pos.y + (-self.collisionbox[2] + self.collisionbox[5]) / 2 + --self.object:set_hp(self.object:get_hp() - math.floor(d - 5)) + self.health = self.health - math.floor(d - 5) - effect(pos, self.blood_amount, self.blood_texture) - end + effect(pos, 5, "tnt_smoke.png") - -- knock back effect - if self.knock_back > 0 then - - local v = self.object:getvelocity() - local r = 1.4 - math.min(punch_interval, 1.4) - local kb = r * 5 - local up = 2 - - -- if already in air then dont go up anymore when hit - if v.y > 0 then - up = 0 - end - - self.object:setvelocity({ - x = dir.x * kb, - y = up, - z = dir.z * kb - }) - - self.pause_timer = r - end - - -- if skittish then run away - if self.runaway == true then - - local lp = hitter:getpos() - local s = self.object:getpos() - - local vec = { - x = lp.x - s.x, - y = lp.y - s.y, - z = lp.z - s.z - } - - if vec.x ~= 0 - and vec.z ~= 0 then - - local yaw = math.atan(vec.z / vec.x) + 3 * pi / 2 - self.rotate - - if lp.x > s.x then - yaw = yaw + pi + if check_for_death(self) then + return end - - self.object:setyaw(yaw) end - self.state = "runaway" - self.runaway_timer = 0 - self.following = nil + self.old_y = self.object:getpos().y + end + end +end + +local mob_punch = function(self, hitter, tflp, tool_capabilities, dir) + + -- direction error check + dir = dir or {x = 0, y = 0, z = 0} + + -- weapon wear + local weapon = hitter:get_wielded_item() + local punch_interval = 1.4 + + -- calculate mob damage + local damage = 0 + local armor = self.object:get_armor_groups() or {} + local tmp + + -- quick error check incase it ends up 0 (serialize.h check test) + if tflp == 0 then + tflp = 0.2 + end + + for group,_ in pairs( (tool_capabilities.damage_groups or {}) ) do + + tmp = tflp / (tool_capabilities.full_punch_interval or 1.4) + + if tmp < 0 then + tmp = 0.0 + elseif tmp > 1 then + tmp = 1.0 end - -- attack puncher and call other mobs for help - if self.passive == false - and self.child == false - and hitter:get_player_name() ~= self.owner then + damage = damage + (tool_capabilities.damage_groups[group] or 0) + * tmp * ((armor[group] or 0) / 100.0) + end - --if self.state ~= "attack" then - -- attack whoever punched mob - self.state = "" - do_attack(self, hitter) - --end + -- check for tool immunity or special damage + for _, no in pairs(self.immune_to) do - -- alert others to the attack - local obj = nil + if no[1] == weapon:get_name() then - for _, oir in pairs(minetest.get_objects_inside_radius(hitter:getpos(), 5)) do + damage = no[2] or 0 - obj = oir:get_luaentity() + break + end + end - if obj then + -- print ("Mob Damage is", damage) - if obj.group_attack == true - and obj.state ~= "attack" then - do_attack(obj, hitter) - end + -- add weapon wear + if tool_capabilities then + punch_interval = tool_capabilities.full_punch_interval or 1.4 + end + + if weapon:get_definition() + and weapon:get_definition().tool_capabilities then + + weapon:add_wear(math.floor((punch_interval / 75) * 9000)) + hitter:set_wielded_item(weapon) + end + + -- weapon sounds + if weapon:get_definition().sounds ~= nil then + + local s = math.random(0, #weapon:get_definition().sounds) + + minetest.sound_play(weapon:get_definition().sounds[s], { + object = hitter, + max_hear_distance = 8 + }) + else + minetest.sound_play("default_punch", { + object = hitter, + max_hear_distance = 5 + }) + end + + -- do damage + self.health = self.health - math.floor(damage) + + -- exit here if dead + if check_for_death(self) then + return + end + + -- add healthy afterglow when hit + core.after(0.1, function() + self.object:settexturemod("^[colorize:#ff000085") + + core.after(0.5, function() + self.object:settexturemod("") + end) + end) + + -- blood_particles + if self.blood_amount > 0 + and not disable_blood then + + local pos = self.object:getpos() + + pos.y = pos.y + (-self.collisionbox[2] + self.collisionbox[5]) / 2 + + effect(pos, self.blood_amount, self.blood_texture) + end + + -- knock back effect (only on full punch) + if self.knock_back > 0 + and tflp > punch_interval then + + local v = self.object:getvelocity() + local r = 1.4 - math.min(punch_interval, 1.4) + local kb = r * 5 + local up = 2 + + -- if already in air then dont go up anymore when hit + if v.y > 0 + or self.fly then + up = 0 + end + + self.object:setvelocity({ + x = dir.x * kb, + y = up, + z = dir.z * kb + }) + + self.pause_timer = r + end + + -- if skittish then run away + if self.runaway == true then + + local lp = hitter:getpos() + local s = self.object:getpos() + + local vec = { + x = lp.x - s.x, + y = lp.y - s.y, + z = lp.z - s.z + } + + if vec.x ~= 0 + and vec.z ~= 0 then + + local yaw = atan(vec.z / vec.x) + 3 * pi / 2 - self.rotate + + if lp.x > s.x then + yaw = yaw + pi + end + + self.object:setyaw(yaw) + end + + self.state = "runaway" + self.runaway_timer = 0 + self.following = nil + end + + -- attack puncher and call other mobs for help + if self.passive == false + and self.state ~= "flop" + and self.child == false + and hitter:get_player_name() ~= self.owner then + + -- attack whoever punched mob + self.state = "" + do_attack(self, hitter) + + -- alert others to the attack + local obj = nil + + for _, oir in pairs(minetest.get_objects_inside_radius(hitter:getpos(), 5)) do + + obj = oir:get_luaentity() + + if obj then + + if obj.group_attack == true + and obj.state ~= "attack" then + do_attack(obj, hitter) end end end - end, + end +end - on_activate = function(self, staticdata, dtime_s) +local mob_activate = function(self, staticdata, dtime_s, def) - -- remove monsters in peaceful mode, or when no data - if (self.type == "monster" and peaceful_only) - or not staticdata then + -- remove monsters in peaceful mode, or when no data + if (self.type == "monster" and peaceful_only) + or not staticdata then + + self.object:remove() + + return + end + + -- load entity variables + local tmp = minetest.deserialize(staticdata) + + if tmp then + + for _,stat in pairs(tmp) do + self[_] = stat + end + end + + -- select random texture, set model and size + if not self.base_texture then + + self.base_texture = def.textures[math.random(1, #def.textures)] + self.base_mesh = def.mesh + self.base_size = self.visual_size + self.base_colbox = self.collisionbox + end + + -- set texture, model and size + local textures = self.base_texture + local mesh = self.base_mesh + local vis_size = self.base_size + local colbox = self.base_colbox + + -- specific texture if gotten + if self.gotten == true + and def.gotten_texture then + textures = def.gotten_texture + end + + -- specific mesh if gotten + if self.gotten == true + and def.gotten_mesh then + mesh = def.gotten_mesh + end + + -- set child objects to half size + if self.child == true then + + vis_size = { + x = self.base_size.x / 2, + y = self.base_size.y / 2 + } + + if def.child_texture then + textures = def.child_texture[1] + end + + colbox = { + self.base_colbox[1] / 2, + self.base_colbox[2] / 2, + self.base_colbox[3] / 2, + self.base_colbox[4] / 2, + self.base_colbox[5] / 2, + self.base_colbox[6] / 2 + } + end + + if self.health == 0 then + self.health = math.random (self.hp_min, self.hp_max) + end + + -- rnd: pathfinding init + self.path = {} + self.path.way = {} -- path to follow, table of positions + self.path.lastpos = {x = 0, y = 0, z = 0} + self.path.stuck = false + self.path.following = false -- currently following path? + self.path.stuck_timer = 0 -- if stuck for too long search for path + -- end init + + self.object:set_armor_groups({immortal = 1, fleshy = self.armor}) + self.old_y = self.object:getpos().y + self.old_health = self.health + self.object:setyaw((math.random(0, 360) - 180) / 180 * pi) + self.sounds.distance = self.sounds.distance or 10 + self.textures = textures + self.mesh = mesh + self.collisionbox = colbox + self.visual_size = vis_size + self.standing_in = "" + + -- set anything changed above + self.object:set_properties(self) + update_tag(self) +end + +local mob_step = function(self, dtime) + + local pos = self.object:getpos() + local yaw = self.object:getyaw() or 0 + + -- when lifetimer expires remove mob (except npc and tamed) + if self.type ~= "npc" + and not self.tamed + and self.state ~= "attack" + and remove_far ~= true then + + self.lifetimer = self.lifetimer - dtime + + if self.lifetimer <= 0 then + + -- only despawn away from player + local objs = minetest.get_objects_inside_radius(pos, 15) + + for _,oir in pairs(objs) do + + if oir:is_player() then + + self.lifetimer = 20 + + return + end + end + + minetest.log("action", + "lifetimer expired, removed " .. self.name) + + effect(pos, 15, "tnt_smoke.png") self.object:remove() return end + end - -- load entity variables - local tmp = minetest.deserialize(staticdata) + falling(self, pos) - if tmp then + -- knockback timer + if self.pause_timer > 0 then - for _,stat in pairs(tmp) do - self[_] = stat - end + self.pause_timer = self.pause_timer - dtime + + if self.pause_timer < 1 then + self.pause_timer = 0 end - -- select random texture, set model and size - if not self.base_texture then + return + end - self.base_texture = def.textures[math.random(1, #def.textures)] - self.base_mesh = def.mesh - self.base_size = self.visual_size - self.base_colbox = self.collisionbox + -- run custom function (defined in mob lua file) + if self.do_custom then + self.do_custom(self, dtime) + end + + -- attack timer + self.timer = self.timer + dtime + + if self.state ~= "attack" then + + if self.timer < 1 then + return end - -- set texture, model and size - local textures = self.base_texture - local mesh = self.base_mesh - local vis_size = self.base_size - local colbox = self.base_colbox + self.timer = 0 + end - -- specific texture if gotten - if self.gotten == true - and def.gotten_texture then - textures = def.gotten_texture - end + -- never go over 100 + if self.timer > 100 then + self.timer = 1 + end - -- specific mesh if gotten - if self.gotten == true - and def.gotten_mesh then - mesh = def.gotten_mesh - end + -- node replace check (cow eats grass etc.) + replace(self, pos) - -- set child objects to half size - if self.child == true then + -- mob plays random sound at times + if self.sounds.random + and math.random(1, 100) == 1 then - vis_size = { - x = self.base_size.x / 2, - y = self.base_size.y / 2 - } + minetest.sound_play(self.sounds.random, { + object = self.object, + max_hear_distance = self.sounds.distance + }) + end - if def.child_texture then - textures = def.child_texture[1] - end + -- environmental damage timer (every 1 second) + self.env_damage_timer = self.env_damage_timer + dtime - colbox = { - self.base_colbox[1] / 2, - self.base_colbox[2] / 2, - self.base_colbox[3] / 2, - self.base_colbox[4] / 2, - self.base_colbox[5] / 2, - self.base_colbox[6] / 2 - } - end + if (self.state == "attack" and self.env_damage_timer > 1) + or self.state ~= "attack" then - if self.health == 0 then - self.health = math.random (self.hp_min, self.hp_max) - end + self.env_damage_timer = 0 - -- rnd: pathfinding init - self.path = {} - self.path.way = {} -- path to follow, table of positions - self.path.lastpos = {x = 0, y = 0, z = 0} - self.path.stuck = false - self.path.following = false -- currently following path? - self.path.stuck_timer = 0 -- if stuck for too long search for path - -- end init + do_env_damage(self) + end - self.object:set_hp(self.health) - self.object:set_armor_groups({fleshy = self.armor}) - self.old_y = self.object:getpos().y - self.object:setyaw((math.random(0, 360) - 180) / 180 * pi) - self.sounds.distance = self.sounds.distance or 10 - self.textures = textures - self.mesh = mesh - self.collisionbox = colbox - self.visual_size = vis_size + monster_attack(self) - -- set anything changed above - self.object:set_properties(self) - update_tag(self) + npc_attack(self) + + breed(self) + + follow_flop(self) + + do_states(self, dtime) + +end + +-- default function when mobs are blown up with TNT +local do_tnt = function(obj, damage) + + --print ("----- Damage", damage) + + obj.object:punch(obj.object, 1.0, { + full_punch_interval = 1.0, + damage_groups = {fleshy = damage}, + }, nil) + + return false, true, {} +end + +mobs.spawning_mobs = {} + +-- register mob function +function mobs:register_mob(name, def) + + mobs.spawning_mobs[name] = true + +minetest.register_entity(name, { + + stepheight = def.stepheight or 0.6, + name = name, + type = def.type, + attack_type = def.attack_type, + fly = def.fly, + fly_in = def.fly_in or "air", + owner = def.owner or "", + order = def.order or "", + on_die = def.on_die, + do_custom = def.do_custom, + jump_height = def.jump_height or 6, + jump_chance = def.jump_chance or 0, + drawtype = def.drawtype, -- DEPRECATED, use rotate instead + rotate = math.rad(def.rotate or 0), -- 0=front, 90=side, 180=back, 270=side2 + lifetimer = def.lifetimer or 180, -- 3 minutes + hp_min = def.hp_min or 5, + hp_max = def.hp_max or 10, + physical = true, + collisionbox = def.collisionbox, + visual = def.visual, + visual_size = def.visual_size or {x = 1, y = 1}, + mesh = def.mesh, + makes_footstep_sound = def.makes_footstep_sound or false, + view_range = def.view_range or 5, + walk_velocity = def.walk_velocity or 1, + run_velocity = def.run_velocity or 2, + damage = def.damage or 0, + light_damage = def.light_damage or 0, + water_damage = def.water_damage or 0, + lava_damage = def.lava_damage or 0, + fall_damage = def.fall_damage or 1, + fall_speed = def.fall_speed or -10, -- must be lower than -2 (default: -10) + drops = def.drops or {}, + armor = def.armor, + on_rightclick = def.on_rightclick, + arrow = def.arrow, + shoot_interval = def.shoot_interval, + sounds = def.sounds or {}, + animation = def.animation, + follow = def.follow, + jump = def.jump or true, + walk_chance = def.walk_chance or 50, + attacks_monsters = def.attacks_monsters or false, + group_attack = def.group_attack or false, + --fov = def.fov or 120, + passive = def.passive or false, + recovery_time = def.recovery_time or 0.5, + knock_back = def.knock_back or 3, + blood_amount = def.blood_amount or 5, + blood_texture = def.blood_texture or "mobs_blood.png", + shoot_offset = def.shoot_offset or 0, + floats = def.floats or 1, -- floats in water by default + replace_rate = def.replace_rate, + replace_what = def.replace_what, + replace_with = def.replace_with, + replace_offset = def.replace_offset or 0, + timer = 0, + env_damage_timer = 0, -- only used when state = "attack" + tamed = false, + pause_timer = 0, + horny = false, + hornytimer = 0, + child = false, + gotten = false, + health = 0, + reach = def.reach or 3, + htimer = 0, + child_texture = def.child_texture, + docile_by_day = def.docile_by_day or false, + time_of_day = 0.5, + fear_height = def.fear_height or 0, + runaway = def.runaway, + runaway_timer = 0, + pathfinding = def.pathfinding, + immune_to = def.immune_to or {}, + explosion_radius = def.explosion_radius, + custom_attack = def.custom_attack, + double_melee_attack = def.double_melee_attack, + + on_blast = def.on_blast or do_tnt, + + on_step = mob_step, + + on_punch = mob_punch, + + on_activate = function(self, staticdata, dtime_s) + mob_activate(self, staticdata, dtime_s, def) end, get_staticdata = function(self) @@ -2064,13 +2281,9 @@ end -- END mobs:register_mob function -- global functions -mobs.spawning_mobs = {} - function mobs:spawn_specific(name, nodes, neighbors, min_light, max_light, interval, chance, active_object_count, min_height, max_height, day_toggle) - mobs.spawning_mobs[name] = true - -- chance override in minetest.conf for registered mob local new_chance = tonumber(minetest.setting_get(name .. "_chance")) @@ -2083,7 +2296,7 @@ function mobs:spawn_specific(name, nodes, neighbors, min_light, max_light, chance = new_chance - print ("[Mobs Redo] Chance setting for " .. name .. " is now " .. chance) + print ("[Mobs Redo] Chance setting for " .. name .. " changed to " .. chance) end @@ -2093,8 +2306,9 @@ function mobs:spawn_specific(name, nodes, neighbors, min_light, max_light, neighbors = neighbors, interval = interval, chance = chance, + catch_up = false, - action = function(pos, node, _, active_object_count_wider) + action = function(pos, node, aoc, active_object_count_wider) -- do not spawn if too many active entities in area if active_object_count_wider > active_object_count @@ -2181,7 +2395,7 @@ end -- compatibility with older mob registration function mobs:register_spawn(name, nodes, max_light, min_light, chance, active_object_count, max_height, day_toggle) - mobs:spawn_specific(name, nodes, {"air"}, min_light, max_light, 30, + mobs:spawn_specific(name, nodes, {"air"}, min_light, max_light, 10, chance, active_object_count, -31000, max_height, day_toggle) end @@ -2211,7 +2425,7 @@ function mobs:explosion(pos, radius, fire, smoke, sound) minetest.sound_play(sound, { pos = pos, - gain = 1.0, + gain = 0.7, max_hear_distance = 16 }) end @@ -2242,33 +2456,11 @@ function mobs:explosion(pos, radius, fire, smoke, sound) and data[vi] ~= c_chest then local n = node_ok(p).name + local on_blast = minetest.registered_nodes[n].on_blast - if minetest.get_item_group(n, "unbreakable") ~= 1 then - - -- if chest then drop items inside - if n == "default:chest" - or n == "3dchest:chest" - or n == "bones:bones" then - - local meta = minetest.get_meta(p) - local inv = meta:get_inventory() - - for i = 1, inv:get_size("main") do - - local m_stack = inv:get_stack("main", i) - local obj = minetest.add_item(p, m_stack) - - if obj then - - obj:setvelocity({ - x = math.random(-2, 2), - y = 7, - z = math.random(-2, 2) - }) - end - end - end - + if on_blast then + return on_blast(p) + else -- after effects if fire > 0 and (minetest.registered_nodes[n].groups.flammable @@ -2279,7 +2471,7 @@ function mobs:explosion(pos, radius, fire, smoke, sound) minetest.set_node(p, {name = "air"}) if smoke > 0 then - effect(p, 2, "mobs_blood.png", 5) + --effect(p, 2, "tnt_smoke.png", 5) end end end @@ -2312,7 +2504,7 @@ function mobs:register_arrow(name, def) timer = 0, switch = 0, - on_step = function(self, dtime) + on_step = def.on_step or function(self, dtime) self.timer = self.timer + 1 @@ -2327,6 +2519,13 @@ function mobs:register_arrow(name, def) return end + -- does arrow have a tail (fireball) + if def.tail + and def.tail == 1 + and def.tail_texture then + effect(pos, 1, def.tail_texture, 10, 0) + end + if self.hit_node then local node = node_ok(pos).name @@ -2388,18 +2587,27 @@ function mobs:register_arrow(name, def) end -- Spawn Egg -function mobs:register_egg(mob, desc, background, addegg) +function mobs:register_egg(mob, desc, background, addegg, no_creative) + + local grp = {} + + -- do NOT add this egg to creative inventory (e.g. dungeon master) + if creative and no_creative == true then + grp = {not_in_creative_inventory = 1} + end local invimg = background if addegg == 1 then - invimg = invimg .. "^mobs_chicken_egg.png" + invimg = "mobs_chicken_egg.png^(" .. invimg .. + "^[mask:mobs_chicken_egg_overlay.png)" end minetest.register_craftitem(mob, { description = desc, inventory_image = invimg, + groups = grp, on_place = function(itemstack, placer, pointed_thing) @@ -2414,6 +2622,11 @@ function mobs:register_egg(mob, desc, background, addegg) local mob = minetest.add_entity(pos, mob) local ent = mob:get_luaentity() + if not ent then + mob:remove() + return + end + if ent.type ~= "monster" then -- set owner and tame if not monster ent.owner = placer:get_player_name() @@ -2659,4 +2872,26 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) mob_sta[name] = nil end -end) \ No newline at end of file +end) + +-- compatibility function for old entities to new modpack entities +function mobs:alias_mob(old_name, new_name) + + -- spawn egg + minetest.register_alias(old_name, new_name) + + -- entity + minetest.register_entity(":" .. old_name, { + + physical = false, + + on_step = function(self) + + local pos = self.object:getpos() + + minetest.add_entity(pos, new_name) + + self.object:remove() + end + }) +end diff --git a/games/default/files/mobs/crafts.lua b/games/default/files/mobs_redo/crafts.lua similarity index 99% rename from games/default/files/mobs/crafts.lua rename to games/default/files/mobs_redo/crafts.lua index b6a7c6239..f6c1bc40f 100644 --- a/games/default/files/mobs/crafts.lua +++ b/games/default/files/mobs_redo/crafts.lua @@ -1,5 +1,5 @@ --- nametag +-- name tag minetest.register_craftitem("mobs:nametag", { description = "Nametag", inventory_image = "mobs_nametag.png", @@ -86,4 +86,4 @@ minetest.register_craft({ {'', 'default:steel_ingot', ''}, {'', 'group:stick', 'default:steel_ingot'}, } -}) \ No newline at end of file +}) diff --git a/games/default/files/mobs/depends.txt b/games/default/files/mobs_redo/depends.txt similarity index 100% rename from games/default/files/mobs/depends.txt rename to games/default/files/mobs_redo/depends.txt diff --git a/games/default/files/mobs_redo/init.lua b/games/default/files/mobs_redo/init.lua new file mode 100644 index 000000000..2fea94ba3 --- /dev/null +++ b/games/default/files/mobs_redo/init.lua @@ -0,0 +1,8 @@ + +local path = minetest.get_modpath("mobs") + +-- Mob API +dofile(path.."/api.lua") + +-- Mob Items +dofile(path.."/crafts.lua") diff --git a/games/default/files/mobs/license.txt b/games/default/files/mobs_redo/license.txt similarity index 80% rename from games/default/files/mobs/license.txt rename to games/default/files/mobs_redo/license.txt index 973364b7c..d5e9ea5ef 100644 --- a/games/default/files/mobs/license.txt +++ b/games/default/files/mobs_redo/license.txt @@ -1,13 +1,3 @@ --= MOBS-MOD for MINETEST =- by PilzAdam and KrupnovPavel -Little has changed. Removed some bugs. -The game now many living creatures. -The sheep and the rat from MOBS-MOD -Deer by Pavel_S - -All my models and change code on valid license The MIT License - - - The MIT License (MIT) Copyright (c) 2014 Krupnov Pavel @@ -28,4 +18,6 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. \ No newline at end of file +THE SOFTWARE. + +Above license is for Krupnov Pavel's animals, the rest is WTFPL. \ No newline at end of file diff --git a/games/default/files/mobs_redo/mod.conf b/games/default/files/mobs_redo/mod.conf new file mode 100644 index 000000000..f3a3ad743 --- /dev/null +++ b/games/default/files/mobs_redo/mod.conf @@ -0,0 +1 @@ +name = mobs diff --git a/games/default/files/mobs_redo/readme.MD b/games/default/files/mobs_redo/readme.MD new file mode 100644 index 000000000..d31af5a4c --- /dev/null +++ b/games/default/files/mobs_redo/readme.MD @@ -0,0 +1,59 @@ + +MOBS REDO for MINETEST + +Credits: +https://github.com/blert2112/mobs_more_animals/tree/master/mobs_wolf +https://github.com/blert2112/mobs_more_animals/tree/master/mobs_bear +https://github.com/blert2112/mobs_more_monsters/tree/master/mobs_zombie +https://github.com/tenplus1/mobs + +Built from PilzAdam's original Simple Mobs with additional mobs by KrupnovPavel, Zeg9, ExeterDad, AspireMint, TenPlus1, kaadmy, blert2112 and MoNTE48. + +This mod contains the API only for adding your own mobs into the world, so please use the additional modpacks to add animals, monsters etc. + + +https://forum.minetest.net/viewtopic.php?f=11&t=9917 + + +Changelog: + +- 1.29- Split original Mobs Redo into a modpack to make it easier to disable mob sets (animal, monster, npc) or simply use the Api itself for your own mod +- 1.28- New damage system added with ability for mob to be immune to weapons or healed by them :) +- 1.27- Added new sheep, lava flan and spawn egg textures. New Lava Pick tool smelts what you dig. New atan checking function. +- 1.26- Pathfinding feature added thanks to rnd, when monsters attack they become scary smart in finding you :) also, beehive produces honey now :) +- 1.25- Mobs no longer spawn within 12 blocks of player or despawn within same range, spawners now have player detection, Code tidy and tweak. +- 1.24- Added feature where certain animals run away when punched (runaway = true in mob definition) +- 1.23- Added mob spawner block for admin to setup spawners in-game (place and right click to enter settings) +- 1.22- Added ability to name tamed animals and npc using nametags, also npc will attack anyone who punches them apart from owner +- 1.21- Added some more error checking to reduce serialize.h error and added height checks for falling off cliffs (thanks cmdskp) +- 1.20- Error checking added to remove bad mobs, out of map limit mobs and stop serialize.h error +- 1.19- Chickens now drop egg items instead of placing the egg, also throwing eggs result in 1/8 chance of spawning chick +- 1.18- Added docile_by_day flag so that monsters will not attack automatically during daylight hours unless hit first +- 1.17- Added 'dogshoot' attack type, shoots when out of reach, melee attack when in reach, also api tweaks and self.reach added +- 1.16- Mobs follow multiple items now, Npc's can breed +- 1.15- Added Feeding/Taming/Breeding function, right-click to pick up any sheep with X mark on them and replace with new one to fix compatibility. +- 1.14- All .self variables saved in staticdata, Fixed self.health bug +- 1.13- Added capture function (thanks blert2112) chance of picking up mob with hand; net; magic lasso, replaced some .x models with newer .b3d one's +- 1.12- Added animal ownership so that players cannot steal your tamed animals +- 1.11- Added flying mobs (and swimming), fly=true and fly_in="air" or "deafult:water_source" for fishy +- 1,10- Footstep removed (use replace), explosion routine added for exploding mobs. +- 1.09- reworked breeding routine, added mob rotation value, added footstep feature, added jumping mobs with sounds feature, added magic lasso for picking up animals +- 1.08- Mob throwing attack has been rehauled so that they can damage one another, also drops and on_die function added +- 1.07- Npc's can now be set to follow player or stand by using self.order and self.owner variables +- beta- Npc mob added, kills monsters, attacks player when punched, right click with food to heal or gold lump for drop +- 1.06- Changed recovery times after breeding, and time taken to grow up (can be sped up by feeding baby animal) +- 1.05- Added ExeterDad's bunny's which can be picked up and tamed with 4 carrots from farming redo or farming_plus, also shears added to get wool from sheep and lastly Jordach/BSD's kitten +- 1.04- Added mating for sheep, cows and hogs... feed animals to make horny and hope for a baby which is half size, will grow up quick though :) +- 1.03- Added mob drop/replace feature so that chickens can drop eggs, cow/sheep can eat grass/wheat etc. +- 1.02- Sheared sheep are remembered and spawn shaven, Warthogs will attack when threatened, Api additions +- 1.01- Mobs that suffer fall damage or die in water/lava/sunlight will now drop items +- 1.0 - more work on Api so that certain mobs can float in water while some sink like a brick :) +- 0.9 - Spawn eggs added for all mobs (admin only, cannot be placed in protected areas)... Api tweaked +- 0.8 - Added sounds to monster mobs (thanks Cyberpangolin for the sfx) and also chicken sound +- 0.7 - mobs.protected switch added to api.lua, when set to 1 mobs no longer spawn in protected areas, also bug fixes +- 0.6 - Api now supports multi-textured mobs, e.g oerkki, dungeon master, rats and chickens have random skins when spawning (sheep fix TODO), also new Honey block +- 0.5 - Mobs now float in water, die from falling, and some code improvements +- 0.4 - Dungeon Masters and Mese Monsters have much better aim due to shoot_offset, also they can both shoot through nodes that aren't walkable (flowers, grass etc) plus new sheep sound :) +- 0.3 - Added LOTT's Spider mob, made Cobwebs, added KPavel's Bee with Honey and Beehives (made texture), Warthogs now have sound and can be tamed, taming of shaved sheep or milked cow with 8 wheat so it will not despawn, many bug fixes :) +- 0.2 - Cooking bucket of milk into cheese now returns empty bucket +- 0.1 - Initial Release diff --git a/games/default/files/mobs/sounds/default_punch.ogg b/games/default/files/mobs_redo/sounds/default_punch.ogg similarity index 100% rename from games/default/files/mobs/sounds/default_punch.ogg rename to games/default/files/mobs_redo/sounds/default_punch.ogg diff --git a/games/default/files/mobs_redo/textures/mobs_chicken_cooked.png b/games/default/files/mobs_redo/textures/mobs_chicken_cooked.png new file mode 100644 index 0000000000000000000000000000000000000000..9b116294f18cf65f652af133b166c660c72a5b61 GIT binary patch literal 364 zcmV-y0h9iTP)@L1 zo^~@}M_(dSPPSA81rgEAett8c9%xA{Fbu82#ME3#D|)C3^bYkVH#0nry^F2Lrz;6_7{J4uNN%7i&^r(MM|9=DSn%G-l)bGAob{lU z9HBO4ejYqLan!~O+;~SNaGAPAw6$60?t9rw=)B+T=Dx1X_45nmwO80Z+;CO^0000< KMNUMnLSTX{#iN7( literal 0 HcmV?d00001 diff --git a/games/default/files/mobs_redo/textures/mobs_chicken_egg.png b/games/default/files/mobs_redo/textures/mobs_chicken_egg.png new file mode 100644 index 0000000000000000000000000000000000000000..ab5b2fbcc0e421ba86f408711c84848cafc1d27d GIT binary patch literal 216 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnF3?v&v(vJfvp#Yx{*Z=?jhx%EUWCt#uUbuN_ z?frAJxi;F@0A(3Vg8YIR9G=}s19D0{T^vIy;?`cc$lIVGz#NdmbjLx^EP-)SGIQSl zP!YYT26^GP@$u_89sf$~=C_@k>u4;T%UkixXQQ=-`ZC)WekR-#7{5r@JI`U@X1sak z0pmyIC+v4PtWGk$U%)uUJK~Cr;#9r}rmGK5hc$lH5_ma5`&Fu+?RNY1zaH$-1=`Qx M>FVdQ&MBb@0OO)eC;$Ke literal 0 HcmV?d00001 diff --git a/games/default/files/mobs_redo/textures/mobs_chicken_egg_overlay.png b/games/default/files/mobs_redo/textures/mobs_chicken_egg_overlay.png new file mode 100644 index 0000000000000000000000000000000000000000..7ca75ecdf177b1fdc337c9345e3c304ebd78dc03 GIT binary patch literal 137 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!D3?x-;bCrM;TYyi9E0F&G|NqjP^X~##j3q&S z!3+-1ZlnP@hMq2tAr*1S4a~>b*uJr_)iJZ#F|sxCux;dF6Bc80mScNr%X7$Df<;B5 e!rZ_>o`E5mjg5Iyp0hJhGlQqApUXO@geCy;z8@t3 literal 0 HcmV?d00001 diff --git a/games/default/files/mobs_redo/textures/mobs_chicken_raw.png b/games/default/files/mobs_redo/textures/mobs_chicken_raw.png new file mode 100644 index 0000000000000000000000000000000000000000..4c003e537b1def824327e172b9057e64220444b0 GIT binary patch literal 401 zcmV;C0dD?@P)|Muqp@YDb6 z;lPA%|Lfz}qmuvM)BMZ4yjm=K00001bW%=J06^y0W&i*H_en%SRCr#s&`EN`FbqUd z0^q3Gc82@kG)+(riAv;Eg6;d&RLTA2MZv`v>={Q_NmPE3NVQT*OMV|HdKV+2-U|}j z#LqJzBIdkp8 zh|Kehq6XcEK;S6eHBi@qA;@#iOf{Giz&H1?FXS_rz|8Ecn{QMnW&-c`J9{&LC-R~J z99#o4;AB}AI6ZyG!st%aHE2%WxLa3RoA1p@;^^*nYwo#n^#C_PsQ%ytr|Qn$aX1u@ vgfsKzLJ$qWgWGpdTr-|Q5tOeA)&ICJ1`-VQ 0 then - player:set_hp(player:get_hp() - 2) - end - end - - -- am I near a cactus? - local near = minetest.find_node_near(pos, 1, "default:cactus") - - if near then - - -- am I touching the cactus? if so it hurts - for _,object in pairs(minetest.get_objects_inside_radius(near, 1.1)) do - - if object:get_hp() > 0 then - object:set_hp(object:get_hp() - 2) - end - end - - end - - end - -end) +--[[ + walking on ice makes player walk faster, + stepping through snow or water slows player down, + touching a cactus hurts player, + stuck inside node suffocates player. + + PlayerPlus by TenPlus1 +]] + +-- get node but use fallback for nil or unknown +local function node_ok(pos, fallback) + + fallback = fallback or "air" + + local node = minetest.get_node_or_nil(pos) + + if not node then + return fallback + end + + if minetest.registered_nodes[node.name] then + return node.name + end + + return fallback +end + +local pp = {} +local def = {} +local time = 0 + +minetest.register_globalstep(function(dtime) + + time = time + dtime + + -- every 1 second + if time < 1 then + return + end + + -- reset time for next check + time = 0 + + -- check players + for _,player in pairs(minetest.get_connected_players()) do + + -- where am I? + local pos = player:getpos() + + -- what is around me? + pos.y = pos.y - 0.1 -- standing on + local nod_stand = node_ok(pos) + + pos.y = pos.y + 1.5 -- head level + local nod_head = node_ok(pos) + + pos.y = pos.y - 1.2 -- feet level + local nod_feet = node_ok(pos) + + pos.y = pos.y - 0.2 -- reset pos + + -- is 3d_armor mod active? if so make armor physics default + if minetest.get_modpath("3d_armor") then + def = armor.def[player:get_player_name()] or {} + end + + -- set to armor physics or defaults + pp.speed = def.speed or 1 + pp.jump = def.jump or 1 + pp.gravity = def.gravity or 1 + + -- standing on ice? if so walk faster + if nod_stand == "default:ice" then + pp.speed = pp.speed + 0.6 + end + + -- standing on snow? if so walk slower + if nod_stand == "default:snow" + or nod_stand == "default:snowblock" + -- wading in water? if so walk slower + or minetest.registered_nodes[nod_feet].groups.water then + pp.speed = pp.speed - 0.1 + end + + -- set player physics + player:set_physics_override(pp.speed, pp.jump, pp.gravity) + --print ("Speed:", pp.speed, "Jump:", pp.jump, "Gravity:", pp.gravity) + + -- is player suffocating inside node? (only solid "normal" type nodes) + if minetest.registered_nodes[nod_head].walkable + and minetest.registered_nodes[nod_head].drawtype == "normal" + and not minetest.check_player_privs(player:get_player_name(), {noclip = true}) then + + if player:get_hp() > 0 then + player:set_hp(player:get_hp() - 2) + end + end + + -- am I near a cactus? + local near = minetest.find_node_near(pos, 1, "default:cactus") + + if near then + + -- am I touching the cactus? if so it hurts + for _,object in pairs(minetest.get_objects_inside_radius(near, 1.1)) do + + if object:get_hp() > 0 then + object:set_hp(object:get_hp() - 2) + end + end + + end + + end + +end) diff --git a/games/default/files/railtrack/textures/carts_rail_brk.png b/games/default/files/railtrack/textures/carts_rail_brk.png index 990087f29bafc7fa7cb202a5d9989137a4c2e872..23d396ce32c868c29d57b8bdd6eb61108b123d23 100644 GIT binary patch delta 165 zcmdnWyoGs#1Y>=>r;B5VM0oF+qk@MS7?>SB`xMWBz=e8O%>(lF`Dy$O9t;c~j0eI? z{v7{%)jl&YnxS%|$a&Eqw?&SB8O#e?n=NGR;=6CJ^WDpM<%rL%Q)0EN6+*v%vFLv6 zTmMf|cXtSbLkLgw-qOov$sw06C#%`{HJ$?JYD@<);T3K0RWD#MS1`L delta 166 zcmV;X09pUE1GNLN7y*BXNklHMItM2qQn72V!LYN4eon_rJB4FIt$Aq{Y+}8DE_dr{MMHn6>y16oM?rZa8nMSx z-hmq|{MA?ztx>IaYTh59OOTIv+N;Bo!{!G=e>J+qZsB@uS5_t+v;;W_Th^P)xIH)U cDtzz10d|HA7XjbtIRF3v07*qoM6N<$g7AJxssI20 delta 176 zcmV;h08jt31GNLN4gr6XNkl*I={1;L1~MxQvW?EfhJ#%zM70)x=#4Z`XG0000xs+<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