Incrementing/decrementing a variable that does not contain a number results in whatever the variable previously referring to being disappeared and replacing it with a new number.
Code Snippet (if applicable) to Reproduce Problem:
mob
verb
test()
var/lol = list("cake")
src << ++lol
lol = "cake"
src << ++lol
lol = new /mob
src << ++lol
Expected Results:
For variables that are typecast, maybe a compile-time error. For non-typecast variables that don't contain numbers, a run-time error.
Actual Results:
Destroys whatever my variable was holding and replaces it with a number.
edit: Destroy isn't the proper word, I think. It just replaces the value of the variable. My object is, I assume, garbage collected.
edit: the above code prints:
1
1
1
Does the problem occur:
Every time? Or how often? Yes
In other games? Yes
In other user accounts? Yes
On other computers? Yes