Register for your free account! | Forgot your password?

Go Back   elitepvpers > Popular Games > Silkroad Online > SRO Private Server
You last visited: Today at 19:43

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Help] How i confirm character spawn

Discussion on [Help] How i confirm character spawn within the SRO Private Server forum part of the Silkroad Online category.

Reply
 
Old   #1
 
ramy_11_1's Avatar
 
elite*gold: 0
Join Date: Feb 2013
Posts: 65
Received Thanks: 37
[Help] How i confirm character spawn

i parser opcodes while i use /wp command , its give me these opcodes :

Code:
[C -> S][7010]
10 00                                             ................
EC 63                                             .c..............
01 00 6B 44 40 7C EB 3A FF 3F 6C 44               ..kD@|.:.?lD....
01 00                                             ................

[S -> C][B010]
01                                                ................
10 00                                             ................

[C -> S][34B6]

[S -> C][34B5]
EC 63                                             .c..............

[S -> C][3013]
now my question is how i confirm my spawn after using warp packet.
i already added in agent.cs each these lines :

Code:
                            else if (current.Opcode == 0xB010)
                            {
                                Packet p = new Packet(0x34B6);
                                Send(p);
                            }

                            else if (current.Opcode == 0x34B5)
                            {
                                Packet p = new Packet(0x34B6);
                                Send(p);
                            }
then i create a new button and give it a /wp packet function by parameters of this packet ..

Code:
            Packet warp = new Packet(0x7010);
            warp.WriteUInt8(0x10); //static 
            warp.WriteUInt8(0); //static 
            warp.WriteInt16(25753); //regionID 
            warp.WriteSingle(1539); //x 
            warp.WriteSingle(-8); //Y 
            warp.WriteSingle(1027); //Z 
            warp.WriteInt8(1); //worldid 
            warp.WriteUInt8(0); //static 
            Agent.Send(warp);
Nothing happened just i get instant dc when i press the button when i open character again i find it in the new region..
So how i fix this spawn problem ?
also in /gotown and /movetouser.

i hope to find answer.

thank you epvp
ramy_11_1 is offline  
Old 06/03/2015, 17:38   #2
 
