Getting a very old client to run

12/05/2011 17:26 Stratti#61
He pax, I think your character list packet is a lil bit wrong.

I think it should be parsed like that:

Code:
[BYTE]		2
[BYTE]		1

[BOOL]		Char slot 1 in use
IF char slot 1 in use
{
	[INT]		ObjectID
	[SHORT]		Length of char name
	[STRING]	Char name
	[BYTE]		Char scale
	[BYTE]		Char level
	[LONG]		ExpOffset
	[SHORT]		Str points
	[SHORT]		Int points
	[SHORT]		Stat points
	[INT]		CurHP
	[INT]		CurMP
	[BYTE]		Num of visible items
	FOREACH visible item
	{
		[INT]		ItemID
	}
}

[BOOL]		Char slot 2 in use
IF char slot 2 in use
{
	...
}

[BOOL]		Char slot 3 in use
IF char slot 3 in use
{
	...
}
[Only registered and activated users can see links. Click Here To Register...]
12/05/2011 17:40 zeteris#62
Quote:
Originally Posted by Stratti View Post
He pax, I think your character list packet is a lil bit wrong.

I think it should be parsed like that:
...
That's right :) It's correctly parsed packet :)
02/06/2012 06:05 Schickl#63
I'll give this thread a BUMP after a long long time
Since zeteris didn't share his packets I had to parse everything myself
And because it was my first try and I had ABSOLUTELY no experience with that old clients it took me quite long(just started with it again, today, because I learned some asm)
Because I had to parse the packet myself I had to, ofc parse it completely, and well that's what I did.
There are only two parts left(One is a part of the quests, and the other one is something at the end)

Once I know the structure of the whole packet, I'll release it
Note: I only know how it's parsed not for what the data is used!!
But that's quite easy to find out, if needed

Here goes a Screenshot:
[Only registered and activated users can see links. Click Here To Register...]
I still spawn at some unknown area and didn't parse the packet with all the char info(hp/mp etc) yet, but this will be done rather fast

This packet was pretty hard tbh

Oh and once my Server is somewhat useable(npc/etc working) I'll release the source code

----------------------------

Another update^_^
Finding out what x/y sectors I need to use, took longer than i thought
a/w
I got it working and understand how it works

realXPos = (xSector - 46)*192 + XOffset/10
realYPos = ((int)ySector/2 - 23)*384 + YOffset/10

BUT

You don't send the ySector to the client!!!
You send (ySector/2) as BYTE, which means that won't be able to get to all odd ySectors(everything after the comma is cut off!)!
How to solve this?
You can't "solve" it
Your yOffset now is valid from 0 to 3840(the xOffset just like it has always been from 0 to 1920)
Example: How to get to ySector 45:44
Let's calculate x first:
x = (45 - 46) * 192 + 0/10 = -192

Now let's try y:
y = (44/2 - 23) * 384 + 0/10
y = (22 - 23) * -384
y = -384

Please not that you can't get to 45:45 directly!! If you want/need to you will have to add 1920 to yOffset, which will put you in the lower left corner of 45:45

That's it i guess

Screenshot(just because i can):
[Only registered and activated users can see links. Click Here To Register...]

