#/baltop skript GUI

1 messages · Page 1 of 1 (latest)

crisp gust
#

Neep desperate help! I am trying to make a /baltop exactly like DonutSMP using Skript, however, loading all offline players balances (vault plugin) causes IMMENSE server lag. How do I make the baltop load every single player without lag, so I can make a proper baltop system. I don't need to be spoon fed or whatever but if anyone can send me skript documentations or an example skript or ANYTHING PLEASE that does this without server lag.

crisp gust
#

anyone

stuck ibex
#

You can waitatick

#

Every so often

#

Otherwise skript tries to compress it all into a tick

haughty nest
#

Keep the Baltop as its dictionary (position, username). It’s pretty unlikely that a players balance will change while they are offline so just update a player’s position in baltop every 5 mins or whatever and when they leave the game.

#

Also do what the guy above me said with waiting a tick

#

Save old baltop and display that while new baltop is calculated

austere pulsar
#

Check and update a list when someone joins and leaves or checks baltop. Sort the list after. This way you're only sorting through 10 entries

rough nest
#

This is probably deleted on every platform but I'm glad I downloaded it before it was taken down

haughty nest
#

@crisp gust I would be wary of downloading plugins from random people on discord, it could easily have malware

modest peak
#

plugin just for baltop 😭

rough nest
rough nest
haughty nest
rough nest
#

u want video or live stream

haughty nest
#

???

rough nest
#

there are couple of ways to show it

haughty nest
#

How would a video or live stream prove its not malware

rough nest
#

how else would i prove its not malware

haughty nest
#

Send source code

rough nest
#

Its not even mine

#

as i told u, its already been deleted. i searched my browser history and the page is gone

haughty nest
rough nest
#

I believe you have some trust issues.

haughty nest
rough nest
#

ive used both

haughty nest
#

When you go to download the file the file name is exactly the same

rough nest
#

Its been re uploaded yea

#

i noticed too

#

the name and page was different

haughty nest
#

So if it’s been re uploaded to a site that checks for malware why wouldn’t you just link it?

rough nest
#

how braindead are u

#

i noticed it NOW

haughty nest
#

Ah

#

You said “I noticed too” which made me think you meant you noticed it was on spigot too

rough nest
#

yea no i noticed after u sent it

haughty nest
#

Also this isn’t a reupload

rough nest
#

i downloaded the file back in august so yea its had more updates sicne then i see

haughty nest
#

If it was a reupload it wouldn’t have an update history

rough nest
#

you're not thinking straight buddy

haughty nest
#

It has an update history going back to July

rough nest
#

idk then maybe someone else posted it

#

i just went to second page

haughty nest
#

It seems to me like this is the one you downloaded

rough nest
#

could be the problem it got deleted then

#

most likely not but file, sure

#

the one i got it from had no images

haughty nest
#

Sounds like ur the one who got it from a reupload

rough nest
#

yuea

#

stolen upload as i believe

#

wait brb

haughty nest
#

Well even if u didn’t put malware in it then the fact that it’s reuploaded makes me think that rhe one u sent has malware in it even more

#

Cause that’s like the #1 reason people reupload plugins

#

To upload them with malware

rough nest
#

or idk

#

possible i need to check it

#

lemme check the one u sent

haughty nest
#

You dont realize anything happend

arctic skiff
#

If it doesnt do anything in general than its malware

#

check the code if possible

rough nest
#

well ive been using the one i sent since i downloaded it

#

works fine

#

comparing it with the one u sent Zev

#

They're almost same

#

the colors changed a bit

#

I didnt click on mine, i suggest y'all dont either

arctic skiff
#

when i get home ill check the code

rough nest
#

aight

#

the way they look in gui also changed a bit

#

names and lore stuff

arctic skiff
#

ok

crisp gust
#

i used to use that zbaltop

#

but i wanna learn how to code it on skript for other leaderboards so

sage willowBOT
#

x8ight suggests that you read this embed

Sorted Indices

The sorted indices expression returns a new list of indices sorted by the value of the index. This can be very helpful for making all sorts of leaderboards. Lets say we have the balances of our players saved in the variable {balance::%player's uuid%}. To create our leaderboard we can use```vb
set {_sorted::} to sorted indices of {balance::} in descending order````{_sorted::*}will be a list of uuids with{_sorted::1}being the person with the most money. If we wanted to check how much money they had we could plug the uuid back into the original variable:{balance::%{_sorted::1}%}`

Leaderboard Example
command /baltop:
    trigger:
        set {_sorted::*} to sorted indices of {balance::*} in descending order
        send "<aqua>Baltop"
        loop first 10 elements of {_sorted::*}:
            send "<gold>%loop-iteration%. <white>%offlineplayer(loop-value)% <gray>- <green>$%{balance::%loop-value%}%"```
crisp gust
#

the problem is that i still need

#

to like

#

load all balances

#

is there like any way on skript to load something like instantly or soemthing

#

there are many plugins that can do it so idk

haughty nest
#

And sort that variable

crisp gust
stuck ibex
#

you can wait a tick after loading every page in the GUI

#

also getting skins of offline players is a bit laggy (so if you use their skulls there's that too)

crisp gust
stuck ibex
#

depends how often you do it and what exactly your loop is doing in the first place

crisp gust
#

alr ty

crisp gust
#

Im so dumb bro i spent 3 hours coding it and kept wondering why it was so laggy

#

but forgot player heads loading cause lag

#

ill just make the playerhead like steve or something unless they are online ig

haughty nest
visual hawk
#

with paginated formatting and being able to handle 100s of page indexes and updates per second from 100 players spamming through pages

modest peak
#

why do you have 1 million balances and why do you need to do it in 1 second

visual hawk
#

Just bad user experience

modest peak
#

"Scalability" when servers will never have 100k players let alone 1m

visual hawk
visual hawk
stuck ibex
#

how many of those 100k leave to never rejoin?

#

no need to list a bunch of 0s; make them qualify for baltop

haughty nest
#

even the most basic minecraft backdoors dont get detected by virustotal