Bem vindo visitante.
Caso ainda não tenha uma conta,pedimos para que crie uma,assim você terá acesso a todos os links e imagens disponíveis no fórum.
Bem vindo visitante.
Caso ainda não tenha uma conta,pedimos para que crie uma,assim você terá acesso a todos os links e imagens disponíveis no fórum.

Você não está conectado. Conecte-se ou registre-se

[Correção de Bugs] Mensagens privadas

5 participantes

Ir para baixo  Mensagem [Página 1 de 1]

1[Correção de Bugs] Mensagens privadas Empty [Correção de Bugs] Mensagens privadas Qua Fev 15, 2012 11:48 pm

Terabin

Terabin
Administrador
Administrador

Bom,isso vai normalizar o sistema de mensagens privadas em seu jogo.
Esse é um bug que já veio com a engine...

Em modInput,troque isso:
Código:
' Player message
        If Left$(ChatText, 1) = "!" Then
            Exit Sub
            ChatText = Mid$(ChatText, 2, Len(ChatText) - 1)
            Name = vbNullString

            ' Get the desired player from the user text
            For i = 1 To Len(ChatText)

                If Mid$(ChatText, i, 1) <> Space(1) Then
                    Name = Name & Mid$(ChatText, i, 1)
                Else
                    Exit For
                End If

            Next

            ChatText = Mid$(ChatText, i, Len(ChatText) - 1)

            ' Make sure they are actually sending something
            If Len(ChatText) - i > 0 Then
                MyText = Mid$(ChatText, i + 1, Len(ChatText) - i)
                ' Send the message to the player
                Call PlayerMsg(ChatText, Name)
            Else
                Call AddText("Usage: !playername (message)", AlertColor)
            End If

            MyText = vbNullString
            frmMain.txtMyChat.text = vbNullString
            Exit Sub
        End If

Por isso:
Código:
' Player message
        If Left$(ChatText, 1) = "!" Then
            ChatText = Mid(MyText, 2, Len(MyText) - 1)
            Name = ""
                   
            ' Get the desired player from the user text
            For i = 1 To Len(ChatText)
                If Mid(ChatText, i, 1) <> " " Then
                    Name = Name & Mid(ChatText, i, 1)
                Else
                    Exit For
                End If
            Next i
                   
            ' Make sure they are actually sending something
            If Len(ChatText) - i > 0 Then
                ChatText = Mid(ChatText, i + 1, Len(ChatText) - i)
                   
                ' Send the message to the player
                Call PlayerMsg(ChatText, Name)
            Else
                Call AddText("Usage: !playername msghere", AlertColor)
            End If
            MyText = ""
            frmMain.txtMyChat.text = ""
            Exit Sub
        End If

Agora,no modClientTCP em PlayerMsg,troque isso:
Código:
Buffer.WriteLong CSayMsg

Por isso:
Código:
    Buffer.WriteLong CPlayerMsg

https://pokepokepoke.forumeiros.com

wyvern670

wyvern670
Iniciante
Iniciante

Vlw tera aqui funfo certinho Smile

Kisuke

Kisuke
Organizador
Organizador

Eu nem sabia que dava pra enviar mensagens privadas... nossa...

Sakuray

Sakuray
Colaborador
Colaborador

/\ tenso ein..

sobre o bug, aqui não tinha nenhum, mais eu já troquei por precaução

http://narutoghostonline.blogspot.com

Sakuray

Sakuray
Colaborador
Colaborador

Se bem que está errado isso, se trocar o Buffer.WriteLong CSayMsg por aquilo lá, vai bugar o chat do MAP, ficadik

http://narutoghostonline.blogspot.com

Terabin

Terabin
Administrador
Administrador

Na verdade o sistema não esta implantado,isso fará com que ele seja usado.

E não,não vai bugar o chat do mapa...

https://pokepokepoke.forumeiros.com

Speakgp

Speakgp
Iniciante
Iniciante

Obrigado =D !

Conteúdo patrocinado



Ir para o topo  Mensagem [Página 1 de 1]

Permissões neste sub-fórum
Não podes responder a tópicos