Восстанелла

/*

  • jc_troll_9
    *
  • version 1.2 by Lorinton September 17 2003
    *
  • On spawn script for regenerating trolls.
  • Assign the script to the troll’s on spawn event replacing the default
  • nw_c2_default9 script.
    *
  • The on damaged and heartbeat user defined events MUST be enabled.
    *
    */

include «nw_i0_generic»

void main()
{
SetSpawnInCondition( NW_FLAG_DAMAGED_EVENT );
SetSpawnInCondition( NW_FLAG_HEARTBEAT_EVENT );

// Set the troll to immortal so that we can script a requirement for fire and
// acid damage to kill the troll.
SetImmortal( OBJECT_SELF, TRUE );

// Run the standard spawn script.
// Change the name to whatever custom script you use if not using the default script.
ExecuteScript( "nw_c2_default9", OBJECT_SELF );

}

=====================================================================

/*

  • version 1.2 by Lorinton September 17 2003
    *
  • A complete rewrite after discovering that a recent patch was causing the
  • previous version to crash the server.
    *
  • The heartbeat UDE controls regeneration and returning to consciousness.
  • The on damaged UDE controls death and being damaged to unconsciousness.
    *
    */

include «nw_i0_generic»

// If you would like to enable the debug messages which are in the code
// uncomment the SpeakString function in DebugSpeak.
void DebugSpeak( string sMessage )
{
// SpeakString( sMessage );
}

// This function is called from the on damaged (1006) UDE when permanent damage
// equals or exceeds the trolls maximum hitpoints.
void KillTroll( object oTroll = OBJECT_SELF )
{
effect eAcid, eFire, eVisual;

// Create a fire or acid visual effect and kill the troll.
DebugSpeak( "Killing " + GetName( oTroll ));
if( GetLocalInt( oTroll, "bAcid" ))
    eAcid = EffectVisualEffect( VFX_IMP_ACID_L );
if( GetLocalInt( oTroll, "bFire" ))
    eFire = EffectVisualEffect( VFX_IMP_FLAME_M );
eVisual = EffectLinkEffects( eAcid, eFire );
ApplyEffectToObject( DURATION_TYPE_INSTANT, eVisual, oTroll );

SetImmortal( oTroll, FALSE );

ApplyEffectToObject( DURATION_TYPE_INSTANT, EffectDeath(), oTroll );

}

// This function is called from the on damaged UDE.
// Fire and acid damage will be summed to the troll’s permanent damage.
// All other damage types will be summed to the troll’s temporary damage.
int CalculateTrollDamage()
{
int iAcidDamage, iFireDamage, iDamage, iTemp;

// Get the most recent fire damage
iFireDamage = GetDamageDealtByType( DAMAGE_TYPE_FIRE );
if( iFireDamage > 0 )
    SetLocalInt( OBJECT_SELF, "bFire", TRUE );
else
{
    iFireDamage = 0;
    SetLocalInt( OBJECT_SELF, "bFire", FALSE );
}

// Get the most recent acid damage
iAcidDamage = GetDamageDealtByType( DAMAGE_TYPE_ACID );
if( iAcidDamage > 0)
    SetLocalInt( OBJECT_SELF, "bAcid", TRUE );
else
{
    iAcidDamage = 0;
    SetLocalInt( OBJECT_SELF, "bAcid", FALSE );
}

// Get the most recent damage (all types combined)
iDamage = GetTotalDamageDealt();

// Calculate the new permanent damage from fire and acid and then add it to
// the existing permenant damage.
iTemp = iFireDamage + iAcidDamage;
DebugSpeak( "Troll new permanent damage = " + IntToString( iTemp ));
// If the troll took permanent damage while unconscious it will be killed.
if( iTemp > 0 && GetLocalInt( OBJECT_SELF, "Troll_unconscious" ))
    KillTroll();
SetLocalInt( OBJECT_SELF, "Troll_PermDamage", GetLocalInt( OBJECT_SELF, "Troll_PermDamage" ) + iTemp );

// Calculate the new temporary damage and then add it to the existing temporary
// damage.
// iTemp still holds the new permanent damage
iTemp = iDamage - iTemp;
DebugSpeak( "Troll temp damage = " + IntToString( iTemp ));
SetLocalInt( OBJECT_SELF, "Troll_TempDamage", GetLocalInt( OBJECT_SELF, "Troll_TempDamage" ) + iTemp );

return iDamage;

}

