Universo Games
Ola , Convidado

Ranking De Level (ate 5 pessoas ) Logo1110

Você ainda não e cadastrado então cadastre-se e veja todas as atualizações no Mundo RPG!!!
Universo Games
Gostaria de reagir a esta mensagem? Crie uma conta em poucos cliques ou inicie sessão para continuar.
Universo Games

Suporte e Desenvolvimento só no Universo Games
 
InícioInício  PortalPortal  EventosEventos  PublicaçõesPublicações  Últimas imagensÚltimas imagens  RegistarRegistar  EntrarEntrar  
Ola Convidado, Seja Bem vindo a equipe lhe deseja boa sorte no seu projeto!

 

 Ranking De Level (ate 5 pessoas )

Ir para baixo 
AutorMensagem
Convidado
Convidado
Anonymous



Ranking De Level (ate 5 pessoas ) Empty
MensagemAssunto: Ranking De Level (ate 5 pessoas )   Ranking De Level (ate 5 pessoas ) EmptyDom 12 Set 2010, 21:33

Abra o Client~Side

pra começar tudo precisamos abrir o Ranking, então crie um botão e dentro dele Adicione

Código:
If PicLevel.Visible = True Then
    PicLevel.Visible = False
    frmMainMenu.lstLEVEL.Clear
    Else
    PicLevel.Visible = True
    Call SendData("level" & SEP_CHAR & END_CHAR)
    End If

Primeiro Crie uma Picture na frmMainMenu com o nome PicLevel e dentro dela uma ListBox com o nome lstLEVEL

Em seguida Procure por:

Código:
If casestring = "allchars" Then

        n = 1

        frmChars.Visible = True
        frmSendGetData.Visible = False

        frmChars.lstChars.Clear

        For i = 1 To MAX_CHARS
            Name = parse(n)
            Msg = parse(n + 1)
            Level = Val(parse(n + 2))

            If Trim$(Name) = vbNullString Then
                frmChars.lstChars.addItem "Free Character Slot"
            Else
                frmChars.lstChars.addItem Name & " a level " & Level & " " & Msg
            End If

            n = n + 3
        Next i

        frmChars.lstChars.ListIndex = 0

        Exit Sub
    End If

Abaixo Adicione

Código:
If Parse(0) = "level" Then
frmMainMenu.lstLEVEL.AddItem (Parse(1) & "  Level:" & Parse(2))
frmMainMenu.lstLEVEL.AddItem (Parse(3) & "  Level:" & Parse(4))
frmMainMenu.lstLEVEL.AddItem (Parse(5) & "  Level:" & Parse(6))
frmMainMenu.lstLEVEL.AddItem (Parse(7) & "  Level:" & Parse(8))
frmMainMenu.lstLEVEL.AddItem (Parse(9) & "  Level:" & Parse(10))
frmMainMenu.PicLevel.Visible = True
Exit Sub
End If

agora no Server~Side

Procure por

Código:
Case "acclogin"
            Call Packet_AccountLogin(Index, Parse(1), Parse(2), Val(Parse(3)), Val(Parse(4)), Val(Parse(5)), Parse(6))
            Exit Sub

Abaixo Adicione

Código:
 Case "level"
Call SendDataTo(Index, "level" & SEP_CHAR & GetVar(App.Path & "\Level.ini", "1", "Nome") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "1", "Level") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "2", "Nome") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "2", "Level") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "3", "Nome") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "3", "Level") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "4", "Nome") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "4", "Level") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "5", "Nome") & SEP_CHAR & GetVar(App.Path & "\Level.ini", "5", "Level") & SEP_CHAR & END_CHAR)
Exit Sub

Agora procure por

Código:
Sub CheckPlayerLEvelUp

Lá no final desta sub adicione

Código:
If GetPlayerLevel(Index) > Val(ReadINI("1", "Level", App.Path & "\Level.ini")) Then
    Call WriteINI("1", "Nome", GetPlayerName(Index), App.Path & "\Level.ini")
    Call WriteINI("1", "Level", GetPlayerLevel(Index), App.Path & "\Level.ini")
    Call WriteINI("3", "Nome", Val(ReadINI("2", "Nome", App.Path & "\Level.ini")), App.Path & "\Level.ini")
    Call WriteINI("3", "Level", Val(ReadINI("2", "Level", App.Path & "\Level.ini")), App.Path & "\Level.ini")
    Call WriteINI("2", "Nome", Val(ReadINI("1", "Nome", App.Path & "\Level.ini")), App.Path & "\Level.ini")
    Call WriteINI("2", "Level", Val(ReadINI("1", "Level", App.Path & "\Level.ini")), App.Path & "\Level.ini")
    End If
If GetPlayerLevel(Index) > Val(ReadINI("2", "Level", App.Path & "\Level.ini")) Then
    Call WriteINI("3", "Nome", Val(ReadINI("2", "Nome", App.Path & "\Level.ini")), App.Path & "\Level.ini")
    Call WriteINI("3", "Level", Val(ReadINI("2", "Level", App.Path & "\Level.ini")), App.Path & "\Level.ini")
    Call WriteINI("2", "Nome", GetPlayerName(Index), App.Path & "\Level.ini")
    Call WriteINI("2", "Level", GetPlayerLevel(Index), App.Path & "\Level.ini")
 
End If
If GetPlayerLevel(Index) > Val(ReadINI("3", "Level", App.Path & "\Level.ini")) Then
    Call WriteINI("3", "Nome", GetPlayerName(Index), App.Path & "\Level.ini")
    Call WriteINI("3", "Level", GetPlayerLevel(Index), App.Path & "\Level.ini")
End If
 Exit Sub

Em seguida crie um Arquivo com o nome Level.ini e o conteudo

Código:
[1]
Nome=Tio Lucas :P
Level=100
[2]
Nome=Tio Lendario :P
Level=100
[3]
Nome=Tio Boas :P
Level=100
[4]
Nome=Tio Hatakki :P
Level=100
[5]
Nome=Tio Lopo :P
Level=100

Pronto seu Ranking automático está pronto

Como Usar:
Aperte o botão que colocou na frmMainMenu e Tchan!


Crédito: Boafesta Por fazer o Ranking
Crédito: Lucas Lopo Por adaptar para Eclipse e para o MainMenu e agora com ate 5 ou mais players no ranking xD
Crédito: Lendario Por tirar o bug do botao ^^
Crédito: Thalesbliss Por Postar.



[Tens de ter uma conta e sessão iniciada para poderes visualizar esta imagem] Very Happy
Ir para o topo Ir para baixo
Lucas Roberto
Administrador
Administrador
Lucas Roberto


Mensagens : 711

Ranking De Level (ate 5 pessoas ) Empty
MensagemAssunto: Re: Ranking De Level (ate 5 pessoas )   Ranking De Level (ate 5 pessoas ) EmptyDom 12 Set 2010, 22:03

Muito Bom
afro lol!
Ir para o topo Ir para baixo
https://universogamesmmo.forumeiros.com
 
Ranking De Level (ate 5 pessoas )
Ir para o topo 
Página 1 de 1
 Tópicos semelhantes
-
» [EEB]Ranking De LeveL Automatico
» As pessoas mais inteligentemente burras da terra 2!!
» As pessoas mais inteligentemente burras da terra!!
» Ranking de Guild
» Sistema de Ranking Configuravel

Permissões neste sub-fórumNão podes responder a tópicos
Universo Games :: Criação de Jogos :: Eclipse :: Tutoriais-
Ir para: