Base close to the endge of the map and raid spawns

Started by Fafn1r, March 11, 2016, 07:51:58 AM

Previous topic - Next topic

Fafn1r

Hi,

Does the game take into account home area when picking spawn location for normal raids? I'm wondering if I build a base close to the edge of the map, will raiders spawn close to it?

JimmyAgnt007

I dont think so and no.  check my fort here, https://ludeon.com/forums/index.php?topic=17754.0 my base started on the far left and moved right.  i got raids in the little patch on the left just outside my base, got them everywhere else too. 

falcongrey

The only thing I have noticed with regards to where the raids come in proximity to the base is how closed in the 'roof' area of the 'home' area is. Like if you build it into the side of a mountain, then close in entry to that area by building walls that cut off canyon entry which, unless you used 'no roof area' to keep open, closes off most of the roof area of that canyon the story teller won't drop in raids in the immediate canyon area. However, if you keep the roof open with just the walls up the story teller would still drop them raids into the middle of the closed off canyon that leads into your mountain complex and bypassing the outer defenses.

From an orbital / aerial tactical view, this is correct strategy in that the attacking force is attempting to minimize casualties and would have been planned out this attack before hand to do such. Tactically, land as close to the target without tripping alerts as possible to minimize tiring out the troops as well as past as many outer defenses already in place to minimize injury.

Does this always happen? No, there are always miscalculations to landing zones emplacement (had them drop down in front of my sentry guns before / game over raiders) and had them many times on the opposite side of the map.

Granted, the specifics of how Tynan had the game calculate this is a mystery to me, it appears from what I have seen that it is determined on: edge of roof coverage + size of raiding party (larger seem to be further away) + difficulty level + or - randomness to distance + is it a siege party or raiding party (raiding parties are always closer than siege which tend to be edge of launcher weapon distance and set up camp on landing).

Remember, this is my opinion based on observation and not actually looking at the coding.
It matters not if we win or fail. It's that we stood and faced it.

skullywag

If its not a drop (which can be a centre drop, an edge drop or a trade beacon drop) then itll be an edge arrival, if thats the case this fires:

public static bool TryFindRandomPawnEntryCell(out IntVec3 result)
{
return CellFinder.TryFindRandomEdgeCellWith((IntVec3 c) => c.Standable() && !Find.RoofGrid.Roofed(c) && c.CanReachColony() && c.GetRoom().TouchesMapEdge, out result);
}


basically find a random edge cell that is standable, not roofed, has a path to the colony and is in an outside area touching the map edge. :)
Skullywag modded to death.
I'd never met an iterator I liked....until Zhentar saved me.
Why Unity5, WHY do you forsake me?