// Regenerate temporary damage
void HealTroll()
{
int iHeal, iPermDamage, iTempDamage, iMaxHPs = GetMaxHitPoints();
effect eHeal;

iTempDamage = GetLocalInt ( OBJECT_SELF, "Troll_TempDamage" );
iPermDamage = GetLocalInt ( OBJECT_SELF, "Troll_PermDamage" );

DebugSpeak( "Permanent and temporary damage = " + IntToString( iPermDamage ) +
    ", " + IntToString( iTempDamage ));

// Reduce temporary damage by the lesser of five hitpoints or the troll's
// temporary damage.
iHeal = ( iTempDamage < 5 ) ? iTempDamage : 5;
iTempDamage -= iHeal;
DebugSpeak( "Troll regeneration = " + IntToString( iHeal ));
SetLocalInt( OBJECT_SELF, "Troll_TempDamage", iTempDamage );

/*
// Sound effect of troll regenerating (one each depending if
// troll is "dead" or still standing
if (GetLocalInt (OBJECT_SELF, "bTrollDown") == TRUE)
    PlaySound("al_na_sludggrat2");  // Sound for dead troll regenerating
else
    PlaySound("as_mg_telepin1"); // Sound for living troll regenerating
*/

// Only heal if the regeneration places the troll into positive hitpoints.
if(( iTempDamage + iPermDamage ) < iMaxHPs )
{
    DebugSpeak( "Troll healing = " + IntToString( iHeal ));
    eHeal = EffectHeal( iHeal );
    ApplyEffectToObject( DURATION_TYPE_INSTANT , eHeal, OBJECT_SELF );
}

}

void main()
{
int iSum, iPermDamage, iTempDamage, iMaxHPs = GetMaxHitPoints();
float fDuration;

switch ( GetUserDefinedEventNumber () )
{
    case EVENT_HEARTBEAT:
        DebugSpeak( "Event 1001..." );
        iTempDamage = GetLocalInt ( OBJECT_SELF, "Troll_TempDamage" );
        // Use iPermDamage as a temporary variable that holds the sum of
        // temporary and permanent damage
        iSum = iTempDamage + GetLocalInt( OBJECT_SELF, "Troll_PermDamage" );
        if( iSum == 0 )
            return;
        if( iSum < iMaxHPs && GetLocalInt( OBJECT_SELF, "Troll_unconscious" ))
        {
            // Return the troll to consciousness as it has regenerated to
            // positive hitpoints.
            DebugSpeak( "Returning the troll to consciousness..." );
            SetCommandable( TRUE, OBJECT_SELF );
            // Force the troll up off the ground as DetermineCombatRound()
            // won't unless it has an attack target.
            ActionForceMoveToLocation( GetLocation( OBJECT_SELF ));
            SetLocalInt( OBJECT_SELF, "Troll_unconscious", FALSE );
            DelayCommand( 0.5, DetermineCombatRound() );
        }
        if( iTempDamage > 0 )
        {
            HealTroll();
        }
        break;
    case EVENT_DAMAGED:
        // Sort new damage into permanent and temporary damage.
        DebugSpeak( "Event 1006..." );
        if( CalculateTrollDamage() )
        {
            iTempDamage = GetLocalInt ( OBJECT_SELF, "Troll_TempDamage" );
            iPermDamage = GetLocalInt( OBJECT_SELF, "Troll_PermDamage" );
            iSum = iTempDamage + iPermDamage;
            if( iPermDamage >= iMaxHPs )
            {
                // Permanent damage has reached or exceeded the troll's maximum
                // hitpoints so kill the troll.
                DebugSpeak( "Killing the troll..." );
                KillTroll();
            }
            else if( iSum >= iMaxHPs )
            {
                // Force the troll to lie down unconcious until it regenerates to
                // positive hitpoints.
                DebugSpeak( "Forcing the troll to be unconcious..." );
                // Play the dead animation for the time it will take to regenerate from the
                // current hitpoints to positive hitpoints.
                // At 5 hitpoints/round with a 6 second round this is 1.2 seconds per HP.
                fDuration = ( 2.0 * IntToFloat( iSum - iMaxHPs ));
                DebugSpeak( "Playing dead animation for " + FloatToString( fDuration ));
                SetCommandable( TRUE, OBJECT_SELF );
                ClearAllActions();
                PlayAnimation( ANIMATION_LOOPING_DEAD_FRONT, 1.0, fDuration );
                SetLocalInt( OBJECT_SELF, "Troll_unconscious", TRUE );
                DelayCommand( 0.05, SetCommandable( FALSE, OBJECT_SELF ));
            }
            // If the troll is unconscious and damaged by a PC with a torch, allow them
            // them use it to kill the troll.
            // Rather than force them to take an action in the middle of combat which
            // might cause AoO's and be against their will, just assume they did so.
            if( GetLocalInt( OBJECT_SELF, "Troll_unconscious" ) &&
                GetBaseItemType( GetItemInSlot( INVENTORY_SLOT_LEFTHAND, GetLastAttacker() )) ==
                BASE_ITEM_TORCH )
            {
                DebugSpeak( GetName( GetLastAttacker() ) + " killing troll with torch..." );
                SetLocalInt( OBJECT_SELF, "bFire", TRUE );
                object oTroll = OBJECT_SELF;
                AssignCommand( GetLastAttacker(), KillTroll( oTroll ) );
            }
        }
        break;
}

}

