2017-05-28 04:54:26 +02:00
|
|
|
-- Functions for sneeker mod
|
2017-05-28 04:30:56 +02:00
|
|
|
|
|
|
|
|
2017-05-29 10:29:08 +02:00
|
|
|
-- Spawns a sneeker entity
|
2017-05-29 09:58:55 +02:00
|
|
|
function sneeker.spawn(pos)
|
2017-07-29 02:10:57 +02:00
|
|
|
core.add_entity(pos, sneeker.mob_name)
|
2021-05-06 04:11:14 +02:00
|
|
|
sneeker.log("debug", "Spawned entity \"" .. sneeker.mob_name .. "\" at " .. tostring(pos.x) .. "," .. tostring(pos.y))
|
2017-05-29 09:58:55 +02:00
|
|
|
end
|
2017-05-29 11:49:02 +02:00
|
|
|
|
|
|
|
-- Retrieves pos coordinates in string value
|
|
|
|
function sneeker.get_pos_string(pos)
|
2021-05-07 06:45:12 +02:00
|
|
|
return "x=" .. tostring(pos.x) .. ", y=" .. tostring(pos.y) .. ", z=" .. tostring(pos.z)
|
2017-05-29 11:49:02 +02:00
|
|
|
end
|