About Global Color after use get Confirm

02/03/2021 18:18 GameRPoP#16
Quote:
Originally Posted by LegendarySouL View Post
not more information
Code:
            else if (type == 6) // Colorful Global Chatting
            {
                Packet packet = new Packet(0xB034);
                packet.WriteUInt8((byte)105);
                packet.WriteUInt32(color);
                packet.WriteAscii(message);
                m_LocalSecurity.Send(packet);
                Send(false);
            }
_________________________________________
Doesn't help people, just wants help, meaning nothing
Since you are using my code (from SROLib), already you can't give more information anyway.
02/03/2021 19:20 Laag#82#17
Quote:
Originally Posted by GameRPoP View Post
Since you are using my code (from SROLib), already you can't give more information anyway.
You really see this as difficult

PHP Code:
[-> C][3026]
06                                                ................
06 00                                             ................
54 65 73 74 31 37                                 Test17..........
0B 00                                             ................
30 30 30 30 30 30 30 30 30 30 30                  00000000000..... 
Quote:
Originally Posted by Exner. View Post
But I want to understand something about how if use a packet or use item ID to send this packet
I will give you more info about it.

You can check packet:0x704C

Code:
[C -> S][704C]
22                                                "...............
EC 29                                             .)..............
04 00                                             ................
54 65 73 74                                       Test............
Code:
Int RefItemID = 0;
Code:
UInt16 e = packet.ReadUInt8(); //byte slot
UInt16 i = packet.ReadUInt16(); //short itemtype

if(i == 0x29EC || i == 0x29ED)
{
      [Charname]+[e] -> You can get it from here [RefItemID]
}
with packet 0x3026 you can change colors


Code:
if (packet.Opcode == 0x3026)
{
      byte type = packet.ReadUInt8();
      if (type == 6) //Chat Global
      {
            string sender = packet.ReadAscii();
            string content = packet.ReadAscii();

            //RefItemID sender content 
            MainForm.WriteConsole(RefItemID + " # " + sender + ":" + content);
            //Or
            Console.WriteLine(RefItemID + " # " + sender + ":" + content);
      }
}
how can send packet from server to client

Example:

Code:
SendPM("T1T1", "Hello to everyone");
Code:
public void SendPM(string SenderName, string Msg)
{
      Packet packet = new Packet(0x3026);
      packet.WriteUInt8(2);
      packet.WriteAscii(SenderName);
      packet.WriteAscii(Msg);
      C_Security.Send(packet);
      Send(false);
}
Good Luck