View difference between Paste ID: QnvCGmss and g6fKt3wJ
SHOW: | | - or go back to the newest paste.
1
local mods = peripheral.wrap "back"
2
if mods.disableAI then mods.disableAI() end
3-
local function yaw_and_pitch(e)
3+
4-
    local x, y, z = e.x, e.y, e.z
4+
5-
    local pitch = -math.atan2(y, math.sqrt(x * x + z * z))
5+
	mods.look(0, 0)
6-
    local yaw = math.atan2(-x, z)
6+
	for i = 1, 16 do
7-
    return math.deg(yaw), math.deg(pitch)
7+
		mods.shoot(1)
8-
end
8+
9
    sleep(0.1)
10
end