Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

[ANSWERED] Math are should have functions?

Asked by
gloveshun 119
5 years ago
Edited 5 years ago

i want to make a weird game...but i dont know how to make a positive number to a negative number... can you make me an answer to help meh?

0
Ah yes, mental abuse to humans. This question is great BashGuy10 384 — 5y
0
oh gloveshun 119 — 5y

1 answer

Log in to vote
0
Answered by 5 years ago
Edited 5 years ago

Lets consider variable "number" is the positive number, you can just multiply it with -1 to make it negative or you could also just put a dash in front of it.

number = number * -1

or

number = -number
0
i could test it gloveshun 119 — 5y
0
Glad it works. :) araltan2002 47 — 5y
0
really gloveshun 119 — 5y
Ad

Answer this question