Register for your free account! | Forgot your password?

You last visited: Today at 17:22

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

Advertisement



[FAQ] HellmouthSource

Discussion on [FAQ] HellmouthSource within the CO2 PServer Guides & Releases forum part of the CO2 Private Server category.

Closed Thread
 
Old 03/20/2011, 13:19   #151
 
elite*gold: 0
Join Date: Apr 2010
Posts: 40
Received Thanks: 0
Quote:
Originally Posted by mohamedkhaled View Post
I already coding NPCS with Python !!! but i don't think that i will have time to code 290 NPCS for hellmouthCO or what ever ^^!
pro how ican coded monster
PePsI_MaN is offline  
Old 03/20/2011, 15:05   #152
 
elite*gold: 0
Join Date: Aug 2008
Posts: 94
Received Thanks: 19
sorry if this is dump . but this is what im thinking atm about mobs .
it would be nice if you helped me guys , specially pro4.. and i would release what i got ( if it works ) :P and i almost finished all NPCs . except reb and reincamate coz i didnt know how to get the prev jobs
well about mobs ...... if (( IF )) i made a mobtoclient.cs . and codded "walk" ,IE ... where should i put that to make mobs follow the code
and also , where to put the code
(Packets.GeneralData(XXXXXX, 0, 0, 0, 135)) for the dead mobs to remove it
hmmmm what else .
Ooh yes, im sure that you guys made the same code of NPCs 80 percent shorter than mine :P .. but it still working good for me .
romeoromeo is offline  
Old 03/20/2011, 16:43   #153
 
BioHazarxPaul's Avatar
 
elite*gold: 0
Join Date: Nov 2005
Posts: 548
Received Thanks: 93
I do not recommend copying and pasting stuff from other sources...
BioHazarxPaul is offline  
Old 03/20/2011, 17:37   #154
 
elite*gold: 0
Join Date: May 2009
Posts: 11
Received Thanks: 0
can somebody post guilddirector dialog plz !
jake12 is offline  
Old 03/20/2011, 17:51   #155
 
elite*gold: 21
Join Date: Jul 2005
Posts: 9,193
Received Thanks: 5,376
Quote:
Originally Posted by romeoromeo View Post
sorry if this is dump . but this is what im thinking atm about mobs .
it would be nice if you helped me guys , specially pro4.. and i would release what i got ( if it works ) :P and i almost finished all NPCs . except reb and reincamate coz i didnt know how to get the prev jobs
well about mobs ...... if (( IF )) i made a mobtoclient.cs . and codded "walk" ,IE ... where should i put that to make mobs follow the code
and also , where to put the code
(Packets.GeneralData(XXXXXX, 0, 0, 0, 135)) for the dead mobs to remove it
hmmmm what else .
Ooh yes, im sure that you guys made the same code of NPCs 80 percent shorter than mine :P .. but it still working good for me .
To be perfectly honest I don't want anyone using this source to have monsters... unless they are capable of coding the system themselves. So saying you'll release what you get (after I do it for you essentially) is just one more reason for me NOT to do it.

-I released this as something for people to build on... they are welcome to do so and post what they worked on

-Does NOT mean I want it to become the new lotf where every single thing is done for you.. that simply encourages people to never learn what they are doing and encourages lazy, bad pservers.

-Seeing as I still am doing pserver stuff it's not like I LOVE the idea of having 50000 other pservers on the same patch as myself using some of the features I designed (such as the way our ctf system works) competing with me. As I said when I released this though, 'it's not like the source is good enough that I can't compete with it' so not exactly worried about that.


People need to learn to program if they want to do a proper pserver. This is simply a kick in the pants to encourage some people to go do it.

Quote:
Originally Posted by jake12 View Post
can somebody post guilddirector dialog plz !
Would be pointless seeing as none of the guild system is coded
pro4never is offline  
Thanks
1 User
Old 03/21/2011, 07:42   #156
 
elite*gold: 0
Join Date: Aug 2008
Posts: 94
Received Thanks: 19
Quote:
Originally Posted by pro4never View Post
To be perfectly honest I don't want anyone using this source to have monsters... unless they are capable of coding the system themselves. So saying you'll release what you get (after I do it for you essentially) is just one more reason for me NOT to do it.

-I released this as something for people to build on... they are welcome to do so and post what they worked on

-Does NOT mean I want it to become the new lotf where every single thing is done for you.. that simply encourages people to never learn what they are doing and encourages lazy, bad pservers.

-Seeing as I still am doing pserver stuff it's not like I LOVE the idea of having 50000 other pservers on the same patch as myself using some of the features I designed (such as the way our ctf system works) competing with me. As I said when I released this though, 'it's not like the source is good enough that I can't compete with it' so not exactly worried about that.


People need to learn to program if they want to do a proper pserver. This is simply a kick in the pants to encourage some people to go do it.



Would be pointless seeing as none of the guild system is coded
.. i did not mean to release a pach or server i just meant to release a code ... i didnt know you dont want that to happen , i thought that you released it for helping and also to cooperate not compete.... anyway .... i wont ask anything no more unless if its about bugs .
romeoromeo is offline  
Old 03/21/2011, 15:30   #157
 
zoro7070's Avatar
 
elite*gold: 0
Join Date: Aug 2008
Posts: 143
Received Thanks: 18
how can i make my account a GM or a PM ?
zoro7070 is offline  
Old 03/21/2011, 15:36   #158
 
