Here:
http://dffd.bay12games.com/file.php?id=13801The goal of this mod is to create an entity that goes through worldgen looking moderately eusocial:
- There is one breeder per site
- That breeder has an impressive number of kids (by worldgen standards)
- Other figures at the site are celibate
then let other, more ambitious modders use it as a base for their meticulously scripted fortress mode fantasies. So you have my permission to steal any number of ideas from my mod for your own, whether you're implementing something eusocial or not, just leave my name in the raws so I can feel warm and fuzzy.
I named them sprites, a diminutive creature, since if I don't mention something you can assume they're the same as dwarves. E.g. workshops, reactions, strange moods, alcoholism, etc.
The entity has four castes:
FEMALE,
MALE,
WORKER, and
BROOD.
MALEs are male, the rest are female.
FEMALEs are the intended breeders,
WORKERs are all homosexual and so do not participate in breeding, but can still form loving relationships so they can enjoy the heartbreak of seeing their lover get eaten by a grue.
BROOD are a part of a kludge to let players control how many breeders they have in fortress mode, more on that later. Their pop ratios are 1:1000:10000:500 female:male:worker:brood.
Step one is achieved by requiring landholders (and the monarch, who is included in most comments on landholders) to be breeders. When a breeder is not available as an historical figure to fill the landholder position, worldgen procures one from the abstract population without checking pop ratios. So if a civ has 8 landholding sites but a total population of only 300 or so, nevertheless there will be 9 breeders: the monarch and landholders.
I made 10% of the population male because I really, really wanted ants instead of termites, so the original plan was to label the males as soldiers and pretend they're females who identify as male because the language has two genders and the species has two castes to distinguish. 10% seemed a decent number of soldiers, especially since the workers are enough like dwarves to
be the military without any loss of function. But it turns out that breeders can be 20% or more of the historical population when procured with the above method, so rather than up the soldier percentage, additional males are procured on an as-needed basis by having civ and site level noble positions that are required to be
MALE, parallel to the monarch and landholders.
Fun fact: I had to remove
DUTY_BOUND from the designated males in order to get marriage rates to an acceptable level. No idea why this is necessary. Neither making males 50% of the population nor procuring dutybound males are as effective at getting the breeders married as procuring non-dutybound males.
Making the married couples have impressive numbers of kids was trivial: I pumped their
LOVE_PROPENSITY and
LUST_PROPENSITY to ridiculous levels. The game seems to respect this when deciding whether an historical figure will have kids in any given year, but it's worth noting that even if I make both males and females antisocial miscreants untrusting and undesiring of any creature other than themselves, it seems to have no effect on marriage rates, so long as orientation permits it, and such misanthropic couples will still find time for one or two kids in their life. This is why all workers have to be homosexual.
Since the entity relies on a feature exclusive to worldgen to get its breeders, fortress mode requires a different technique to gain access to any breeders beyond the player's original supplied landholder and monarch. In lieu of anything convenient, I made a secret that transforms brood into breeders. Originally it changed workers and brood didn't exist, but neither orientation nor sex can be changed by syndrome, which meant workers had to be fertile, which in turn meant they sucked up all the available males, preventing breeders from getting married at acceptable rates. Brood overcome this limitation by dying before they're old enough to marry even the youngest adult soldier (
MAXAGE:6:7). They leave childhood at 2, so you only have 4 or 5 years to assign them as scholars and hope they read the right text.
CE_BODY_TRANSFORMATION correctly changes
MAXAGE, letting brood survive into the breeding years if they learn the secret, as well as qualifying the brood for
FEMALE only positions. Back when I was playing with workers, I did see a worker successfully survive a shortened lifespan and be appointed to a noble position, so I know it works, but the reduced popratio of brood makes it unlikely to happen in worldgen for the current version.
This is definitely a weak point in the entity. Statistically speaking, you should always have a brood member lying around as long as you have a functional breeder, but if you lose said breeder it's easy to run out of brood to replace her, and it's also easy to reach max pop and likewise have the short-lived brood get squeezed out. A more player-oriented solution would be to have an ingested syndrome and a custom reaction to create the potion, then have brood be longer lived but children their entire lives. You can lock them in a room with the potion and eventually they'll turn themselves into a breeder. But I hated the idea of a custom reaction since it doesn't work in worldgen. While it's currently very rare, it's possible for new breeders to be created in worldgen using the secret method.
The entity worships a natural force, and the secret belongs to the sphere of nature, so the entity always has a source for the secret and never a native source for any death-based secret. It turns males and non-sprites into genuine necromancers. The males make raidable towers quite likely, because of the ubiquitous presence of a nature deity. The non-sprites keep the secret from affecting non-sprite worldgen negatively. Workers get transformed into a creature that doesn't raise dead, with the hope that they will store their slab in a functioning colony and someone else in that colony might read it. Back when it was just workers, I saw them get so far as storing a slab, but I never saw anyone read such a slab. In the current version homebound workers are choked out by a plethora of male necromancers. I'm not sure why. Said male necromancers will take workers as apprentices, so that much works, at least.
I made other tweaks to make the entity more playable in fortress mode, even though my goal was worldgen focused. First and foremost, each caste gets its own set of profession names, so you can separate the women from the boys just by looking at the unit screen. Currently brood and breeders share a set of names, please put custom names on your breeders to distinguish them. Many of the names were manufactured from various endings, which creates a lot of clumsy, ahistorical, but nominally feminine titles for workers and nominally doubly feminine titles for brood.
Second, all noble positions were renamed. I used a religious motif in order to exploit the connection between sisters, the intended relationship of workers, and sisters, women living communal lives of poverty, chastity, and regular rituals involving wine. Positions retain the same title in the raws as their equivalent dwarven positions, it's only their display name that is changed. This is so you can convert the graphics pack of your choice with a hopefully single line change of the appropriate file.
There are some exceptions. In keeping with current science regarding eusocial species, which holds that the breeders have no leadership role in the colony, and that their goals often conflict with the goals of workers (the breeder decides whether eggs are male or female, but the workers decide which eggs hatch), I've created breeding and working lines of nobles, as follows.
Breeding nobles:
- MONARCH, named Queen. Her only duties are law making, designing coins, and appointing lesser breeders. Succession is by position, the positions being DUKE, COUNT, and BARON. This seems to work as one would hope.
- DRUID, named Patriarch. The Queen's designated male, although he usually marries someone else. His responsibility is religion. I gave him the druid tag just in case it makes it easier to adjust a graphics pack.
- DUKE, COUNT, BARON, named Matriarch, Matron, Mater. Their duties are lawmaking and building morale, the latter in an attempt to get them to hang out with soldiers in fortress mode, because they are procured single. The Queen does not build morale because she's supposed to come from the ranks of lesser landholders and hence should already be married.
- CHAMPION, named Scion. The landholding designated male. Does not build morale as that's the landholders' job now. Has PATROL_TERRITORY and ATTACK_ENEMIES because at one point I was trying to encourage both circulation and turnover. I suspect landholders have a slightly higher death rate than nonlandholders, just by going by hf pop counts in legends mode. No idea if this is at all useful but I'm hanging on to it.
Breeding nobles never ask for offices. They can make demands but can't issue mandates. Basically their job is to hang out in their bedroom, surrounded by luxury. They only have lawmaking because that's how things get named after them. The
MAYOR has 3 mandates instead of 1 to make up for the disparity.
Administrative nobles cannot be brood or female. They can only be male if it's a military position. Note that this method means members of other species who worm their way into the civilization can take up any of these positions. The only completely new administrative noble is the
LEADER, named Abbess, who receives diplomats and sets military goals in lieu of the monarch. She has 5 mandates, also in lieu of the monarch, as well as a few demands. (The monarch has a reduced number of demands to compensate). She, like all the other administrative nobles, never asks for a dining room and has a bedroom requirement of 1, to represent the egalitarian nature of the workers. However, her office requirements are stiff, again like other administrative nobles. This is the most convenient place to dump the room value necessary to stay roughly par with dwarves.
The civ-level military,
GENERAL,
LIEUTENANT, and
CAPTAIN, are renamed Bailiff, Commander, and Officer, these being the ranks of the knights of Malta, a religious military order.
Site-level military,
MILITIA_COMMANDER,
MILITIA_CAPTAIN,
SHERIFF, and
CAPTAIN_OF_THE_GUARD, are named master, instructor (I was going for a martial arts/rpg monk theme but it failed), circuitor (a monastic position), and churchwarden (with cathedral constables).
The remaining offices,
EXPEDITION_LEADER,
MAYOR,
MANAGER,
CHIEF_MEDICAL_DWARF,
BROKER,
BOOKKEEPER,
OUTPOST_LIAISON,
DIPLOMAT, and
HAMMERER are named chaplain, prior, precentor, infirmarian, cellarer, sacristan, procurator, advocate, and flagellant.
Soldiers. You'll have to tell me if this is too much or too little, I must confess I am playing dwarf fortress right now only because it seemed the right game to mod in some eusocial critters. I don't actually have much experience with it. My goals were to make the player excited to put soldiers on the front line, but grateful they were only 10% of the population. For the first goal, they're human sized, human gaited, and have both extravision and a number of innate combat skills. For the second they're slow learner and prone to rage. I like prone to rage because, if you train them up as military, it's a strict benefit, but if you try to turn your soldiers into an elite hauling force (plausible. See also: human sized, human gaited), you're far more likely to be annoyed by prone to rage than if you're playing to it. Extravision is likewise a benefit to the military, but because of prone to rage a bit of a minus for a hauling force.
This post reads like it was written by a twelve year old because I'm sick. I'm going to quit here and maybe come back to this after a nap.