generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Finding Highest Value?

Previous Thread :: Next Thread 
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:38 AM
If I had 9 values

Value1 - Value9 How could I compare them all at once?
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:39 AM
math.max(var1, var2, ..., var9)
Report Abuse
cntkillme is not online. cntkillme
Joined: 07 Apr 2008
Total Posts: 44956
03 Jan 2014 01:40 AM
highest = math.max(val1, val2, val3, ...)
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:41 AM
@cnt: Stop being slow!
Report Abuse
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:41 AM
Notunknown99 == cntkillme :O
Report Abuse
cntkillme is not online. cntkillme
Joined: 07 Apr 2008
Total Posts: 44956
03 Jan 2014 01:41 AM
Notun I got floodchecks everywhere!11
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:41 AM
Notunknown99 > cntkillme
Report Abuse
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:42 AM
What to do if 2 values are the same??
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:42 AM
@cnt: Excuses, excuses...

Stupid floodcheck... (2)
Report Abuse
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:42 AM
e.e Im not even offline...
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:43 AM
Then what does it matter? You get the highest one.

FC (2)
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:43 AM
The online dot is like quite a lot of roblox: Very glitchy.
Report Abuse
cntkillme is not online. cntkillme
Joined: 07 Apr 2008
Total Posts: 44956
03 Jan 2014 01:43 AM
Notunknown99 > cntkillme * 0
Report Abuse
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:44 AM
Well, if I am voting for a map and two values are the same, what does the math.max grab?
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:45 AM
Notunknown99 == math.abs(cntkillme) + 1
Report Abuse
cntkillme is not online. cntkillme
Joined: 07 Apr 2008
Total Posts: 44956
03 Jan 2014 01:45 AM
Probably the second one.

math.max(5, 5) would _probably_ give you the second argument's 5, or not.
Report Abuse
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:45 AM
Notunknown99 < cntkillme

I am emotionally attached to cnt
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:46 AM
I do not know. Probably the first one it comes across.
Report Abuse
cntkillme is not online. cntkillme
Joined: 07 Apr 2008
Total Posts: 44956
03 Jan 2014 01:48 AM
get dropt Notun.

Notunknown99 > cntkillme * math.sin(math.pi)
Report Abuse
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:48 AM
I dont understand :D
Report Abuse
cntkillme is not online. cntkillme
Joined: 07 Apr 2008
Total Posts: 44956
03 Jan 2014 01:49 AM
He's greater than 0
Report Abuse
Notunknown99 is not online. Notunknown99
Joined: 05 Sep 2008
Total Posts: 25360
03 Jan 2014 01:50 AM
cntkillme == 0

∴ Notunknown99 > cntkillme
Report Abuse
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:51 AM
If I do Highest = math.max(with my values)

if Highest == ? then

do I have to do that for each value? I have 2k+ Values D:
Report Abuse
cntkillme is not online. cntkillme
Joined: 07 Apr 2008
Total Posts: 44956
03 Jan 2014 01:52 AM
You can't change a constant, cntkillme is originally (2^63)-1 and Notunknown99 was never set.

nil > 9223372036854775807
Report Abuse
person725 is not online. person725
Joined: 11 Oct 2009
Total Posts: 535
03 Jan 2014 01:52 AM
OGM NOT MADE AN ARROR

cntkillme = 0

∴ Notunknown99 > cntkillme


Only use 2 equal signs when comparing values...NOOB
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image