;'Player General Level list' - timed script

UserID = #USERID

Player = GetUserID(GetUserMessage(UserID))
If Player > 0
	GeneralLevel = GetUserStrength(Player) + GetUserWisdom(Player) + GetUserAgility(Player) + GetUserEndurance(Player)
	GeneralLevel = Floor(GeneralLevel / 4)
	If GetUserAccess(Player) > 0
		SendMessageToUser(UserID,"(God)"+GetUserName(Player)+": "+GeneralLevel,#MSG_SERVER)
	Else
		SendMessageToUser(UserID,GetUserName(Player)+": "+GeneralLevel,#MSG_SERVER)
	EndIf
	GoTo END
EndIf

Player = GetUserFlag(UserID,45)

SendMessageToUser(UserID,"General Player Levels:",#MSG_EMOTE)

i = 0
While i < 5
	If Player = 0
		SendMessageToUser(UserID,"~End of player list~",#MSG_EMOTE)
		GoTo SKIP
	EndIf
	
	GeneralLevel = GetUserStrength(Player) + GetUserWisdom(Player) + GetUserAgility(Player) + GetUserEndurance(Player)
	GeneralLevel = Floor(GeneralLevel / 4)
	If GetUserAccess(Player) > 0
		SendMessageToUser(UserID,"(God)"+GetUserName(Player)+": "+GeneralLevel,#MSG_SERVER)
	Else
		SendMessageToUser(UserID,GetUserName(Player)+": "+GeneralLevel,#MSG_SERVER)
	EndIf
	
	Label SKIP
	Player = GetNextUser(Player)
	i=i+1
Wend

SetUserFlag(UserID,45,Player)

Label END

Continue = 1