SRL Archive - Help

Multiply Symbol?


Littellj

2012-04-01 12:55:53

What is the mutliply symbol for Simba?

I want to make
XPGain := (CurrentXP - OriginalXP);

into

XPGain := ((CurrentXP - OriginalXP)*.85);

Assuming * is the multiply symbol.

Frement

2012-04-01 13:45:36

* is the multiply symbol.

So:
XPGain := ((CurrentXP - OriginalXP) * 0.85);[SIMBA]

Littellj

2012-04-01 14:29:03

I get a type mismatch when i do that.

Imagine

2012-04-01 14:36:30

I'm not positive, but did you declare XPGain as an integer? You might need to declare it as an extended value so you can store decimal places because 0.85 is not always going to give you an integer answer when you multiply it by something else.

Home

2012-04-01 14:42:43

XPGain as integer or you need to Round it.

~Home

putonajonny

2012-04-01 15:00:53

XPGain := Round((CurrentXP - OriginalXP) * 0.85);[SIMBA]

Littellj

2012-04-01 19:53:52

Thanks guys, I had thought that but didn't know how to do it.