elite*gold: 0
Join Date: May 2013
Posts: 1,447
Received Thanks: 1,046
Code:
                        if (sqlDataReader1.Read())
                        {
                            if (newposx == 0 && newposy == 0 && newposz == 0)
                            {
                            string Name = sqlDataReader1.GetString(0);
                            int region = Int16.Parse(sqlDataReader1["Region"].ToString());
                            string region1 = string.Format("0x{0:x}", region);
                            int posx = Int32.Parse(sqlDataReader1["X"].ToString());
                            string posx1 = string.Format("0x{0:x}", posx);
                            int posy = Int32.Parse(sqlDataReader1["Y"].ToString());
                            string posy1 = string.Format("0x{0:x}", posy);
                            int posz = Int32.Parse(sqlDataReader1["Z"].ToString());
                            string posz1 = string.Format("0x{0:x}", posz);
                            int worldid = Int32.Parse(sqlDataReader1["worldID"].ToString());
                            string worldid1 = string.Format("0x{0:x}", worldid);
                            Int32 region2 = Convert.ToInt32(region1, 16);
                            Int32 posx2 = Convert.ToInt32(posx1, 16);
                            Int32 posy2 = Convert.ToInt32(posy1, 16);
                            Int32 posz2 = Convert.ToInt32(posz1, 16);
                            Int32 worldid2 = Convert.ToInt32(worldid1, 16);
                            Packet packet15 = new Packet(0x7010);
                            packet15.WriteInt8(0x10); //static
                            packet15.WriteInt8(0); //static
                            packet15.WriteInt16(region2); //regionID to hex
                            packet15.WriteInt32(posx2); //x to hex
                            packet15.WriteInt32(posy2); //y to hex
                            packet15.WriteInt32(posz2); //z to hex
                            packet15.WriteInt8(worldid2); //worldid to hex
                            packet15.WriteInt8(0); //static
                            Agent.Send(packet15);
                            Thread.Sleep(1000);
                            Packet confirm1 = new Packet(0x34B6);
                            Agent.Send(confirm1);
                            sqlDataReader1.Close();
                            Globals.MainWindow.Log("\nMoving to location (/wp): " + region + " " + posx + " " + posy + " " + posz + ". Location name: " + Name, new object[0]);
                            }
                            else
                            {
                                Int32 newregion2 = Convert.ToInt32(newregion1, 16);
                                Int32 newposx2 = Convert.ToInt32(newposx1, 16);
                                Int32 newposy2 = Convert.ToInt32(newposy1, 16);
                                Int32 newposz2 = Convert.ToInt32(newposz1, 16);
                                Int32 newworldid2 = Convert.ToInt32(newworldid1, 16);
                                Packet packet15 = new Packet(0x7010);
                                packet15.WriteInt8(0x10); //static
                                packet15.WriteInt8(0); //static
                                packet15.WriteInt16(newregion2); //regionID to hex
                                packet15.WriteInt32(newposx2); //x to hex
                                packet15.WriteInt32(newposy2); //y to hex
                                packet15.WriteInt32(newposz2); //z to hex
                                packet15.WriteInt8(newworldid2); //worldid to hex
                                packet15.WriteInt8(0); //static
                                Agent.Send(packet15);
                                Thread.Sleep(1000);
                                Packet confirm2 = new Packet(0x34B6);
                                Agent.Send(confirm2);
                                Globals.MainWindow.Log("\nMoving to location (/wp): " + newregion + " " + newposx + " " + newposy + " " + newposz + ". Location name: custom", new object[0]);
                            }

reads from SQL table for X Y Z RegID and WorldID
Anonymous-6723 is offline  
Thanks
1 User
Old 06/03/2015, 18:59   #3
 
ramy_11_1's Avatar
 
elite*gold: 0
Join Date: Feb 2013
Posts: 65
Received Thanks: 37
from where i can get these parameters ?
i understood all your codes i get by sql reader Region , X , Y , Z , worldID then i convert them then i send first packet of warp then sleep 1 second then send spawn packet , but you did 2 cases first is : if (newposx == 0 && newposy == 0 && newposz == 0) second is : else
so from where you got newposx , newposy , newposz ?

by the way i tried to send a warp packet without converting values from string to int then sleep 1 second then send a spawn packet , also its not work .. i think it's need to sent when receive a packet from server to client , like login spawn.

#Fixed
#Close
ramy_11_1 is offline  
Reply


Similar Threads Similar Threads
Character spawn location
07/30/2015 - EO PServer Hosting - 18 Replies
Well, I was thinking... Because i know alot of people wouldnt of looked into this, You should all help me with this and we should all Research for the Spawn Locations for when you create an account, to e.g not spawning at water fountin and spawning over by market when u first make an account .... i think this would be good, lets get busy... post what u find here im going to look now ... Note, i have tryd making Cq_users the default location to the Coordinates next to sodar, still nothing lets...
Character spawn with health bar under the name.
01/05/2015 - CO2 Private Server - 7 Replies
Hello, i saw in ConquerPS they spawning characters with health bars under their names i waited 2 days for them to make the server online again so i can sniff the packet but they never came online.. and i tried to spawn it as a "Birdman" or any mob name but when i change the name the health bar goes, anyone knows how they done it ?
How Change New Character spawn map?
06/04/2014 - SRO Private Server - 1 Replies
Change New Character spawn map? Euro and Ch for downhang or other map
Change New Character spawn map
04/13/2013 - Dekaron Private Server - 2 Replies
Hi, I successfully created a server with 11 classes. When I create a character they spawn in braiken. How can I change the default spawn and return location of another map like Ardeca or Loa when someone creates a new character?
[Effect-Flowers]Spawn Character
05/07/2012 - CO2 Private Server - 24 Replies
Hello , we try to finish Flowers system on 5165 and we got it...but we have a small problem ( I think is small ) you can see flower at spawn character but anyone can't see that ! look at photos : http://img255.imageshack.us/img255/8994/bastab.jp g BastA --->girl character ! http://img710.imageshack.us/img710/8159/girlchara cter.jpg girl character !



All times are GMT +1. The time now is 19:43.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.