Quote:
Originally Posted by _tao4229_
It's not a radius, considering its not a circle.
dist = max(abs(x2 - x),abs(y2-y))
Maximum distance is anywhere from 16-32, even TQ gives you retarded distanced entities half the time.
|
Ooh... for some reason I had in my mind that TQ used more circular versions of range to spawn things. Now that I think of it, no clue why I would possibly think that :S
I'll re-write my quad testing later. Right now writing a simple program to run through my dmaps and pull the map id and max x/y so I can setup the quads for the different map (thinking I'll just use a mapobjects dictionary to store map id and the associated quad).
Hard to test much w/ these w/o a graphic representation but it's letting me add/remove objects and it's subdividing under certain circumstances so seems to be working xD
<edit>
Dumb question here... Is not the spawning based on an ACTUAL rectangle then? (wider than it is tall). I remember the spawn ranges confusing a bunch of people including korv but if I set up a rectangle using like height 16 width 24 will that not cover things properly? And yes... not sure wtf was causing me to think circles. I think it was the ease of calculating circular intersections that made me go that route.
<edit x2>
Got bored today and had some spare time so I added some super basic stuff.
Ground items working. Wrote base systems for inheritance for objects. Basicly I have a dictionary holding mapid and a map struct. map stuct holds a list of all map objects and other factors (eg: weather, dimensions, and anything else I want (skill use permissions, pk permissions, etc)
Also threw in weather. I think I already posted that I have item info packet working but w/e. All in 1 screen
[Only registered and activated users can see links. Click Here To Register...]
Not huge progress... mostly was screwing around with base stuff cause bit hungover and have some time before work. Good relaxing mini coding that won't get me too stressed or anything lol