Author Topic: A question  (Read 3830 times)

Offline Peksa

  • Bot Destroyer
  • ***
  • Posts: 118
    • View Profile
A question
« 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.
Code: [Select]
start
blah blab >
400 *971 store
« Last Edit: November 24, 2007, 09:45:36 AM by Peksa »

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
A question
« Reply #1 on: November 24, 2007, 09:48:21 AM »
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.

Offline Peksa

  • Bot Destroyer
  • ***
  • Posts: 118
    • View Profile
A question
« Reply #2 on: November 24, 2007, 09:51:52 AM »
So even 98 **.eye5 store would be possible?

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
A question
« Reply #3 on: November 24, 2007, 10:05:42 AM »
You would have to do

98 *.eye5 * store

but yeah, that would work.  Not sure what it would do though

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
A question
« Reply #4 on: November 24, 2007, 09:32:01 PM »
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.
Many beers....