====================================================================

28.03.2023 23:28:07: 0 ошибок. ‘ce_o0_respawn’ успешно скомпилирован

//::///////////////////////////////////////////////
//:: Generic On Pressed Respawn Button
//:: Copyright (c) 2001 Bioware Corp.
//:://////////////////////////////////////////////
/*
// * June 1: moved RestoreEffects into plot include
*/
//:://////////////////////////////////////////////
//:: Created By: Brent
//:: Created On: November
//:://////////////////////////////////////////////

include «nw_i0_plot»

// * Applies an XP and GP penalty
// * to the player respawning
void ApplyPenalty(object oDead)
{
int nXP = GetXP(oDead);
int nPenalty = 50 * GetHitDice(oDead);
int nHD = GetHitDice(oDead);
// * You can not lose a level with this respawning
int nMin = ((nHD * (nHD — 1)) / 2) * 1000;

int nNewXP = nXP - nPenalty;
if (nNewXP < nMin)
   nNewXP = nMin;
SetXP(oDead, nNewXP);
int nGoldToTake =    FloatToInt(0.10 * GetGold(oDead));
// * a cap of 10 000gp taken from you
if (nGoldToTake > 10000)
{
    nGoldToTake = 10000;
}
AssignCommand(oDead, TakeGoldFromCreature(nGoldToTake, oDead, TRUE));
DelayCommand(4.0, FloatingTextStrRefOnCreature(58299, oDead, FALSE));
DelayCommand(4.8, FloatingTextStrRefOnCreature(58300, oDead, FALSE));

}

void main()
{
object oRespawner = GetLastRespawnButtonPresser();
ApplyEffectToObject(DURATION_TYPE_INSTANT,EffectResurrection(),oRespawner);
ApplyEffectToObject(DURATION_TYPE_INSTANT,EffectHeal(GetMaxHitPoints(oRespawner)), oRespawner);
RemoveEffects(oRespawner);
//* Return PC to temple

string sDestTag =  "NW_DEATH_TEMPLE";
string sArea = GetTag(GetArea(oRespawner));

    ApplyPenalty(oRespawner);
    SetMaxHenchmen(GetMaxHenchmen()+1);
    object oSpawnPoint = GetObjectByTag(sDestTag);
    AssignCommand(oRespawner,JumpToLocation(GetLocation(oSpawnPoint)));

}

==============================================================================================

Tales Of The Hullack Forest: The Sunken Cemetery 1.26 (SoU/HotU) — Респаун +1 спутник!

Adventure Type: Story based; Combat intensive; Quests and Puzzles

Character Levels: Solo player, levels 10th — 14th (12th level recommended) — You can now play with a lower level character and get leveled up within the module.

Classes: Any

Description: Восстанелла-Повреждалка! _-Сделала!!

Tales of travelers from the Hullack Forest to the east tell of a mysterious cemetery that has arisen from the earth cloaked in eternal night. You have traveled the road from Arabel in the west through the rolling hills and forests of Cormyr for what seems like ages — uneventful ages — at least until now. Do you dare go forward to see if these tales hold some truth?

Note: This version requires SoU and HotU X-Packs!

===============================================================================================

nw_s0_fear

===============================================================================================

//::///////////////////////////////////////////////
//:: Default:On Death
//:: NW_C2_DEFAULT7
//:: Copyright (c) 2001 Bioware Corp.
//:://////////////////////////////////////////////
/*
Shouts to allies that they have been killed
*/
//:://////////////////////////////////////////////
//:: Created By: Preston Watamaniuk
//:: Created On: Oct 25, 2001
//:://////////////////////////////////////////////

include «hench_i0_ai»

include «x2_inc_compon»

include «x0_i0_spawncond»

