Polymorph Self
-
@Bolthor:
Is the actual command:
.ps goblin!
.ps goblin
"!" part of all of the commands?
The exclamation will cast it instantly if you have it memorized.
Without, it just sets it up for a later casting.
-
Just so I know, spell focus transmutation and greater spell focus transmutation are needed to transform into anything with the text nFeatTier= 1 ; } or nFeatTier= 2 ; } respectively? And nFeatTier= 0 ; } are forms that can be taken without feats?
-
how will this work if we use a metamagic version of the spell and the normal spell? (say extended spell)
-
Just so I know, spell focus transmutation and greater spell focus transmutation are needed to transform into anything with the text nFeatTier= 1 ; } or nFeatTier= 2 ; } respectively? And nFeatTier= 0 ; } are forms that can be taken without feats?
The code answers that for you here: (relevant points in bold)
if (nFeatTier == 1 && GetHasFeat(FEAT_SPELL_FOCUS_TRANSMUTATION, OBJECT_SELF) != TRUE)
{ SendMessageToPC(OBJECT_SELF, "Selected form requires spell focus in transmutation");And:
if (nFeatTier == 2 && GetHasFeat(FEAT_GREATER_SPELL_FOCUS_TRANSMUTATION, OBJECT_SELF) != TRUE)
{ SendMessageToPC(OBJECT_SELF, "Selected form requires greater spell focus in transmutation") -
longest 'yes' I've ever seen.
;) -
how will this work if we use a metamagic version of the spell and the normal spell? (say extended spell)
The code answers that for you here: (relevant points in bold)
int nDuration = nCasterLevel;
if (nMetaMagic == METAMAGIC_EXTEND) {
nDuration = nDuration *2; //Duration is +100%
}Here is some random text so that I don't answer only in quotes :D
-
I used an extended polymorph self earlier, and turned into one of the new forms.
-
Will any of the forms have their abilities like petrifying breath and so on? Cause if not, some forms have little to no reason to require SF or GSF. Mechanically, of course.
-
Not everything is mechanical. We find it acceptable to have some forms requiring SF or GSF, for the sheer awesomeness of the form itself.
-
Will any of the forms have their abilities like petrifying breath and so on? Cause if not, some forms have little to no reason to require SF or GSF. Mechanically, of course.
Most oft hem were weighted both mechanically and in a logic sense, loosely based on the Shifter acquisition levels.
There's a couple of exceptions (Krenshar, and Hook Horror being standouts for having no especially redeeming features in mechanics or RP), but most of the higher tiered ones have passive properties that're fairly potent even without their powers.
-
Let me just say, that I realy enjoy this new function.
However I tried the Human and Dwarf "variables", and they did not seem to work, I was informed to check my spelling.
I tried .ps Human and .ps HUMAN as well as .ps Dwarf
-
Let me just say, that I realy enjoy this new function.
However I tried the Human and Dwarf "variables", and they did not seem to work, I was informed to check my spelling.
I tried .ps Human and .ps HUMAN as well as .ps Dwarf
I mentioned it in bug reports, but yeah. those add-ons were after the version originally sent to the DMs. While the code is in this thread, it'lll have to wait on them having time to implement it in.
-
I copied the scrpit but I don't get anything for the polymorph. No changes at all. only cancel polymorph option. No stat changes, no apperance changes. SOmething I'm missing.
or does it only work with dot commands. and if so how does that work?
Or better yet where does this go???? N00B! I know I know.
Code:
// –------ From onPlayerChat -----------
object oPC = GetPCChatSpeaker();
string sCommand = GetPCChatMessage();if (GetStringLeft(sCommand, 3) == ".ps")
{
int nCmdLength = GetStringLength(sCommand);
int nCastNow = FALSE;// Check if there's any param to the chat command
if (nCmdLength <= 4) {
SendMessageToPC(oPC, "Usage: .ps ");
return;
}// Does it end with "!"?
if (GetStringRight(sCommand, 1) == "!") nCastNow = TRUE;string sPolyFormID = GetSubString(sCommand, 4, nCmdLength - (nCastNow?5:4));
SetLocalString(oPC, "sPolyFormID", sPolyFormID);
SendMessageToPC(oPC, "Poly set at: " + sPolyFormID);// Assign cast spell if ends with "!"
if (nCastNow) AssignCommand(oPC, ActionCastSpellAtObject(SPELL_POLYMORPH_SELF, oPC));
} -
Do you mean you just copied it for a separate module you work on?
You have to replace the nwn polymorph self script with the one above.
You have to add code in your OnPlayerChat script so that it can be activated by a vocal command.
You should also check polymorph.2da to make sure it has all the forms available in the new spell script.
-
You should also check polymorph.2da to make sure it has all the forms available in the new spell script.
This is a big one that will generate the effect of turning you into a werewolf or a headless guy with no stat changes, generally.
-
OKay I'm getting the hang of it. But here the code I'm runngin on my game.
//::///////////////////////////////////////////////
//:: Polymorph Self
//:: NW_S0_PolySelf.nss
//:: Copyright © 2001 Bioware Corp.
//:://////////////////////////////////////////////
/*
The PC is able to changed their form to one of
several forms.
*/
//:://////////////////////////////////////////////
//:: Created By: Preston Watamaniuk
//:: Created On: Jan 21, 2002
//:://////////////////////////////////////////////#include "x2_inc_spellhook"
void main()
{/*
Spellcast Hook Code
Added 2003-06-23 by GeorgZ
If you want to make changes to all spells,
check x2_inc_spellhook.nss to find out more*/
if (!X2PreSpellCastCode())
{
// If code within the PreSpellCastHook (i.e. UMD) reports FALSE, do not run this spell
return;
}// End of Spell Cast Hook
//Declare major variables
int nSpell = GetSpellId();
object oTarget = GetSpellTargetObject();
effect eVis = EffectVisualEffect(VFX_IMP_POLYMORPH);
effect ePoly;
int nPoly;
int nMetaMagic = GetMetaMagicFeat();
int nDuration = GetCasterLevel(OBJECT_SELF);
//Enter Metamagic conditions
if (nMetaMagic == METAMAGIC_EXTEND)
{
nDuration = nDuration *2; //Duration is +100%
}//Determine Polymorph subradial type
if(nSpell == 295)
{
nPoly = POLYMORPH_TYPE_DEATH_SLAAD;
}
else if (nSpell == 190)
{
nPoly = POLYMORPH_TYPE_DOOM_KNIGHT;
}
else if (nSpell == 561)
{
nPoly = POLYMORPH_TYPE_CELESTIAL_AVENGER;
}
else if (nSpell == 185)
{
nPoly = POLYMORPH_TYPE_IMP;
}
else if (nSpell == 316)
{
nPoly = POLYMORPH_TYPE_WEREWOLF;
}
ePoly = EffectPolymorph(nPoly);
//Fire cast spell at event for the specified target
SignalEvent(oTarget, EventSpellCastAt(OBJECT_SELF, SPELL_POLYMORPH_SELF, FALSE));//Apply the VFX impact and effects
AssignCommand(oTarget, ClearAllActions()); // prevents an exploit
ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oTarget);
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, ePoly, oTarget, TurnsToSeconds(nDuration));
}But they all are turning into Werewolves. Somethign I'm not seeing here. I'm just changing what the poloymorph changes into. As you can see, a death slaad and a few other. Just for a change of flavor. ANy help of what I'm missing would be great. Thanks guys.
-
If you get a Werewolf it means you tried to turn into NULL or 0 value. (Bioware werewolves are line 0 in the 2da).
In your case, I think it may lay in your determining the radial, since the values there are wildly different (jumping between 190 and 561). I'm guessing you copied lines from Shapechange, which in terms of nSpellID will only work with Shapechange, you had to leave the nSpellID bits alone, and change the nPoly Equals only.
-
Our old polymorph script, probably the original nwn one.
#include "x2_inc_spellhook" void main() { if (!X2PreSpellCastCode()) { // If code within the PreSpellCastHook (i.e. UMD) reports FALSE, do not run this spell return; } // End of Spell Cast Hook //Declare major variables int nSpell = GetSpellId(); object oTarget = GetSpellTargetObject(); ExportSingleCharacter(oTarget); //effect eVis = EffectVisualEffect(VFX_IMP_POLYMORPH); effect ePoly; int nPoly; int nMetaMagic = GetMetaMagicFeat(); int nDuration = GetCasterLevel(OBJECT_SELF); //Enter Metamagic conditions if (nMetaMagic == METAMAGIC_EXTEND) { nDuration = nDuration *2; //Duration is +100% } //Determine Polymorph subradial type if(nSpell == 387) { nPoly = POLYMORPH_TYPE_GIANT_SPIDER; } else if (nSpell == 388) { nPoly = POLYMORPH_TYPE_TROLL; } else if (nSpell == 389) { nPoly = POLYMORPH_TYPE_UMBER_HULK; } else if (nSpell == 390) { nPoly = POLYMORPH_TYPE_PIXIE; } else if (nSpell == 391) { nPoly = POLYMORPH_TYPE_ZOMBIE; } ePoly = EffectPolymorph(nPoly); //Fire cast spell at event for the specified target SignalEvent(oTarget, EventSpellCastAt(OBJECT_SELF, SPELL_POLYMORPH_SELF, FALSE)); //Apply the VFX impact and effects //ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oTarget); ApplyEffectToObject(DURATION_TYPE_TEMPORARY, ePoly, oTarget, TurnsToSeconds(nDuration)); //Empty the action queue after a polymorph - Snowy 24/09/2009 AssignCommand(oTarget, ClearAllActions(TRUE)); }
If you want new shapes, use this portion and replace only POLYMORPH_TYPE_*. Leave the rest untouched.
//Determine Polymorph subradial type if(nSpell == 387) { nPoly = POLYMORPH_TYPE_GIANT_SPIDER; } else if (nSpell == 388) { nPoly = POLYMORPH_TYPE_TROLL; } else if (nSpell == 389) { nPoly = POLYMORPH_TYPE_UMBER_HULK; } else if (nSpell == 390) { nPoly = POLYMORPH_TYPE_PIXIE; } else if (nSpell == 391) { nPoly = POLYMORPH_TYPE_ZOMBIE; }
-
OKay so insted of:
//Determine Polymorph subradial type
if(nSpell == 387)
{
nPoly = POLYMORPH_TYPE_GIANT_SPIDER;
}
else if (nSpell == 388)It should be:
//Determine Polymorph subradial type
if(nSpell == 387)
{
nPoly = POLYMORPH_TYPE_WEREWOLF;
}
else if (nSpell == 388)Thanks again guys and gals
-
Not real keen to waste the gold on a scroll to become a heavily encumbered pixie, BUT, to cast from a backup 'make me a bear to carry the dead fighter and his seven suits of armour away' scroll is it…?
Set the poly morph via .ps polar bear
then select any form via the circly menu by 'using' the scroll itself to become polar bear?