Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Frequency of CLEAN_SELF and CLEAN_FRIEND interactions?  (Read 804 times)

bloop_bleep

  • Bay Watcher
    • View Profile
Frequency of CLEAN_SELF and CLEAN_FRIEND interactions?
« on: March 10, 2018, 01:47:27 am »

So, I've been trying to make my alchemy mod, which involves making a lot of creatures that act like alchemy components. These are able to do touch interactions with each other in order to move around mana, spells, and other ingredients. Now, I remember reading somewhere that GREETING interactions are now used much less often in recent versions. I'm hoping to make the delay between interactions to be preferably under 100 ticks, 500 ticks at most. Is that possible to achieve with GREETING interactions? If not, I was thinking of using CLEAN_FRIEND interactions instead -- basically, when the component corpses are crafted and then resurrected using an Alchemical Activator, they would transform into a creature that emits a vapor cloud, condensing some the vapor as a contaminant on itself. This would trigger a syndrome that turns the creature into the creature that actually performs the desired function. The point is, whenever a component's neighbor satisfies certain requirements, the component will attempt to perform a CLEAN_FRIEND interaction that performs the desired effect on the neighbor, but doesn't actually clean any contaminant (IE_GRIME_LEVEL will be set to zero.) This also fits my plan for ingredient movement system -- it requires that creatures that are currently holding an ingredient to occasionally perform a "renewal" interaction on themselves. The only USAGE_HINT I can see that allows this is CLEAN_SELF.

My question is -- how often are CLEAN_FRIEND and CLEAN_SELF interactions performed? Is their frequency high enough for my purposes? Also, can CLEAN_FRIEND interactions have both a SELF_ONLY and a TOUCHABLE target?
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

IndigoFenix

  • Bay Watcher
  • All things die, but nothing dies forever.
    • View Profile
    • Boundworlds: A Browser-Based Multiverse Creation and Exploration Game
Re: Frequency of CLEAN_SELF and CLEAN_FRIEND interactions?
« Reply #1 on: March 12, 2018, 09:27:28 am »

Cleaning interactions only occur if the target has contamination.

Greetings do not work at all unless the user is non-sapient, OR they are in combat (lethal or higher).

Pretty much the only way to control interactions is if the creature is in combat, in which case they will use interactions whenever possible.  This makes the interaction system much less flexible than it used to be, unfortunately.

bloop_bleep

  • Bay Watcher
    • View Profile
Re: Frequency of CLEAN_SELF and CLEAN_FRIEND interactions?
« Reply #2 on: March 12, 2018, 02:43:51 pm »

The point of the vapor thing was to deposit contaminants on the creature. Later I realized I could perhaps use secretions instead, but it doesn't seem to work; I copied the dwarf raws into a "modified dwarf" creature to which I gave [IMMOBILE] and a self-cleaning interaction that induced severe necrosis and bleeding of all tissues. The interaction worked when I assumed control and performed it explicitly, but it didn't seem to be activated on its own. Perhaps secretions are considered "natural" and can't be cleaned. I'll try vapor later.

As for greeting interactions -- they do seem to work on sapient creatures, although not very often. (Not that it matters all that much; my alchemical components aren't sapient, being alchemical components.) I changed the USAGE_HINT for the death cleaning interaction to GREETING, the TARGET declaration to LINE_OF_SIGHT (instead of SELF_ONLY), and then spawned two modified dwarves in the arena both of side "1" right next to each other. Within some time I noticed that one of them dropped dead; there was no combat, so I assume that it was caused by the interaction. It took several seconds in the arena running at 100 FPS, so it probably will be too slow for my purposes, but it's good to know for the future.
« Last Edit: March 12, 2018, 02:46:01 pm by bloop_bleep »
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

bloop_bleep

  • Bay Watcher
    • View Profile
Re: Frequency of CLEAN_SELF and CLEAN_FRIEND interactions?
« Reply #3 on: March 12, 2018, 03:15:16 pm »

I have an update. Apparently the greeting interaction did NOT take several seconds to activate, but rather ~20 adv. mode ticks; I simply didn't notice it because the syndrome was only active for a small period of time, requiring repeated attempts in order to trigger death from blood loss. This was also the case when the combat level was turned all the way down to Encounter. The interaction was not in fact used as often as it could (given that it had [CDI:FREE_ACTION]), but it was used often enough for me. As for the "renewal" interaction -- I realized I could just use a region interaction with 100% frequency instead.

In fact, I'll try to turn up the wait period on the interaction, to see how what happens then....
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

Warlord255

  • Bay Watcher
  • Master Building Designer
    • View Profile
Re: Frequency of CLEAN_SELF and CLEAN_FRIEND interactions?
« Reply #4 on: March 15, 2018, 12:15:46 am »

Cleaning interactions only occur if the target has contamination.

Greetings do not work at all unless the user is non-sapient, OR they are in combat (lethal or higher).

Pretty much the only way to control interactions is if the creature is in combat, in which case they will use interactions whenever possible.  This makes the interaction system much less flexible than it used to be, unfortunately.

I would refute this, as I've used GREETING as the trigger for a sneezing reaction for my plump helmet plague. It seems to work reliably when you've got dwarves milling about in a tavern.
Logged
DF Vanilla-Spice Revised: Better balance, more !!fun!!
http://www.bay12forums.com/smf/index.php?topic=173907.msg7968772#msg7968772

LeadfootSlim on Steam, LeadfootSlim#1851 on Discord. Hit me up!

bloop_bleep

  • Bay Watcher
    • View Profile
Re: Frequency of CLEAN_SELF and CLEAN_FRIEND interactions?
« Reply #5 on: March 15, 2018, 12:22:13 am »

There's also a plague-spreading interaction example that uses GREETING on the wiki (although I understand that can be outdated sometimes.)
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.