------------------------
Once more an update(wonder how many posts epvp stacks onto the previous one lol)
I got movement working
Not that it was that hard(but it wasn't easy either!), but it made "exploring" things easier^^
Not too bad for 2 days work
Some Screenshots:
[Only registered and activated users can see links. Click Here To Register...]
[Only registered and activated users can see links. Click Here To Register...]
Pretty cool if you can run from ht to dw without teleporting^^
02/07/2012 20:16 Schickl#64
----------------------

Aaaaaand one more update...
[Only registered and activated users can see links. Click Here To Register...]
Spawning mobs works now
ONLY mobs though and I'm still missing some small parts in the packet

Edit: NPCs are working w/o errors too(some hours already^^; just didn't post here)
oh and Autospawn is in progress
I want this server to be as realistic as possible^_^

--------------------

Day 4: I can now spawn Other players. There are only a few Bytes left in the single spawn packet I need to find out what they are used for
[Only registered and activated users can see links. Click Here To Register...]
This was easier than I thought
02/08/2012 19:36 [H2K] ^ LordyK#65
Quote:
Originally Posted by Schickl View Post
----------------------

Aaaaaand one more update...
[Only registered and activated users can see links. Click Here To Register...]
Spawning mobs works now
ONLY mobs though and I'm still missing some small parts in the packet

Edit: NPCs are working w/o errors too(some hours already^^; just didn't post here)
oh and Autospawn is in progress
I want this server to be as realistic as possible^_^

--------------------

Day 4: I can now spawn Other players. There are only a few Bytes left in the single spawn packet I need to find out what they are used for
[Only registered and activated users can see links. Click Here To Register...]
This was easier than I thought
if you fit with swsro files it can be more than awesome and ofcourse I will buy from you for good price because you put effort in this

-and for zeteris , he is only a greedy person like half of community
02/08/2012 20:17 Schickl#66
Quote:
Originally Posted by [H2K] ^ LordyK View Post
if you fit with swsro files it can be more than awesome and ofcourse I will buy from you for good price because you put effort in this

-and for zeteris , he is only a greedy person like half of community
I won't sell them
it will be open source
And i don't have any server files I can play with
I use olly to parse the packets and examples of up2date sro versions to reconstruct them
I have no packets from old sro versions and had to learn assembler in order to do this now. That's why it took me so long to get started^^(and well I have other things to do as well)

I'll release the first beta version when Autospawn is working(and buying/selling and such basic things)

Oh and I make a documentation of every packet I parse. These will be released as well
02/08/2012 20:31 R0bbY LoLz#67
great news :D good luck
02/08/2012 20:35 ÑõÑ_Ŝŧóp#68
Quote:
Originally Posted by Schickl View Post
I won't sell them
it will be open source
And i don't have any server files I can play with
I use olly to parse the packets and examples of up2date sro versions to reconstruct them
I have no packets from old sro versions and had to learn assembler in order to do this now. That's why it took me so long to get started^^(and well I have other things to do as well)

I'll release the first beta version when Autospawn is working(and buying/selling and such basic things)

Oh and I make a documentation of every packet I parse. These will be released as well
language? don't tell me c++ :|
02/08/2012 21:07 Schickl#69
Quote:
Originally Posted by ÑõÑ_Ŝŧóp View Post
language? don't tell me c++ :|
well
Sorry to disappoint you, but it is written in C++ xD
I don't use the C++ libraries though(Only chose C++, because I can create classes, else I'd have used C)
Why?
02/08/2012 22:13 ÑõÑ_Ŝŧóp#70
Quote:
Originally Posted by Schickl View Post
well
Sorry to disappoint you, but it is written in C++ xD
I don't use the C++ libraries though(Only chose C++, because I can create classes, else I'd have used C)
Why?
because I hate c++?:D
02/09/2012 01:48 Schickl#71
Quote:
Originally Posted by ÑõÑ_Ŝŧóp View Post
because I hate c++?:D
Well it's not that hard to learn^^
And if you know C#/PHP you should also know C++.
Not that much of a difference imo
02/09/2012 13:46 evolution007#72
Quote:
Originally Posted by Schickl View Post
well
Sorry to disappoint you, but it is written in C++ xD
I don't use the C++ libraries though(Only chose C++, because I can create classes, else I'd have used C)
Why?
yey c++! cant wait for first version. GL with your project
02/09/2012 21:34 Schickl#73
Quote:
Originally Posted by evolution007 View Post
yey c++! cant wait for first version. GL with your project
Thanks^_^

I'm working hard on Autospawn now
Some might wonder why I start with this "that early"
Well. They way I do it, multiplayer will require my autospawn system
And I want that to be working very well!
That's why I start that early. It gives me enough time to improve it as the project goes on
Small things can be done all the time, but handling spawns server-wide requires it's time.

It's a bit more complex than some of you may think
I'm pretty sure that my server will use 100MB in idle
But after that the growth per logged in player won't be high(this is just what i think^^; only time will tell though)
02/09/2012 21:52 vorosmihaly#74
Quote:
Originally Posted by Schickl View Post
Thanks^_^

I'm working hard on Autospawn now
Some might wonder why I start with this "that early"
Well. They way I do it, multiplayer will require my autospawn system
And I want that to be working very well!
That's why I start that early. It gives me enough time to improve it as the project goes on
Small things can be done all the time, but handling spawns server-wide requires it's time.

It's a bit more complex than some of you may think
I'm pretty sure that my server will use 100MB in idle
But after that the growth per logged in player won't be high(this is just what i think^^; only time will tell though)
btw..if you've got the spawn packets already,then autospawn shouldn't take too long..it's prolly one of the easiest things to do..
02/09/2012 21:58 Schickl#75
Quote:
Originally Posted by vorosmihaly View Post
btw..if you've got the spawn packets already,then autospawn shouldn't take too long..it's prolly one of the easiest things to do..
It's definitely not the way i do it xD
All mobs/npcs will be created on startup
And Mobs will walk too!(All the time, even if no player is in range; still not sure how I'll do it)
And only objects in range of the player will be spawned and if he get's out of range they will be despawned