Panwellz
|
  |
| Joined: 16 Oct 2012 |
| Total Posts: 749 |
|
|
| 09 Feb 2016 10:38 AM |
scripts i need:
- A script that shortens leaderstat values from 1000 to 1,00K, 10000 to 10,0K 100000 to 100K, 1000000 to 1.00M and so on. pay = 200-250 robux
- A script that puts gear into the backpack of players owning gamepassID pay = 75-100 robux
- A script to use in a gear that breaks joints of items inside the "Humanoid", Only the humanoid of the player that has the gear pay = 300+ robux
|
|
|
| Report Abuse |
|
|
Panwellz
|
  |
| Joined: 16 Oct 2012 |
| Total Posts: 749 |
|
| |
|
jroles7
|
  |
| Joined: 24 Oct 2014 |
| Total Posts: 766 |
|
|
| 09 Feb 2016 11:35 AM |
| i'll do the Shorten script PM me |
|
|
| Report Abuse |
|
|
chimmihc
|
  |
| Joined: 01 Sep 2014 |
| Total Posts: 17143 |
|
|
| 09 Feb 2016 11:59 AM |
"1000 to 1,00K, 10000 to 10,0K 100000 to 100K, 1000000 to 1.00M"
Your rules for this shortening seem rather random.
Also there is no possible way to add such functionality to your game by simple adding a script. You would have to store the actual stats somewhere else and replace them with StringValues.
|
|
|
| Report Abuse |
|
|
jroles7
|
  |
| Joined: 24 Oct 2014 |
| Total Posts: 766 |
|
|
| 09 Feb 2016 12:12 PM |
| I just did nub so actually you can its called leaderbard stats it convertes anything with certain amount of 0 to k or m or b or t, etc |
|
|
| Report Abuse |
|
|
chimmihc
|
  |
| Joined: 01 Sep 2014 |
| Total Posts: 17143 |
|
|
| 09 Feb 2016 12:23 PM |
You do know that NumberValues and IntValue can't hold strings right?
|
|
|
| Report Abuse |
|
|
chimmihc
|
  |
| Joined: 01 Sep 2014 |
| Total Posts: 17143 |
|
|
| 09 Feb 2016 12:38 PM |
You probably don't. No doubt you are too 1337 for logic and sandboxes.
|
|
|
| Report Abuse |
|
|
Panwellz
|
  |
| Joined: 16 Oct 2012 |
| Total Posts: 749 |
|
|
| 09 Feb 2016 12:40 PM |
@chim It is possible to make just check miners haven
|
|
|
| Report Abuse |
|
|
chimmihc
|
  |
| Joined: 01 Sep 2014 |
| Total Posts: 17143 |
|
|
| 09 Feb 2016 01:12 PM |
I have not played it so I do not know if it used the default playerlist or not. But either way it employs the exact tactic I explained in my first post. Store the actual number value somewhere else, display its value formatted.
|
|
|
| Report Abuse |
|
|
Panwellz
|
  |
| Joined: 16 Oct 2012 |
| Total Posts: 749 |
|
|
| 09 Feb 2016 01:14 PM |
yeah that makes sense, guess i'll just rescript everything to a money value outside leaderstats
|
|
|
| Report Abuse |
|
|
|
| 09 Feb 2016 01:55 PM |
Miners haven is a bit more complex actually, since the numbers go really big in that game, it stores each section separately in a table, I saw it on the devforum somewhere.
It's similar to Adventure capitalist, they go up to like 1x10^255. |
|
|
| Report Abuse |
|
|
chimmihc
|
  |
| Joined: 01 Sep 2014 |
| Total Posts: 17143 |
|
|
| 09 Feb 2016 02:11 PM |
"Miners haven is a bit more complex actually, since the numbers go really big in that game, it stores each section separately in a table, I saw it on the devforum somewhere.
It's similar to Adventure capitalist, they go up to like 1x10^255."
How you store the number doesn't matter, the concept is the exact same.
And that number isn't possible, doubles loose integer precision LONG before that.
9999999999999999 is the limit, afterwards digit precision is gone.
|
|
|
| Report Abuse |
|
|
|
| 09 Feb 2016 02:15 PM |
- A script that shortens leaderstat values from 1000 to 1,00K, 10000 to 10,0K 100000 to 100K, 1000000 to 1.00M and so on. function shortennumber(num) local mil=0 while num >= 1000000 do mil=mil+1 num=num-1000000 end local th=0 while num >= 1000 do th=th+1 num=num-1000 end local str=tostring(num) if mil >= 1 then str=(mil+(th*10000/1000000))..'M' elseif th >= 1 then str=(th+(num/1000))..'K' end return str end print(shortennumber(100000))
- A script that puts gear into the backpack of players owning gamepassID
GamePassId = 0000 AdminTools = {}
local function e(b, a) assert(b, "ERROR: WaitForChild: parent is nil") while not b:FindFirstChild(a) do b.ChildAdded:wait() end return b[a] end local d = game:service('GamePassService') local b = game:service('Players') local c = game:service('InsertService') local a = game:service('Lighting') local function f(b) for a, a in pairs(AdminTools) do local a = c:LoadAsset(a):children()[1] a.Parent = b end end local function a(b) if d:PlayerHasPass(b, GamePassId) then local a = e(b, 'StarterGear') f(a) if b.Character then local a = e(b, 'Backpack') f(a) end end end b.PlayerAdded:connect(a)
- A script to use in a gear that breaks joints of items inside the "Humanoid", Only the humanoid of the player that has the gear script.Parent.Activated:connect(function() game.Players.LocalPlayer.Character:BreakJoints() end)
You owe me atleast 675 robux. |
|
|
| Report Abuse |
|
|
|
| 09 Feb 2016 02:24 PM |
"9999999999999999 is the limit, afterwards digit precision is gone."
I don't think you get how its stored, its not a single digit, its a table of digits
Like they store 4 digits for every 3 digits or similar, so example is they would store how much Quattuornonagintillion money they have, then the next would be Quinnonagintillion, etc.
To handle adding, they would just do a loop through, like if Quattuornonagintillion > 1000, Quattuornonagintillion = Quattuornonagintillion - 1000, then Quinnonagintillion + 1
Just an example. |
|
|
| Report Abuse |
|
|