diff --git a/tpdata/co8infra.dat b/tpdata/co8infra.dat index 5e048f7a6..00e958ccb 100644 Binary files a/tpdata/co8infra.dat and b/tpdata/co8infra.dat differ diff --git a/tpdata/templeplus/lib/templeplus/constants.py b/tpdata/templeplus/lib/templeplus/constants.py index a25f58c6c..8909ec6bf 100644 --- a/tpdata/templeplus/lib/templeplus/constants.py +++ b/tpdata/templeplus/lib/templeplus/constants.py @@ -3359,6 +3359,59 @@ spell_new_slot_lvl_9 = 1614 +# Marshal Spells +spell_marshal_minor_aura = 3831 +spell_marshal_major_aura = 3832 +spell_marshal_adrenaline_boost = 3833 + +# Dragon Shaman Spells +spell_draconic_aura = 3840 +spell_double_draconic_aura = 3841 + +# Aura Types +aura_type_minor = 1 +aura_type_major = 2 +aura_type_draconic = 3 +aura_type_double_draconic = 4 + +#Aura Enums +aura_accurate_strike = 1 +aura_art_of_war = 2 +aura_Demand_fortitude = 3 +aura_Determined_caster = 4 +aura_force_of_will = 5 +aura_master_of_opportunity = 6 +aura_master_of_tactics = 7 +aura_motivate_charisma = 8 +aura_motivate_constitution = 9 +aura_motivate_dexterity = 10 +aura_motivate_intelligence = 11 +aura_motivate_strength = 12 +aura_motivate_wisdom = 13 +aura_over_the_top = 14 +aura_watchful_eye = 15 +aura_hardy_soldiers = 16 +aura_motivate_ardor = 17 +aura_motivate_attack = 18 +aura_motivate_care = 19 +aura_motivate_urgency = 20 +aura_resilient_troops = 21 +aura_steady_hand = 22 +aura_energy_shield = 23 +aura_power = 24 +aura_presence = 25 +aura_resistance = 26 +aura_senses = 27 +aura_toughness = 28 +aura_vigor = 29 +aura_break_spell_resistance = 30 +aura_energy = 31 +aura_insight = 32 +aura_resolve = 33 +aura_stamina = 34 +aura_swiftness =35 + + stat_strength = 0 stat_dexterity = 1 stat_constitution = 2 diff --git a/tpdata/tpgamefiles.dat b/tpdata/tpgamefiles.dat index 17897a70f..98b42eefd 100644 Binary files a/tpdata/tpgamefiles.dat and b/tpdata/tpgamefiles.dat differ diff --git a/tpdatasrc/co8infra/scr/py00416standard_equipment_chest.py b/tpdatasrc/co8infra/scr/py00416standard_equipment_chest.py index 2a25f82ba..eccefd0ba 100644 --- a/tpdatasrc/co8infra/scr/py00416standard_equipment_chest.py +++ b/tpdatasrc/co8infra/scr/py00416standard_equipment_chest.py @@ -38,6 +38,9 @@ def give_default_starting_equipment(x = 0): elif pc.stat_level_get(stat_level_fighter) > 0: for aaa in [6013 ,6010 ,6011 ,6012 ,6059 ,4062 ,8014]: create_item_in_inventory( aaa, pc ) + elif pc.stat_level_get(stat_level_marshal) > 0: + for aaa in [6013, 6010, 6011, 6012, 6059, 4062, 8014]: + create_item_in_inventory( aaa, pc ) elif pc.stat_level_get(stat_level_monk) > 0: if pc.stat_level_get(stat_race) in [race_gnome, race_halfling]: for aaa in [6205 ,6202 ,4060 ,8014]: # dagger (4060) instead of quarterstaff diff --git a/tpdatasrc/tpgamefiles/mes/auras.mes b/tpdatasrc/tpgamefiles/mes/auras.mes new file mode 100644 index 000000000..2bb2cca1d --- /dev/null +++ b/tpdatasrc/tpgamefiles/mes/auras.mes @@ -0,0 +1,86 @@ +// Aura List +// Used by Marshal, Dragon Shaman and Draconic Aura Feats + +// Marshal Auras +// 1-15 Minor Auras +// 16-22 Major Auras + +{1}{Accurate Strike} +{2}{Art of War} +{3}{Demand Fortitude} +{4}{Determined Caster} +{5}{Force of Will} +{6}{Master of Opportunity} +{7}{Master of Tactics} +{8}{Motivate Charisma} +{9}{Motivate Constitution} +{10}{Motivate Dexterity} +{11}{Motivate Intelligence} +{12}{Motivate Strength} +{13}{Motivate Wisdom} +{14}{Over the Top} +{15}{Watchful Eye} +{16}{Hardy Soldiers} +{17}{Motivate Ardor} +{18}{Motivate Attack} +{19}{Motivate Care} +{20}{Motivate Urgency} +{21}{Resilient Troops} +{22}{Steady Hand} + +// Draconic Auras +// PHB II: 23-29 +// Dragon Magic 30+ + +{23}{Energy Shield} +{24}{Power} +{25}{Presence} +{26}{Resistance} +{27}{Senses} +{28}{Toughness} +{29}{Vigor} +{30}{Break Spell Resistance} // Renamed from Power as a different Aura is already named Power +{31}{Energy} +{32}{Insight} +{33}{Resolve} +{34}{Stamina} +{35}{Swiftness} + +// Aura Tags +// Enums are +1000 + +{1001}{TAG_AURA_ACCURATE_STRIKE} +{1002}{TAG_AURA_ART_OF_WAR} +{1003}{TAG_AURA_DEMAND_FORTITUDE} +{1004}{TAG_AURA_DETERMINED_CASTER} +{1005}{TAG_AURA_FORCE_OF_WILL} +{1006}{TAG_AURA_MASTER_OF_OPPORTUNITY} +{1007}{TAG_AURA_MASTER_OF_TACTICS} +{1008}{TAG_AURA_MOTIVATE_CHARISMA} +{1009}{TAG_AURA_MOTIVATE_CONSTITUTION} +{1010}{TAG_AURA_MOTIVATE_DEXTERITY} +{1011}{TAG_AURA_MOTIVATE_INTELLIGENCE} +{1012}{TAG_AURA_MOTIVATE_STRENGTH} +{1013}{TAG_AURA_MOTIVATE_WISDOM} +{1014}{TAG_AURA_OVER_THE_TOP} +{1015}{TAG_AURA_WATCHFUL_EYE} +{1016}{TAG_AURA_HARDY_SOLDIERS} +{1017}{TAG_AURA_MOTIVATE_ARDOR} +{1018}{TAG_AURA_MOTIVATE_ATTACK} +{1019}{TAG_AURA_MOTIVATE_CARE} +{1020}{TAG_AURA_MOTIVATE_URGENCY} +{1021}{TAG_AURA_RESILIENT_TROOPS} +{1022}{TAG_AURA_STEADY_HAND} +{1023}{TAG_AURA_ENERGY_SHIELD} +{1024}{TAG_AURA_POWER} +{1025}{TAG_AURA_PRESENCE} +{1026}{TAG_AURA_RESISTANCE} +{1027}{TAG_AURA_SENSES} +{1028}{TAG_AURA_TOUGHNESS} +{1029}{TAG_AURA_VIGOR} +{1030}{TAG_AURA_BREAK_SPELL_RESISTANCE} // Renamed from Power as a different Aura is already named Power +{1031}{TAG_AURA_ENERGY} +{1032}{TAG_AURA_INSIGHT} +{1033}{TAG_AURA_RESOLVE} +{1034}{TAG_AURA_STAMINA} +{1035}{TAG_AURA_SWIFTNESS} diff --git a/tpdatasrc/tpgamefiles/mes/help/marshal_help.tab b/tpdatasrc/tpgamefiles/mes/help/marshal_help.tab new file mode 100644 index 000000000..0d12f6f1c --- /dev/null +++ b/tpdatasrc/tpgamefiles/mes/help/marshal_help.tab @@ -0,0 +1,30 @@ +TAG_MARSHALS TAG_NONCORE_CLASSES Marshals Sometimes it is not enough to be a conquering warrior, a champion of all that's right, an experienced sellsword, or an elite foot soldier. Sometimes the circumstances require a solid commander of soldiers and situations. Sometimes the circumstances demand a marshal. Characteristics: Trained in the basics of fighting, marshals possess a general knowledge of weapons and armor. Their real strength is their ability to lead those who follow them to success they might not otherwise reach in combat. Marshals make passable warriors themselves, when personal danger finds them. Religion: Marshals often worship Heironeous (god of valor) or Kord (god of strength). Some worship St. Cuthbert (god of retribution), Hextor (god of tyranny), or Erythnul (god of slaughter). Other Classes: The marshal relies on the other classes in all ways -- it is his job to support a team, magnifying the strengths of each member for success in battles or forays into dangerous cavern complexes. Role: In most adventuring parties, the marshal serves as the lead tactician, while his comrades support him with spells, ranged attacks, and other effects. However, once a plan is in motion, most marshals enter the melee to assure victory. Alignment: Marshals may be of any alignment. Good-aligned marshals are often crusading leaders who seek out and fight evil. Lawful-aligned marshals accept commissions from people who face invasion by foreign aggressors. Chaotic-aligned marshals lead mercenaries to wherever the pay is best. Evil-aligned marshals tend to lead forces of foreign aggressors set on invasion and plunder. Hit Die: d8 Base Attack and Base Save Bonuses: see ~table~[TAG_CLASS_FEATURES_MARSHAL] Class Skills: ~Bluff~[TAG_BLUFF], ~Diplomacy~[TAG_DIPLOMACY], Handle Animal, ~Intimidate~[TAG_INTIMIDATE], Knowledge, ~Listen~[TAG_LISTEN], ~Perform~[TAG_PERFORM], Ride, ~Sense Motive~[TAG_SENSE_MOTIVE], Speak Language, ~Spot~[TAG_SPOT], ~Survival~[TAG_SURVIVAL], and ~Swim~[TAG_SWIM]. Skill Points at Each Level: 4 + Int modifier Class Features: [CMD_CHILDREN] +TAG_CLASS_FEATURES_MARSHAL_WEAPON_ARMOR_PROF TAG_MARSHALS Weapon and Armor Proficiency Marshals are proficient with all simple and martial weapons, with all types of armor (heavy, medium, and light), and with shields (except tower shields). +TAG_CLASS_FEATURES_MARSHAL TAG_DUMMY Marshal Base Attack & Base Save Bonuses Level ~Base Attack Bonus~[TAG_LEVEL_BONUSES] ~Fortitude~[TAG_FORTITUDE] ~Save~[TAG_LEVEL_BONUSES] ~Reflex~[TAG_REFLEX] ~Save~[TAG_LEVEL_BONUSES] ~Will~[TAG_WILL] ~Save~[TAG_LEVEL_BONUSES] 1 @t+0 @t+2 @t+0 @t+2 2 @t+1 @t+3 @t+0 @t+3 3 @t+2 @t+3 @t+1 @t+3 4 @t+3 @t+4 @t+1 @t+4 5 @t+3 @t+4 @t+1 @t+4 6 @t+4 @t+5 @t+2 @t+5 7 @t+5 @t+5 @t+2 @t+5 8 @t+6/+1 @t+6 @t+2 @t+6 9 @t+6/+1 @t+6 @t+3 @t+6 10 @t+7/+2 @t+7 @t+3 @t+7 11 @t+8/+3 @t+7 @t+3 @t+7 12 @t+9/+4 @t+8 @t+4 @t+8 13 @t+9/+4 @t+8 @t+4 @t+8 14 @t+10/+5 @t+9 @t+4 @t+9 15 @t+11/+6/+1 @t+9 @t+5 @t+9 16 @t+12/+7/+2 @t+10 @t+5 @t+10 17 @t+12/+7/+2 @t+10 @t+5 @t+10 18 @t+13/+8/+3 @t+11 @t+6 @t+11 19 @t+14/+9/+4 @t+11 @t+6 @t+11 20 @t+15/+10/+5 @t+12 @t+6 @t+12 +TAG_CLASS_FEATURES_MARSHAL_AURAS TAG_MARSHALS Marshal Auras The marshal exerts an effect on allies in his vicinity. He can learn to produce different effects, or auras, over the course of his career. The marshal may project one minor aura and (starting at 2nd level) one major aura at a time. Projecting an aura is a swift action. The aura remains in effect until the marshal uses a free action to dismiss it or activates another aura of the same kind (major or minor). A marshal can have an aura active continually; thus, an aura can be in effect at the start of a combat encounter even before the marshal takes his first turn. Activating an aura involves haranguing, ordering, directing, encouraging, cajoling, or calming allies. A marshal sizes up the enemy, allies, and the terrain, then gives allies the direction that they can use to do their best. Unless otherwise noted, a marshal's aura affects all allies within 60 feet (including himself) who can hear the marshal. An ally must have an Intelligence score of 3 or higher and be able to understand the marshal's language to gain the bonus. A marshal's aura is dismissed if he is dazed, unconscious, stunned, paralyzed, or otherwise unable to be heard or understood by his allies. A marshal begins play knowing one minor aura of his choice. As his marshal level increases, he gains access to new auras, as indicated on Table 1-5: The Marshal. All bonuses granted by a marshal's auras are circumstance bonuses that do not stack with each other. Minor Auras: A minor aura lets allies add the marshal's Charisma bonus (if any) to certain rolls. ~Minor Aura List~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS][CMD_CHILDREN_SORTED] Major Auras: Beginning at 2nd level, a marshal can project a major aura in addition to his minor aura. A major aura lets allies add +1 to certain rolls. This bonus improves by +1 at 7th, 14th, and 20th level. ~Major Aura List~[TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS][CMD_CHILDREN_SORTED] +TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS TAG_MARSHALS Minor Auras A minor aura lets allies add the marshal's Charisma bonus (if any) to certain rolls. Minor Aura List [CMD_CHILDREN_SORTED] +TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS TAG_MARSHALS Major Auras Beginning at 2nd level, a marshal can project a major aura in addition to his minor aura. A major aura lets allies add +1 to certain rolls. This bonus improves by +1 at 7th, 14th, and 20th level. Major Aura List [CMD_CHILDREN_SORTED] +TAG_CLASS_FEATURES_MARSHAL_SKILL_FOCUS TAG_MARSHALS Skill Focus(Diplomacy) Because a marshal has a way with people, he gains this feat as a bonus feat. If the marshal already has the feat, he can choose a different one. +TAG_CLASS_FEATURES_MARSHAL_ADRENALINE_BOOST TAG_MARSHALS Adrenaline Boost Starting at 4th level, you can exhort your allies to discover a reservoir of energy they didn't think they had. Once per day, as a standard action, you can grant temporary hit points equal to your marshal level to any or all of your allies within 30 feet (but not to yourself). If the ally's current hit point total is no more than half his full normal hit points, the number of temporary hit points granted to that character is doubled (to twice your marshal level). This ability only affects allies with an Intelligence score of 3 or higher who can hear you and understand your language. The temporary hit points last for up to 1 minute per marshal level. At 8th level, you can use this ability twice per day. You can use it three times per day at 12th level, four times per day at 16th level, and five times per day at 20th level. If you use this ability on a creature that is still under the effect of a previous use, the new temporary hit points overlap (do not stack with) the temporary hit points the creature had remaining. +TAG_AURA_ACCURATE_STRIKE TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Accurate Strike ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on rolls made to confirm critical hits. +TAG_AURA_ART_OF_WAR TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Art of War ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on disarm, trip, bull rush, and sunder attempts. +TAG_AURA_DEMAND_FORTITUDE TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Demand Fortitude ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Fortitude saves. +TAG_AURA_DETERMINED_CASTER TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Determined Caster ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on rolls to overcome spell resistance. +TAG_AURA_FORCE_OF_WILL TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Force of Will ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Will saves. +TAG_AURA_MASTER_OF_OPPORTUNITY TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Master of Opportunity ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] to Armor Class against attacks of opportunity. +TAG_AURA_MASTER_OF_TACTICS TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Master of Tactics ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on damage rolls when flanking. +TAG_AURA_MOTIVATE_CHARISMA TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Motivate Charisma ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Charisma checks and Charisma-based skill checks. +TAG_AURA_MOTIVATE_CONSTITUTION TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Motivate Constitution ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Constitution checks and Constitution-based skill checks. +TAG_AURA_MOTIVATE_DEXTERITY TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Motivate Dexterity ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Dexterity checks and Dexterity-based skill checks. +TAG_AURA_MOTIVATE_INTELLIGENCE TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Motivate Intelligence ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Intelligence checks and Intelligence-based skill checks. +TAG_AURA_MOTIVATE_STRENGTH TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Motivate Strength ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Strength checks and Strength-based skill checks. +TAG_AURA_MOTIVATE_WISDOM TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Motivate Wisdom ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Wisdom checks and Wisdom-based skill checks. +TAG_AURA_OVER_THE_TOP TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Over the Top ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on damage rolls when charging. +TAG_AURA_WATCHFUL EYE TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS Watchful Eye ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS] on Reflex saves. +TAG_AURA_HARDY_SOLDIERS TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS Hardy Soldiers The marshal's allies gain damage reduction equal to the amount of ~bonus~[TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS] the aura provides. For example, if the marshal is 10th level, everyone affected gains DR 2/-. +TAG_AURA_MOTIVATE_ARDOR TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS Motivate Ardor ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS] on damage rolls. +TAG_AURA_MOTIVATE_ATTACK TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS Motivate Attack ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS] on melee attack rolls. +TAG_AURA_MOTIVATE_CARE TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS Motivate Care ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS] to Armor Class. +TAG_AURA_MOTIVATE_URGENCY TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS Motivate Urgency Allies' base land speed is increased by a number of feet equal to 5 x the amount of ~bonus~[TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS] the aura provides. For example, the allies of a 10th-level marshal (+2 major aura) add 10 feet to their base land speed. +TAG_AURA_RESILIENT_TROOPS TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS Resilient Troops ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS] on all saves. +TAG_AURA_STEADY_HAND TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS Steady Hand ~Aura Bonus~[TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS] on ranged attack rolls. diff --git a/tpdatasrc/tpgamefiles/mes/spell_ext/aura_spells.mes b/tpdatasrc/tpgamefiles/mes/spell_ext/aura_spells.mes new file mode 100644 index 000000000..1f9405169 --- /dev/null +++ b/tpdatasrc/tpgamefiles/mes/spell_ext/aura_spells.mes @@ -0,0 +1,6 @@ +// Spell Enums for Draconic + Marshal Auras +{3831}{Marshal Minor Aura} +{3832}{Marshal Major Aura} +{3833}{Marshal Adrenaline Boost} +{3840}{Draconic Aura} +{3841}{Double Draconic Aura} diff --git a/tpdatasrc/tpgamefiles/mes/stat_ext.mes b/tpdatasrc/tpgamefiles/mes/stat_ext.mes index 71e43bbf3..6755f16a2 100644 --- a/tpdatasrc/tpgamefiles/mes/stat_ext.mes +++ b/tpdatasrc/tpgamefiles/mes/stat_ext.mes @@ -65,6 +65,9 @@ // {82}{Fochlucan Lyrist} +{83}{Marshal} +{84}{Dragon Shaman} +{85}{Dragonheart Mage} {300}{Psi Points} // max {301}{Psi Points} // cur @@ -137,6 +140,9 @@ {1080}{Rkvn} {1081}{Ssnj} {1082}{Foch} +{1083}{Mrshl} +{1084}{DrgSh} +{1085}{DrgHrt} @@ -323,6 +329,15 @@ Bardic knowledge, Speak Druidic, Evasion. Spells: 1st-level arcane and divine spells. Decipher Script 7, Diplomacy 7, Gather Information 7, Perform 13, Sleight of Hand 7 } +{13076}Marshal{Sometimes it is not enough to be a conquering warrior, a champion of all that's right, an experienced sellsword, or an elite foot soldier. Sometimes the circumstances require a solid commander of soldiers and situations. Sometimes the circumstances demand a marshal.} +{13077}Dragon Shaman{Dragon Shamans TBD!} +{13078}Dragonheart Mage{Dragonheart Mage TBD! + +Requirements +Spellcasting: Ability to spontaneously cast arcance spells. +Skills: Knowledge (arcana) 8 +Feats: Draconic Heritage +} // Cannot Pick Class Short Help Goes in the range of 20007+ {20007} Arcane Archer{Arcane Archer requirements: diff --git a/tpdatasrc/tpgamefiles/rules/char_class/class083_marshal.py b/tpdatasrc/tpgamefiles/rules/char_class/class083_marshal.py new file mode 100644 index 000000000..22880b52b --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/char_class/class083_marshal.py @@ -0,0 +1,76 @@ +from toee import * +import char_class_utils +import char_editor +################################################### + +def GetConditionName(): # used by API + return "Marshal" + +def GetCategory(): + return "Miniatures Handbook Base Classes" + +def GetClassDefinitionFlags(): + return CDF_BaseClass + +def GetClassHelpTopic(): + return "TAG_MARSHALS" + +classEnum = stat_level_marshal + +################################################### + +class_feats = { + +1: (feat_armor_proficiency_light, feat_armor_proficiency_medium, feat_armor_proficiency_heavy, feat_shield_proficiency, feat_simple_weapon_proficiency, +feat_martial_weapon_proficiency_all, feat_skill_focus_diplomacy, "Marshal Minor Auras"), +2: ("Marshal Major Auras",), +4: ("Marshal Adrenaline Boost",) +} + +class_skills = (skill_bluff, skill_diplomacy, skill_handle_animal, skill_intimidate, skill_knowledge_all, skill_listen, skill_perform, skill_ride, skill_sense_motive, skill_spot, skill_wilderness_lore, skill_swim) + +def IsEnabled(): + return 1 + +def GetHitDieType(): + return 8 + +def GetSkillPtsPerLevel(): + return 4 + +def GetBabProgression(): + return base_attack_bonus_type_semi_martial + +def IsFortSaveFavored(): + return 1 + +def IsRefSaveFavored(): + return 0 + +def IsWillSaveFavored(): + return 1 + +def GetSpellListType(): + return spell_list_type_none + +def IsClassSkill(skillEnum): + return char_class_utils.IsClassSkill(class_skills, skillEnum) + +def IsClassFeat(featEnum): + return char_class_utils.IsClassFeat(class_feats, featEnum) + +def GetClassFeats(): + return class_feats + +def IsAlignmentCompatible(alignment): + return 1 + +def ObjMeetsPrereqs(obj): + return 1 + +def GetDeityClass(): + return stat_level_fighter + + ## Levelup +def LevelupSpellsFinalize( obj, classLvlNew = -1 ): + return 0 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/d20_actions/action08301_marshal_activate_minor_aura.py b/tpdatasrc/tpgamefiles/rules/d20_actions/action08301_marshal_activate_minor_aura.py new file mode 100644 index 000000000..64ca13c10 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/d20_actions/action08301_marshal_activate_minor_aura.py @@ -0,0 +1,18 @@ +from toee import * +import tpactions + +def GetActionName(): + return "Activate Marshal Minor Aura" + +def GetActionDefinitionFlags(): + return D20ADF_MagicEffectTargeting + +def GetTargetingClassification(): + return D20TC_CastSpell + +def GetActionCostType(): + return D20ACT_Swift_Action + +def AddToSequence(d20action, action_seq, tb_status): + action_seq.add_action(d20action) + return AEC_OK \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/d20_actions/action08302_marshal_activate_major_aura.py b/tpdatasrc/tpgamefiles/rules/d20_actions/action08302_marshal_activate_major_aura.py new file mode 100644 index 000000000..a7716a9bc --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/d20_actions/action08302_marshal_activate_major_aura.py @@ -0,0 +1,18 @@ +from toee import * +import tpactions + +def GetActionName(): + return "Activate Marshal Major Aura" + +def GetActionDefinitionFlags(): + return D20ADF_MagicEffectTargeting + +def GetTargetingClassification(): + return D20TC_CastSpell + +def GetActionCostType(): + return D20ACT_Swift_Action + +def AddToSequence(d20action, action_seq, tb_status): + action_seq.add_action(d20action) + return AEC_OK \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/d20_actions/action08303_marshal_dismiss_minor_aura.py b/tpdatasrc/tpgamefiles/rules/d20_actions/action08303_marshal_dismiss_minor_aura.py new file mode 100644 index 000000000..7f9194f75 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/d20_actions/action08303_marshal_dismiss_minor_aura.py @@ -0,0 +1,18 @@ +from toee import * +import tpactions + +def GetActionName(): + return "Dismiss Marshal Minor Aura" + +def GetActionDefinitionFlags(): + return D20ADF_None + +def GetTargetingClassification(): + return D20TC_Target0 + +def GetActionCostType(): + return D20ACT_NULL + +def AddToSequence(d20action, action_seq, tb_status): + action_seq.add_action(d20action) + return AEC_OK \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/d20_actions/action08304_marshal_dismiss_major_aura.py b/tpdatasrc/tpgamefiles/rules/d20_actions/action08304_marshal_dismiss_major_aura.py new file mode 100644 index 000000000..1cae17a29 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/d20_actions/action08304_marshal_dismiss_major_aura.py @@ -0,0 +1,18 @@ +from toee import * +import tpactions + +def GetActionName(): + return "Dismiss Marshal Major Aura" + +def GetActionDefinitionFlags(): + return D20ADF_None + +def GetTargetingClassification(): + return D20TC_Target0 + +def GetActionCostType(): + return D20ACT_NULL + +def AddToSequence(d20action, action_seq, tb_status): + action_seq.add_action(d20action) + return AEC_OK \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/d20_actions/action08305_marshal_adrenaline_boost.py b/tpdatasrc/tpgamefiles/rules/d20_actions/action08305_marshal_adrenaline_boost.py new file mode 100644 index 000000000..0ee4b2685 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/d20_actions/action08305_marshal_adrenaline_boost.py @@ -0,0 +1,18 @@ +from toee import * +import tpactions + +def GetActionName(): + return "Marshal Adrenaline Boost" + +def GetActionDefinitionFlags(): + return D20ADF_MagicEffectTargeting + +def GetTargetingClassification(): + return D20TC_CastSpell + +def GetActionCostType(): + return D20ACT_Standard_Action + +def AddToSequence(d20action, action_seq, tb_status): + action_seq.add_action(d20action) + return AEC_OK \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/d20_actions/action08311_marshal_learn_minor_aura.py b/tpdatasrc/tpgamefiles/rules/d20_actions/action08311_marshal_learn_minor_aura.py new file mode 100644 index 000000000..343f83251 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/d20_actions/action08311_marshal_learn_minor_aura.py @@ -0,0 +1,18 @@ +from toee import * +import tpactions + +def GetActionName(): + return "Marshal Learn Minor Aura" + +def GetActionDefinitionFlags(): + return D20ADF_None + +def GetTargetingClassification(): + return D20TC_Target0 + +def GetActionCostType(): + return D20ACT_NULL + +def AddToSequence(d20action, action_seq, tb_status): + action_seq.add_action(d20action) + return AEC_OK \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/d20_actions/action08312_marshal_learn_major_aura.py b/tpdatasrc/tpgamefiles/rules/d20_actions/action08312_marshal_learn_major_aura.py new file mode 100644 index 000000000..cc525e0ea --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/d20_actions/action08312_marshal_learn_major_aura.py @@ -0,0 +1,18 @@ +from toee import * +import tpactions + +def GetActionName(): + return "Marshal Learn Major Aura" + +def GetActionDefinitionFlags(): + return D20ADF_None + +def GetTargetingClassification(): + return D20TC_Target0 + +def GetActionCostType(): + return D20ACT_NULL + +def AddToSequence(d20action, action_seq, tb_status): + action_seq.add_action(d20action) + return AEC_OK \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/major aura hardy soldiers.txt b/tpdatasrc/tpgamefiles/rules/feats/major aura hardy soldiers.txt new file mode 100644 index 000000000..d8a7bd3d8 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/major aura hardy soldiers.txt @@ -0,0 +1,5 @@ +name: Major Aura Hardy Soldiers +flags: 8 +prereqs: +description: The marshal's allies gain damage reduction equal to the amount of bonus the aura provides. For example, if the marshal is 10th level, everyone affected gains DR 2/-. +prereq descr: Marshal 2 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/major aura motivate ardor.txt b/tpdatasrc/tpgamefiles/rules/feats/major aura motivate ardor.txt new file mode 100644 index 000000000..4dddce96f --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/major aura motivate ardor.txt @@ -0,0 +1,5 @@ +name: Major Aura Motivate Ardor +flags: 8 +prereqs: +description: Bonus on damage rolls. +prereq descr: Marshal 2 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/major aura motivate attack.txt b/tpdatasrc/tpgamefiles/rules/feats/major aura motivate attack.txt new file mode 100644 index 000000000..45205fe00 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/major aura motivate attack.txt @@ -0,0 +1,5 @@ +name: Major Aura Motivate Attack +flags: 8 +prereqs: +description: Bonus on melee attack rolls. +prereq descr: Marshal 2 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/major aura motivate care.txt b/tpdatasrc/tpgamefiles/rules/feats/major aura motivate care.txt new file mode 100644 index 000000000..9a75ce91f --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/major aura motivate care.txt @@ -0,0 +1,5 @@ +name: Major Aura Motivate Care +flags: 8 +prereqs: +description: Bonus to Armor Class. +prereq descr: Marshal 2 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/major aura motivate urgency.txt b/tpdatasrc/tpgamefiles/rules/feats/major aura motivate urgency.txt new file mode 100644 index 000000000..6fe246081 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/major aura motivate urgency.txt @@ -0,0 +1,5 @@ +name: Major Aura Motivate Urgency +flags: 8 +prereqs: +description: Allies' base land speed is increased by a number of feet equal to 5 x the amount of bonus the aura provides. For example, the allies of a 10th-level marshal (+2 major aura) add 10 feet to their base land speed. +prereq descr: Marshal 2 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/major aura resilient troops.txt b/tpdatasrc/tpgamefiles/rules/feats/major aura resilient troops.txt new file mode 100644 index 000000000..072a60b31 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/major aura resilient troops.txt @@ -0,0 +1,5 @@ +name: Major Aura Resilient Troops +flags: 8 +prereqs: +description: Bonus on all saves. +prereq descr: Marshal 2 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/major aura steady hand.txt b/tpdatasrc/tpgamefiles/rules/feats/major aura steady hand.txt new file mode 100644 index 000000000..fe6a48f63 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/major aura steady hand.txt @@ -0,0 +1,5 @@ +name: Major Aura Steady Hand +flags: 8 +prereqs: +description: Bonus on ranged attack rolls. +prereq descr: Marshal 2 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/marshal adrenaline boost.txt b/tpdatasrc/tpgamefiles/rules/feats/marshal adrenaline boost.txt new file mode 100644 index 000000000..4bc375d5a --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/marshal adrenaline boost.txt @@ -0,0 +1,5 @@ +name: Marshal Adrenaline Boost +flags: 8 +prereqs: +description: Grant Temporary Hit Points to Allies +prereq descr: Marshal 4 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/marshal major auras.txt b/tpdatasrc/tpgamefiles/rules/feats/marshal major auras.txt new file mode 100644 index 000000000..c07e4ce3a --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/marshal major auras.txt @@ -0,0 +1,5 @@ +name: Marshal Major Auras +flags: 8 +prereqs: +description: Beginning at 2nd level, a marshal can project a major aura in addition to his minor aura. A major aura lets allies add +1 to certain rolls. This bonus improves by +1 at 7th, 14th, and 20th level. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/marshal minor auras.txt b/tpdatasrc/tpgamefiles/rules/feats/marshal minor auras.txt new file mode 100644 index 000000000..894424b51 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/marshal minor auras.txt @@ -0,0 +1,5 @@ +name: Marshal Minor Auras +flags: 8 +prereqs: +description: Marshal Minor Auras grant a bonus equal to the Charisma Modifier of the Marshal. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura accurate strike.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura accurate strike.txt new file mode 100644 index 000000000..385358a0b --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura accurate strike.txt @@ -0,0 +1,5 @@ +name: Minor Aura Accurate Strike +flags: 8 +prereqs: +description: Minor Aura Accurate Strike adds the Marshal's Charisma bonus (if any) to rolls made to confirm critical hits. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura art of war.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura art of war.txt new file mode 100644 index 000000000..9398b7c7d --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura art of war.txt @@ -0,0 +1,5 @@ +name: Minor Aura Art of War +flags: 8 +prereqs: +description: Bonus on disarm, trip, bull rush, and sunder attempts. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura demand fortitude.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura demand fortitude.txt new file mode 100644 index 000000000..d88ce456a --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura demand fortitude.txt @@ -0,0 +1,5 @@ +name: Minor Aura Demand Fortitude +flags: 8 +prereqs: +description: Bonus on Fortitude saves. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura determined caster.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura determined caster.txt new file mode 100644 index 000000000..292a78fa9 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura determined caster.txt @@ -0,0 +1,5 @@ +name: Minor Aura Determined Caster +flags: 8 +prereqs: +description: Bonus on rolls to overcome spell resistance. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura force of will.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura force of will.txt new file mode 100644 index 000000000..7f3e742b4 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura force of will.txt @@ -0,0 +1,5 @@ +name: Minor Aura Force of Will +flags: 8 +prereqs: +description: Bonus on Will saves. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura master of opportunity.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura master of opportunity.txt new file mode 100644 index 000000000..7d81adc7b --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura master of opportunity.txt @@ -0,0 +1,5 @@ +name: Minor Aura Master of Opportunity +flags: 8 +prereqs: +description: Bonus to Armor Class against attacks of opportunity. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura master of tactics.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura master of tactics.txt new file mode 100644 index 000000000..785814b2a --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura master of tactics.txt @@ -0,0 +1,5 @@ +name: Minor Aura Master of Tactics +flags: 8 +prereqs: +description: Lets allies add the Marshal's Charisma bonus damage rolls when flanking. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate charisma.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate charisma.txt new file mode 100644 index 000000000..d3a15cc1b --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate charisma.txt @@ -0,0 +1,5 @@ +name: Minor Aura Motivate Charisma +flags: 8 +prereqs: +description: Bonus on Charisma checks and Charisma-based skill checks. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate constitution.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate constitution.txt new file mode 100644 index 000000000..192f8fe52 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate constitution.txt @@ -0,0 +1,5 @@ +name: Minor Aura Motivate Constitution +flags: 8 +prereqs: +description: Bonus on Constitution checks and Constitution-based skill checks. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate dexterity.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate dexterity.txt new file mode 100644 index 000000000..89bc018d8 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate dexterity.txt @@ -0,0 +1,5 @@ +name: Minor Aura Motivate Dexterity +flags: 8 +prereqs: +description: Bonus on Dexterity checks, Dexterity-based skill checks, and initiative checks. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate intelligence.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate intelligence.txt new file mode 100644 index 000000000..397783336 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate intelligence.txt @@ -0,0 +1,5 @@ +name: Minor Aura Motivate Intelligence +flags: 8 +prereqs: +description: Bonus on Intelligence checks and Intelligence-based skill checks. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate strength.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate strength.txt new file mode 100644 index 000000000..1d6b8bd37 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate strength.txt @@ -0,0 +1,5 @@ +name: Minor Aura Motivate Strength +flags: 8 +prereqs: +description: Bonus on Strength checks and Strength-based skill checks. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate wisdom.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate wisdom.txt new file mode 100644 index 000000000..52461f6e9 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura motivate wisdom.txt @@ -0,0 +1,5 @@ +name: Minor Aura Motivate Wisdom +flags: 8 +prereqs: +description: Bonus on Wisdom checks and Wisdom-based skill checks. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura over the top.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura over the top.txt new file mode 100644 index 000000000..b1a0ea60d --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura over the top.txt @@ -0,0 +1,5 @@ +name: Minor Aura Over the Top +flags: 8 +prereqs: +description: Bonus on damage rolls when charging. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/feats/minor aura watchful eye.txt b/tpdatasrc/tpgamefiles/rules/feats/minor aura watchful eye.txt new file mode 100644 index 000000000..1c8787b6e --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/feats/minor aura watchful eye.txt @@ -0,0 +1,5 @@ +name: Minor Aura Watchful Eye +flags: 8 +prereqs: +description: Bonus on Reflex saves. +prereq descr: Marshal 1 \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/indicators/marshal_adrenaline_boost.txt b/tpdatasrc/tpgamefiles/rules/indicators/marshal_adrenaline_boost.txt new file mode 100644 index 000000000..321d9fd2a --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/indicators/marshal_adrenaline_boost.txt @@ -0,0 +1,5 @@ +ID_string: MARSHAL_ADRENALINE_BOOST +effect_type: 0 +texture_file: art\interface\player_conditions\buffs\spell heroism.tga +help_topic: TAG_CLASS_FEATURES_MARSHAL_ADRENALINE_BOOST +tooltip_base_text: Marshal Adrenaline Boost diff --git a/tpdatasrc/tpgamefiles/rules/indicators/marshal_major_aura.txt b/tpdatasrc/tpgamefiles/rules/indicators/marshal_major_aura.txt new file mode 100644 index 000000000..9ae797036 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/indicators/marshal_major_aura.txt @@ -0,0 +1,5 @@ +ID_string: MARSHAL_MAJOR_AURA +effect_type: 0 +texture_file: art\interface\player_conditions\buffs\spell heroism.tga +help_topic: TAG_CLASS_FEATURES_MARSHAL_MAJOR_AURAS +tooltip_base_text: Marshal Major Aura diff --git a/tpdatasrc/tpgamefiles/rules/indicators/marshal_minor_aura.txt b/tpdatasrc/tpgamefiles/rules/indicators/marshal_minor_aura.txt new file mode 100644 index 000000000..8a2010d74 --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/indicators/marshal_minor_aura.txt @@ -0,0 +1,5 @@ +ID_string: MARSHAL_MINOR_AURA +effect_type: 0 +texture_file: art\interface\player_conditions\buffs\spell aid.tga +help_topic: TAG_CLASS_FEATURES_MARSHAL_MINOR_AURAS +tooltip_base_text: Marshal Minor Aura diff --git a/tpdatasrc/tpgamefiles/rules/spells/3831 - Marshal Minor Aura.txt b/tpdatasrc/tpgamefiles/rules/spells/3831 - Marshal Minor Aura.txt new file mode 100644 index 000000000..cfc17983d --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/spells/3831 - Marshal Minor Aura.txt @@ -0,0 +1,15 @@ +School: None +Casting Time: 1 action +Range: Personal +Saving Throw: None +Spell Resistance: No +Projectile: No +flags_Target: Range +flags_Target: Radius +inc_flags_Target: Self +inc_flags_Target: Other +exc_flags_Target: Dead +exc_flags_Target: Non-critter +mode_Target: Personal +radius_Target: 60 +ai_type: ai_action_defensive \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/spells/3832 - Marshal Major Aura.txt b/tpdatasrc/tpgamefiles/rules/spells/3832 - Marshal Major Aura.txt new file mode 100644 index 000000000..cfc17983d --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/spells/3832 - Marshal Major Aura.txt @@ -0,0 +1,15 @@ +School: None +Casting Time: 1 action +Range: Personal +Saving Throw: None +Spell Resistance: No +Projectile: No +flags_Target: Range +flags_Target: Radius +inc_flags_Target: Self +inc_flags_Target: Other +exc_flags_Target: Dead +exc_flags_Target: Non-critter +mode_Target: Personal +radius_Target: 60 +ai_type: ai_action_defensive \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/rules/spells/3833 - Marshal Adreanline Boost.txt b/tpdatasrc/tpgamefiles/rules/spells/3833 - Marshal Adreanline Boost.txt new file mode 100644 index 000000000..55a55725e --- /dev/null +++ b/tpdatasrc/tpgamefiles/rules/spells/3833 - Marshal Adreanline Boost.txt @@ -0,0 +1,15 @@ +School: None +Casting Time: 1 action +Range: Personal +Saving Throw: None +Spell Resistance: No +Projectile: No +flags_Target: Range +flags_Target: Radius +inc_flags_Target: Other +exc_flags_Target: Dead +exc_flags_Target: Non-critter +exc_flags_Target: Self +mode_Target: Personal +radius_Target: 30 +ai_type: ai_action_defensive \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/scr/Spell3831 - Marshal Minor Aura.py b/tpdatasrc/tpgamefiles/scr/Spell3831 - Marshal Minor Aura.py new file mode 100644 index 000000000..4809d27a6 --- /dev/null +++ b/tpdatasrc/tpgamefiles/scr/Spell3831 - Marshal Minor Aura.py @@ -0,0 +1,38 @@ +from toee import * +import aura_utils + +def OnBeginSpellCast(spell): + print "Marshal Minor Aura OnBeginSpellCast" + print "spell.target_list=", spell.target_list + print "spell.caster=", spell.caster, " caster.level= ", spell.caster_level + +def OnSpellEffect(spell): + print "Marshal Minor Aura OnSpellEffect" + print "spell.target_list=", spell.target_list + print "spell.caster=", spell.caster, " caster.level= ", spell.caster_level + print "spell.id= ", spell.id + + ### Workaround caster level ### + if spell.caster_level < 1: + spell.caster_level = spell.caster.stat_level_get(stat_level_marshal) + + targetsToRemove = [] + spell.duration = 0 + + auraRadius = 60.0 + (spell.caster.radius / 12.0) + auraEventId = spell.caster.object_event_append(OLC_CRITTERS, auraRadius) + auraEnum = spell.caster.d20_query_with_data("PQ_Activated_Aura", spell.id, 0) + spell.caster.condition_add_with_args("sp-Marshal Minor Aura", spell.id, auraEnum, auraEventId, aura_type_minor, 0) + auraName = aura_utils.getAuraName(auraEnum) + for spellTarget in spell.target_list: + if spellTarget.obj.is_friendly(spell.caster) and aura_utils.verifyTarget(spellTarget.obj): + spellTarget.obj.condition_add_with_args("Marshal Minor Aura {}".format(auraName), spell.id, auraEnum, auraEventId, 0, 0) + else: + targetsToRemove.append(spellTarget.obj) + spell.target_list.remove_list(targetsToRemove) + +def OnBeginRound(spell): + print "Marshal Minor Aura OnBeginRound" + +def OnEndSpellCast(spell): + print "Marshal Minor Aura OnEndSpellCast" diff --git a/tpdatasrc/tpgamefiles/scr/Spell3832 - Marshal Major Aura.py b/tpdatasrc/tpgamefiles/scr/Spell3832 - Marshal Major Aura.py new file mode 100644 index 000000000..23f8330f9 --- /dev/null +++ b/tpdatasrc/tpgamefiles/scr/Spell3832 - Marshal Major Aura.py @@ -0,0 +1,38 @@ +from toee import * +import aura_utils + +def OnBeginSpellCast(spell): + print "Marshal Major Aura OnBeginSpellCast" + print "spell.target_list=", spell.target_list + print "spell.caster=", spell.caster, " caster.level= ", spell.caster_level + +def OnSpellEffect(spell): + print "Marshal Major Aura OnSpellEffect" + print "spell.target_list=", spell.target_list + print "spell.caster=", spell.caster, " caster.level= ", spell.caster_level + print "spell.id= ", spell.id + + ### Workaround caster level ### + if spell.caster_level < 1: + spell.caster_level = spell.caster.stat_level_get(stat_level_marshal) + + targetsToRemove = [] + spell.duration = 0 + + auraRadius = 60.0 + (spell.caster.radius / 12.0) + auraEventId = spell.caster.object_event_append(OLC_CRITTERS, auraRadius) + auraEnum = spell.caster.d20_query_with_data("PQ_Activated_Aura", spell.id, 0) + spell.caster.condition_add_with_args("sp-Marshal Major Aura", spell.id, auraEnum, auraEventId, aura_type_major, 0) + auraName = aura_utils.getAuraName(auraEnum) + for spellTarget in spell.target_list: + if spellTarget.obj.is_friendly(spell.caster) and aura_utils.verifyTarget(spellTarget.obj): + spellTarget.obj.condition_add_with_args("Marshal Major Aura {}".format(auraName), spell.id, auraEnum, auraEventId, 0, 0) + else: + targetsToRemove.append(spellTarget.obj) + spell.target_list.remove_list(targetsToRemove) + +def OnBeginRound(spell): + print "Marshal Major Aura OnBeginRound" + +def OnEndSpellCast(spell): + print "Marshal Major Aura OnEndSpellCast" \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/scr/Spell3833 - Marshal Adrenaline Boost.py b/tpdatasrc/tpgamefiles/scr/Spell3833 - Marshal Adrenaline Boost.py new file mode 100644 index 000000000..df8e8b582 --- /dev/null +++ b/tpdatasrc/tpgamefiles/scr/Spell3833 - Marshal Adrenaline Boost.py @@ -0,0 +1,34 @@ +from toee import * +from aura_utils import verifyTarget + +def OnBeginSpellCast(spell): + print "Marshal Adrenaline Boost OnBeginSpellCast" + print "spell.target_list=", spell.target_list + print "spell.caster=", spell.caster, " caster.level= ", spell.caster_level + +def OnSpellEffect(spell): + print "Marshal Adrenaline Boost OnSpellEffect" + print "spell.target_list=", spell.target_list + print "spell.caster=", spell.caster, " caster.level= ", spell.caster_level + + ### Workaround caster level ### + if spell.caster_level < 1: + spell.caster_level = spell.caster.stat_level_get(stat_level_marshal) + + targetsToRemove = [] + spell.duration = 10 * spell.caster_level + + for spellTarget in spell.target_list: + if spellTarget.obj.is_friendly(spell.caster) and verifyTarget(spellTarget.obj): + game.particles('sp-Cure Minor Wounds', spellTarget.obj) + spellTarget.obj.float_text_line("Adrenaline Boost") + spellTarget.obj.condition_add_with_args("sp-Marshal Adrenaline Boost", spell.id, spell.duration, 0, 0) + else: + targetsToRemove.append(spellTarget.obj) + spell.target_list.remove_list(targetsToRemove) + +def OnBeginRound(spell): + print "Marshal Adrenaline Boost OnBeginRound" + +def OnEndSpellCast(spell): + print "Marshal Adrenaline Boost OnEndSpellCast" \ No newline at end of file diff --git a/tpdatasrc/tpgamefiles/scr/aura_utils.py b/tpdatasrc/tpgamefiles/scr/aura_utils.py new file mode 100644 index 000000000..6bea79163 --- /dev/null +++ b/tpdatasrc/tpgamefiles/scr/aura_utils.py @@ -0,0 +1,448 @@ +from templeplus.pymod import PythonModifier +from toee import * +import tpdp +from utilities import * +import tpactions + +########## Python Action Enums ########## +activateMinorAuraEnum = 8301 +activateMajorAuraEnum = 8302 +dismissMinorAuraEnum = 8303 +dismissMajorAuraEnum = 8304 +activateDraconicAuraEnum = 8451 +activateDoubleDraconicAuraEnum = 8452 +dismissDraconicAuraEnum = 8453 +dismissDoubleDraconicAuraEnum = 8454 +######################################### + +def getMinorAuraList(): + minor_auras = [ + aura_accurate_strike, + aura_art_of_war, + aura_Demand_fortitude, + aura_Determined_caster, + aura_force_of_will, + aura_master_of_opportunity, + aura_master_of_tactics, + aura_motivate_charisma, + aura_motivate_constitution, + aura_motivate_dexterity, + aura_motivate_intelligence, + aura_motivate_strength, + aura_motivate_wisdom, + aura_over_the_top, + aura_watchful_eye + ] + return minor_auras + +def getMajorAuraList(): + major_auras = [ + aura_hardy_soldiers, + aura_motivate_ardor, + aura_motivate_attack, + aura_motivate_care, + aura_motivate_urgency, + aura_resilient_troops, + aura_steady_hand + ] + return major_auras + +def getDraconicAuras(): + draconic_auras = [ + aura_energy_shield, + aura_power, + aura_presence, + aura_resistance, + aura_senses, + aura_toughness, + aura_vigor, + aura_break_spell_resistance, + aura_energy, + aura_insight, + aura_resolve, + aura_stamina, + aura_swiftness + ] + return draconic_auras + +def getAuraName(auraEnum): + return game.get_mesline('mes\\auras.mes', auraEnum) + +def getAuraTag(auraEnum): + return game.get_mesline('mes\\auras.mes', (auraEnum + 1000)) + +def getLearnedAuras(attachee, auraType): + learnedAuras = [] + if auraType == aura_type_minor: + auraList = getMinorAuraList() + auraTypeString = "Minor Aura" + elif auraType == aura_type_major: + auraList = getMajorAuraList() + auraTypeString = "Major Aura" + elif auraType == aura_type_draconic or auraType == aura_type_double_draconic: + auraList = getDraconicAuras() + auraTypeString = "Draconic Aura" + for auraEnum in auraList: + auraName = getAuraName(auraEnum) + if attachee.has_feat("{} {}".format(auraTypeString, auraName)): + learnedAuras.append(auraEnum) + return learnedAuras + +def getMinorAuraBonus(auraCaster): + #auraBonus can't be lower than 0 + charismaValue = auraCaster.stat_level_get(stat_charisma) + auraBonus = int((charismaValue -10)/2) + return max(auraBonus, 0) + +def getMajorAuraBonus(auraCasterLevel): + if auraCasterLevel < 7: + return 1 + elif auraCasterLevel < 14: + return 2 + elif auraCasterLevel < 20: + return 3 + return 4 + +def getDraconicAuraBonus(auraCaster): + sorcLevel = auraCaster.stat_level_get(stat_level_sorcerer) + dragonShamanLevel = auraCaster.stat_level_get(stat_level_dragon_shaman) + if sorcLevel: + charLevel = auraCaster.stat_level_get(stat_level) + if charLevel < 7: + sorcBonus = 1 + elif charLevel < 14: + sorcBonus = 2 + elif charLevel < 20: + sorcBonus = 3 + else: + sorcBonus = 4 + else: + sorcBonus = 0 + if dragonShamanLevel: + dragonShamanBonus = 1 + (dragonShamanLevel / 5) + else: + dragonShamanBonus = 0 + return max(sorcBonus, dragonShamanBonus) + +def getAuraTypeString(auraType): + if auraType == aura_type_minor: + return "Marshal Minor Aura" + elif auraType == aura_type_major: + return "Marshal Major Aura" + elif auraType == aura_type_draconic or auraType == aura_type_double_draconic: + return "Draconic Aura" + return 0 + +def auraAddBonusList(attachee, args, evt_obj): + auraType = args.get_param(0) + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraEnum = args.get_arg(1) + auraName = getAuraName(auraEnum) + auraTag = getAuraTag(auraEnum) + auraTypeString = getAuraTypeString(auraType) + if auraType == aura_type_minor: + auraBonus = getMinorAuraBonus(auraSpellPacket.caster) + auraBonusType = 21 #ID 21 = Circumstance Bonus + elif auraType == aura_type_major: + auraBonus = getMajorAuraBonus(auraSpellPacket.caster) + auraBonusType = 21 #ID 21 = Circumstance Bonus + elif auraType == aura_type_draconic or auraType == aura_type_double_draconic: + auraBonus = getDraconicAuraBonus(auraSpellPacket.caster) + auraBonusType = 190 # new ID for Draconic Auras + evt_obj.bonus_list.add(auraBonus, auraBonusType, "~{}: {}~[{}]".format(auraTypeString, auraName, auraTag)) + return 0 + +def getTargetsInAura(auraSpellPacket): + targetCount = auraSpellPacket.target_count + targetList = [] + counter = 0 + for counter in range(0, targetCount): + target = auraSpellPacket.get_target(counter) + targetList.append(target) + counter += 1 + return targetList + +# Marshal Targets are not automatically affected and need to be checked +def verifyTarget(auraTarget): + if auraTarget.stat_level_get(stat_intelligence) < 3: + return False + elif auraTarget.d20_query(Q_Critter_Is_Deafened): + return False + return True + +##### class AuraModifier ##### +def onLeaveAura(attachee, args, evt_obj): + auraSpellPacket = tpdp.SpellPacket(args.get_arg(0)) + auraEventId = args.get_arg(2) + if auraEventId != evt_obj.evt_id: + return 0 + args.remove_spell_mod() + return 0 + +def auraEndSignal(attachee, args, evt_obj): + signalId = evt_obj.data1 + spellId = args.get_arg(0) + if signalId == spellId: + args.remove_spell_mod() + return 0 + +def onAuraConditionRemove(attachee, args, evt_obj): + auraSpellPacket = tpdp.SpellPacket(args.get_arg(0)) + auraSpellPacket.remove_target(attachee) + return 0 + +def auraTooltip(attachee, args, evt_obj): + auraEnum = args.get_arg(1) + auraName = getAuraName(auraEnum) + if auraEnum in getMinorAuraList(): + evt_obj.append("Minor Aura: {}".format(auraName)) + elif auraEnum in getMajorAuraList(): + evt_obj.append("Major Aura: {}".format(auraName)) + else: + evt_obj.append("Draconic Aura: {}".format(auraName)) + return 0 + +def auraEffectTooltip(attachee, args, evt_obj): + #ToDo: Customize EffectToolTip icons and text + auraEnum = args.get_arg(1) + auraName = getAuraName(auraEnum) + if auraEnum in getMinorAuraList(): + evt_obj.append(tpdp.hash("MARSHAL_MINOR_AURA"), -2, " ({})".format(auraName)) + elif auraEnum in getMajorAuraList(): + evt_obj.append(tpdp.hash("MARSHAL_MAJOR_AURA"), -2, " ({})".format(auraName)) + else: + evt_obj.append(tpdp.hash("DRACONIC_AURA"), -2, " ({})".format(auraName)) + return 0 + +def auraAddPreActions(attachee, args, evt_obj): + #ToDo: Add Deafen and inteligence drop remove + return 0 + +class AuraModifier(PythonModifier): + # AuraModifier have 5 arguments: + # 0: auraSpellId, 1: auraEnum, 2: auraEventId, 3 + 4: empty + def __init__(self, name): + PythonModifier.__init__(self, name, 5, True) + self.AddHook(ET_OnObjectEvent, EK_OnLeaveAoE, onLeaveAura, ()) + self.AddHook(ET_OnD20Signal, EK_S_Spell_End, auraEndSignal, ()) + self.AddHook(ET_OnGetTooltip, EK_NONE, auraTooltip, ()) + self.AddHook(ET_OnGetEffectTooltip, EK_NONE, auraEffectTooltip, ()) + self.AddHook(ET_OnConditionRemove, EK_NONE, onAuraConditionRemove, ()) + self.AddSpellTeleportPrepareStandard() + self.AddSpellTeleportReconnectStandard() + + def marshalAuraAddPreActions(self): + self.AddHook(ET_OnConditionAddPre, EK_NONE, auraAddPreActions, ()) + + def addSkillBonus(self, auraType, *args): + for skill in args: + eventKey = skill + 20 + self.AddHook(ET_OnGetSkillLevel, eventKey, auraAddBonusList, (auraType,)) + +##### class AuraAoeHandlingModifier ##### +def onEnterAoeAura(attachee, args, evt_obj): + auraEventId = args.get_arg(2) + if auraEventId != evt_obj.evt_id: + return 0 + auraType = args.get_arg(3) + auraTypeString = getAuraTypeString(auraType) + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraTarget = evt_obj.target + if auraTarget.is_friendly(attachee): + if auraType > aura_type_major or verifyTarget(auraTarget): + if auraSpellPacket.add_target(auraTarget, 0): + auraEnum = args.get_arg(1) + auraName = getAuraName(auraEnum) + auraTarget.condition_add_with_args("{} {}".format(auraTypeString, auraName), auraSpellId, auraEnum, auraEventId, 0, 0) + return 0 + +def aoeHandlerSignalEnd(attachee, args, evt_obj): + spellId = args.get_arg(0) + signalId = evt_obj.data1 + if spellId == signalId: + spellPacket = tpdp.SpellPacket(spellId) + targetList = getTargetsInAura(spellPacket) + for target in targetList: + if target == OBJ_HANDLE_NULL: + break + target.d20_send_signal(S_Spell_End, spellId, 0) + args.remove_spell() + return 0 + +class AuraAoeHandlingModifier(PythonModifier): + # AuraModifier have 5 arguments: + # 0: spellId, 1: activeAura, 2: auraEventId, 3: auraType, 4: empty + def __init__(self, name): + PythonModifier.__init__(self, name, 5, True) + self.AddHook(ET_OnObjectEvent, EK_OnEnterAoE, onEnterAoeAura, ()) + self.AddHook(ET_OnD20PythonSignal, "PS_Aura_End", aoeHandlerSignalEnd, ()) + self.AddSpellTeleportPrepareStandard() + self.AddSpellTeleportReconnectStandard() + self.AddAoESpellEndStandardHook() + +##### class auraRadialModifier ##### +##### used by Marshal Class for both Minor and Major Aura ##### +##### and by the Draconic Aura Feats ##### +def getAuraSpellEnum(auraType): + if auraType == aura_type_minor: + return spell_marshal_minor_aura + elif auraType == aura_type_major: + return spell_marshal_major_aura + elif auraType == aura_type_draconic: + return spell_draconic_aura + elif auraType == aura_type_double_draconic: + return spell_double_draconic_aura + return 0 + +def getPythonEnum(auraType): + if auraType == aura_type_minor: + return activateMinorAuraEnum + elif auraType == aura_type_major: + return activateMajorAuraEnum + elif auraType == aura_type_draconic: + return activateDraconicAuraEnum + elif auraType == aura_type_double_draconic: + return activateDoubleDraconicAuraEnum + return 0 + +def radialAura(attachee, args, evt_obj): + #auraType = args.get_param(0) + auraType = args.get_arg(1) + learnedAuras = getLearnedAuras(attachee, auraType) + spellClass = stat_level_sorcerer if auraType == aura_type_draconic else stat_level_marshal + if not learnedAuras: + return 0 + #Add the top level menu + auraTypeString = getAuraTypeString(auraType) + pythonEnum = getPythonEnum(auraType) + pythonDismissEnum = pythonEnum + 2 + auraSpellEnum = getAuraSpellEnum(auraType) + radialAuraTop = tpdp.RadialMenuEntryParent(auraTypeString) + if auraType == aura_type_draconic and attachee.stat_level_get(stat_level_dragon_shaman) < 1: + radialAuraTopId = radialAuraTop.add_child_to_standard(attachee, tpdp.RadialMenuStandardNode.Feats) + elif auraType == aura_type_double_draconic: + radialAuraTopId = radialAuraTop.add_child_to_standard(attachee, tpdp.RadialMenuStandardNode.Feats) + else: + radialAuraTopId = radialAuraTop.add_child_to_standard(attachee, tpdp.RadialMenuStandardNode.Class) + #Add aura childs + for auraEnum in learnedAuras: + auraName = getAuraName(auraEnum) + auraTag = getAuraTag(auraEnum) + auraRadialId = tpdp.RadialMenuEntryPythonAction(auraName, D20A_PYTHON_ACTION, pythonEnum, auraEnum, auraTag) + spellData = tpdp.D20SpellData(auraSpellEnum) + casterLevel = attachee.stat_level_get(spellClass) + spellData.set_spell_class(spellClass) + spellData.set_spell_level(casterLevel) + auraRadialId.set_spell_data(spellData) + auraRadialId.add_as_child(attachee, radialAuraTopId) + #Add Dismiss Radial + activeAura = args.get_arg(3) + if activeAura: + activeAuraName = getAuraName(activeAura) + dismissAuraId = tpdp.RadialMenuEntryPythonAction("Dismiss {}".format(activeAuraName), D20A_PYTHON_ACTION, pythonDismissEnum, activeAura, auraTag) + if auraType == aura_type_draconic and attachee.stat_level_get(stat_level_dragon_shaman) < 1: + dismissAuraId.add_child_to_standard(attachee, tpdp.RadialMenuStandardNode.Feats) + elif auraType == aura_type_double_draconic: + dismissAuraId.add_child_to_standard(attachee, tpdp.RadialMenuStandardNode.Feats) + else: + dismissAuraId.add_child_to_standard(attachee, tpdp.RadialMenuStandardNode.Class) + return 0 + +def activateAura(attachee, args, evt_obj): + # check if toggle needs to deactivate an already active Aura first + oldSpellId = args.get_arg(2) + if oldSpellId: + attachee.d20_send_signal("PS_Aura_End", oldSpellId) + args.set_arg(2, 0) + args.set_arg(3, 0) + # activate new Aura + auraEnum = evt_obj.d20a.data1 + currentSequence = tpactions.get_cur_seq() + spellPacket = currentSequence.spell_packet + newSpellId = tpactions.get_new_spell_id() + args.set_arg(2, newSpellId) + args.set_arg(3, auraEnum) + tpactions.register_spell_cast(spellPacket, newSpellId) + tpactions.trigger_spell_effect(newSpellId) + auraName = getAuraName(auraEnum) + auraTag = getAuraTag(auraEnum) + attachee.float_text_line("{} activated".format(auraName)) + game.create_history_freeform("{} activates ~{}~[{}]\n\n".format(attachee.description, auraName, auraTag)) + return 0 + +def queryActivatedAura(attachee, args, evt_obj): + spellId = args.get_arg(2) + signalId = evt_obj.data1 + if spellId == signalId: + evt_obj.return_val = args.get_arg(3) + return 0 + +def dismissAura(attachee, args, evt_obj): + if args.get_arg(3): + attachee.d20_send_signal("PS_Aura_End", args.get_arg(2), 0) + #attachee.d20_send_signal(S_Spell_End, args.get_arg(2)) + args.set_arg(2, 0) + args.set_arg(3, 0) + return 0 + +def checkDeactivateMarshal(attachee, args, evt_obj): + #Deactivate Aura if specific conditions are added + #panicked & fascinated missing + #Basically all conditions that prohibit communication will end the auras + if (evt_obj.is_modifier("Unconscious") + or evt_obj.is_modifier("Dead") + or evt_obj.is_modifier("sp-Silence") + or evt_obj.is_modifier("Held") + or evt_obj.is_modifier("sp-Daze") + or evt_obj.is_modifier("Nauseated Condition") + or evt_obj.is_modifier("Paralyzed") + or evt_obj.is_modifier("Stunned")): + if args.get_arg(3): + attachee.d20_send_signal(S_Spell_End, args.get_arg(2)) + args.set_arg(2, 0) + args.set_arg(3, 0) + return 0 + +def checkDeactivateDraconic(attachee, args, evt_obj): + #Deactivate Aura if attachee is getting Unconscious + if (evt_obj.is_modifier("Unconscious") + or evt_obj.is_modifier("Dead")): + if args.get_arg(3): + attachee.d20_send_signal(S_Spell_End, args.get_arg(2)) + args.set_arg(2, 0) + args.set_arg(3, 0) + return 0 + +class AuraRadialModifier(PythonModifier): + # AuraRadialModifier have 5 arguments: + # 0: featEnum, 1: auraType, 2: spellId, 3: activeAuraEnum 4: empty + # use MapToFeat("[Name]", feat_cond_arg2 = aura_type_minor/major/draconic) + # to set arg2 to the aura the modifier should handle + def __init__(self, name): + PythonModifier.__init__(self, name, 5, True) + self.AddHook(ET_OnBuildRadialMenuEntry, EK_NONE, radialAura, ()) + self.AddHook(ET_OnD20PythonQuery, "PQ_Activated_Aura", queryActivatedAura, ()) + self.AddHook(ET_OnNewDay, EK_NEWDAY_REST, dismissAura, ()) + + # Add aura specific fuction to the Modifier + def marshalMinorAuraActions(self): + self.AddHook(ET_OnConditionAddPre, EK_NONE, checkDeactivateMarshal, ()) + self.AddHook(ET_OnD20PythonActionPerform, activateMinorAuraEnum, activateAura, ()) + self.AddHook(ET_OnD20PythonActionPerform, dismissMinorAuraEnum, dismissAura, ()) + + def marshalMajorAuraActions(self): + self.AddHook(ET_OnConditionAddPre, EK_NONE, checkDeactivateMarshal, ()) + self.AddHook(ET_OnD20PythonActionPerform, activateMajorAuraEnum, activateAura, ()) + self.AddHook(ET_OnD20PythonActionPerform, dismissMajorAuraEnum, dismissAura, ()) + + def draconicAuraActions(self): + self.AddHook(ET_OnConditionAddPre, EK_NONE, checkDeactivateDraconic, ()) + self.AddHook(ET_OnD20PythonActionPerform, activateDraconicAuraEnum, activateAura, ()) + self.AddHook(ET_OnD20PythonActionPerform, dismissDraconicAuraEnum, dismissAura, ()) + + def doubleDraconicAuraActions(self): + self.AddHook(ET_OnConditionAddPre, EK_NONE, checkDeactivateDraconic, ()) + self.AddHook(ET_OnD20PythonActionPerform, activateDoubleDraconicAuraEnum, activateAura, ()) + self.AddHook(ET_OnD20PythonActionPerform, dismissDoubleDraconicAuraEnum, dismissAura, ()) diff --git a/tpdatasrc/tpgamefiles/scr/tpModifiers/marshal.py b/tpdatasrc/tpgamefiles/scr/tpModifiers/marshal.py new file mode 100644 index 000000000..a74e78c66 --- /dev/null +++ b/tpdatasrc/tpgamefiles/scr/tpModifiers/marshal.py @@ -0,0 +1,225 @@ +from templeplus.pymod import PythonModifier +from toee import * +import tpdp +import char_class_utils +import aura_utils +import tpactions + +################################################### + +def GetConditionName(): + return "Marshal" + +print "Registering {}".format(GetConditionName()) + +classEnum = stat_level_marshal +classSpecModule = __import__('class083_marshal') + +################################################### + +########## Python Action ID's ########## +adrenalineBoostEnum = 8305 +learnMinorAuraEnum = 8311 #workaround +learnMajorAuraEnum = 8312 #workaround +######################################## + + +#### standard callbacks - BAB and Save values +def OnGetToHitBonusBase(attachee, args, evt_obj): + classLvl = attachee.stat_level_get(classEnum) + babvalue = game.get_bab_for_class(classEnum, classLvl) + evt_obj.bonus_list.add(babvalue, 0, 137) # untyped, description: "Class" + return 0 + +def OnGetSaveThrowFort(attachee, args, evt_obj): + value = char_class_utils.SavingThrowLevel(classEnum, attachee, D20_Save_Fortitude) + evt_obj.bonus_list.add(value, 0, 137) + return 0 + +def OnGetSaveThrowReflex(attachee, args, evt_obj): + value = char_class_utils.SavingThrowLevel(classEnum, attachee, D20_Save_Reflex) + evt_obj.bonus_list.add(value, 0, 137) + return 0 + +def OnGetSaveThrowWill(attachee, args, evt_obj): + value = char_class_utils.SavingThrowLevel(classEnum, attachee, D20_Save_Will) + evt_obj.bonus_list.add(value, 0, 137) + return 0 + +classSpecObj = PythonModifier(GetConditionName(), 4) #numberMinorAurasLearned, numberMajorAurasLearned, empty, empty +classSpecObj.AddHook(ET_OnToHitBonusBase, EK_NONE, OnGetToHitBonusBase, ()) +classSpecObj.AddHook(ET_OnSaveThrowLevel, EK_SAVE_FORTITUDE, OnGetSaveThrowFort, ()) +classSpecObj.AddHook(ET_OnSaveThrowLevel, EK_SAVE_REFLEX, OnGetSaveThrowReflex, ()) +classSpecObj.AddHook(ET_OnSaveThrowLevel, EK_SAVE_WILL, OnGetSaveThrowWill, ()) + +#### Marshal Class Mechanics + +### Learn Auras +##### Workaround until Class Features are implemented ##### +## Can't be done via Bonus Feats, as there is no flag to mark feats as bonus feat only + +# Minor Auras Learn +def newMinorAuraAvailible(classLevel, numberAurasLearned): + dictKnownAuras = { + 1: 1, + 2: 1, + 3: 2, + 4: 2, + 5: 3, + 6: 3, + 7: 4, + 8: 4, + 9: 5, + 10: 5, + 11: 5, + 12: 6, + 13: 6, + 14: 6, + 15: 7, + 16: 7, + 17: 7, + 18: 7, + 19: 7, + 20: 8 + } + return True if dictKnownAuras[classLevel] > numberAurasLearned else False + +def radialLearnMinorAura(attachee, args, evt_obj): + classLevel = attachee.stat_level_get(classEnum) + minorAuras = aura_utils.getMinorAuraList() + learnedAuras = aura_utils.getLearnedAuras(attachee, aura_type_minor) + numberAurasLearned = args.get_arg(0) + if newMinorAuraAvailible(classLevel, numberAurasLearned): + radialLearnTop = tpdp.RadialMenuEntryParent("Learn New Minor Aura") + radialLearnTopId = radialLearnTop.add_child_to_standard(attachee, tpdp.RadialMenuStandardNode.Class) + for auraEnum in minorAuras: + if not auraEnum in learnedAuras: + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + radialLearnAuraId = tpdp.RadialMenuEntryPythonAction(auraName, D20A_PYTHON_ACTION, learnMinorAuraEnum, auraEnum, auraTag) + radialLearnAuraId.add_as_child(attachee, radialLearnTopId) + return 0 + +def addNewMinorAura(attachee, args, evt_obj): + auraEnum = evt_obj.d20a.data1 + auraName = aura_utils.getAuraName(auraEnum) + attachee.feat_add("Minor Aura {}".format(auraName)) + attachee.float_text_line("{} learned".format(auraName)) + aurasLearned = args.get_arg(0) + aurasLearned +=1 + args.set_arg(0, aurasLearned) + return 0 + +classSpecObj.AddHook(ET_OnBuildRadialMenuEntry , EK_NONE, radialLearnMinorAura, ()) +classSpecObj.AddHook(ET_OnD20PythonActionPerform, learnMinorAuraEnum, addNewMinorAura, ()) + +# Major Auras Learn +def newMajorAuraAvailible(classLevel, numberAurasLearned): + dictKnownAuras = { + 1: 0, + 2: 1, + 3: 1, + 4: 1, + 5: 2, + 6: 2, + 7: 2, + 8: 2, + 9: 3, + 10: 3, + 11: 3, + 12: 3, + 13: 3, + 14: 4, + 15: 4, + 16: 4, + 17: 4, + 18: 4, + 19: 4, + 20: 5 + } + return True if dictKnownAuras[classLevel] > numberAurasLearned else False + +def radialLearnMajorAura(attachee, args, evt_obj): + classLevel = attachee.stat_level_get(classEnum) + majorAuras = aura_utils.getMajorAuraList() + learnedAuras = aura_utils.getLearnedAuras(attachee, aura_type_major) + numberAurasLearned = args.get_arg(1) + if newMajorAuraAvailible(classLevel, numberAurasLearned): + radialLearnTop = tpdp.RadialMenuEntryParent("Learn New Major Aura") + radialLearnTopId = radialLearnTop.add_child_to_standard(attachee, tpdp.RadialMenuStandardNode.Class) + for auraEnum in majorAuras: + if not auraEnum in learnedAuras: + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + radialLearnAuraId = tpdp.RadialMenuEntryPythonAction(auraName, D20A_PYTHON_ACTION, learnMajorAuraEnum, auraEnum, auraTag) + radialLearnAuraId.add_as_child(attachee, radialLearnTopId) + return 0 + +def addNewMajorAura(attachee, args, evt_obj): + auraEnum = evt_obj.d20a.data1 + auraName = aura_utils.getAuraName(auraEnum) + attachee.feat_add("Major Aura {}".format(auraName)) + attachee.float_text_line("{} learned".format(auraName)) + aurasLearned = args.get_arg(1) + aurasLearned +=1 + args.set_arg(1, aurasLearned) + return 0 + +classSpecObj.AddHook(ET_OnBuildRadialMenuEntry , EK_NONE, radialLearnMajorAura, ()) +classSpecObj.AddHook(ET_OnD20PythonActionPerform, learnMajorAuraEnum, addNewMajorAura, ()) + +##### Workaround Learn Auras end ##### + +## Auras +marshalMinorAura = aura_utils.AuraRadialModifier("Marshal Minor Aura Feat") +marshalMinorAura.MapToFeat("Marshal Minor Auras", feat_cond_arg2 = aura_type_minor) +marshalMinorAura.marshalMinorAuraActions() + +marshalMajorAura = aura_utils.AuraRadialModifier("Marshal Major Aura Feat") +marshalMajorAura.MapToFeat("Marshal Major Auras", feat_cond_arg2 = aura_type_major) +marshalMajorAura.marshalMajorAuraActions() + +## Adrenaline Boost Alternate Class Feature +def adrenalineBoostRadial(attachee, args, evt_obj): + #Add the top level menu + radialAdrenalineId = tpdp.RadialMenuEntryPythonAction("Adrenaline Boost ({}/{})".format(args.get_arg(1), args.get_arg(2)), D20A_PYTHON_ACTION, adrenalineBoostEnum, 0, "TAG_CLASS_FEATURES_MARSHAL_ADRENALINE_BOOST") + spellData = tpdp.D20SpellData(spell_marshal_adrenaline_boost) + casterLevel = attachee.stat_level_get(classEnum) + spellData.set_spell_class(classEnum) + spellData.set_spell_level(casterLevel) + radialAdrenalineId.set_spell_data(spellData) + radialAdrenalineId.add_as_child(attachee, tpdp.RadialMenuStandardNode.Class) + return 0 + +def resetChargesToMax(attachee, args, evt_obj): + classLevel = attachee.stat_level_get(classEnum) + maxUses = classLevel/4 + args.set_arg(1, maxUses) + args.set_arg(2, maxUses) + return 0 + +def checkChargesAdrenalineBoost(attachee, args, evt_obj): + chargesLeft = args.get_arg(1) + if chargesLeft < 1: + evt_obj.return_val = AEC_OUT_OF_CHARGES + #ToDo: can't boost while silcened + return 0 + +def activateAdrenalineBoost(attachee, args, evt_obj): + currentSequence = tpactions.get_cur_seq() + spellPacket = currentSequence.spell_packet + newSpellId = tpactions.get_new_spell_id() + tpactions.register_spell_cast(spellPacket, newSpellId) + tpactions.trigger_spell_effect(newSpellId) + chargesLeft = args.get_arg(1) + chargesLeft -= 1 + args.set_arg(1, chargesLeft) + return 0 + +adrenalineBoost = PythonModifier("Adrenaline Boost Feat", 4) #featEnum, chargesLeft, maxUses, empty +adrenalineBoost.MapToFeat("Marshal Adrenaline Boost") +adrenalineBoost.AddHook(ET_OnBuildRadialMenuEntry , EK_NONE, adrenalineBoostRadial, ()) +adrenalineBoost.AddHook(ET_OnNewDay, EK_NEWDAY_REST, resetChargesToMax, ()) +adrenalineBoost.AddHook(ET_OnConditionAdd, EK_NONE, resetChargesToMax, ()) +adrenalineBoost.AddHook(ET_OnD20PythonActionCheck, adrenalineBoostEnum, checkChargesAdrenalineBoost, ()) +adrenalineBoost.AddHook(ET_OnD20PythonActionPerform, adrenalineBoostEnum, activateAdrenalineBoost, ()) diff --git a/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_adrenaline_boost.py b/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_adrenaline_boost.py new file mode 100644 index 000000000..f22b1509d --- /dev/null +++ b/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_adrenaline_boost.py @@ -0,0 +1,46 @@ +from templeplus.pymod import PythonModifier +from toee import * +import tpdp +from utilities import * +import spell_utils +print "Registering sp-Marshal Adrenaline Boost" + +def onConditionPreActions(attachee, args, evt_obj): + #Adrenaline Boost does not stack with itself. + #If used again while old Boost is active + #tempHP will be reset; this is done by removing + #the old condition and apply the newer one + if evt_obj.is_modifier("sp-Marshal Adrenaline Boost"): + evt_obj.return_val = 1 + args.condition_remove() + return 0 + +def addTempHP(attachee, args, evt_obj): + spellId = args.get_arg(0) + spellPacket = tpdp.SpellPacket(spellId) + duration = args.get_arg(1) + currentHp = attachee.stat_level_get(stat_hp_current) + maxHp = attachee.stat_level_get(stat_hp_max) + tempHp = spellPacket.caster_level + #Adrenaline Boost TempHP are doubled if target is at or below half HP + if (currentHp * 2) <= maxHp: + tempHp *= 2 + attachee.condition_add_with_args('Temporary_Hit_Points', spellId, duration, tempHp) + return 0 + +def removeTempHp(attachee, args, evt_obj): + attachee.d20_send_signal(S_Spell_End, args.get_arg(0)) + return 0 + +marshalAdrenalineBoostSpell = PythonModifier("sp-Marshal Adrenaline Boost", 4, False) # spell_id, duration, empty, empty +marshalAdrenalineBoostSpell.AddHook(ET_OnConditionAddPre, EK_NONE, onConditionPreActions,()) +marshalAdrenalineBoostSpell.AddHook(ET_OnConditionAdd, EK_NONE, addTempHP,()) +marshalAdrenalineBoostSpell.AddHook(ET_OnConditionRemove, EK_NONE, removeTempHp, ()) +marshalAdrenalineBoostSpell.AddHook(ET_OnD20Signal, EK_S_Temporary_Hit_Points_Removed, spell_utils.removeTempHp, ()) +marshalAdrenalineBoostSpell.AddHook(ET_OnGetTooltip, EK_NONE, spell_utils.spellTooltip, ()) +marshalAdrenalineBoostSpell.AddHook(ET_OnGetEffectTooltip, EK_NONE, spell_utils.spellEffectTooltip, ()) +marshalAdrenalineBoostSpell.AddHook(ET_OnD20Signal, EK_S_Killed, spell_utils.spellKilled, ()) +marshalAdrenalineBoostSpell.AddSpellTeleportPrepareStandard() +marshalAdrenalineBoostSpell.AddSpellTeleportReconnectStandard() +marshalAdrenalineBoostSpell.AddSpellCountdownStandardHook() + diff --git a/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_major_aura.py b/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_major_aura.py new file mode 100644 index 000000000..f96a8151b --- /dev/null +++ b/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_major_aura.py @@ -0,0 +1,104 @@ +from templeplus.pymod import PythonModifier +from toee import * +import tpdp +import aura_utils + +print "Registering Marshal Major Auras" + +marshalMajorAuraSpell = aura_utils.AuraAoeHandlingModifier("sp-Marshal Major Aura") + +### All Major Aura descriptions can be found at: http://archive.wizards.com/default.asp?x=dnd/ex/20030906b ### +### All Auras have 5 args: auraSpellId, auraEnum, auraEventId, empty, empty (may get reduced to 4 in final version) + +### Marshal Major Aura Hardy Soldiers ### +def auraBonusHardySoldiers(attachee, args, evt_obj): + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraBonus = aura_utils.getMajorAuraBonus(auraSpellPacket.caster_level) + damageMesId = 126 + evt_obj.damage_packet.add_physical_damage_res(auraBonus, D20DAP_UNSPECIFIED, damageMesId) + return 0 + +majorAuraHardySoldiers = aura_utils.AuraModifier("Marshal Major Aura Hardy Soldiers") +majorAuraHardySoldiers.AddHook(ET_OnTakingDamage2, EK_NONE, auraBonusHardySoldiers, ()) +majorAuraHardySoldiers.marshalAuraAddPreActions() + + +### Marshal Major Aura Motivate Ardor ### +def auraBonusMotivateArdor(attachee, args, evt_obj): + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraEnum = args.get_arg(1) + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + auraBonus = aura_utils.getMajorAuraBonus(auraSpellPacket.caster_level) + auraBonusType = 21 #ID 21 = Circumstance Bonus + evt_obj.damage_packet.bonus_list.add(auraBonus, auraBonusType, "~Circumstance~[TAG_MODIFIER_CIRCUMSTANCE] : ~{}~[{}]".format(auraName, auraTag)) + return 0 + +majorAuraMotivateArdor = aura_utils.AuraModifier("Marshal Major Aura Motivate Ardor") +majorAuraMotivateArdor.AddHook(ET_OnDealingDamage2, EK_NONE, auraBonusMotivateArdor, ()) +majorAuraMotivateArdor.marshalAuraAddPreActions() + + +### Marshal Major Aura Motivate Attack ### +def auraBonusMotivateAttack(attachee, args, evt_obj): + if not evt_obj.attack_packet.get_flags() & D20CAF_RANGED: + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraEnum = args.get_arg(1) + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + auraBonus = aura_utils.getMajorAuraBonus(auraSpellPacket.caster_level) + auraBonusType = 21 #ID 21 = Circumstance Bonus + evt_obj.bonus_list.add(auraBonus, auraBonusType, "~Circumstance~[TAG_MODIFIER_CIRCUMSTANCE] : ~{}~[{}]".format(auraName, auraTag)) + return 0 + +majorAuraMotivateAttack = aura_utils.AuraModifier("Marshal Major Aura Motivate Attack") +majorAuraMotivateAttack.AddHook(ET_OnToHitBonus2, EK_NONE, auraBonusMotivateAttack, ()) +majorAuraMotivateAttack.marshalAuraAddPreActions() + +### Marshal Major Aura Motivate Care ### +majorAuraMotivateCare = aura_utils.AuraModifier("Marshal Major Aura Motivate Care") +majorAuraMotivateCare.AddHook(ET_OnGetAC, EK_NONE, aura_utils.auraAddBonusList, (aura_type_major,)) +majorAuraMotivateCare.marshalAuraAddPreActions() + +### Marshal Major Aura Motivate Urgency ### +def auraBonusMotivateUrgency(attachee, args, evt_obj): + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraEnum = args.get_arg(1) + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + auraBonus = aura_utils.getMajorAuraBonus(auraSpellPacket.caster_level) + auraBonusType = 21 #ID 21 = Circumstance Bonus + auraBonus *= 5 + evt_obj.bonus_list.add(auraBonus, auraBonusType, "~Circumstance~[TAG_MODIFIER_CIRCUMSTANCE] : ~{}~[{}]".format(auraName, auraTag)) + return 0 + +majorAuraMotivateUrgency = aura_utils.AuraModifier("Major Aura Motivate Urgency") +majorAuraMotivateUrgency.AddHook(ET_OnGetMoveSpeedBase, EK_NONE, auraBonusMotivateUrgency, ()) +majorAuraMotivateUrgency.marshalAuraAddPreActions() + + +### Marshal Major Aura Resilient Troops" ### +majorAuraResilientTroops = aura_utils.AuraModifier("Marshal Major Aura Resilient Troops") +majorAuraResilientTroops.AddHook(ET_OnSaveThrowLevel, EK_NONE, aura_utils.auraAddBonusList, (aura_type_major,)) +majorAuraResilientTroops.marshalAuraAddPreActions() + +### Marshal Major Aura Steady Hand ### +def auraBonusSteadyHand(attachee, args, evt_obj): + if evt_obj.attack_packet.get_flags() & D20CAF_RANGED: + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraEnum = args.get_arg(1) + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + auraBonus = aura_utils.getMajorAuraBonus(auraSpellPacket.caster_level) + auraBonusType = 21 #ID 21 = Circumstance Bonus + evt_obj.bonus_list.add(auraBonus, auraBonusType, "~Circumstance~[TAG_MODIFIER_CIRCUMSTANCE] : ~{}~[{}]".format(auraName, auraTag)) + return 0 + +majorAuraSteadyHand = aura_utils.AuraModifier("Marshal Major Aura Steady Hand") +majorAuraSteadyHand.AddHook(ET_OnToHitBonus2, EK_NONE, auraBonusSteadyHand, ()) +majorAuraSteadyHand.marshalAuraAddPreActions() diff --git a/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_minor_aura.py b/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_minor_aura.py new file mode 100644 index 000000000..8733adea1 --- /dev/null +++ b/tpdatasrc/tpgamefiles/scr/tpModifiers/sp_marshal_minor_aura.py @@ -0,0 +1,132 @@ +from templeplus.pymod import PythonModifier +from toee import * +import tpdp +import aura_utils + +print "Registering Marshal Minor Auras" + +marshalMinorAuraSpell = aura_utils.AuraAoeHandlingModifier("sp-Marshal Minor Aura") + +### All Minor Aura descriptions can be found at: http://archive.wizards.com/default.asp?x=dnd/ex/20030906b ### +### All Auras have 5 args: auraSpellId, auraEnum, auraEventId, empty, empty (may get reduced to 4 in final version) + +### Marshal Minor Aura Accurate Strike ### +marshalMinorAuraAccurateStrike = aura_utils.AuraModifier("Marshal Minor Aura Accurate Strike") +marshalMinorAuraAccurateStrike.AddHook(ET_OnConfirmCriticalBonus, EK_NONE, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraAccurateStrike.marshalAuraAddPreActions() + +### Marshal Minor Aura Art of War ### +marshalMinorAuraArtOfWar = aura_utils.AuraModifier("Marshal Minor Aura Art of War") +marshalMinorAuraArtOfWar.AddHook(ET_OnGetAbilityCheckModifier, EK_NONE, aura_utils.auraAddBonusList, (aura_type_minor,)) #are there AbilityCheckModifier that are not disarm, trip, bull rush, or sunder? If yes redo! +marshalMinorAuraArtOfWar.marshalAuraAddPreActions() + +### Marshal Minor Aura Demand Fortitude ### +marshalMinorAuraDemandFortitude = aura_utils.AuraModifier("Marshal Minor Aura Demand Fortitude") +marshalMinorAuraDemandFortitude.AddHook(ET_OnSaveThrowLevel, EK_SAVE_FORTITUDE, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraDemandFortitude.marshalAuraAddPreActions() + +### Marshal Minor Aura Determined Caster ### +marshalMinorAuraDeterminedCaster= aura_utils.AuraModifier("Marshal Minor Aura Determined Caster") +marshalMinorAuraDeterminedCaster.AddHook(ET_OnSpellResistanceCheckBonus, EK_NONE, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraDeterminedCaster.marshalAuraAddPreActions() + +### Marshal Minor Aura Force of Will ### +marshalMinorAuraForceOfWill = aura_utils.AuraModifier("Marshal Minor Aura Force of Will") +marshalMinorAuraForceOfWill.AddHook(ET_OnSaveThrowLevel, EK_SAVE_WILL, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraForceOfWill.marshalAuraAddPreActions() + +### Marshal Minor Aura Master of Opportunity ### +def auraBonusMasterOfOpportunity(attachee, args, evt_obj): + if evt_obj.attack_packet.get_flags() & D20CAF_ATTACK_OF_OPPORTUNITY: + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraEnum = args.get_arg(1) + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + auraBonus = aura_utils.getMinorAuraBonus(auraSpellPacket.caster) + auraBonusType = 21 #ID 21 = Circumstance Bonus + evt_obj.bonus_list.add(auraBonus, auraBonusType,"~Circumstance~[TAG_MODIFIER_CIRCUMSTANCE] : ~{}~[{}]".format(auraName, auraTag)) + return 0 + +marshalMinorAuraMasterOfOpportunity = aura_utils.AuraModifier("Marshal Minor Aura Master of Opportunity") +marshalMinorAuraMasterOfOpportunity.AddHook(ET_OnGetAC, EK_NONE, auraBonusMasterOfOpportunity, ()) +marshalMinorAuraMasterOfOpportunity.marshalAuraAddPreActions() + +### Marshal Minor Aura Master of Tactics ### +def auraBonusMasterOfTactics(attachee, args, evt_obj): + if evt_obj.attack_packet.get_flags() & D20CAF_FLANKED: + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraEnum = args.get_arg(1) + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + auraBonus = aura_utils.getMinorAuraBonus(auraSpellPacket.caster) + auraBonusType = 21 #ID 21 = Circumstance Bonus + evt_obj.damage_packet.bonus_list.add(auraBonus, auraBonusType,"~Circumstance~[TAG_MODIFIER_CIRCUMSTANCE] : ~{}~[{}]".format(auraName, auraTag)) + return 0 + +marshalMinorAuraMasterOfTactics = aura_utils.AuraModifier("Marshal Minor Aura Master of Tactics") +marshalMinorAuraMasterOfTactics.AddHook(ET_OnDealingDamage2, EK_NONE, auraBonusMasterOfTactics, ()) +marshalMinorAuraMasterOfTactics.marshalAuraAddPreActions() + +### Marshal Minor Aura Motivate Charisma ### +marshalMinorAuraMotivateCharisma = aura_utils.AuraModifier("Marshal Minor Aura Motivate Charisma") +marshalMinorAuraMotivateCharisma.AddHook(ET_OnGetAbilityCheckModifier, EK_STAT_CHARISMA, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraMotivateCharisma.addSkillBonus(aura_type_minor, skill_bluff, skill_diplomacy, skill_disguise, skill_gather_information, skill_handle_animal, +skill_intimidate, skill_perform, skill_use_magic_device) +marshalMinorAuraMotivateCharisma.marshalAuraAddPreActions() + +### Marshal Minor Aura Motivate Constitution ### +marshalMinorAuraMotivateConstitution = aura_utils.AuraModifier("Marshal Minor Aura Motivate Constitution") +marshalMinorAuraMotivateConstitution.AddHook(ET_OnGetAbilityCheckModifier, EK_STAT_CONSTITUTION, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraMotivateConstitution.addSkillBonus(aura_type_minor, skill_concentration) +marshalMinorAuraMotivateConstitution.marshalAuraAddPreActions() + +### Marshal Minor Aura Motivate Dexterity ### +marshalMinorAuraMotivateDexterity = aura_utils.AuraModifier("Marshal Minor Aura Motivate Dexterity") +marshalMinorAuraMotivateDexterity.AddHook(ET_OnGetAbilityCheckModifier, EK_STAT_DEXTERITY, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraMotivateDexterity.addSkillBonus(aura_type_minor, skill_balance, skill_balance, skill_escape_artist, skill_hide, skill_move_silently, +skill_open_lock, skill_ride, skill_pick_pocket, skill_tumble, skill_use_rope) +marshalMinorAuraMotivateDexterity.marshalAuraAddPreActions() + +### Marshal Minor Aura Motivate Intelligence ### +marshalMinorAuraMotivateIntelligence = aura_utils.AuraModifier("Marshal Minor Aura Motivate Intelligence") +marshalMinorAuraMotivateIntelligence.AddHook(ET_OnGetAbilityCheckModifier, EK_STAT_INTELLIGENCE, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraMotivateIntelligence.addSkillBonus(aura_type_minor, skill_appraise, skill_craft, skill_decipher_script, skill_disable_device, skill_forgery, +skill_knowledge_arcana, skill_knowledge_religion, skill_knowledge_nature, skill_search, skill_spellcraft) +#marshalMinorAuraMotivateIntelligence.AddHook(ET_OnGetSkillLevel, EK_SKILL_KNOWLEDGE_ALL, auraAddBonusList, ()) +marshalMinorAuraMotivateIntelligence.marshalAuraAddPreActions() + +### Marshal Minor Aura Motivate Strength ### +marshalMinorAuraMotivateStrength = aura_utils.AuraModifier("Marshal Minor Aura Motivate Strength") +marshalMinorAuraMotivateStrength.AddHook(ET_OnGetAbilityCheckModifier, EK_STAT_STRENGTH, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraMotivateStrength.addSkillBonus(aura_type_minor, skill_climb, skill_jump, skill_swim) +marshalMinorAuraMotivateStrength.marshalAuraAddPreActions() + +### Marshal Minor Aura Motivate Wisdom ### +marshalMinorAuraMotivateWisdom = aura_utils.AuraModifier("Marshal Minor Aura Motivate Wisdom") +marshalMinorAuraMotivateWisdom.AddHook(ET_OnGetAbilityCheckModifier, EK_STAT_WISDOM, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraMotivateWisdom.addSkillBonus(aura_type_minor, skill_heal, skill_listen, skill_sense_motive, skill_spot, skill_wilderness_lore) +marshalMinorAuraMotivateWisdom.marshalAuraAddPreActions() + +### Marshal Minor Aura Over the Top ### +def auraBonusMasterOfTactics(attachee, args, evt_obj): + if evt_obj.attack_packet.get_flags() & D20CAF_CHARGE: + auraSpellId = args.get_arg(0) + auraSpellPacket = tpdp.SpellPacket(auraSpellId) + auraEnum = args.get_arg(1) + auraName = aura_utils.getAuraName(auraEnum) + auraTag = aura_utils.getAuraTag(auraEnum) + auraBonus = aura_utils.getMinorAuraBonus(auraSpellPacket.caster) + auraBonusType = 21 #ID 21 = Circumstance Bonus + evt_obj.damage_packet.bonus_list.add(auraBonus, auraBonusType,"~Circumstance~[TAG_MODIFIER_CIRCUMSTANCE] : ~{}~[{}]".format(auraName, auraTag)) + return 0 + +marshalMinorAuraOverTheTop = aura_utils.AuraModifier("Marshal Minor Aura Over the Top") +marshalMinorAuraOverTheTop.AddHook(ET_OnDealingDamage2, EK_NONE, auraBonusMasterOfTactics, ()) +marshalMinorAuraOverTheTop.marshalAuraAddPreActions() + +### Marshal Minor Aura Watchful Eye ### +marshalMinorAuraWatchfulEye = aura_utils.AuraModifier("Marshal Minor Aura Watchful Eye") +marshalMinorAuraWatchfulEye.AddHook(ET_OnSaveThrowLevel, EK_SAVE_REFLEX, aura_utils.auraAddBonusList, (aura_type_minor,)) +marshalMinorAuraWatchfulEye.marshalAuraAddPreActions()