Determining damage or tease victory

Ace Hangman

Well-Known Member
Sep 16, 2021
869
704
47
What method is used to determine when Champ defeats an opponent in combat and whether the last blow was an attack or a tease? I figure it was easier back when Resolve damage was a thing, but even now I believe a few opponents, like Lyla, still have victory conditions that vary based on whether you beat her with an attack or a tease (though maybe I'm wrong).
Looking for the parser or variable that would check for such an instance for a combat encounter I'm working on. Obviously don't want to have something like 'The last blow sends them reeling...' or something if the last blow was a tease.
 

CroqueMonsieur

Well-Known Member
Jul 17, 2023
102
171
According to Drake's parser documentation, resDefeated is the parser you're looking for, it checks what type of damage finished the opponent off.

Schermafbeelding 2023-09-23 220208.png

In-game it appears to be a bit inconsistent however, as from the quick spars i did with Lyla using "Carnal hex" and "Hypnotic words" as finishers, only "Carnal hex" seems to trigger her "defeat by horny" dialogue.
 
Last edited:
  • Like
Reactions: Ace Hangman

Ace Hangman

Well-Known Member
Sep 16, 2021
869
704
47
According to Drake's parser documentation, resDefeated is the parser you're looking for, it checks what type of damage finished the opponent off.
Yes, I see them now that I know what to search for. 'resDefeated' and 'HPDefeated'. It looks like they link up with 'finisher' and 'lastStanding'
So presumably, if we were talking about Lyla, the coding in the scene after combat ends (and she's the loser) would be something like,
[lastStanding.resDefeated|"I'm too horny to fight anymore."|"I'm too injured to fight anymore."]
or
[lastStanding.HPDefeated| (as above but in reverse order)]
?
 

CroqueMonsieur

Well-Known Member
Jul 17, 2023
102
171
You got it.

Schermafbeelding 2023-09-23 224417.png

EDIT: Here's another snippet from Meira's code that's written exactly like your examples, Lyla uses another method.

Schermafbeelding 2023-09-23 224749.png
 
Last edited: