Skip to content

Commit

Permalink
Added fix for raise dead and aasumars.
Browse files Browse the repository at this point in the history
  • Loading branch information
doug1234 committed Sep 5, 2024
1 parent 23d38db commit d47bd10
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion tpdatasrc/co8infra/scr/Spell379 - Raise Dead.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,16 @@ def OnSpellEffect( spell ):
spell.duration = 0
target_item = spell.target_list[0]

prevType = 0
if target_item.obj.is_category_type( mc_type_outsider ) and target_item.obj.is_category_subtype(mc_subtype_human):
subrace = target_item.obj.stat_base_get(stat_subrace)
if (subrace == human_subrace_aasumar or subrace == human_subrace_tiefling):
prevType = target_item.obj.obj_get_int64(obj_f_critter_monster_category)
target_item.obj.obj_set_int64(obj_f_critter_monster_category, mc_type_humanoid)

target_item.obj.condition_add_with_args( 'sp-Raise Dead', spell.id, spell.duration, 0 )
#target_item.partsys_id = game.particles( 'sp-Raise Dead', target_item.obj )

if target_item.obj.stat_level_get( stat_level ) == 1:
game.global_vars[752] = 0
elif target_item.obj.stat_level_get( stat_level ) == 2:
Expand Down Expand Up @@ -65,6 +72,10 @@ def OnSpellEffect( spell ):

spell.spell_end( spell.id, 1 )

if prevType != 0:
target_item = spell.target_list[0]
target_item.obj.obj_set_int64(obj_f_critter_monster_category, prevType)

def OnBeginRound( spell ):
spell.spell_end( spell.id, 1 )
print "Raise Dead OnBeginRound"
Expand Down

0 comments on commit d47bd10

Please sign in to comment.