Help with leaderboard

sensesxfailx

New Member
Reaction score
0
I need help with this leaderboard i dont know how to fix the error.
It says that line 66 has a Expected 'set' which is the error
Line 66 is call ForForce( GetPlayersAll(), function Trig_Leaderboard_Func003A )
The whole trigger is below, Please help

//***************************************************************************
//*
//* Global Variables
//*
//***************************************************************************

globals
// User-defined
integer array udg_Player_Kills

// Generated
rect gg_rct_Spawn = null
rect gg_rct_sight = null
trigger gg_trg_Begining = null
trigger gg_trg_spawning = null
trigger gg_trg_Sight = null
rect gg_rct_Blade = null
rect gg_rct_Demon = null
rect gg_rct_Player1 = null
rect gg_rct_Player2 = null
rect gg_rct_Sight2 = null
rect gg_rct_Spawn2 = null
trigger gg_trg_Blade = null
unit gg_unit_Obla_0007 = null
trigger gg_trg_Blade_Copy = null
trigger gg_trg_Demon = null
unit gg_unit_Edem_0008 = null
trigger gg_trg_Demon_Copy = null
rect gg_rct_Choose = null
trigger gg_trg_Leaderboard = null
trigger gg_trg_Unit_Died = null
endglobals

function InitGlobals takes nothing returns nothing
local integer i = 0
set i = 0
loop
exitwhen (i > 1)
set udg_Player_Kills = 0
set i = i + 1
endloop

endfunction

function Trig_Leaderboard_Func003Func001C takes nothing returns boolean
if ( not ( GetPlayerController(GetEnumPlayer()) == MAP_CONTROL_USER ) ) then
return false
endif
if ( not ( GetPlayerSlotState(GetEnumPlayer()) == PLAYER_SLOT_STATE_PLAYING ) ) then
return false
endif
return true
endfunction

function Trig_Leaderboard_Func003A takes nothing returns nothing
if ( Trig_Leaderboard_Func003Func001C() ) then
call LeaderboardAddItemBJ( GetEnumPlayer(), GetLastCreatedLeaderboard(), GetPlayerName(GetEnumPlayer()), 0 )
else
call DoNothing( )
endif
endfunction

function Trig_Leaderboard_Actions takes nothing returns nothing
call CreateLeaderboardBJ( GetPlayersAll(), "TRIGSTR_020" )
bj_wantDestroyGroup=true
call ForForce( GetPlayersAll(), function Trig_Leaderboard_Func003A )
call LeaderboardDisplayBJ( true, GetLastCreatedLeaderboard() )
endfunction

//===========================================================================
function InitTrig_Leaderboard takes nothing returns nothing
set gg_trg_Leaderboard = CreateTrigger( )
call TriggerRegisterTimerEventSingle( gg_trg_Leaderboard, 5 )
call TriggerAddAction( gg_trg_Leaderboard, function Trig_Leaderboard_Actions )
endfunction
 
Uhhh, I can't do JASS (this is JASS right?) but anyhow just here to say put your code in code tags, looks nicer. Use the # to do so.
 
Look for a JASS checker on world-editor-tutorials.thehelper.net. It should be able to detect your probelm.
 
That's just a converted GUI trigger... Why did you convert it in the first place? Your error is
Code:
bj_wantDestroyGroup=true
. It should be
Code:
set bj_wantDestroyGroup=true
 
By the way, set bj_WantDestroyGroup = true will do nothing at all in that script.
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    It is weird seeing a way more realistic users online number
  • The Helper The Helper:
    Happy Tuesday Night!
    +1
  • V-SNES V-SNES:
    Happy Friday!
    +1
  • The Helper The Helper:
    News portal has been retired. Main page of site goes to Headline News forum now
  • The Helper The Helper:
    I am working on getting access to the old news portal under a different URL for those that would rather use that for news before we get a different news view.
  • Ghan Ghan:
    Easily done
    +1
  • The Helper The Helper:
    https://www.thehelper.net/pages/news/ is a link to the old news portal - i will integrate it into the interface somewhere when i figure it out
  • Ghan Ghan:
    Need to try something
  • Ghan Ghan:
    Hopefully this won't cause problems.
  • Ghan Ghan:
    Hmm
  • Ghan Ghan:
    I have converted the Headline News forum to an Article type forum. It will now show the top 20 threads with more detail of each thread.
  • Ghan Ghan:
    See how we like that.
  • The Helper The Helper:
    I do not see a way to go past the 1st page of posts on the forum though
  • The Helper The Helper:
    It is OK though for the main page to open up on the forum in the view it was before. As long as the portal has its own URL so it can be viewed that way I do want to try it as a regular forum view for a while
  • Ghan Ghan:
    Yeah I'm not sure what the deal is with the pagination.
  • Ghan Ghan:
    It SHOULD be there so I think it might just be an artifact of having an older style.
  • Ghan Ghan:
    I switched it to a "Standard" article forum. This will show the thread list like normal, but the threads themselves will have the first post set up above the rest of the "comments"
  • The Helper The Helper:
    I don't really get that article forum but I think it is because I have never really seen it used on a multi post thread
  • Ghan Ghan:
    RpNation makes more use of it right now as an example: https://www.rpnation.com/news/
  • The Helper The Helper:

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top