Commit c72bc4ac authored by Eben Blaisdell's avatar Eben Blaisdell

dev change

parent 95bd18ad
--[[
Lua needed to initialize the blocks
]]--
--[[
BlockCode variables
......
--[[ A blank program with only the bare minimum requirements ]]--
function onTurn()
end
function onMessage(dir, msg)
......
clockwise = true
currentDir = 0
function onTurn()
end
function onMessage(dir, msg)
--dont do anything on message
end
--[[
Code to have the automata move accross the map, back and forth
]]--
currentDir = 0
function onTurn()
......
--[[
Relies on random chance encounters and a follow-the-crowd custom algorithm to attempt to have all blocks move in the same direction..
This is interesting because at the beginning of the game, all blocks' compasses are randomized
This means that the 0 direction is up for some, left for some, and so on.
This algorithm has shown to be ineffective in the space of 600 turns.
]]--
id = math.random(0,100000) -- assign random id's to each automaton so there are ew collisions.
currentDir = 0
......
--[[
Very simple code so that the blocks just move (in the direction they think is) forward.
]]--
function onTurn()
move(0)
end
function onMessage(dir, msg)
end
--[[
Code that moves all automata to the outside and have them move in a large spiral.
]]--
currentDir = 0
function onTurn()
......
--[[
Arguably the most basic automaton that is any good at the game.
Automata will move to other Automata randomly, ask for a password, and kill those that provide an Incorrect response
]]--
question = "what is the password?"
password = "some random thing #@%%&#@#@#^&%$#@#(*)"
......
--[[
Code for automata that just kill everything in front of them.
]]--
function onTurn()
move(0)
attack(0)
......
math.randomseed( os.time() ) -- this may not be possible after sandboxing
--[[
Code for cellular automata that move randomly
]]--
function onTurn()
local dir = math.random(0,3) -- random direction
......
--[[
The most cowardly cellular automaton. It runs away from everything.
]]--
movesLeft = 0
function onTurn()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment