[Question]ConquerOnlineEnumalator

09/20/2010 15:16 { Angelius }#1
ok im trying to edit the source an give it a sided database just like the oldcodb in the newestcoserver and keep the log in system working on the mysql database storing the password & the username and the other info for players with out the need to use the users folder in side the oldcodb and this way the client is gonna be connected to the oldcodb and the log in and register system is gonna be on the mysql database . and i made it but i have a problem with it which is once the server is done loading the maps and stuff and the char is loged in using the mysql database user and password the game is gonna be empty no npc's no mobs nothing but the char knowing that its all loaded just like the following pic's And plz correct me if im wrong
P.1
[Only registered and activated users can see links. Click Here To Register...]
P.2
[Only registered and activated users can see links. Click Here To Register...]

im missing something here but i cant get to know what it is so i need some help guys and let me know if that was possible :D
09/20/2010 19:23 pro4never#2
enums work like the following...

public enum Map : ushort
{
TwinCity = 1002,
MapName = X,
etc
}

Then to recall do


(ushort)Map to pull the number from the name.
09/20/2010 19:43 { Angelius }#3
the mob spawn Arrangement thats what i need to know i ment to make the source spawn the monster the same way the newestcoserver dose but it dosent accept the same Arrangement thought or maybe spawning the mobs throw a.txt file using this source fails and its not gonna work
09/20/2010 22:29 pro4never#4
Ummm You're talking about impulse's 5165 source? it does not have monsters coded.

First step is to ensure you have a spawn monster packet coded (it doesn't by default)

Then load spawns from either sql or text file

Make a data structure to hold monster spawns (dict + struct is prob best bet)

Spawn the monsters using your spawn packet (you will need a mob struct obviously

Now use your monster thread to control movement/attacking of monsters.


Eg: it's not something someone's going to be able or willing to just hand over. It takes quite a bit of work to get a full mob system working properly and efficiently.
09/20/2010 22:47 { Angelius }#5
i did like %90 of what you just told me to do but way to go just now i know that its gonna take some time an i have to start doing it all over again and its driving me crazy it says that i got a 7232 mobspawn an it seems to be all fine but when i enter the game its damn empty
09/21/2010 00:00 pro4never#6
Cause you aren't sending the spawned monsters to the client when they are on screen.

Eg: in your spawn all code you need to check map monsters, check if they are in range and not already spawned and then send the monster spawn packet to the client in order to actually see them (this assumes everything else is already done).