-- File: codersea/codersea-urchin.lua -- Purpose: CoderSea urchin support module -- Credits: See "codersea.md" -- Licenses: See "LICENSE" local spawnchance = codersea_chance_urchin if spawnchance < 300 then spawnchance = 300 end local mobtype = "animal" if codersea_monster_urchin then mobtype = "monster" end mobs:register_mob ("codersea:urchin", { do_custom = mob_custom , type = mobtype , attack_type = "dogfight" , damage = 2 , reach = 1 , hp_min = 5 , hp_max = 10 , armor = 40 , walk_velocity = 0.1 , run_velocity = 0.1 , floats = 0 , fly = false , fly_in = fly_water , fall_speed = -1 , view_range = 2 , stepheight = 0.5 , jump_height = 0.5 , water_damage = 0 , lava_damage = 5 , light_damage = 0 , visual = "mesh" , mesh = "codersea_urchin.b3d" , collisionbox = { -0.10, -0.10, -0.10, 0.10, 0.10, 0.10 } , textures = { { "codersea_urchin.png" } } , makes_footstep_sound = false, on_rightclick = function (self, clicker) mobs:capture_mob (self, clicker, 80, 100, 0, true, nil) end }) mobs:spawn_specific ("codersea:urchin", { "codersea:water_source" , "default:water_source" , "default:water_gel" , } , { "codersea:water_flowing" , "codersea:water_source" , "default:water_flowing" , "default:water_source" , } , 2, 25, 30, spawnchance, codersea_aoc_urchin, -31000, -1) mobs:register_egg ("codersea:urchin", "Sea Urchin", "codersea_urchin_item.png", 0)