lottery?

03/21/2013 01:14 |xabi|#1
what the hell that had happend to 1314 i compare the old packet and the newest one and notice that no thing changed
03/21/2013 01:17 shadowman123#2
you are wrong dude .. Its Length Had Changed instead of 24 it became 20 and ItemID offset had changed too
03/21/2013 01:56 |xabi|#3
Quote:
Originally Posted by shadowman123 View Post
you are wrong dude .. Its Length Had Changed instead of 24 it became 20 and ItemID offset had changed too
ohh i notice Length but i didn't notice itemid
i think the ItemID offest is 12 and still not working.
03/21/2013 05:06 EgyptianMano#4
still works very fine with me here is my structure
byte(type,4)
byte(Gem1,7)
byte(Gem2,8)
byte(plus,9)
byte(color,10)
byte(Jades,11)
uint(ItemId,12)
03/21/2013 10:59 shadowman123#5
sure it will work fine cuz u have updated it
03/21/2013 13:29 EgyptianMano#6
Quote:
Originally Posted by shadowman123 View Post
sure it will work fine cuz u have updated it
i ddnt , this is my 5660 structure or so, can't really remember
03/21/2013 14:04 Haary*Potter#7
Quote:
Originally Posted by EgyptianMano View Post
still works very fine with me here is my structure
byte(type,4)
byte(Gem1,7)
byte(Gem2,8)
byte(plus,9)
byte(color,10)
byte(Jades,11)
uint(ItemId,12)

when i use this structure client disconnect

its wrong :(
03/21/2013 14:30 EgyptianMano#8
i don't think so, notice that i just put the info he needs ,u still need to put the packet length and type at the top of the packet and then seal it with TQServer

the packet length is 20 and the type is 1314
03/21/2013 23:52 MrCaSpR#9
Quote:
Originally Posted by EgyptianMano View Post
still works very fine with me here is my structure
byte(type,4)
byte(Gem1,7)
byte(Gem2,8)
byte(plus,9)
byte(color,10)
byte(Jades,11)
uint(ItemId,12)
nice EgyptianMano but when i use it nothing changed lottery screen is not appear
03/22/2013 00:05 shadowman123#10
Quote:
Originally Posted by EgyptianMano View Post
i don't think so, notice that i just put the info he needs ,u still need to put the packet length and type at the top of the packet and then seal it with TQServer

the packet length is 20 and the type is 1314
dude u r Wrong .. b4 patch 5700 the the length was 24 after 5700 its 20 u know what will happen when u send wrong packet length to client ? guess what .. Yea the client disconnect and at offset 16 there were the ItemId of won item after 5700 it had changed to 12 so ?

Quote:
Originally Posted by MrCaSpR View Post
nice EgyptianMano but when i use it nothing changed lottery screen is not appear
sure nothing will appear cuz u havent sent the Packet type and length
03/22/2013 00:12 |xabi|#11
Quote:
Originally Posted by shadowman123 View Post
sure nothing will appear cuz u havent sent the Packet type and length
Packet Type 1314.
Length 20.
updated and still nothing appears
03/22/2013 00:15 abdoumatrix#12
Quote:
Originally Posted by shadowman123 View Post
dude u r Wrong .. b4 patch 5700 the the length was 24 after 5700 its 20 u know what will happen when u send wrong packet length to client ? guess what .. Yea the client disconnect and at offset 16 there were the ItemId of won item after 5700 it had changed to 12 so ?



sure nothing will appear cuz u havent sent the Packet type and length
already done and same issue

03/22/2013 00:23 |xabi|#13
Quote:
Originally Posted by abdoumatrix View Post
already done and same issure

PHP Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;

namespace 
Conquer_Online_Server.Network.GamePackets
{
    class 
LotterySystem WriterInterfaces.IPacket
    
{
        public const 
ushort Accept 0AddJade 1, Continue = 2;

        
byte[] Buffer;       
        public 
LotterySystem(bool Create)
        {
            if (
Create)
            {
                
Buffer = new byte[32];
                
WriteUInt16(200Buffer);
                
WriteUInt16(13142Buffer);
                
WriteByte(34Buffer);
                
WriteByte(310Buffer);
                
WriteByte(25Buffer);
                
WriteByte(26Buffer);
             
            }
        }

        public 
byte Type
        
{
            
get { return Buffer[4]; }
            
set Buffer[4] = value; }
        }
        public 
byte SocketGem1
        
{
            
get { return Buffer[7]; }
            
set Buffer[7] = value; }
        }
        public 
byte SocketGem2
        
{
            
get { return Buffer[8]; }
            
set Buffer[8] = value; }
        }
        public 
byte Plus
        
{
            
get { return Buffer[9]; }
            
set Buffer[9] = value; }
        }
        public 
byte ItemColor
        
{
            
get { return Buffer[10]; }
            
set Buffer[10] = value; }
        }
        public 
byte JadesAdded
        
{
            
get { return Buffer[11]; }
            
set Buffer[11] = value; }
        }
        public 
ushort LottoTimes
        
{
            
get { return BitConverter.ToUInt16(Buffer12); }
            
set WriteUInt16(value12Buffer); }
        }
        public 
ushort LottoTimes1
        
{
            
get { return BitConverter.ToUInt16(Buffer13); }
            
set WriteUInt16(value13Buffer); }
        }
        public 
uint ItemID
        
{            
            
get { return BitConverter.ToUInt32(Buffer16); }
            
set WriteUInt32(value16Buffer); }
        }
        public 
void Deserialize(byte[] buffer)
        {
            
Buffer buffer;
        }
        public 
byte[] ToArray()
        {
            return 
Buffer;
        }
        public 
void Send(Client.GameState client)
        {
            
client.Send(Buffer);
        }
    }
    

u just did Length
03/22/2013 00:26 abdoumatrix#14
Quote:
Originally Posted by |xabi| View Post
u just did Length
copy mistake but i do it right
ty anyway
03/22/2013 00:28 |xabi|#15
Quote:
Originally Posted by abdoumatrix View Post
copy mistake but i do it right
ty anyway
what copy mistake mean??
remove lottotimes and change itemid from 16 to 12