Player Resource Consortium

 

Author Topic: need help?  (Read 10545 times)

0 Members and 1 Guest are viewing this topic.

June 08, 2011, 11:37:31 AM
Reply #15
  • Jr. Associate
  • **
  • Posts: 88
  • Karma: +0/-0
    • View Profile

oki dokie, ill take a look at this as soon as i finish optinizing mod. 1k maps is hard to manage, specialy with all those plasables triggering heart beats lol, so im now working on some optimization to get some basic prc stuff back to work. laik intuitive attack.

i also added some of the acp emotes on the feats and spells 2da. did not put much effort on this since its only there for roll playing but it works fine, i included those in the player tools since i did not want to mess up with future prc stuff, if youd like, i could copy paste the spells and feat lines to include them as per prc-acp compativility.

known issue:
i took some random tlk line for the spell / feat names, so ull see that a "charge" emote is named under maybe psyionic warrior xxx
lol


June 09, 2011, 01:38:23 AM
Reply #16
  • Jr. Associate
  • **
  • Posts: 88
  • Karma: +0/-0
    • View Profile

i edited uliving weapon a bit to allow casting on self summons without saves.

here's code, u might want to add it or add the idea, whichever works better 4 u. or not lol


pasting only main, rest is same old same

Quote
#include "prc_inc_spells"
#include "prc_add_spell_dc"
void main()
{
    // Set the spellschool
    PRCSetSchool(SPELL_SCHOOL_NECROMANCY);

    // Run the spellhook.
    if (!X2PreSpellCastCode()) return;

    object oPC = OBJECT_SELF;
    object oTarget = PRCGetSpellTargetObject();
    int nDC = PRCGetSaveDC(oTarget, oPC);
    int nCasterLvl = PRCGetCasterLevel(oPC);
    float fDur = HoursToSeconds(nCasterLvl);
    int nCounter = (FloatToInt(fDur))/3;
    int nSaved = 0;

    //Spell Resistance
    if (!PRCDoResistSpell(oPC, oTarget, nCasterLvl + SPGetPenetr()))
    {
        //Saving Throw
        if (!PRCMySavingThrow(SAVING_THROW_WILL, oTarget, nDC, SAVING_THROW_TYPE_SPELL))
        {
            if(PRCGetMetaMagicFeat() & METAMAGIC_EXTEND)
            {
                fDur += fDur;
            }

            int nHP = GetCurrentHitPoints(oTarget);

            HiImABomb(oTarget, nCounter, nHP, nCasterLvl);
            nSaved = 1;
        }

    }

// undead summons should let their masters cast unliving weapon on them without
   if (nSaved == 0){

if (GetMaster(oTarget) == oPC){
            if(PRCGetMetaMagicFeat() & METAMAGIC_EXTEND)
            {
                fDur += fDur;
            }

            int nHP = GetCurrentHitPoints(oTarget);

            HiImABomb(oTarget, nCounter, nHP, nCasterLvl);
        }
         }

   }


    SPEvilShift(oPC);
    PRCSetSchool();
}


June 09, 2011, 02:17:52 AM
Reply #17
  • Hero Member
  • *****
  • Posts: 1439
  • Karma: +27/-0
  • Gender: Male
    • View Profile

I think you missed some bugs in this script ;p

metamagic check does nothing, and the spell should only be cast on undead

and shouldn't the undead be destroyed after this spell triggers?


June 09, 2011, 05:25:24 PM
Reply #18
  • Jr. Associate
  • **
  • Posts: 88
  • Karma: +0/-0
    • View Profile

yeah, well, this is just a pice of sp_unliv_weapon script, i left the script as it was, only added the nSaved int to avoid save checks on self summons.

after i read the script i saw the same things, but, its working, so, "if its not broken, dont fix it" lol

this is the only code i added to script:

Quote
// undead summons should let their masters cast unliving weapon on them without
if (nSaved == 0){

if (GetMaster(oTarget) == oPC){

int nHP = GetCurrentHitPoints(oTarget);

HiImABomb(oTarget, nCounter, nHP, nCasterLvl);
}
}


with the definition for nSaved int ofc


June 11, 2011, 05:20:49 PM
Reply #19
  • Jr. Associate
  • **
  • Posts: 88
  • Karma: +0/-0
    • View Profile

water breathing spell is also broken, no inmunities are provided


June 13, 2011, 08:23:22 AM
Reply #20
  • Hero Member
  • *****
  • Posts: 1439
  • Karma: +27/-0
  • Gender: Male
    • View Profile

it works for me (I get an extra effect icon on my character after casting the spell) - it should provide immunity to drown and mass drown spells.


June 16, 2011, 01:23:05 AM
Reply #21
  • Jr. Associate
  • **
  • Posts: 88
  • Karma: +0/-0
    • View Profile

hmm.. k, will doble check, odd i casted the spell my self, i checked code and seemed fine, will doble check, thx again xwarren