oerkki.lua 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. local S = mobs.intllib
  2. -- Oerkki by PilzAdam
  3. mobs:register_mob("mobs_monster:oerkki", {
  4. type = "monster",
  5. passive = false,
  6. attack_type = "dogfight",
  7. pathfinding = true,
  8. reach = 2,
  9. damage = 4,
  10. hp_min = 8,
  11. hp_max = 34,
  12. armor = 100,
  13. collisionbox = {-0.4, -1, -0.4, 0.4, 0.9, 0.4},
  14. visual = "mesh",
  15. mesh = "mobs_oerkki.b3d",
  16. textures = {
  17. {"mobs_oerkki.png"},
  18. {"mobs_oerkki2.png"},
  19. },
  20. makes_footstep_sound = false,
  21. sounds = {
  22. random = "mobs_oerkki",
  23. },
  24. walk_velocity = 1,
  25. run_velocity = 3,
  26. view_range = 10,
  27. jump = true,
  28. drops = {
  29. {name = "default:obsidian", chance = 3, min = 0, max = 2},
  30. {name = "default:gold_lump", chance = 2, min = 0, max = 2},
  31. },
  32. water_damage = 2,
  33. lava_damage = 4,
  34. light_damage = 1,
  35. fear_height = 4,
  36. animation = {
  37. stand_start = 0,
  38. stand_end = 23,
  39. walk_start = 24,
  40. walk_end = 36,
  41. run_start = 37,
  42. run_end = 49,
  43. punch_start = 37,
  44. punch_end = 49,
  45. speed_normal = 15,
  46. speed_run = 15,
  47. },
  48. replace_rate = 5,
  49. replace_what = {"default:torch"},
  50. replace_with = "air",
  51. replace_offset = -1,
  52. immune_to = {
  53. {"default:sword_wood", 0}, -- no damage
  54. {"default:gold_lump", -10}, -- heals by 10 points
  55. },
  56. })
  57. if not mobs.custom_spawn_monster then
  58. mobs:spawn({
  59. name = "mobs_monster:oerkki",
  60. nodes = {"default:stone"},
  61. max_light = 7,
  62. chance = 7000,
  63. max_height = -10,
  64. })
  65. end
  66. mobs:register_egg("mobs_monster:oerkki", S("Oerkki"), "default_obsidian.png", 1)
  67. mobs:alias_mob("mobs:oerkki", "mobs_monster:oerkki") -- compatiblity