Scripts

TR_m4_VA_budak2_scr

TR_Mainland.esm
Variables 16
Local Variables
nolore
TR_Map
T_Local_Vampire
control
controlQ
NoHello
NoFlee
NoIdle
NoIntruder
NoThief
T_Local_NPC
T_Local_NoLore
checkBlood
doOnce
andasOnce
state
Source
1begin TR_m4_VA_budak2_scr 2 3short nolore 4short TR_Map 5short T_Local_Vampire 6short control 7short controlQ 8 9short NoHello 10short NoFlee 11short NoIdle 12short NoIntruder 13short NoThief 14short T_Local_NPC 15short T_Local_NoLore 16 17short checkBlood 18short doOnce 19short andasOnce 20short state 21 22if ( GetJournalIndex TR_m4_VA_Roadside == 30 ) 23 if ( "TR_m4_Dridas Orthil"->GetHealth > 0 ) 24 Startcombat "TR_m4_Dridas Orthil" 25 "TR_m4_Dridas Orthil"->Startcombat Player 26 endif 27endif 28 29;----------------------------------------------- 30; Drop vampire dust on death like vanilla 31;----------------------------------------------- 32 33if ( OnDeath ) 34 AddItem "ingred_vampire_dust_01" 1 35endif 36 37 38;----------------------------------------------- 39; Check player infection/vampire status 40;----------------------------------------------- 41 42if ( CellChanged ) 43 set checkBlood to 0 44 set state to 0 45 46 if ( T_Glob_PorphyricInfected ) 47 elseif ( player->GetSpell "Vampire Blood Quarra" ) 48 elseif ( player->GetSpell "Vampire Blood Aundae" ) 49 elseif ( player->GetSpell "Vampire Blood Berne" ) 50 elseif ( PCVampire != 0 ) 51 elseif ( PCWerewolf == 1 ) 52 else 53 ;Player isn't infected/vampire/cured vampire/werewolf 54 set checkBlood to 1 55 endif 56endif 57 58if ( MenuMode ) 59 return 60endif 61 62;------------------------------------------------ 63; Player was not infected before changing cell, 64; so constantly check for infection and then run 65; this clan's specific global script 66;------------------------------------------------ 67 68if ( checkBlood ) 69 if ( player->GetSpellEffects "T_Vamp_Dis_Orlukh" ) 70 if ( ScriptRunning "T_ScVamp_Orlukh_PC" != 1 ) 71 StartScript "T_ScVamp_Orlukh_PC" 72 endif 73 endif 74 75;------------------------------------------------ 76; Player was infected/vampire before changing cell, 77; so check whether player is in an enemy clan 78;------------------------------------------------ 79 80elseif ( state != 1 ) 81 if ( VampClan == 101 ) 82 SetFight 30 ;Player is a friendly vampire 83 else 84 SetFight 90 ;Player is an enemy vampire 85 endif 86 87 set state to 1 88endif 89 90;------------------------------------------------ 91; Apply vampire spells/abilities to this NPC once 92;------------------------------------------------ 93 94if ( doOnce == 0 ) 95 AddSpell "T_Vamp_Dis_Orlukh" 96 AddSpell "T_Vamp_Ab_Orlukh" 97 AddSpell "Vampire Attributes" 98 AddSpell "Vampire Skills" 99 AddSpell "Vampire Immunities" 100 AddSpell "Vampire Sun Damage" 101 AddSpell "Vampire Touch" 102 ModRestoration 75 103 ;set province-specific location variable for dialogue here 104 set TR_Map to 4 105 set doOnce to 1 106endif 107 108end