Thread: grids
View Single Post
  #6  
Old 02-27-2004, 02:20 PM
smogo
Discordant
 
Join Date: Jan 2004
Location: 47
Posts: 339
Default

k, don't blame me, i'm just playing the bad guy here

Quote:
with zone, we will be able to start grids ids at 1 for each zone ( i don't know if it's better or not than autoincrements )
if the int16 is annoying you, then it's much better to make it an int32 (i.e. an int, in normal programming language :lol. Adding zone to waypoint is does not add to fucntionnality, and you'd have to create 2 indexes (one for zone, one for number) in case perf becomes an issue.

Quote:
with starting_waypoint, we'll then be able to share grids with different monsters and they'll start at different grid waypoints ( no more trains ! =)
atm, very few grids are shared; One effect is cause of the other, but yet :
Code:
mysql> select count(distinct spawngroupID) as nombre, pathgrid from spawn2 group by pathgrid order by nombre desc limit 100;
+--------+----------+
| nombre | pathgrid |
+--------+----------+
|  53265 |        0 |
|      2 |     9073 |
|      2 |     5022 |
|      2 |        1 |
|      2 |        2 |
|      2 |        3 |
|      2 |     5032 |
|      2 |        4 |
|      2 |     5034 |
|      2 |     5170 |
|      2 |     9071 |
|      1 |     1003 |
|      1 |     1019 |
only 10 grids shared, out of 382. A few duplicates would not harm. Well, this DB may not be representative.

reverse_path and starting_waypoint are not usefull if pathgrid is unique to each mob, else anywway starting_waypoint must be close to spawn point, so that's little change if any, and reverse_order is much like the patrol wandering option

Sorry, that was the bad guy part.

On the normal guy part :

- i'd like to know of efficiency on real servers for the normalized (duno if it's the english word, that means table splitted) version of pathgrid. This should be little overhead (grids are loaded boot time, or spawn time, aren't they ?). If devs think this can be interesting, we could work on spawn 2 functions.

- i believe this is a good idea.

- Let's go a bit further : waypoints are 'you can be here' points, and path ordering is 'there is direct way from wp N to wp N+1'. One could define wp a b c d e f and say :
grid #1 is 1:a 2:b 3:e 4:f
grid #2 is 1:d 2:c
and even : grid #3=#1 then #2

- there have been threads about wp design (i came across an old one like Nov 2002 today) dealing with grids. Recently, we discussed the matter of mobs fleeing, still to be done. Maybe changes to the grid system should now start thinking of the map and its usages (wandering, but also fleeing, whatever ...)

imho
- perf can be adressed fairly easily, so build clean.
- there should be no limit to grid number
- there should be no limit to wp in a grid
- the easier for the world builder to define a grid, the better.
Reply With Quote