void main()
{
int nClass = GetLevelByClass(CLASS_TYPE_COMMONER);
int nAlign = GetAlignmentGoodEvil(OBJECT_SELF);
object oKiller = GetLastKiller();
if(nClass > 0 && (nAlign == ALIGNMENT_GOOD || nAlign == ALIGNMENT_NEUTRAL))
{
AdjustAlignment(oKiller, ALIGNMENT_EVIL, 5);
}

if (GetLocalInt(OBJECT_SELF,"GaveHealing"))
{
    // Pausanias: destroy potions of healing
    object oItem = GetFirstItemInInventory();
    while (GetIsObjectValid(oItem))
    {
        if (GetTag(oItem) == "NW_IT_MPOTION003")
            DestroyObject(oItem);
        oItem = GetNextItemInInventory();
    }
}

if (GetLocalInt(OBJECT_SELF, sHenchSummonedFamiliar) ||
    GetLocalInt(OBJECT_SELF, sHenchSummonedFamiliar))
{
    int nCurPos = 1;
    object oAssoc = GetAssociate(ASSOCIATE_TYPE_HENCHMAN, OBJECT_SELF, 1);
    while (GetIsObjectValid(oAssoc))
    {
        if (GetLocalInt(oAssoc, sHenchPseudoSummon))
        {
            DestroyObject(oAssoc, 0.1);
            ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, EffectVisualEffect(VFX_IMP_UNSUMMON), GetLocation(oAssoc));
        }
        nCurPos++;
        oAssoc = GetAssociate(ASSOCIATE_TYPE_HENCHMAN, OBJECT_SELF, nCurPos);
    }
}
ClearEnemyLocation();

SpeakString("NW_I_AM_DEAD", TALKVOLUME_SILENT_TALK);
//Shout Attack my target, only works with the On Spawn In setup
SpeakString("NW_ATTACK_MY_TARGET", TALKVOLUME_SILENT_TALK);
if(GetSpawnInCondition(NW_FLAG_DEATH_EVENT))
{
    SignalEvent(OBJECT_SELF, EventUserDefined(1007));
}

craft_drop_items(oKiller);
        ActionCastSpellAtObject(SPELL_MONSTROUS_REGENERATION, oKiller, METAMAGIC_NONE, TRUE, 18, PROJECTILE_PATH_TYPE_DEFAULT, TRUE);
        ActionCastSpellAtObject(SPELLABILITY_PULSE_DISEASE, oKiller, METAMAGIC_NONE, TRUE, 18, PROJECTILE_PATH_TYPE_DEFAULT, TRUE);
        if(Random(100) >= 69)
                {AdjustAlignment(oKiller, ALIGNMENT_GOOD, 1);
                 AdjustAlignment(oKiller, ALIGNMENT_LAWFUL, 1);}
                 GiveGoldToCreature(oKiller, 1999);
                 if(Random(100) >= 50)
                 {effect eGirlHP = EffectTemporaryHitpoints(11);
  eGirlHP = SupernaturalEffect(eGirlHP);
  ApplyEffectToObject(DURATION_TYPE_PERMANENT, eGirlHP, oKiller);}
  if(Random(100) >= 55)
      AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyVampiricRegeneration(1), GetItemInSlot(INVENTORY_SLOT_RIGHTHAND, oKiller));
              if(Random(100) >= 72)
     AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyReducedSavingThrowVsX(IP_CONST_SAVEVS_MINDAFFECTING, 1), GetItemInSlot(INVENTORY_SLOT_RIGHTHAND, oKiller));
    if(Random(100) >= 63)
       AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyBonusSavingThrowVsX(IP_CONST_SAVEVS_FEAR, 1), GetItemInSlot(INVENTORY_SLOT_RIGHTHAND, oKiller));


    if(Random(100) >= 91)

AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDecreaseAbility(IP_CONST_ABILITY_CON, 1), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 90)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDecreaseAbility(IP_CONST_ABILITY_CHA, 1), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 88)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDecreaseSkill(SKILL_DISCIPLINE, 1), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 85)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDecreaseAC(IP_CONST_ACMODIFIERTYPE_DEFLECTION, 1), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 92)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDecreaseAC(IP_CONST_ACMODIFIERTYPE_DODGE, 1), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 93)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDecreaseAC(IP_CONST_ACMODIFIERTYPE_NATURAL, 1), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 82)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyReducedSavingThrow(IP_CONST_SAVEBASETYPE_WILL, 1), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 83)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDecreaseAbility(IP_CONST_ABILITY_INT, 1), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));

    if(Random(100) >= 86)

AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDamageImmunity(IP_CONST_DAMAGETYPE_PIERCING, IP_CONST_DAMAGEIMMUNITY_10_PERCENT), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 88)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDamageImmunity(IP_CONST_DAMAGETYPE_BLUDGEONING, IP_CONST_DAMAGEIMMUNITY_5_PERCENT), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));
if(Random(100) >= 90)
AddItemProperty(DURATION_TYPE_PERMANENT, ItemPropertyDamageImmunity(IP_CONST_DAMAGETYPE_DIVINE, IP_CONST_DAMAGEIMMUNITY_10_PERCENT), GetItemInSlot(INVENTORY_SLOT_CARMOUR, oKiller));

}

