3 #include "godconduct.h"
6 #include "godpassive.h"
16 /////////////////////////////////////////////////////////////////////
17 // god_conduct_trigger
19 god_conduct_trigger::god_conduct_trigger(
20 conduct_type c
, int pg
, bool kn
, const monster
* vict
)
21 : conduct(c
), pgain(pg
), known(kn
), enabled(true), victim(NULL
)
25 victim
.reset(new monster
);
26 *(victim
.get()) = *vict
;
30 void god_conduct_trigger::set(conduct_type c
, int pg
, bool kn
,
39 victim
.reset(new monster
);
40 *victim
.get() = *vict
;
44 god_conduct_trigger::~god_conduct_trigger()
46 if (enabled
&& conduct
!= NUM_CONDUCTS
)
47 did_god_conduct(conduct
, pgain
, known
, victim
.get());
50 // This function is the merger of done_good() and naughty().
51 // Returns true if god was interested (good or bad) in conduct.
52 bool did_god_conduct(conduct_type thing_done
, int level
, bool known
,
53 const monster
* victim
)
55 ASSERT(!crawl_state
.game_is_arena());
59 if (you
.religion
!= GOD_NO_GOD
&& you
.religion
!= GOD_XOM
)
77 simple_god_message(" forgives your inadvertent "
78 "blood-drinking, just this once.");
81 if (you
.religion
== GOD_SHINING_ONE
)
83 piety_change
= -2*level
;
98 piety_change
= -level
;
107 case DID_CORPSE_VIOLATION
:
108 if (you
.religion
== GOD_FEDHAS
)
112 piety_change
= -level
;
118 simple_god_message(" forgives your inadvertent necromancy, "
126 case DID_ATTACK_HOLY
:
127 switch (you
.religion
)
130 case GOD_SHINING_ONE
:
132 if (!known
&& thing_done
!= DID_ATTACK_HOLY
)
134 simple_god_message(" forgives your inadvertent unholy act, "
139 if (thing_done
== DID_ATTACK_HOLY
&& victim
140 && !testbits(victim
->flags
, MF_NO_REWARD
)
141 && !testbits(victim
->flags
, MF_WAS_NEUTRAL
))
146 piety_change
= -level
;
147 penance
= level
* ((you
.religion
== GOD_SHINING_ONE
) ? 2
157 if (you
.religion
== GOD_YREDELEMNUL
)
161 simple_god_message(" forgives your inadvertent holy act, "
166 piety_change
= -level
;
171 case DID_UNCHIVALRIC_ATTACK
:
173 if (you
.religion
== GOD_SHINING_ONE
)
175 if (thing_done
== DID_UNCHIVALRIC_ATTACK
)
177 if (victim
&& tso_unchivalric_attack_safe_monster(victim
))
182 simple_god_message(" forgives your inadvertent "
183 "dishonourable attack, just this "
189 piety_change
= -level
;
195 if (you
.religion
== GOD_JIYVA
&& !victim
->is_shapeshifter())
198 piety_change
= -level
;
204 case DID_PLANT_KILLED_BY_SERVANT
:
205 // Piety loss but no penance for killing a plant.
206 if (you
.religion
== GOD_FEDHAS
)
209 piety_change
= -level
;
213 case DID_ATTACK_NEUTRAL
:
214 switch (you
.religion
)
216 case GOD_SHINING_ONE
:
220 simple_god_message(" forgives your inadvertent attack on a "
221 "neutral, just this once.");
224 penance
= level
/2 + 1;
225 // deliberate fall through
230 simple_god_message(" forgives your inadvertent attack on a "
231 "neutral, just this once.");
234 piety_change
= -(level
/2 + 1);
239 if (victim
&& mons_is_slime(victim
)
240 && !victim
->is_shapeshifter())
242 piety_change
= -(level
/2 + 3);
243 penance
= level
/2 + 3;
253 case DID_ATTACK_FRIEND
:
254 if (god_hates_attacking_friend(you
.religion
, victim
))
258 simple_god_message(" forgives your inadvertent attack on "
259 "an ally, just this once.");
263 piety_change
= -level
;
270 case DID_FRIEND_DIED
:
271 case DID_SOULED_FRIEND_DIED
:
272 switch (you
.religion
)
275 // Ballistomycetes dying is penalised separately.
276 if (victim
&& fedhas_protects(victim
)
277 && victim
->mons_species() != MONS_BALLISTOMYCETE
)
279 // level is (1 + monsterHD/2) for this conduct,
280 // trying a fixed cost since plant HD aren't that
288 case GOD_ELYVILON
: // healer god cares more about this
289 // Converted allies (marked as TSOites) can be martyrs.
290 if (victim
&& victim
->god
== GOD_SHINING_ONE
)
293 if (player_under_penance())
294 penance
= 1; // if already under penance smaller bonus
300 // Converted allies (marked as TSOites) can be martyrs.
301 if (victim
&& victim
->god
== GOD_SHINING_ONE
)
304 // Zin only cares about the deaths of those with souls.
305 if (thing_done
== DID_FRIEND_DIED
)
310 piety_change
= -level
;
319 case DID_KILL_LIVING
:
320 switch (you
.religion
)
323 // Killing is only disapproved of during prayer.
324 if (you
.duration
[DUR_LIFESAVING
])
326 simple_god_message(" does not appreciate your shedding "
327 "blood when asking for salvation!");
329 piety_change
= -level
;
334 case GOD_KIKUBAAQUDGHA
:
335 case GOD_YREDELEMNUL
:
342 if (god_hates_attacking_friend(you
.religion
, victim
))
345 simple_god_message(" accepts your kill.");
347 piety_denom
= level
+ 18 - you
.experience_level
/ 2;
348 piety_change
= piety_denom
- 6;
349 piety_denom
= std::max(piety_denom
, 1);
350 piety_change
= std::max(piety_change
, 0);
358 case DID_KILL_UNDEAD
:
359 switch (you
.religion
)
361 case GOD_SHINING_ONE
:
367 if (god_hates_attacking_friend(you
.religion
, victim
))
370 simple_god_message(" accepts your kill.");
372 // Holy gods are easier to please this way.
373 piety_denom
= level
+ 18 - (is_good_god(you
.religion
) ? 0 :
374 you
.experience_level
/ 2);
375 piety_change
= piety_denom
- 5;
376 piety_denom
= std::max(piety_denom
, 1);
377 piety_change
= std::max(piety_change
, 0);
386 switch (you
.religion
)
388 case GOD_SHINING_ONE
:
392 case GOD_KIKUBAAQUDGHA
:
394 if (god_hates_attacking_friend(you
.religion
, victim
))
397 simple_god_message(" accepts your kill.");
399 // Holy gods are easier to please this way.
400 piety_denom
= level
+ 18 - (is_good_god(you
.religion
) ? 0 :
401 you
.experience_level
/ 2);
402 piety_change
= piety_denom
- 4;
403 piety_denom
= std::max(piety_denom
, 1);
404 piety_change
= std::max(piety_change
, 0);
412 case DID_KILL_NATURAL_UNHOLY
:
413 case DID_KILL_NATURAL_EVIL
:
414 if (you
.religion
== GOD_SHINING_ONE
415 && !god_hates_attacking_friend(you
.religion
, victim
))
417 simple_god_message(" accepts your kill.");
419 piety_denom
= level
+ 18;
420 piety_change
= piety_denom
- 4;
424 case DID_KILL_UNCLEAN
:
425 case DID_KILL_CHAOTIC
:
426 if (you
.religion
== GOD_ZIN
427 && !god_hates_attacking_friend(you
.religion
, victim
))
429 simple_god_message(" accepts your kill.");
431 piety_denom
= level
+ 18;
432 piety_change
= piety_denom
- 4;
436 case DID_KILL_PRIEST
:
437 if (you
.religion
== GOD_BEOGH
438 && !god_hates_attacking_friend(you
.religion
, victim
))
440 simple_god_message(" appreciates your killing of a heretic "
443 piety_denom
= level
+ 10;
444 piety_change
= piety_denom
- 6;
448 case DID_KILL_WIZARD
:
449 if (you
.religion
== GOD_TROG
450 && !god_hates_attacking_friend(you
.religion
, victim
))
452 simple_god_message(" appreciates your killing of a magic "
455 piety_denom
= level
+ 10;
456 piety_change
= piety_denom
- 6;
461 if (you
.religion
== GOD_CHEIBRIADOS
462 && !god_hates_attacking_friend(you
.religion
, victim
))
465 piety_denom
= level
+ 18 - you
.experience_level
/ 2;
466 piety_change
= piety_denom
- 6;
467 piety_denom
= std::max(piety_denom
, 1);
468 piety_change
= std::max(piety_change
, 0);
470 const int speed_delta
=
471 cheibriados_monster_player_speed_delta(victim
);
472 dprf("Che DID_KILL_FAST: %s speed delta: %d",
473 victim
->name(DESC_PLAIN
, true).c_str(),
475 if (speed_delta
> 0 && x_chance_in_y(speed_delta
, 12))
478 simple_god_message(" thoroughly appreciates the change of pace.");
481 simple_god_message(" appreciates the change of pace.");
485 case DID_KILL_ARTIFICIAL
:
486 if (you
.religion
== GOD_YREDELEMNUL
487 && !god_hates_attacking_friend(you
.religion
, victim
))
489 simple_god_message(" accepts your kill.");
491 piety_denom
= level
+ 18;
492 piety_change
= piety_denom
- 3;
496 // Note that holy deaths are special, they are always noticed...
497 // If you or any friendly kills one, you'll get the credit or
500 switch (you
.religion
)
503 case GOD_SHINING_ONE
:
506 && !testbits(victim
->flags
, MF_NO_REWARD
)
507 && !testbits(victim
->flags
, MF_WAS_NEUTRAL
))
513 piety_change
= -level
* 3;
517 case GOD_YREDELEMNUL
:
518 case GOD_KIKUBAAQUDGHA
:
522 if (god_hates_attacking_friend(you
.religion
, victim
))
525 simple_god_message(" accepts your kill.");
527 piety_denom
= level
+ 18;
528 piety_change
= piety_denom
- 3;
530 if (you
.religion
== GOD_YREDELEMNUL
)
532 simple_god_message(" appreciates your killing of a holy "
544 case DID_HOLY_KILLED_BY_UNDEAD_SLAVE
:
545 switch (you
.religion
)
547 case GOD_YREDELEMNUL
:
548 case GOD_KIKUBAAQUDGHA
:
552 if (god_hates_attacking_friend(you
.religion
, victim
))
555 simple_god_message(" accepts your slave's kill.");
557 piety_denom
= level
+ 18;
558 piety_change
= piety_denom
- 3;
566 case DID_HOLY_KILLED_BY_SERVANT
:
567 switch (you
.religion
)
570 case GOD_SHINING_ONE
:
573 && !testbits(victim
->flags
, MF_NO_REWARD
)
574 && !testbits(victim
->flags
, MF_WAS_NEUTRAL
))
580 piety_change
= -level
* 3;
587 if (god_hates_attacking_friend(you
.religion
, victim
))
590 simple_god_message(" accepts your collateral kill.");
592 piety_denom
= level
+ 18;
593 piety_change
= piety_denom
- 3;
601 case DID_LIVING_KILLED_BY_UNDEAD_SLAVE
:
602 switch (you
.religion
)
604 case GOD_YREDELEMNUL
:
605 case GOD_KIKUBAAQUDGHA
:
610 simple_god_message(" accepts your slave's kill.");
612 piety_denom
= level
+ 10 - you
.experience_level
/3;
613 piety_change
= piety_denom
- 6;
614 piety_denom
= std::max(piety_denom
, 1);
615 piety_change
= std::max(piety_change
, 0);
622 case DID_LIVING_KILLED_BY_SERVANT
:
623 switch (you
.religion
)
630 simple_god_message(" accepts your collateral kill.");
632 piety_denom
= level
+ 10 - you
.experience_level
/3;
633 piety_change
= piety_denom
- 6;
634 piety_denom
= std::max(piety_denom
, 1);
635 piety_change
= std::max(piety_change
, 0);
642 case DID_UNDEAD_KILLED_BY_UNDEAD_SLAVE
:
643 switch (you
.religion
)
649 simple_god_message(" accepts your slave's kill.");
651 piety_denom
= level
+ 10 - you
.experience_level
/3;
652 piety_change
= piety_denom
- 6;
653 piety_denom
= std::max(piety_denom
, 1);
654 piety_change
= std::max(piety_change
, 0);
661 case DID_UNDEAD_KILLED_BY_SERVANT
:
662 switch (you
.religion
)
664 case GOD_SHINING_ONE
:
669 simple_god_message(" accepts your collateral kill.");
671 piety_denom
= level
+ 10 - (is_good_god(you
.religion
) ? 0 :
672 you
.experience_level
/3);
673 piety_change
= piety_denom
- 6;
674 piety_denom
= std::max(piety_denom
, 1);
675 piety_change
= std::max(piety_change
, 0);
682 case DID_DEMON_KILLED_BY_UNDEAD_SLAVE
:
683 switch (you
.religion
)
685 case GOD_KIKUBAAQUDGHA
:
688 simple_god_message(" accepts your slave's kill.");
690 piety_denom
= level
+ 10 - you
.experience_level
/3;
691 piety_change
= piety_denom
- 6;
692 piety_denom
= std::max(piety_denom
, 1);
693 piety_change
= std::max(piety_change
, 0);
700 case DID_DEMON_KILLED_BY_SERVANT
:
701 switch (you
.religion
)
703 case GOD_SHINING_ONE
:
707 simple_god_message(" accepts your collateral kill.");
709 piety_denom
= level
+ 10 - (is_good_god(you
.religion
) ? 0 :
710 you
.experience_level
/3);
711 piety_change
= piety_denom
- 6;
712 piety_denom
= std::max(piety_denom
, 1);
713 piety_change
= std::max(piety_change
, 0);
720 case DID_NATURAL_UNHOLY_KILLED_BY_SERVANT
:
721 case DID_NATURAL_EVIL_KILLED_BY_SERVANT
:
722 if (you
.religion
== GOD_SHINING_ONE
)
724 simple_god_message(" accepts your collateral kill.");
726 piety_denom
= level
+ 10;
727 piety_change
= piety_denom
- 6;
731 case DID_UNCLEAN_KILLED_BY_SERVANT
:
732 case DID_CHAOTIC_KILLED_BY_SERVANT
:
733 if (you
.religion
== GOD_ZIN
)
735 simple_god_message(" accepts your collateral kill.");
738 piety_denom
= level
+ 10;
739 piety_change
= piety_denom
- 6;
743 case DID_ARTIFICIAL_KILLED_BY_UNDEAD_SLAVE
:
744 if (you
.religion
== GOD_YREDELEMNUL
)
746 simple_god_message(" accepts your slave's kill.");
748 piety_denom
= level
+ 18;
749 piety_change
= piety_denom
- 3;
753 // Currently used only when confused undead kill artificial
754 // beings, which Yredelemnul doesn't care about.
755 case DID_ARTIFICIAL_KILLED_BY_SERVANT
:
758 case DID_SPELL_MEMORISE
:
759 if (you
.religion
== GOD_TROG
)
761 penance
= level
* 10;
762 piety_change
= -penance
;
767 case DID_SPELL_CASTING
:
768 if (you
.religion
== GOD_TROG
)
770 piety_change
= -level
;
776 case DID_SPELL_PRACTISE
:
777 // Like CAST, but for skill advancement.
778 // Level is number of skill points gained...
779 // typically 10 * exercise, but may be more/less if the
780 // skill is at 0 (INT adjustment), or if the PC's pool is
781 // low and makes change.
782 if (you
.religion
== GOD_SIF_MUNA
)
784 // Old curve: random2(12) <= spell-level, this is
785 // similar, but faster at low levels (to help ease
786 // things for low level spells). Power averages about
787 // (level * 20 / 3) + 10 / 3 now. Also note that spell
788 // skill practise comes just after XP gain, so magical
789 // kills tend to do both at the same time (unlike
790 // melee). This means high level spells probably work
791 // pretty much like they used to (use spell, get piety).
792 piety_change
= level
+ 10;
799 if (you
.religion
== GOD_NEMELEX_XOBEH
)
801 piety_change
= level
;
804 // level == 0: stacked, deck not used up
805 // level == 1: used up or nonstacked
806 // level == 2: used up and nonstacked
807 // and there's a 1/3 chance of an additional bonus point
808 // for nonstacked cards.
812 case 0: chance
= 0; break;
813 case 1: chance
= 40; break;
814 case 2: chance
= 70; break;
816 case 3: chance
= 100; break;
819 if (x_chance_in_y(chance
, 100)
820 && you
.attribute
[ATTR_CARD_COUNTDOWN
])
822 you
.attribute
[ATTR_CARD_COUNTDOWN
]--;
823 #if defined(DEBUG_DIAGNOSTICS) || defined(DEBUG_CARDS) || defined(DEBUG_GIFTS)
824 mprf(MSGCH_DIAGNOSTICS
, "Countdown down to %d",
825 you
.attribute
[ATTR_CARD_COUNTDOWN
]);
831 case DID_CAUSE_GLOWING
:
832 case DID_DELIBERATE_MUTATING
:
833 if (you
.religion
== GOD_ZIN
)
835 if (!known
&& thing_done
!= DID_CAUSE_GLOWING
)
837 simple_god_message(" forgives your inadvertent chaotic "
838 "act, just this once.");
842 if (thing_done
== DID_CAUSE_GLOWING
)
844 static long last_glowing_lecture
= -1L;
847 simple_god_message(" is not enthusiastic about the "
848 "mutagenic glow surrounding you.");
850 else if (last_glowing_lecture
!= you
.num_turns
)
852 last_glowing_lecture
= you
.num_turns
;
853 // Increase contamination within yellow glow.
854 simple_god_message(" does not appreciate the extra "
855 "mutagenic glow surrounding you!");
859 piety_change
= -level
;
864 // level depends on intelligence: normal -> 1, high -> 2
865 // cannibalism is still worse
866 case DID_EAT_SOULED_BEING
:
867 if (you
.religion
== GOD_ZIN
)
869 piety_change
= -level
* 5;
877 if (you
.religion
== GOD_ZIN
)
882 simple_god_message(" forgives your inadvertent unclean "
883 "act, just this once.");
886 piety_change
= -level
;
892 if (you
.religion
== GOD_ZIN
)
897 simple_god_message(" forgives your inadvertent chaotic "
898 "act, just this once.");
901 piety_change
= -level
;
906 case DID_ATTACK_IN_SANCTUARY
:
907 if (you
.religion
== GOD_ZIN
)
909 piety_change
= -level
;
914 case DID_DESECRATE_ORCISH_REMAINS
:
915 if (you
.religion
== GOD_BEOGH
)
917 piety_change
= -level
;
922 case DID_DESTROY_ORCISH_IDOL
:
923 if (you
.religion
== GOD_BEOGH
)
925 piety_change
= -level
;
932 if (you
.religion
== GOD_CHEIBRIADOS
)
936 simple_god_message(" forgives your accidental hurry, just this once.");
939 simple_god_message(" thinks you should slow down.");
940 piety_change
= -level
;
947 case DID_DESTROY_SPELLBOOK
:
948 if (you
.religion
== GOD_SIF_MUNA
)
950 piety_change
= -level
;
951 penance
= level
* (known
? 2 : 1);
956 case DID_EXPLORATION
:
957 if (you
.religion
== GOD_ASHENZARI
)
959 // levels: x1, x2, x4, x6
960 piety_change
= ash_bondage_level() * 2;
963 piety_change
*= 8; // base gain per dungeon level
970 case DID_GLUTTONY
: // previously used for Chei
971 case DID_STABBING
: // unused
972 case DID_STIMULANTS
: // unused
973 case DID_EAT_MEAT
: // unused
974 case DID_CREATE_LIFE
: // unused
975 case DID_SPELL_NONUTILITY
: // unused
976 case DID_DEDICATED_BUTCHERY
: // unused
981 #ifdef DEBUG_DIAGNOSTICS
982 int old_piety
= you
.piety
;
985 if (piety_change
> 0)
986 gain_piety(piety_change
, piety_denom
);
988 dock_piety(div_rand_round(-piety_change
, piety_denom
), penance
);
990 #ifdef DEBUG_DIAGNOSTICS
991 // don't announce exploration piety unless you actually got a boost
992 if (retval
&& (thing_done
!= DID_EXPLORATION
|| old_piety
!= you
.piety
))
994 static const char *conducts
[] =
997 "Necromancy", "Holy", "Unholy", "Attack Holy", "Attack Neutral",
998 "Attack Friend", "Friend Died", "Stab", "Unchivalric Attack",
999 "Poison", "Field Sacrifice", "Kill Living", "Kill Undead",
1000 "Kill Demon", "Kill Natural Unholy", "Kill Natural Evil",
1001 "Kill Unclean", "Kill Chaotic", "Kill Wizard", "Kill Priest",
1002 "Kill Holy", "Kill Fast", "Undead Slave Kill Living",
1003 "Servant Kill Living", "Undead Slave Kill Undead",
1004 "Servant Kill Undead", "Undead Slave Kill Demon",
1005 "Servant Kill Demon", "Servant Kill Natural Unholy",
1006 "Servant Kill Natural Evil", "Undead Slave Kill Holy",
1007 "Servant Kill Holy", "Spell Memorise", "Spell Cast",
1008 "Spell Practise", "Spell Nonutility", "Cards", "Stimulants",
1009 "Drink Blood", "Cannibalism", "Eat Meat", "Eat Souled Being",
1010 "Deliberate Mutation", "Cause Glowing", "Use Unclean",
1011 "Use Chaos", "Desecrate Orcish Remains", "Destroy Orcish Idol",
1012 "Create Life", "Kill Slime", "Kill Plant", "Servant Kill Plant",
1013 "Was Hasty", "Gluttony", "Corpse Violation",
1014 "Souled Friend Died", "Servant Kill Unclean",
1015 "Servant Kill Chaotic", "Attack In Sanctuary",
1016 "Kill Artificial", "Undead Slave Kill Artificial",
1017 "Servant Kill Artificial", "Destroy Spellbook",
1021 COMPILE_CHECK(ARRAYSZ(conducts
) == NUM_CONDUCTS
, c1
);
1022 mprf(MSGCH_DIAGNOSTICS
,
1023 "conduct: %s; piety: %d (%+d/%d); penance: %d (%+d)",
1024 conducts
[thing_done
],
1025 you
.piety
, piety_change
, piety_denom
,
1026 you
.penance
[you
.religion
], penance
);
1032 do_god_revenge(thing_done
);
1037 // These two arrays deal with the situation where a beam hits a non-fleeing
1038 // monster, the monster starts to flee because of the damage, and then the
1039 // beam bounces and hits the monster again. If the monster wasn't fleeing
1040 // when the beam started then hits from bounces shouldn't count as
1041 // unchivalric attacks, but if the first hit from the beam *was* unchivalrous
1042 // then all the bounces should count as unchivalrous as well.
1044 // Also do the same sort of check for harming a friendly monster,
1045 // since a Beogh worshipper zapping an orc with lightning might cause it to
1046 // become a follower on the first hit, and the second hit would be
1047 // against a friendly orc.
1048 static FixedVector
<bool, MAX_MONSTERS
> _first_attack_conduct
;
1049 static FixedVector
<bool, MAX_MONSTERS
> _first_attack_was_unchivalric
;
1050 static FixedVector
<bool, MAX_MONSTERS
> _first_attack_was_friendly
;
1052 void god_conduct_turn_start()
1054 _first_attack_conduct
.init(true);
1055 _first_attack_was_unchivalric
.init(false);
1056 _first_attack_was_friendly
.init(false);
1059 void set_attack_conducts(god_conduct_trigger conduct
[3], const monster
* mon
,
1062 const unsigned int midx
= mon
->mindex();
1064 if (mon
->friendly())
1066 if (_first_attack_conduct
[midx
]
1067 || _first_attack_was_friendly
[midx
])
1069 conduct
[0].set(DID_ATTACK_FRIEND
, 5, known
, mon
);
1070 _first_attack_was_friendly
[midx
] = true;
1073 else if (mon
->neutral())
1075 conduct
[0].set(DID_ATTACK_NEUTRAL
, 5, known
, mon
);
1078 if (is_unchivalric_attack(&you
, mon
)
1079 && (_first_attack_conduct
[midx
]
1080 || _first_attack_was_unchivalric
[midx
]))
1082 conduct
[1].set(DID_UNCHIVALRIC_ATTACK
, 4, known
, mon
);
1083 _first_attack_was_unchivalric
[midx
] = true;
1087 conduct
[2].set(DID_ATTACK_HOLY
, mon
->hit_dice
, known
, mon
);
1089 _first_attack_conduct
[midx
] = false;
1092 void enable_attack_conducts(god_conduct_trigger conduct
[3])
1094 for (int i
= 0; i
< 3; ++i
)
1095 conduct
[i
].enabled
= true;
1098 void disable_attack_conducts(god_conduct_trigger conduct
[3])
1100 for (int i
= 0; i
< 3; ++i
)
1101 conduct
[i
].enabled
= false;