This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
MrDeano's profile picture

i dont understand

Started by MrDeano, 14 October 2012 - 05:59 PM
MrDeano #1
Posted 14 October 2012 - 07:59 PM
hey guy i got a problem every time i go out the area i LOSE mt turtles and i don't know why then i remembered that the chucks unload so the first thing i put anchors everywhere but i still lose them then i tried teleport tethers but yet i still lose them they just disappeared
Doyle3694 #2
Posted 14 October 2012 - 08:01 PM
They disappear?

Someone is trolling you is the first thing that comes to my mind.
PixelToast #3
Posted 14 October 2012 - 08:02 PM
explain to us what you did to the turtles before they dissapeared, are you on smp?
try reloading the level, constant movement can cause visual artifacts making them look invisible
MrDeano #4
Posted 14 October 2012 - 08:17 PM
yes im on smp and no one is trolling me no one is on lol
PixelToast #5
Posted 14 October 2012 - 08:20 PM
are your turtles constantly moving?
is it in the startup program?
MrDeano #6
Posted 14 October 2012 - 08:23 PM
no heres the code that im running

SpoilerxCoord = -164
zCoord = 195
yCoord = 72

xQuarry = 999
zQuarry = 999
yQuarry = 150

xProgress = 999
zProgress = 999
yProgress = 150
oProgress = 1
xHome = xCoord
zHome = zCoord
yHome = yCoord
yTravel = 85
orientation = 4
orientations = {"north", "east", "south", "west"}

zDiff = {-1, 0, 1, 0}
xDiff = {0, 1, 0, -1}
lineLength = 2
lines = 3

yMin = 999
function inventoryFull()

turtle.select(9)

full = turtle.getItemCount(9) > 0

turtle.select(1)

return full
end

function left()

orientation = orientation - 1

orientation = (orientation - 1) % 4

orientation = orientation + 1

turtle.turnLeft()
end

function right()

orientation = orientation - 1

orientation = (orientation + 1) % 4

orientation = orientation + 1

turtle.turnRight()
end

function moveForward()

xCoord = xCoord + xDiff[orientation]

zCoord = zCoord + zDiff[orientation]

turtle.dig()


moved = false

while not(moved) do

moved = turtle.forward()

end
end

function moveUp()

yCoord = yCoord + 1


turtle.digUp()

moved = false

while not(moved) do

moved = turtle.up()

end
end

function moveDown()

yCoord = yCoord - 1

turtle.digDown()


moved = false

while not(moved) do

moved = turtle.down()

end


if yMin > yCoord then

yMin = yCoord

end
end

function look(direction)

while direction ~= orientations[orientation] do

right()

end
end
function goto(xTarget, zTarget, yTarget)

while yTarget < yCoord do

moveDown()

end


while yTarget > yCoord do

moveUp()

end


if xTarget < xCoord then

look("west")

while xTarget < xCoord do

moveForward()

end

end

if xTarget > xCoord then

look("east")

while xTarget > xCoord do

moveForward()

end

end


if zTarget < zCoord then

look("north")

while zTarget < zCoord do

moveForward()

end

end

if zTarget > zCoord then

look("south")

while zTarget > zCoord do

moveForward()

end

end
end

function returnItems()

xProgress = xCoord

zProgress = zCoord

yProgress = yCoord

oProgress = orientation


goto(xHome, zHome, yTravel)

goto(xHome, zHome, yHome)


for i = 1,9 do

turtle.select(i)

turtle.drop()

end

turtle.select(1)


goto(xProgress, zProgress, yTravel)

goto(xProgress, zProgress, yProgress)

look(orientations[oProgress])
end
function digLine()

for i = 1,lineLength do

if inventoryFull() then

returnItems()

end


moveForward()

end
end

function digLayer()

for i = 1,lines do

digLine()

if (i%2) == 1 and i < lines then

left()

moveForward()

left()

elseif i < lines then

right()

moveForward()

right()

end

end

goto(xQuarry, zQuarry, yCoord)

look("north")

moveDown()
end

function digQuarry(xTarget, zTarget, yTarget)

xQuarry = xTarget

zQuarry = zTarget

yQuarry = yTarget


goto(xQuarry, zQuarry, yTravel)

goto(xQuarry, zQuarry, yQuarry)

look("north")

while yMin > 7 do

digLayer()

end

goto(xQuarry, zQuarry, yQuarry)

yMin = 999
end

digQuarry(-170, 210, 70)
PixelToast #7
Posted 14 October 2012 - 08:55 PM
not sure :/
possibly getting stuck at bedrock?
MrDeano #8
Posted 14 October 2012 - 09:04 PM
its at lvl 44
Doyle3694 #9
Posted 14 October 2012 - 09:44 PM
wait, so we arn't talking about still turtles here? You we're very uninformative in OP
MrDeano #10
Posted 14 October 2012 - 09:47 PM
not still turtles my turtles are dissapearing
Doyle3694 #11
Posted 14 October 2012 - 10:38 PM
your english makes no sense right now….
MrDeano #12
Posted 14 October 2012 - 10:41 PM
look my turtles are disappearing when i unload chucks but i put world anchors and teleport tethers but they still keep disappearing
Doyle3694 #13
Posted 14 October 2012 - 10:53 PM
then you aren't unloadung the chunks. also, define CC version