Darwinbots Forum
Bots and Simulations => DNA - General => Topic started by: Peksa on November 24, 2007, 09:42:31 AM
-
What happens if you try to store a value in location above 1000? Is the location modded (12345 1000 mod)?
EDIT:
Can you store memory location into a memory location?
Eg.
start
blah blab >
400 *971 store
-
Memory locations are just numbers, so you can store the numbers in a memory location no problem. Then you can dereference them with the * operator, like in your example. So yeah, things like pointers are quite possible.
I believe Eric has implemented modding for values > 1000 and values < 0, but I'm not 100% sure on that, so you'll need to double check.
-
So even 98 **.eye5 store would be possible?
-
You would have to do
98 *.eye5 * store
but yeah, that would work. Not sure what it would do though
-
The memory locaiton arguement for stores, incs and decs is indeed MODed for both postive and negative values with the exception that multiples of 1000 store to location 1000.
The only exception is a store to location 0, which by design, does nothing.