your adding Strings together, hehe.
Attribute Types:
String = a collection of characters
a
1
dead
abc_123abc_123
fhafhbfebc384ubu3bd39dyy3vy3vdyv_bdjeei7349398du_bjkebuub
so, a String of "1" + a String of "1" = "11"
so, a String of 'a' + a String of 'a' = "aa"
so, a String of "1" + a String of "1" + a String of "1" + a String of "1" + a String of "1" = "11111"
what you got to do is to use Integers (int):
Integer = a number value (-100, -1, 0, 1, 100)
"1" is a String Value (anything in typed into the code with quotes makes it a string)
1 is an Integer Value
A String: "apple"
An Object: apple
see, how 1 can be either an integer or a string?
you got to change your 1's into an Integer Attribute Type
get input {
-> // you type in 1, but when it is used (referenced) in~by the coding, it is: Attribute Type: String, so you got to convert it into: Attribute Type: Integer (int), by doing: ToInt (your_value_be_it_directly_a_number_value_or_a_variable_such_as_'result' )
}
get input {
-> // you type in during game play: 1
-> quest sets its default variable: result = your_input_which_is_a_string
-> variable_x = ToInt (result)
-> // 'ToInt' converts your 'result' from Type:String into Type:Integer, and now 'variable_x' = a type:integer value
}
An Integer: ToInt (result)
A String: ToString (result)
you probably didn't change the attribute type from a string to an integer when you created (added) your attribute in the GUI~Editor:
(whatever) Object -> Attribute (tab) -> Attributes -> Add ->
Object: (whatever)
Attribute Name: blah
Attribute Type: int
Attribute Value: 0
for example (in code):
<game name="blah">
-> // other code (attribute) lines
-> <attr name="turns" type="int">0</attr>
-> // other code (attribute) lines
</game>
<turnscript name="global_turnscript">
-> <enabled />
-> <script>
->-> game.turns = game.turns + 1
-> </script>
</turnscript>
---------
also, you got to make sure both your values being computed (added, subtracted, multiplied, or divided), be integers, as you can't compute a String and Integer, as neither quest~computer nor us-humans understand how to do this, lol.
------
if you provide your game code, we can show you how to change it for it to work, as we don't know your code~script method for generating your number value.