wowgetoffyourcellphone Posted January 30, 2017 Report Share Posted January 30, 2017 Hey guy. So, on some maps the AI builds things in bad places, like choke points and pathways. This is a major problem on maps like Acropolis where paths down from the top of the starting area should not be blocked. The AI often will block these paths with buildings, mainly houses. So, I have make obstructor to prevent this. It prevent building construction and placement, but does not block pathfinding. It is only visible in Atlas. Attached is the template file if you wanr to use it for vanilla or your mod. <?xml version="1.0" encoding="utf-8"?> <Entity parent="template_entity_full"> <Footprint> <Square width="38.5" depth="7.0"/> <Height>9.0</Height> </Footprint> <Obstruction> <Active>true</Active> <BlockMovement>false</BlockMovement> <BlockPathfinding>false</BlockPathfinding> <BlockFoundation>true</BlockFoundation> <BlockConstruction>true</BlockConstruction> <DisableBlockMovement>false</DisableBlockMovement> <DisableBlockPathfinding>false</DisableBlockPathfinding> <Static width="37.0" depth="6.0"/> </Obstruction> <Selectable> <Overlay> <Outline> <LineTexture>outline_border.png</LineTexture> <LineTextureMask>outline_border_mask.png</LineTextureMask> <LineThickness>0.4</LineThickness> </Outline> </Overlay> </Selectable> <Visibility> <RetainInFog>true</RetainInFog> <AlwaysVisible>false</AlwaysVisible> <Corpse>false</Corpse> <Preview>false</Preview> </Visibility> <VisualActor> <Actor>structures/hellenes/wall_long.xml</Actor> <SilhouetteDisplay>false</SilhouetteDisplay> <SilhouetteOccluder>false</SilhouetteOccluder> <VisibleInAtlasOnly>true</VisibleInAtlasOnly> </VisualActor> </Entity> A few minor problems: I don't know what DisableBlockMovement and DisableBlockPathfinding mean, lol. Regardless, it seem to work as needed. And, also, the tooltip in-game when preventing the placement of building says something about can't place new building over an existing building. Obviously the player cannot see a building there, so might get frustrated. This is minor, since most human player will not choose to block the path with buildings in most instances. placement_obstructor.xml Quote Link to comment Share on other sites More sharing options...
FeXoR Posted January 30, 2017 Report Share Posted January 30, 2017 IMO this a bug in the AI and thus should be fixed there. It would be nice to be able to paint passability in atlas as terrain textures and elevation. I don't think invisible objects are to be used for that. 2 Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted January 30, 2017 Author Report Share Posted January 30, 2017 I mod the game as it is. 2 Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted January 30, 2017 Author Report Share Posted January 30, 2017 (edited) 8 hours ago, FeXoR said: It would be nice to be able to paint passability in atlas as terrain textures and elevation. A 1 or more paintable "layer" in atlas would be nice for this. But in meantime, my placement obstructor makes up the difference. Edited January 30, 2017 by wowgetoffyourcellphone Quote Link to comment Share on other sites More sharing options...
niektb Posted January 30, 2017 Report Share Posted January 30, 2017 Ah, this seems like something that I need for Silk Road! Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted January 31, 2017 Author Report Share Posted January 31, 2017 9 hours ago, niektb said: Ah, this seems like something that I need for Silk Road! Does the AI build on things it shouldn't? Quote Link to comment Share on other sites More sharing options...
niektb Posted January 31, 2017 Report Share Posted January 31, 2017 The player should be prohibited to block off the trade route Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted January 31, 2017 Author Report Share Posted January 31, 2017 Ah, cool, make sense. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.