Universo Games
Ola , Convidado

Sistema de Resets 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!

 

 Sistema de Resets

Ir para baixo 
AutorMensagem
Convidado
Convidado
Anonymous



Sistema de Resets Empty
MensagemAssunto: Sistema de Resets   Sistema de Resets EmptyQua 30 Nov 2011, 20:15


Client~Side

No final da Type PlayerRec antes do End Type adicione:

Código:
    Resets As Long

Procure por:

Código:
    Call SetPlayerPK(i, Buffer.ReadLong)

E abaixo adicione:

Código:
    Call SetPlayerResets(i, Buffer.ReadLong)

Procure por:

Código:
Sub SetPlayerPK(ByVal Index As Long, ByVal PK As Long)
    ' If debug mode, handle error then exit out
    If Options.Debug = 1 Then On Error GoTo errorhandler


    If Index > MAX_PLAYERS Then Exit Sub
    Player(Index).PK = PK
   
    ' Error handler
    Exit Sub
errorhandler:
    HandleError "SetPlayerPK", "modDatabase", Err.Number, Err.Description, Err.Source, Err.HelpContext
    Err.Clear
    Exit Sub
End Sub

E abaixo adicione:

Código:
Function GetPlayerResets(ByVal Index As Long) As Long
    ' If debug mode, handle error then exit out
    If Options.Debug = 1 Then On Error GoTo errorhandler


    If Index > MAX_PLAYERS Then Exit Function
    GetPlayerResets = Player(Index).Resets
   
    ' Error handler
    Exit Function
errorhandler:
    HandleError "GetPlayerResets", "modDatabase", Err.Number, Err.Description, Err.Source, Err.HelpContext
    Err.Clear
    Exit Function
End Function

Sub SetPlayerResets(ByVal Index As Long, ByVal Resets As Long)
    ' If debug mode, handle error then exit out
    If Options.Debug = 1 Then On Error GoTo errorhandler


    If Index > MAX_PLAYERS Then Exit Sub
    Player(Index).Resets = Resets
   
    ' Error handler
    Exit Sub
errorhandler:
    HandleError "SetPlayerResets", "modDatabase", Err.Number, Err.Description, Err.Source, Err.HelpContext
    Err.Clear
    Exit Sub
End Sub

Serve~Side

No final da Type PlayerRec antes do End Type adicione:

Código:
    Resets As Long

Procure por:

Código:
    Buffer.WriteLong GetPlayerPK(index)

E abaixo adicione:

Código:
    Buffer.WriteLong GetPlayerResets(index)

No final da Sub CheckPlayerLevelUp, antes do End Sub, adicione:

Código:
    If GetPlayerLevel(index) = 1000 Then ' Mude o 1000 para o level nessessario para resetar
        Call PlayerMsg(index, "Parabens " & GetPlayerName(index) & "você acaba  de resetar", 15)
        Call SendAnimation(1, GetPlayerMap(index), GetPlayerX(index), GetPlayerY(index)) ' Mude o número 1 para o número da animção que aparecera ao resetar
        Call SetPlayerLevel(index, 1) 'Volta para o level 1
        Call SetPlayerExp(index, 1) ' Traz a experiencia do player para 1
        Call setplayerResets(index, GetPlayerResets(index) + 1)
        Call SendPlayerData(index)  ' Salva o player
        Call SendEXP(index)  ' Salva a experiencia do player
    End If

Procure por:

Código:
Sub SetPlayerPK(ByVal index As Long, ByVal PK As Long)
    Player(index).PK = PK
End Sub

E abaixo adicione:

Código:
Function GetPlayerResets(ByVal index As Long) As Long
    If index > MAX_PLAYERS Then Exit Function
    GetPlayerResets = Player(index).Resets
End Function


Sub SetPlayerResets(ByVal index As Long, ByVal Resets As Long)
    Player(index).Resets = Resets
End Sub

Créditos:

Ricardo
Ir para o topo Ir para baixo
Convidado
Convidado
Anonymous



Sistema de Resets Empty
MensagemAssunto: Re: Sistema de Resets   Sistema de Resets EmptyQua 30 Nov 2011, 20:26

Muito Bom Ricardo!, alem de eu nao entender nada disso '-', mais tipo eu axo q esse sistema de reset ja tem postado, ainda deve ter muitos, tipo tem de resets automatico e um monte eu axo :$, seila

por min vc merece meu Cred ! Razz
Ir para o topo Ir para baixo
Convidado
Convidado
Anonymous



Sistema de Resets Empty
MensagemAssunto: Re: Sistema de Resets   Sistema de Resets EmptyQua 30 Nov 2011, 20:46

Sim, mas esse é diferente, ele conta os resets do player na conta Very Happy
Ir para o topo Ir para baixo
Conteúdo patrocinado





Sistema de Resets Empty
MensagemAssunto: Re: Sistema de Resets   Sistema de Resets Empty

Ir para o topo Ir para baixo
 
Sistema de Resets
Ir para o topo 
Página 1 de 1
 Tópicos semelhantes
-
» Sistema Resets (Source)
» [AJUDA]Presiso de um Sistema de Ranking De Resets Tipoh que Atualize cada Segundo..
» [EO]Sistema de Pet
» [ALL]Sistema VIP
» Leve, Resets, Forç, Def na formmirage

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