Palaxin Posted November 23, 2015 Report Share Posted November 23, 2015 (edited) Some suggestions, copied from http://trac.wildfiregames.com/ticket/3634I would be glad to get some opinions, perhaps some of the described features may have been already discussed somewhere somewhen. Feel free to close the trac ticket, if it's annoying you.Note that I'm not able to implement the "Advanced" and "Fancy" suggestions nor can I say how easy it would be to do so.The "Simple" ones should be doable for quite some people, not sure if I would succeed.OverviewIt would be nice if the line of sight depended on the surrouding terrain, buildings and other big obstacles. Also the field of view could get a more realistic shape.This would provide a more strategic role for line of sight, I can think of situations likescouting an enemy army without being seensneaking from behind to an enemymore realistic guerilla warfare between (blocks of) buildingsTerrainSimple: adjust LoS like archer's rangeAdvanced: units cannot see behind hills/mountains, on top of a plateau (when standing on a lower place) or at the bottom of deep gorges (if not standing at the cliff's edge)ObjectsSimple: units get an LoS Bonus when garrisoned on a wall (also tower, fortress or ship if implemented)Advanced: Buildings and gaia elements like rocks with their height above the unit's eyes (human ~1.5m, mounted units ~2.5m, units on elephants ~4m, units on ships, buildings and siege towers perhaps even more) block the vision behind them.Fancy: even if the obstacle's height is below the eyes' height there should be invisible area behind it like shadow is not "visible" for the sun; also smaller objects like trees or large animals could partially block vision (I don't know if this would demand too much resources for a large amount of units and therefore lead to game lags)Field of ViewHumans have a field of view of about 180° with decreasing vision quality at the edges. Animals have various angles and therefore a field of view in the shape of circular sectors. Actually I think it is debatable if animals should have an LoS since they can't communicate and therefore can't provide information - perhaps they could show some passive reaction if they detect something interesting instead?Simple: LoS offset towards the current viewing directionAdvanced: semicircle LoS for humans and other circular sectors for animals (if they have LoS)Fancy: modified "semicircle" LoS with less vision range at the edges e.g. vision range is described by something like r(θ)=sin(θ)*R for 0<=θ<=π where R=r(θ=π/2)=r(θ=90°) is the vision range straight forward. For animals the sine function would have to be stretched to match the specific maximum angle. Edited November 23, 2015 by Palaxin Quote Link to comment Share on other sites More sharing options...
wraitii Posted November 23, 2015 Report Share Posted November 23, 2015 OverviewIt would be nice if the line of sight depended on the surrouding terrain, buildings and other big obstacles. Also the field of view could get a more realistic shape.This would provide a more strategic role for line of sight, I can think of situations likescouting an enemy army without being seensneaking from behind to an enemymore realistic guerilla warfare between (blocks of) buildingsWhile I agree this would be an interesting feature to have to an extent, it has the problem of being tremendously slow. This is partly because our LOS code isn't the most elegant, but also because LOS in an RTS is something that is very complicated.I would like walls, mostly, to stop LOS (and arrows), but even that is very complicated. There is a reason if Age of Empires never did it.TerrainSimple: adjust LoS like archer's rangeAdvanced: units cannot see behind hills/mountains, on top of a plateau (when standing on a lower place) or at the bottom of deep gorges (if not standing at the cliff's edge)See above for "Advanced". Your "Simple" advantage might be possible, but it will be slow and difficult.ObjectsSimple: units get an LoS Bonus when garrisoned on a wall (also tower, fortress or ship if implemented)Advanced: Buildings and gaia elements like rocks with their height above the unit's eyes (human ~1.5m, mounted units ~2.5m, units on elephants ~4m, units on ships, buildings and siege towers perhaps even more) block the vision behind them.Fancy: even if the obstacle's height is below the eyes' height there should be invisible area behind it like shadow is not "visible" for the sun; also smaller objects like trees or large animals could partially block vision (I don't know if this would demand too much resources for a large amount of units and therefore lead to game lags)Field of ViewI don't believe Field of View can work in the context of 0 A.D. Units can turn instantly, and there really isn't a point to it. We're not Company of Heroes.Basically all of this would lead to a ton of lag, sadly. Perhaps in the future when computers have gotten faster. 1 Quote Link to comment Share on other sites More sharing options...
Palaxin Posted November 23, 2015 Author Report Share Posted November 23, 2015 Ok, thank you for the explanations. Lag is nothing you wish whatever you get for it :/I've expected that not all ideas would actually work well, but I didn't know that it's such a great performance issue. Interesting to know... So all in all you would get a little improvement in gameplay but be heavily punished by performance.I thought the one big problem is always pathfinding (I once read it took 70% of the AoK resources) and LoS would be not that difficult to deal with at least using a dedicated GPU (which I do not have by the way )Perhaps one day I will play around with the "simple" things, if I feel confident enough I need to understand the code much more at the moment.At least units hiding in the forest/trees/bushes is something mensioned in the design document, and is more easy to implement, I think. Quote Link to comment Share on other sites More sharing options...
Stan` Posted November 23, 2015 Report Share Posted November 23, 2015 This is for next alpha hopefully, code is here see #3177 Quote Link to comment Share on other sites More sharing options...
Palaxin Posted November 24, 2015 Author Report Share Posted November 24, 2015 Oh yes, would be very nice 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.