Enthalpy's v6 Variable Guide

Get started with the upcoming AAO version 6.

Moderator: EN - Forum Moderators

User avatar
Enthalpy
Community Manager
Posts: 5118
Joined: Wed Jan 04, 2012 4:40 am
Gender: Male
Spoken languages: English, limited Spanish

Re: Enthalpy's v6 Variable Guide

Post by Enthalpy »

I've done some minor grammar and clarity fixes.
[D]isordered speech is not so much injury to the lips that give it forth, as to the disproportion and incoherence of things in themselves, so negligently expressed. ~ Ben Jonson
Mertens
Posts: 5
Joined: Wed Jul 15, 2020 3:14 am
Gender: Male
Spoken languages: Español, Inglés

Re: Enthalpy's v6 Variable Guide

Post by Mertens »

i wonder... how do I add something to a variable? I tried doing "Var = Var + 1" in the advanced mode but it changes the value to the expression, I also tried this "'Var' + 1" but it changes the value to "NaN" or something, then I tried it without the '' and like this (cause i saw someone saying it in the spanish version of this) "xpr = Var + 1" and it sometimes changes the value to false and others to the "var + 1"
What should I do? I do not understand what's wrong
User avatar
Tiagofvarela
Posts: 353
Joined: Thu Jun 26, 2014 7:16 pm
Gender: Male
Spoken languages: English, Portuguese
Location: Portugal

Re: Enthalpy's v6 Variable Guide

Post by Tiagofvarela »

Mertens wrote:i wonder... how do I add something to a variable? I tried doing "Var = Var + 1" in the advanced mode but it changes the value to the expression, I also tried this "'Var' + 1" but it changes the value to "NaN" or something, then I tried it without the '' and like this (cause i saw someone saying it in the spanish version of this) "xpr = Var + 1" and it sometimes changes the value to false and others to the "var + 1"
What should I do? I do not understand what's wrong
Assume I have a variable named theory. Here's what I do:
https://i.imgur.com/wvk8YlU.png?1
A Laggy Turnabout ★
A Batty Turnabout ★
A Tricky Turnabout ★
Upcoming: A Worldly Turnabout, A Courtly Turnabout, A Clumsy Turnabout, A Needy Turnabout
User avatar
drvonkitty
Posts: 535
Joined: Sat Apr 14, 2012 12:25 am
Gender: Male
Spoken languages: English

Re: Enthalpy's v6 Variable Guide

Post by drvonkitty »

Hey, been brushing up on variables and returned to this guide, but I had one question that I haven't been able to figure out. Apologies if this is a noob question—I've never been good with the variables!

Let's say I have a variable X, and I want to modify that variable by adding 1 to it. So let's say on Frame 1, I define x = 0. Then, on frame 2, I want to add 1, so x = 1. Then frame 3, add 1, x = 2, so on and so forth. Is that possible?

My goal is to simplify investigation variables by combining multiple into one universal variable. The standard method is to define several variables, let's say "CrimeScene1, CrimeScene2, CrimeScene3" that we define with each examine, and then testing to make sure all of them equal 1. Instead, my idea is to have just one variable, "CrimeScene", and add 1 for each successful examine. Then, we hide the frame that adds 1 once we've completed that examine (so you have to complete each examine). That way we just test for "CrimeScene = 3" instead of the longer combination of several variables.
Image
User avatar
TimeAxis
Posts: 151
Joined: Fri Jan 01, 2021 8:27 pm
Spoken languages: English

Re: Enthalpy's v6 Variable Guide

Post by TimeAxis »

drvonkitty wrote: Wed Apr 13, 2022 8:48 pm Hey, been brushing up on variables and returned to this guide, but I had one question that I haven't been able to figure out. Apologies if this is a noob question—I've never been good with the variables!

Let's say I have a variable X, and I want to modify that variable by adding 1 to it. So let's say on Frame 1, I define x = 0. Then, on frame 2, I want to add 1, so x = 1. Then frame 3, add 1, x = 2, so on and so forth. Is that possible?

My goal is to simplify investigation variables by combining multiple into one universal variable. The standard method is to define several variables, let's say "CrimeScene1, CrimeScene2, CrimeScene3" that we define with each examine, and then testing to make sure all of them equal 1. Instead, my idea is to have just one variable, "CrimeScene", and add 1 for each successful examine. Then, we hide the frame that adds 1 once we've completed that examine (so you have to complete each examine). That way we just test for "CrimeScene = 3" instead of the longer combination of several variables.
Yes, you can do this. You have to turn on Advanced mode, then check the "Load from runtime expression" box in the Variable value field, then whenever you want to add 1, you'd define x as

Code: Select all

x + 1
It should look like this:
Image
Image
Question Arcs (Threads Coming Soon)
ImageImageImageImage

Gaiden Episodes
Champion of Turnabouts (Coming Soon)
User avatar
drvonkitty
Posts: 535
Joined: Sat Apr 14, 2012 12:25 am
Gender: Male
Spoken languages: English

Re: Enthalpy's v6 Variable Guide

Post by drvonkitty »

TimeAxis wrote: Wed Apr 13, 2022 10:08 pm -snip-
I see, so I have to press the scary button that I've never pressed before, got it :side:

Thank you!! Just tested it and it works perfectly!
Image
Post Reply