===============================================================================================

Малый Амулет Мастера «Магу Цирессе Гинд’ра удалось проникнуть к Ночным Маскам Арфистов незадолго до того, как она утонула в луже глубиной в пять сантиметров недалеко от своего дома. Чтобы проникнуть к ним, Циресса изготовила амулет, позволяющий имитировать способности мастера-вора. Однажды ночью она воспользовалась этим амулетом, чтобы пробраться в частные владения Короля Ночи. Она не знала о личной страже Короля, которой помогало постоянно действующее заклинание обнаружения. Когда Король Ночи покончил с Цирессой, он забрал у нее этот амулет. Так как амулет обладал качествами, полезными для любого искателя приключений, Король создал его копии и начал продавать их по всей стране.»
Бонус к умению: Взлом замков +2
Бонус к умению: Знание +2
Бонус к умению: Обезвредить ловушку +2
Бонус к умению: Поиск +2
Бонус к умению: Убеждение +2
Сопротивление магии 12
Сотворить заклинание: Хитрость мошенника (3) 1 раз/день

Амулет Здоровья «Натнея Чеш была одной из первых жриц Келемвора на Муншейских островах. Она получила прозвище «Защитница Мертвых», когда помешала одному некроманту вызвать армию нежити. В качестве награды за ее подвиг Келемвор дал ей этот амулет и раскрыл тайну создания таких же амулетов для клериков, посвятивших себя борьбе с могущественным злом нежити. С тех пор многие воры на собственном опыте поняли, что эти амулеты могут быть просто незаменимыми в их сфере деятельности.»
Иммунитет: смешанный: Болезнь
Иммунитет: смешанный: Понижение уровня/способности
Иммунитет: смешанный: Яд
КЗ бонус пр. расовой группы: Нежить +7
Сотворить заклинание: Исцеление критических ран (7) 5 раз/день

Big World P «Плащи представляют из себя обычные предметы гардероба, используемые для защиты обладателя от ненастья и иных неприятностей в пути.»
Бонус к способности: Телосложение +5
КЗ бонус +5
Сотворить заклинание: Улучшенная невидимость (7) 3 раз/день
Сотворить заклинание: Ультра-зрение (6) 3 раз/день
Сотворить заклинание: Ускорение (10) 3 раз/день

Delivery Item «Tales of The Hullack Forest — Затонувшее кладбище

Рассказы путешественников из Халлакского леса на восток рассказывают о таинственном кладбище, возникшем из земли, окутанной вечной ночью. Вы путешествовали по дороге из Арабель на запад через холмы и леса Кормира, что кажется веками — веками без происшествий — по крайней мере, до сих пор. Осмелитесь ли вы пойти вперед, чтобы увидеть, есть ли в этих сказках доля правды?»

Сотворить заклинание: Призвание существа I (5) Неограниченно раз/день
Сотворить заклинание: Разделение Морденкайнена (17) 1 раз/день

Амулет изгнания нежити «Эти ожерелья иногда раздавались могущественными храмами верующим, чтобы защитить их от нежити во время выполнения священных миссий. Подобные ожерелья могут использовать только не злые клерики и паладины. Чаще всего такие амулеты можно найти у последователей Латандера, и на них часто изображают символ Владыки зари. Это дроу-жрицы.»
Бонус к навыку: Дополнительное изгнание
Иммунитет: заклинания за уровень 7 уровня и ниже
Использовать ограничение: класс: Жрец
Использовать ограничение: класс: Паладин
Легкая Слабый (10 м) Красный
Сокращенный показатель Параметра: Интеллект -3
Сотворить заклинание: Изгнание (15) 1 раз/день

Mifril Egggss SS «Амулеты — это нашейные украшения с различными знаками или символами. Большинство из них являются лишь безделушками, но некоторые могут быть магическими предметами.»
Бонус к способности: Интеллект +4
Сокращенные спасброски: Против разума -5
Сокращенные спасброски: индивидуальные: Воля -5
Сокращенный КЗ: КЗ Естественный модификатор -5
Уменьшение повреждений: +3 Поглощение урона 40
Ячейка уровня бонуса: Волшебник Уровень 9

Нет, спасибо лесбоживотик-дриада.

_<////


Один комментарий на «“Восстанелла”»

Оставьте комментарий

Создайте подобный сайт на WordPress.com
Начало работы