Jump to content

Dock Placement


Recommended Posts

Yep that was discussed in the Build Limits / Restrictions topic. We've discussed this further on IRC and the guys are now working on a placement restriction similar to what you describe. Some maps, like Belgian bog, do not often have a coastline on which the building can sit (it's a marsh/bog thing), so this needs to be worked out. Also some docks are much larger than others (see super_dock on svn), so this makes placement even trickier.

See here for some further discussion.

Link to comment
Share on other sites

Dock placement seems a bit picky. It seems that it only allows a little part of the dock to extend into the water. How about as long as the dock is touching land it can be placed?

Yeah I've already got a fix for this (hopefully). Basically it was only including 3 tiles on either side of the land/water boundary, but now I'm making it so that all the water and the first 2 tiles of land are counted. This should make the dock placement a bit looser and also allow bigger foundations.

Also, it seems now that buildings can't be placed in water, even if that water is 1 millimeter deep and invisible to the player.

Yeah this is a tricky problem, I noticed some maps like Siwa Oasis have this (near player 1 starting area). There is a difference between what the renderer detects as being "underwater" and what a simple test like GroundHeight < WaterHeight reveals. But due to the terrain sloping, it could be that 1mm actually turns into a lake or river. Maybe it's enough to add some tolerance to the calculation, I'll test and find out.

Link to comment
Share on other sites

Also, builders have to reach the dock, so the back of the dock (the part that faces land) can have at most a depth of 2m, but the front must be able to spawn ships, so it must have a depth of at least 1m (see simulation/data/pathfinder.xml for these definitions). Probably rather than hard-coding these values, they should be tied to the unit passability classes.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...