agentx Posted June 4, 2014 Report Share Posted June 4, 2014 Changeset 15196 broke a lot of Hannibal, since it uses classes as civ independent feature detector. Now farmsteads are still in class farmstead, but houses are no longer in class house. On the other hand cleaning up 3 different versions of civcentre is probably a good idea.Google couldn't find a single bit of info about VisibleClasses, may I ask what is the thinking? Is there a plan and what is the difference between Classes and VisibleClasses. Why are both needed? 1 Quote Link to comment Share on other sites More sharing options...
sanderd17 Posted June 4, 2014 Report Share Posted June 4, 2014 The plan is to remove that info from the tooltips of the gui. Now every unit has a class list which sometimes matches, sometimes not, and is a pain to localised.I first tried with the buildings, to see if it works. But the units should follow.There's a helper function to extract a single class list from the template in the simulation helpers. But that probably needs to be moved to the global scripts. Quote Link to comment Share on other sites More sharing options...
agentx Posted June 4, 2014 Author Report Share Posted June 4, 2014 Ok, I understand, the helper function provides the classes combined with no duplicates. That's good! The other part of the question targeted which classes contain which entities? It seems some classes are a must have, others are nice to have and others are superfluous.Which entitiy <-> class relation is future proof? Quote Link to comment Share on other sites More sharing options...
sanderd17 Posted June 4, 2014 Report Share Posted June 4, 2014 The classes have no hierarchy, an entity has multiple classes, and a class appears on multiple entities. They're merely tags.Those tags can be used in the code to restrict stuff (I.e. restrict females to attack soldiers), to apply bonuses (I.e. the attack bonuses) or any other use of filtering.So it's nice, when f.e. a technology states it affects military buildings, that you can see in the gui that a building is military. Otoh, some classes are really to broad (like you know what a unit is), and shouldn't be displayed.That's why there is a distinction between visible classes, and classes that are only to aid programmatic filtering, but are really clear to the user without putting it in the gui. 1 Quote Link to comment Share on other sites More sharing options...
agentx Posted June 4, 2014 Author Report Share Posted June 4, 2014 15280 1 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.