@Endarei
I think I could get you fairly close to the bonding mechanism through interactions (though it would have some problems such as either a dwarf would be able to stop multiple dragons, even those it hadn't bonded with, from suiciding). It would require a fair bit of work through, and a bit of micromanagement. I think the keyword here is "hoops as fuck".
Here are the steps:
1)The dragon is born. Newborn dragons are of a caste (you could call it "*color* hatchling" or something similar) that secretes a poison within themselves that only affects newborn dragons. This poison should be fairly strong, but not strong enough to kill them before they can bond.
The next few steps are fairly complicated, so I'll outline some of the information prior to them. Note that "hatchlings" and "dragons" are two different castes.
There are a total of 4 interactions here (per color), all of which do multiple things:
"Bond" interaction: This is accessible by default to hatchlings. This interaction is short range, has a long cool down time, and has a variety of effects.
0)Targets dwarves without the "[color] rider" syndrome
1)Assign a harmless syndrome called "[color] rider" on the target dwarf.
2)Enables the "Connect" interaction on the target dwarf for a short period of time.
3)Enables the "Reinforce" interaction on the target dwarf permanently.
"Connect" interaction: This is enabled by the "Bond" interaction on bonded dwarves temporarily. The interaction has a slightly longer range then the "Bond" interaction and has a cool down time longer then the period it is enabled.
0)Targets hatchlings of a given color.
1)Transforms a hatchling into its matching "adult" caste. This is identical to the hatchling caste, but doesn't secrete the poison and is immune to it. It also has an itemcorpse of a boiling stone (you could call it "between dust" or something similar)
2)Assigns a harmless syndrome called "bonded dragon" to the transformed dragon. This should be applied only temporarily (this determines the timer on a dragon's suicide, so don't make it too short).
"Reinforce" interaction: This is enabled by the "Bond" interaction on bonded dwarves permanently. The interaction has a medium range with a fairly short cooldown (think 2-3x shorter then the "bonded dragon" syndrome duration).
0)Targets dragons of a given color.
1)Applies the "bonded dragon" syndrome to the targeted dragon.
"Suicide" interaction: This is accessible by default on all dragons. This interaction is self targeting and has no cooldown.
0)Cannot target dragons with the "bonded dragon" syndrome.
1)This interaction applies a fast acting and deadly syndrome to the targeted dragon, killing it quickly.
2)The hatchling uses the "Bond" interaction on a nearby dwarf.
3)The dwarf completes the connection by using the "Connect" interaction on the hatchling.
4)The hatchling should now be kept as close to the dwarf as possible, this can be done through training and then assigning it to the given dwarf. If the dragon is too far from a rider of it's color for too long it will die.
5)The rider dwarves use the "Reinforce" interaction to reset the suicide timers on the adult dragons.
6)If the dragon goes unreinforced for too long, it uses the "Suicide" interaction to kill itself (this will occur most often if it's rider dies, assuming they are kept close most of the time).
As for
Would it be possible to make their ability to breathe fire dependent on consumption of a specific item? I haven't bothered trying yet because it didn't look feasible, but I don't know much about the Interactions yet.
Totally possible. Just have a food item that temporarily allows dragons to use the material breath interaction. It would be incredibly difficult to get the dragons to eat it though, and anybody else could eat it as well for food.
The sexual orientation thing is out the window though, simply because right now dwarves only have two orientations, "male" and "female". You could limit the "Bond" interaction by gender though.
Also while I could potentially set it up that dwarves suicide if their dragon dies as well, it opens up more loopholes and errors then it fixes, so I decided to leave it out.