Jump to content


EatenAlive3's Content

There have been 52 items by EatenAlive3 (Search limited from 10-February 22)


By content type

See this member's


Sort by                Order  

#43614 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 23 October 2012 - 09:54 PM in Turtle Programs

Original post updated with example code by O.S.

Thanks for letting me use it!



#32221 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 16 September 2012 - 03:52 PM in Turtle Programs

You have to use type it using the filename you specify, if you're using it as an API. If you're just running it, use setPos() instead of mt.setPos().



#26869 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 17 August 2012 - 01:09 PM in Turtle Programs

To connect this to a remote terminal, you would have to broadcast the messages from a central turtle/computer, and receive them from your target turtle.



#24569 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 08 August 2012 - 05:59 PM in Turtle Programs

I'd love to hear your ideas, if you're willing to share them. Send me a PM if you want, and we might be able to code it in. Currently I am unable to improve the API because I've injured my left hand and want to keep it out of use, but I will return to the project soon and I'm open to ideas.



#23366 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 03 August 2012 - 08:59 PM in Turtle Programs

It only matters that an ingame turtle has this installed, and then you can redistribute it to other computers via floppy-disks.



#23224 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 03 August 2012 - 10:35 AM in Turtle Programs

Read in the original post, "Basic Usage guide." Don't worry, it isn't a long read!



#18200 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 07 July 2012 - 11:02 AM in Turtle Programs

Remember, Lua is case-sensitive. Use mt.setPos(), not mt.setpos.



#16019 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 17 June 2012 - 02:57 PM in Turtle Programs

Thanks! Yes, the architect system is pretty clever. I try to make turtles more useful by letting them collect as much information as they possibly can. The more they know, the more they can do!



#14365 [Error] multiple points [SOLVED]

Posted by EatenAlive3 on 03 June 2012 - 02:04 AM in Ask a Pro

