Author Topic: trace and access variables?  (Read 476 times)  Share 

trace and access variables?
« on: 08 Apr 2004, 16:12 »
hi all,

2 - questions:
how i can trace variables, during runtime?
and
can i access a roomvariable from another room?
for example, if i have a roomvariable for a door.
i need the status (open or closed) in both rooms, where the door come in use.

thx greets rocco

ps: please correct my english, if its not accurate and if you have enough time  ;)

ElectricMonk

  • Secret Worshipper of Little Cthulhu
Re:trace and access variables?
« Reply #1 on: 08 Apr 2004, 16:33 »
Quote
can i access a roomvariable from another room?
for example, if i have a roomvariable for a door.
i need the status (open or closed) in both rooms, where the door come in use.

I think you'll need to use a global variable for that.

And your English is fine. ;)

Scummbuddy

  • Mittens Knight
  • Give Stylish Confetti to BoZo - Wheee!
    • I can help with AGS tutoring
    •  
    • I can help with animation
    •  
    • I can help with backgrounds
    •  
    • I can help with characters
    •  
    • I can help with proof reading
    •  
    • I can help with scripting
    •  
    • I can help with story design
    •  
    • I can help with voice acting
    •  
Re:trace and access variables?
« Reply #2 on: 08 Apr 2004, 17:31 »
and to trace a variable, i think you'll want GetGlobalInt, theres more info in the manual, I can't post it, since im not on my home computer. And I also think your english is very good.
- Oh great, I'm stuck in colonial times, tentacles are taking over the world, and now the toilets backing up.
- No, I mean it's really STUCK. Like adventure-game stuck.
-Hoagie from DOTT

Re:trace and access variables?
« Reply #3 on: 08 Apr 2004, 22:46 »
thanks, i thought it works like the defined ones, @overhotspot@ @scoretext@,
but that dont works with normal variables, so i have to use display instead.
access roomavariables from outside is not possible, you say.

@ElektricMonk
i want to partizipate in this months ags contest, can you help me correcting and translating text sequences if i can finsih it, cause im from austria and i recognize that you also speak german.

ElectricMonk

  • Secret Worshipper of Little Cthulhu
Re:trace and access variables?
« Reply #4 on: 09 Apr 2004, 04:28 »
Quote
@ElektricMonk
i want to partizipate in this months ags contest, can you help me correcting and translating text sequences if i can finsih it, cause I'm from austria and i recognize that you also speak german.

Sure, if the game is not too long, send me a message when it's done. Just leave me some time before the deadline of the contest, so I won't have to translate the whole thing in one evening or so... ;)

Re:trace and access variables?
« Reply #5 on: 09 Apr 2004, 23:53 »

Sure, if the game is not too long, send me a message when it's done. Just leave me some time before the deadline of the contest, so I won't have to translate the whole thing in one evening or so... ;)

thanks,
the game is short, nobody can make a very long game in 20 days (except one without a job:).
I will hurry up, and hopefully need only grammatical corretions and not a full translation.

Scorpiorus

  • 100101101010b
Re:trace and access variables?
« Reply #6 on: 10 Apr 2004, 18:39 »
Quote
how i can trace variables, during runtime?
Currently, there is no way to trace them with some built-in debugging mechanism, so yes using a Display() function or some sort of a debug GUI is the only possibility.

Quote
can i access a roomvariable from another room?
you can't but you can either make a use of GlobalInts as ElectricMonk suggested or declare a global variable and export it so different rooms can share it:

main global script:
int shared_var;

end of main global script:
export shared_var;

script header
import int shared_var; //thus it will be imported into every room

~Cheers