elite*gold: 0
Join Date: May 2009
Posts: 11
Received Thanks: 0
just type in database in perm... 5 or 6
jake12 is offline  
Old 03/22/2011, 06:38   #159
 
elite*gold: 0
Join Date: Aug 2008
Posts: 94
Received Thanks: 19
:P i got the mobs move and drop but the problem is . ((((MATH)))) dont know how to make them target me lol , they only stop if im in thier way . any clue ? anything code or math hehehe just how to calc direction
romeoromeo is offline  
Old 03/22/2011, 06:55   #160
 
elite*gold: 21
Join Date: Jul 2005
Posts: 9,193
Received Thanks: 5,376
Hmm lets see. You already have them attacking you if you're in range correct?

Well the simplest way for them to work would be....


-Pull closest player to monster
>>something like cycling through clients on map and return distance something like... math.abs(math.max(Math.Abs(x1 - x2), Math.Abs(y1-y2)));

-Calculate direction to move
>>use same as the walk calculations + From/To coord calculations to determine which direction(s) you need to move.

Once you calculate the direction, update the server coords for the mob and send the walk packet for the monster to all clients on it's screen.

Tada! It now works :P
pro4never is offline  
Thanks
1 User
Old 03/22/2011, 07:21   #161
 
elite*gold: 0
Join Date: Aug 2008
Posts: 94
Received Thanks: 19
Quote:
Originally Posted by pro4never View Post
Hmm lets see. You already have them attacking you if you're in range correct?

Well the simplest way for them to work would be....


-Pull closest player to monster
>>something like cycling through clients on map and return distance something like... math.abs(math.max(Math.Abs(x1 - x2), Math.Abs(y1-y2)));

-Calculate direction to move
>>use same as the walk calculations + From/To coord calculations to determine which direction(s) you need to move.

Once you calculate the direction, update the server coords for the mob and send the walk packet for the monster to all clients on it's screen.

Tada! It now works :P
Thanks alot , i will try that and inform you , i didnt expect you to help , thanks alot ..... and No mobs not attack yet , they just move and stop if im im in rang , . attack is easy to do .
romeoromeo is offline  
Old 03/22/2011, 08:02   #162
 
elite*gold: 21
Join Date: Jul 2005
Posts: 9,193
Received Thanks: 5,376
kk well if you already have a thread that moves them properly you may want to write some basic methods such as...


PullClosestTarget

PullTargetDirection

PullTargetRange

etc. Basically just helpers to determine which action the mob should be taking range < attack range? Attack! else move towards nearest target (target locking can be added but depends how you want mobs to behave).
pro4never is offline  
Old 03/22/2011, 16:32   #163
 
elite*gold: 0
Join Date: May 2009
Posts: 11
Received Thanks: 0
public static void NewSpawnSystem()
{
MySqlCommand cmd = new MySqlCommand(MySqlCommandType.SELECT);
cmd.Select("Spawnit");
uint Count = 0;
MySqlReader r = new MySqlReader(cmd);
while (r.Read())
{
Mob Monster = new Mob();
Monster.X = r.ReadUInt16("X");
Monster.Y = r.ReadUInt16("Y");
Monster.NextX = r.ReadUInt16("X2");
Monster.NextY = r.ReadUInt16("Y2");
Monster.MobLevel = r.ReadByte("Level") ;
Monster.MobHP = r.ReadUInt16("HP");
Monster.UID = r.ReadUInt32("UID");
Monster.Name = r.ReadString("Name");
Monster.Mesh = r.ReadUInt16("Mesh");
Monster.Instance = r.ReadUInt16("Instance");
Monster.Map = r.ReadUInt16("Map");
Dictionary.Maps.ThreadSafeAdd(Monster.Map, new Map(0));
Count++;
}
Console.WriteLine(Program.Title + " Spawning " + Count + " monsters");
} (is this right?)
jake12 is offline  
Old 03/22/2011, 16:58   #164
 
elite*gold: 0
Join Date: May 2009
Posts: 45
Received Thanks: 5
Quote:
Originally Posted by jake12 View Post
public static void NewSpawnSystem()
{
MySqlCommand cmd = new MySqlCommand(MySqlCommandType.SELECT);
cmd.Select("Spawnit");
uint Count = 0;
MySqlReader r = new MySqlReader(cmd);
while (r.Read())
{
Mob Monster = new Mob();
Monster.X = r.ReadUInt16("X");
Monster.Y = r.ReadUInt16("Y");
Monster.NextX = r.ReadUInt16("X2");
Monster.NextY = r.ReadUInt16("Y2");
Monster.MobLevel = r.ReadByte("Level") ;
Monster.MobHP = r.ReadUInt16("HP");
Monster.UID = r.ReadUInt32("UID");
Monster.Name = r.ReadString("Name");
Monster.Mesh = r.ReadUInt16("Mesh");
Monster.Instance = r.ReadUInt16("Instance");
Monster.Map = r.ReadUInt16("Map");
Dictionary.Maps.ThreadSafeAdd(Monster.Map, new Map(0));
Count++;
}
Console.WriteLine(Program.Title + " Spawning " + Count + " monsters");
} (is this right?)
No it won't work!
mohamedkhaled is offline  
Old 03/22/2011, 21:31   #165
 
elite*gold: 0
Join Date: May 2009
Posts: 11
Received Thanks: 0
Quote:
Originally Posted by mohamedkhaled View Post
No it won't work!
why?
jake12 is offline  

Powered by vBulletin®
Copyright ©2000 - 2024, 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 ©2024 elitepvpers All Rights Reserved.