- Kira
ADMINISTRADOR - Mensagens : 311
Data de inscrição : 14/01/2015
Idade : 25
Re: STAFF CHAT
Qui Set 14, 2017 8:29 pm
player information
- Andriel9
MEMBRO - Mensagens : 239
Data de inscrição : 04/06/2017
Idade : 19
Re: STAFF CHAT
Qui Set 21, 2017 5:39 pm
in my source, i not found the "sendPlayerIdentification" help me?Kira escreveu:player information
Re: STAFF CHAT
Qui Set 21, 2017 11:42 pm
Andriel9 escreveu:in my source, i not found the "sendPlayerIdentification" help me?Kira escreveu:player information
provavelmente seja a "def sendLogin"
Re: STAFF CHAT
Sex Set 22, 2017 2:56 am
Danshweger escreveu:Andriel9 escreveu:in my source, i not found the "sendPlayerIdentification" help me?Kira escreveu:player information
provavelmente seja a "def sendLogin"
http://prntscr.com/go6qrc
- Andriel9
MEMBRO - Mensagens : 239
Data de inscrição : 04/06/2017
Idade : 19
Re: STAFF CHAT
Sex Set 22, 2017 7:27 am
E depois, oque eu faço?Danshweger escreveu:Andriel9 escreveu:in my source, i not found the "sendPlayerIdentification" help me?Kira escreveu:player information
provavelmente seja a "def sendLogin"
- Andriel9
MEMBRO - Mensagens : 239
Data de inscrição : 04/06/2017
Idade : 19
Re: STAFF CHAT
Sex Set 22, 2017 11:25 am
Consegui! fiz umas coisas e deu na versão 1.401, não sei se da em outra, pois meu PC é 32bits e não consigo tirar proteção da swf mais recente...
- Código:
def sendLogin(this):
if this.privLevel in [11, 12]:
this.sendPacket([26, 2], ByteArray().writeInt(this.playerID).writeUTF(this.playerName).writeInt(6000000).writeByte(this.langueID).writeInt(this.playerCode).writeBoolean(True).writeByte(5).writeByte(5).writeBoolean(False).writeByte(10).writeByte(-1).writeByte(-1).writeByte(-1).toByteArray())
if this.privLevel in [6, 7, 8, 9, 10]:
this.sendPacket([26, 2], ByteArray().writeInt(this.playerID).writeUTF(this.playerName).writeInt(6000000).writeByte(this.langueID).writeInt(this.playerCode).writeBoolean(True).writeByte(1).writeByte(5).writeBoolean(False).toByteArray())
if this.privLevel in [1, 2, 3, 4, 5]:
this.sendPacket([26, 2], ByteArray().writeInt(this.playerID).writeUTF(this.playerName).writeInt(6000000).writeByte(this.langueID).writeInt(this.playerCode).writeBoolean(True).writeByte(1).writeByte(0).writeBoolean(False).toByteArray())
if this.isGuest:
this.sendPacket(Identifiers.send.Login_Souris, ByteArray().writeByte(1).writeByte(10).toByteArray())
this.sendPacket(Identifiers.send.Login_Souris, ByteArray().writeByte(2).writeByte(5).toByteArray())
this.sendPacket(Identifiers.send.Login_Souris, ByteArray().writeByte(3).writeByte(15).toByteArray())
this.sendPacket(Identifiers.send.Login_Souris, ByteArray().writeByte(4).writeUnsignedByte(200).toByteArray())
- Andriel9
MEMBRO - Mensagens : 239
Data de inscrição : 04/06/2017
Idade : 19
Re: STAFF CHAT
Sex Set 22, 2017 6:48 pm
Change the privlevels in "def senStaffChat" in souce.pyAdrianOficial escreveu:on my source only #Server work
Re: STAFF CHAT
Sáb Set 23, 2017 3:57 am
Andriel9 escreveu:Change the privlevels in "def senStaffChat" in souce.pyAdrianOficial escreveu:on my source only #Server work
- Código:
def sendStaffChat(this, type, langue, playerName, message, sender):
playerName = sender.playerName if type == -1 else ('' if type == 0 else ('Message Serveur' if type == 1 else sender.langue.upper() + '][' + {11: 'Admin][',
10: 'Admin][',
9: 'Coord][',
8: 'Smod][',
7: 'Mod][',
6: 'MapCrew][',
5: 'Helper][',
4: 'DV][',
3: 'LUA]['}[sender.privLevel]))
if '][' in playerName:
playerName += sender.playerName
for client in (sender.room.clients if type == 0 else this.players).values():
if (type == -1 or type == 0 or type == 1 or (type == 2 or type == 5) and client.privLevel >= 5 or (type == 3 or type == 4) and client.privLevel >= 7 or (type == 6 or type == 7) and client.privLevel >= 6 or type == 8 and client.privLevel >= 3 or type == 9 and client.privLevel >= 4) and (client.langue == langue or type == -1 or type == 1 or type == 4 or type == 5 or type == 6):
client.sendPacket(Identifiers.send.Staff_Chat, ByteArray().writeByte(1 if type == -1 else type).writeUTF(playerName).writeUTF(message).writeShort(0).writeByte(0).toByteArray())
How? ))
Omg is hard
- Weeslleeyone
MEMBRO - Mensagens : 227
Data de inscrição : 14/01/2015
Idade : 28
Localização : Marte
Re: STAFF CHAT
Dom Set 24, 2017 12:52 am
Teoricamente pode até funcionar, mas acho que a estrutura está meio errada em.Andriel9 escreveu:Consegui! fiz umas coisas e deu na versão 1.401, não sei se da em outra, pois meu PC é 32bits e não consigo tirar proteção da swf mais recente...
- Código:
def sendLogin(this):
if this.privLevel in [11, 12]:
this.sendPacket([26, 2], ByteArray().writeInt(this.playerID).writeUTF(this.playerName).writeInt(6000000).writeByte(this.langueID).writeInt(this.playerCode).writeBoolean(True).writeByte(5).writeByte(5).writeBoolean(False).writeByte(10).writeByte(-1).writeByte(-1).writeByte(-1).toByteArray())
if this.privLevel in [6, 7, 8, 9, 10]:
this.sendPacket([26, 2], ByteArray().writeInt(this.playerID).writeUTF(this.playerName).writeInt(6000000).writeByte(this.langueID).writeInt(this.playerCode).writeBoolean(True).writeByte(1).writeByte(5).writeBoolean(False).toByteArray())
if this.privLevel in [1, 2, 3, 4, 5]:
this.sendPacket([26, 2], ByteArray().writeInt(this.playerID).writeUTF(this.playerName).writeInt(6000000).writeByte(this.langueID).writeInt(this.playerCode).writeBoolean(True).writeByte(1).writeByte(0).writeBoolean(False).toByteArray())
if this.isGuest:
this.sendPacket(Identifiers.send.Login_Souris, ByteArray().writeByte(1).writeByte(10).toByteArray())
this.sendPacket(Identifiers.send.Login_Souris, ByteArray().writeByte(2).writeByte(5).toByteArray())
this.sendPacket(Identifiers.send.Login_Souris, ByteArray().writeByte(3).writeByte(15).toByteArray())
this.sendPacket(Identifiers.send.Login_Souris, ByteArray().writeByte(4).writeUnsignedByte(200).toByteArray())
- Código:
playerID (int)
playerName (utf)
playerTime (int)
langueCode (byte)
playerCode (int)
isGuest (boolean)
quantidade de permissões (byte)
número para cada permissão que o usuário tem (byte)
3 - Árbrito
5 - Mod
10 - Admin
11 - Mapcrew
12 - LuaTeam
13 - FunCorp
15 - FashionSquad
luateam ou fashionsquad (boolean)
Na parte das permissões, faria algo tipo, no caso de um admin:
- Código:
perms = [3, 5, 10, 11, 12, 13, 15]
packet.writeByte(len(perms))
for perm in perms:
packet.writeByte(perm)
Assim, ele teria acesso a todos os chats, igual deve ser. Pada cada privLevel a lista de permissões muda.
Permissões neste sub-fórum
Não podes responder a tópicos
|
|