In this segment of code, I've gotten that same error before:
table.insert(cube,#cube+1,xb+iii..","..yb-i..","..zb+ii)
I found out that you can't do any operations like addition and subtraction within string concatenations. So, the fixed code would be using parenthesis:
table.insert(cube,#cube+1,(xb+iii)..","..(yb-i)..","..(zb+ii))
Search your code for things like this.



#13650 [Turtle][CraftOS]Liraal's Stuff: Keycard Lock; magicTurtle API v. 1.252

Posted by EatenAlive3 on 27 May 2012 - 10:13 PM in Turtle Programs

View PostLiraal, on 27 February 2012 - 07:04 PM, said:

save this as magicTurtle (without the '.txt' part) into your turtle's root folder (.minecraft/saves/savename/computer/computerID/).
then enter LUA prompt in-game. type 'os.loadAPI("magicTurtle")' then follow the instructions in the first post. then you can simply call the functions by using magicTurtle.functionname(params) (e.g. 'magicTurtle.tunnel(3,3,10)' )
the rest is up to you.



#13637 How to make a Game with OOP PART 2/2

Posted by EatenAlive3 on 27 May 2012 - 04:23 PM in Tutorials

The post seems a little unclear, maybe you should include a sample file. Also, you should combine this with the first thread, rather than make it separate.

And these are called 'prototypes,' not classes. Lua doesn't support classes.



#13631 MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!

Posted by EatenAlive3 on 27 May 2012 - 01:17 PM in Turtle Programs

Hi all. Originally, I found Liraal's MagicTurtle API and started improving on it, and then we started working together. Eventually, I suppose he lost interest, but he did give me permission to post this as my own API. I haven't worked on this in a while, so it is still in the beta stage for a few features, like unmapped pathfinding, although it does work for the most part. Anyway, full feature list below in spoilers, but here are some of the highlights:

> The turtle will record data through a mapping system as it travels; it remembers where it's been and what blocks were there.
> The turtle is able to explore portions of land fairly quickly.
> Turtles are now able to pathfind to given coordinates, so long as it has mapped the area for it.
> ...if the area has not been mapped, it will do its best to get there.
> Ability to render a map of what's been explored, or a given coordinate.
> Tons of features that really should be in turtles, like place(cobblestone), forward(5), or select(wood).
> Tons of even more cool features that make it so you will never have to worry about turtle functions again!

Spoiler

Pastebin:
http://pastebin.com/Yt1u8zAu

If there is enough support for this, then I will go on to finish v1.4, and possibly more beyond that. v1.4 will streamline all code, and fix any bugs that may exist. I'm actually about 40% done with that so far. Post any questions, comments, or suggestions about the API in this thread.

Basic usage guide:
Spoiler

If you would like an example code, here is something that O.S. wrote, as a manual remote control for turtles using a modified graph function:
Spoiler

Smarter turtles for a smarter future!

Enjoy!



#10118 (Question)Starting Out

Posted by EatenAlive3 on 22 April 2012 - 12:35 AM in Ask a Pro

If you're making a turtle program, one of the first things I would recommend is to automate the movement functions. For example, this code would automate the turtle.forward() function:
function forward(spaces)
  if not spaces then spaces = 1 end
  local state = true
  while state and spaces < 0 do
    state = turtle.forward()
    spaces = spaces - 1
  end
  return state
end
You could also download or create a turtle API to do these things outside of one program. With streamlined functions, all you will ever need to do is one function rather than a for loop.



#10112 Remote Control Turtle Program

Posted by EatenAlive3 on 22 April 2012 - 12:20 AM in Programs

Nice, and welcome :3



#9307 Advanced Programs: Orefinder, Tunnel.

Posted by EatenAlive3 on 14 April 2012 - 02:42 PM in Turtle Programs

BlackNavi, try navigating to the folder that the advanced tunnel program is listed in, and run it from that directory.



#8881 [Simple][Miner][Turtle]Square Maker

Posted by EatenAlive3 on 11 April 2012 - 12:42 AM in Turtle Programs

Looks good. Unfortunately, you wasted some typing on all those ones, as the turtle movement and digging functions take no arguments (turtle.forward() works the same as turtle.forward(1), or even turtle.forward(9)). I'd reccomend using functions or loops for things like this. Usually, three for loops can get you pretty far, especially if working with mining and cuboids (one for the X axis, one for Y, one for Z.) Good job :P/>



#8855 Sphere and Dome Builder

Posted by EatenAlive3 on 10 April 2012 - 09:10 PM in Turtle Programs

Awesome!



#8680 Turtle autominig (kind of api)

Posted by EatenAlive3 on 09 April 2012 - 05:58 PM in Turtle Programs

Some API documentation would be fabulous. I'd love to find out the full extent of your API.



#8618 [Read New Post]Unexpected Symbol Error

Posted by EatenAlive3 on 09 April 2012 - 12:20 AM in Ask a Pro

A hint for these 'direct' errors: after [string "program"]:, the number is the line number the error occurs at. If your error isn't a logic issue or similar, then you can find exactly which keyword is causing the issue by dividing your line onto multiple lines of code.



#8556 Ninja's Programs (Taking Request)

Posted by EatenAlive3 on 08 April 2012 - 06:37 PM in Programs

Try my idea that I posted on your last thread:
Spoiler



#8553 [Turtle][CraftOS]Liraal's Stuff: Keycard Lock; magicTurtle API v. 1.252

Posted by EatenAlive3 on 08 April 2012 - 06:35 PM in Turtle Programs

Try something like this, and tell me what happens. I've never had any difficulty with saving and loading the position.
setPos(60,64,60,2)
savePos()
getPosF()



#8539 [Turtle][CraftOS]Liraal's Stuff: Keycard Lock; magicTurtle API v. 1.252

Posted by EatenAlive3 on 08 April 2012 - 03:21 PM in Turtle Programs

@kinxkinxkin, 1.4 is currently in beta, so bugs are expected. If you want a stable release, continue to use 1.3 until 1.4 is fully released.

@M1cr0man: If you mean making hollow versions of blueprints, that is certainly possible. I can add that in. Otherwise, I don't understand what you mean.



#8532 [1.3]Advanced Turtle Detection

Posted by EatenAlive3 on 08 April 2012 - 02:06 PM in Suggestions

You can already partially compare two slots, although it only works with blocks. Place slot1, switch to slot2, and compare. It will return true if the slots are the same and false if not.



#8447 Ninja's Programs [Now Taking Requests]

Posted by EatenAlive3 on 08 April 2012 - 02:09 AM in General

Program Name: Shape Builder
What Will the Program Be Used For: Creating perfectly calculated structures of varying sizes via turtles.
---- Program Description ----
After starting the program, a list of several options would be shown: Sphere, Cylinder, Cone, Cuboid, Pyramid. After the user selects one, it asks for the dimensions of the shape, and the mode (dig or build.) Sphere, for example, would take a radius, and if mode is set to build, would build a sphere, or if set to dig, would dig out a spherical room. When completed, the program ends.



#8445 String Manipulation Help

Posted by EatenAlive3 on 08 April 2012 - 02:02 AM in Ask a Pro

Length usage:
string = "cabbage"
return string:len()
> returns 7