Need Help with Leaderboard

  • Thread starter Thread starter Unregistered
  • Start date Start date
U

Unregistered

Guest
So im not an expert with the world editor yet, but I'm getting better. Anyway, Darg you helped my out with a trigger problem ealier, maybe you can help with my leader board problem, it may be complex, but maybe you can still help.

So here's the premise and want i'd like to do. The map i made is an 8 player 2v2v2v2. Players 1-8 are human players, and 11 is the computer. The computer spawns monsters that attack every 5 minutes. I want to create a leader board that has the four teams and keeps track of how many player 11 kills each team has.

At the end of the spawning (last round is over) id like to have the team with highest points win.

If you could help that would be great and i would appreciate it much. Thanks in advance.
 
you need to make an integer kill array which keeps track of your kills. this array will be using 8 slots, one for each player.

ok so you set up the leaderboard and add 4 players to it (any 4 players), and give those players the values of the 2 allys in each team e.g.

player 1 value = (kills[1] + kills[2])
player 2 value = (kills[3] + kills[4])
.......

so:

event:
a unit owner by player 11 dies

action:
set kills[player number of owner of killing unit] = set kills[player number of owner of killing unit] + 1

then you need to change the value of the leaderboard everytime this happens too:

leaderboard - change value for player 1 to (kills[1] + kill[2])
........



when your game is over, now you need to find the team with the most kills. this isn't trivial when i think about it, you have to use the integer comparison 'math - max' (or something like that), which will tell you which of 2 values are higher (so you compare 2 kill values). just compare all the values till you find the highest one.
 
a different leaderboard

...why not post here.


this is simple, i want to make it so that when you type a certain thing, leaderboard count goes up ( i know this sounds really stupid )

basically...for example, you put down "lift weights" and then in the leaderboard it will go up by 1. you type it again, it goes to 2...
 
um, leaderboards can have multiple entries each with a value. How many entries does your board have?

Assuming it just has 1, u need to keep track of the value of it using a variable. Call it say 'variable' or something. Make it an integer variable.

so:

event: [chat message]
player types "lift weights" as an exact string

action:
set variable = variable + 1
change value of <player 1> in <last created leaderboard> to <variable>

that action assumes that that value you put into the leaderboard is for <player 1>. Remember that you have to specify a player when entering a value in the board. In reality this doesn't mean anything because you can put any value in, and it is very misleading to people who are new to the editor.
 
woo

finally found out...thanks, basically, i am making a game where you can train your stats and battle other people.

Player 1 Position- Life
Player 2 Position- Strength
Player 3 Position- Defense
Player 4 Position- Intelligence
Player 5 Position- Accuracy
Player 6 Position- Speed

You type in "Punching Bag" and your strength increases by 1. Type "Target practice" and your accuracy increases. Get it?

For life, it goes like this.

Event- Player 1 enters a chat message "Swimming Lap" as an Exact Match.

Condition- None

Action- Set Integer Array[1]= (IntegerArray[1]=1)
Run Swimming Lap Add, ignoring conditions

and in swimming lap add it changes value
 
anyway...so i'm still making the map, and i also put in another player ( 8, green ) that represents the weight of your player...( i know this game sounds stupid but it is really fun so far )


anyway, you can eat chicken, which does: SetIntegerArray[10]=(IntegerArray[10]+1)

it adds 1 weight, so the leaderboard goes:

Status:
WEIGHT: 1

then, you can eat a thing called a diet pill, which reduces it by 1...
SetIntegerArray[11]=(IntegerArray[11]+-1)

Status:
WEIGHT: 0

However, instead it simply makes the weight -1 instead of subtracting 1, which makes it zero....right?

So it does this:

Status/Weight: -1

then i eat another chicken bone, and it should go back up to 1 from 0, but it brings me to 2.... they're basically in 2 different worlds

anyway, i'm gonna go listen to some starcraft music now....sounds like rock lol
 
two that i know...
BACKINTIME- Starcraft Theme Music
GROBAN- Weird music

anyway, starcraft theme music isn't that bad...but kind of crabby, it doesn't work well...and most of the time it never works when i type it! but it sounds cool anyway....
 
Um, are there any new questions being asked in this thread that I haven't answered yet? I actually can't tell anymore, cause there's so much stuff in here.....

Let me just say that I have NEVER gotten 'BACKINTIME' to work. And I don't understand HOW it would work either, since I am yet to find ANY starcraft music on the war3 cd, or in the war3 directory on the hdd.

I challenge anyone who gets the music playing to record it and post it up here in mp3 format. And tell us EXACTLY under what conditions this cheat will and will not work.
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Ghan Ghan:
    Real users can't really disable Javascript anymore these days.
  • Ghan Ghan:
    The internet is broken without it.
  • Ghan Ghan:
    Bot readable, not human usable.
  • The Helper The Helper:
    got it
  • The Helper The Helper:
    Happy Thursday!
  • The Helper The Helper:
    Check out the new Featured Content feature we apparently got with the forum software upgrade! https://www.thehelper.net/featured/
  • The Helper The Helper:
    Also on the bottom right side bar we now have a Trending Content Box!
    +1
  • The Helper The Helper:
    Not on the Headline News page just on the Forums page can we get that Featured and Trending on the home page?
  • Ghan Ghan:
    Since the home page is technically a forum, it now shows on all forum views. Still in the sidebar.
    +1
  • The Helper The Helper:
    Happy Friday! Hope everyone has a fantastic day and an even better weekend!
  • The Helper The Helper:
    Happy Sunday!
  • The Helper The Helper:
    I lovc that I can post webp and X links now! :)
  • The Helper The Helper:
    Happy Thursday!
  • V-SNES V-SNES:
    Happy Friday!
    +1
  • The Helper The Helper:
    we were down for a minute - think a log file or something got too big
    +1
  • Ghan Ghan:
    The alerts say it was down for a while unfortunately.
  • Ghan Ghan:
    Didn't know what was going on while I was at work.
  • Ghan Ghan:
    Disk filled up with logs. Fixed now.
    +1
  • The Helper The Helper:
    not a problem at all thanks for getting us back up
  • The Helper The Helper:
    I think the bots are finding a way to get through the anubis
  • The Helper The Helper:
    Happy Wednesday Everyone! Hope everyone has a Fantastic Day!
    +1
  • The Helper The Helper:
    Yeah, stats are showing big bot influx like 12k page views.
  • Wizard Wizard:
    :wave:
    +1
  • Ghan Ghan:
    TH changed his avatar again. 6 more weeks of summer.
    +3
  • Wizard Wizard:
    lol
    +1

The Helper Discord

Members online

No members online now.

Affiliates

Hive Workshop NUON Dome World Editor Tutorials
Back
Top