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: Easy Math Question

Previous Thread :: Next Thread 
Miro034 is not online. Miro034
Joined: 07 Oct 2009
Total Posts: 6568
18 Jan 2012 04:38 PM
Is it possible to use probabilities in RBX.Lua? If yes, please give me an example.
Report Abuse
Miro034 is not online. Miro034
Joined: 07 Oct 2009
Total Posts: 6568
18 Jan 2012 04:45 PM
Come on people!
Report Abuse
grimm343 is not online. grimm343
Joined: 18 Sep 2008
Total Posts: 2796
18 Jan 2012 04:53 PM
Can you give us an example of where you would use one? :o
Report Abuse
swimguy777 is not online. swimguy777
Joined: 30 May 2009
Total Posts: 17092
18 Jan 2012 04:53 PM
That's quite vague, please explain.

-[::ƧѡÎḾḠΰῩ::]-[::Maker of stuff and Helper of Scripting::]-
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
18 Jan 2012 04:54 PM
I don't see how probability calculation is very useful in ROBLOX, but you just use it like normal math :P

~Would you like some butter with that latetoast?
Report Abuse
legend8887 is not online. legend8887
Joined: 06 Nov 2010
Total Posts: 13765
18 Jan 2012 05:00 PM
Give us an example.
Report Abuse
Miro034 is not online. Miro034
Joined: 07 Oct 2009
Total Posts: 6568
19 Jan 2012 11:54 AM
Ok. Give me a minute.
Report Abuse
Miro034 is not online. Miro034
Joined: 07 Oct 2009
Total Posts: 6568
19 Jan 2012 12:07 PM
Probability is used to be described an attitude of mind towards of some proposition of whose truth we are not certain.

Is it possible if I can use the probability scale?

0% (impossible)
25% (unlikely)
50% (even chance)
75% (likely)
100% (certain)

It's really really hard to explain. I hope blockoo and crazyman32 understands.
Report Abuse
su8 is not online. su8
Joined: 06 Mar 2009
Total Posts: 6334
19 Jan 2012 12:10 PM
Number to percent?
Report Abuse
DragonFang1 is not online. DragonFang1
Joined: 02 Apr 2009
Total Posts: 1068
19 Jan 2012 12:29 PM
you could use it as a drop chance in RPG game or something like that

dropchance=100

math.random(1,drop chance/100)

something like that ..too hungry to think right now :P
Report Abuse
ownage94 is not online. ownage94
Joined: 11 Dec 2008
Total Posts: 375
19 Jan 2012 12:34 PM
You could use statistical algorithms to do this... i was never any good at statistics though, hold on a sec, ill try and find the one.
Report Abuse
litozinnamon is not online. litozinnamon
Joined: 21 Dec 2009
Total Posts: 891
19 Jan 2012 02:42 PM
probability = 100 -- 100%
math.random(0+probability,100)


that?
Report Abuse
bikerking200 is not online. bikerking200
Joined: 11 Mar 2010
Total Posts: 5047
19 Jan 2012 02:46 PM
So you're asking is it possible to get a percentage in RBX.Lua?

It's not easy being cheesy.
Report Abuse
DragonFang1 is not online. DragonFang1
Joined: 02 Apr 2009
Total Posts: 1068
20 Jan 2012 10:21 AM
yea then you can use litozinnamon code as a drop chance and add these

if chance=1 then
local d=drop:clone()
d.Parent=game.Players[humanoid:findFirstChild("creator").Value].BackPack
end

something like that if its an rpg game or so.
Report Abuse
Miro034 is not online. Miro034
Joined: 07 Oct 2009
Total Posts: 6568
20 Jan 2012 02:04 PM
Thanks. All I need to know is just infomation to enchance my scripting skill. Thanks by the way.

@Ownage

When you going to show it?
Report Abuse
Miro034 is not online. Miro034
Joined: 07 Oct 2009
Total Posts: 6568
20 Jan 2012 02:11 PM

Probabilities aren't ONLY about Percentages. It's about what's the chance of getting it. (Bad grammar Lolz)

Example:

If I tossed a coin. What is the probability of getting heads?

Anwser: 1/2 because there are two types. (heads n' tails)

P(1 head) = 1/2

But if I tossed 2 coins and you want to know the probability of getting heads.

P(2 head) = 1/4

TROLOLOLOLOLOLO!
Report Abuse
ElectricAxel is not online. ElectricAxel
Joined: 15 May 2009
Total Posts: 16239
20 Jan 2012 02:14 PM
According to what I read about the poker player's fallacy, chances are the same regardless of how many times they are 'stacked', so if you get head, chances of getting another head are not 1/4, but the same 1/2, but yes, if you do take the chances of getting all the heads in a row BEFORE tossing the first coin, it should logically be 1/4.
Report Abuse
DragonFang1 is not online. DragonFang1
Joined: 02 Apr 2009
Total Posts: 1068
21 Jan 2012 12:57 AM
you shouldn't use math.random() btw you should add tick()
I don't remember how you join them up but you should find it in the wiki
Report Abuse
ElectricAxel is not online. ElectricAxel
Joined: 15 May 2009
Total Posts: 16239
21 Jan 2012 03:00 AM
math.randomseed(tick()) ...
Report Abuse
DragonFang1 is not online. DragonFang1
Joined: 02 Apr 2009
Total Posts: 1068
21 Jan 2012 03:14 AM
yea thats the one
Report Abuse
Apocalyps is not online. Apocalyps
Joined: 15 Feb 2009
Total Posts: 816
21 Jan 2012 06:32 AM
I think this is what you mean:

http://en.wikipedia.org/wiki/Fuzzy_logic
Report Abuse
Miro034 is not online. Miro034
Joined: 07 Oct 2009
Total Posts: 6568
21 Jan 2012 02:35 PM
@Apocalyps

It looks really similar to me. Thanks. Are there any more ways?
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