the script looks like a holdover from Nwn1, what became in Nwn2 a straightforward gc_ dialog script …
so I doubt it’s used anywhere in Nwn2, unless someone dug it up and plugged it into a dialog somewhere.
note: the CLASS_TYPE_* variables are constants defined in NwScript.nss – they are actually the row IDs in Classes.2da. That is, they are integers.
if you’re scripting and you want one for AnimalSib:
const int CLASS_TYPE_ANIMALSIB = x; // change ‘x’ to the value of the AnimalSib row in Classes.2da
( or use the (integer)rowId directly, although doing it this way is using what’s called a magic number for obvious reasons … eg. wtf is “42” )
re. the Animal Companion
don’t forget the col in Classes.2da “HasAnimalCompanion” + grant the feat Animal Companion
… Kaedrin seems to have given Animal Companions to his classes Verdant Guardian and Lion of Talisid. And i seem to recall someone figured out how to give the Paladin and/or Cleric classes a companion also … so i figure it’s possible
Both Verdant Guardian and Lion of Talisid are prestige classes. The Cleric can have an animal companion from the Animal domain but it only levels up with Cleric levels. Can a basic class use featmapping with another basic class? Could I for example take one level of Druid and then have my Animal Sib featmap to the Druid to level up the animal companion as Animal Sib progressed?
I wish I could send you a copy of my alpha files to look them over. It actually creates the animal companion entries in the bic file for the character if you accept the default configuration. I tried to approach the animal companion from a couple of different directions. My problem is that I need and AnimalSib_Companion feat and I already feel like my head is going to explode.
Sorry but upload to the cloud means nothing to me. I do not currently know of any way to send it and the zip is about 4.2 MB. If you know of a place please let me know.
no registration req’d. I tried it with a textfile and it downloaded wonderfully. go Poland :)
just remember to copy the link it presents after upload. (or we’ll never find it ever again and you’d have to re-upload). Then paste the link either here or PM it to me …
I have made progress. I turned off the domains (might test them later) and extracted a script from the KaedrinPRCpack and placed it in the animal override folder. The script is nw_s2_animalcom.NCS.
Now once I get the dinosaur companion feat I can summon the Deinonychus. Unfortunately I still cannot get him/her to level up.
He removed all of the source NSS files so I do not know what he changed.
note. The 2das are not quite correctly formatted. The only one i notice where this might be an issue is packspasib.2da – spaces are not allowed within a field unless the whole string is enclosed in double-quotes.
eg.
Cure Minor Wounds
should be either
"Cure Minor Wounds"
or
Cure_Minor_Wounds
But it’s probably not an issue since the “Label” col is rightmost in the 2da. just so you know. 2das are pretty forgiving but there is a technical definition …
Good catch, thank you for that. It was a quick fix. I have it all in excel. Just a quick search and replace of space for underscore. I glanced through the other 2da’s but I did not spot any more formatting issues. I have been glancing at your kL_MetaPrepa and unless I really do not understand what I am reading, it looks like you are just the person to help me with my Animal Level up issue. I found a loophole in the program. I cannot have a normal animal companion, but I can have a Dinosaur companion which was what I wanted anyway. He actually summons when I use Kaedrin’s version of the nw_s2_animalcom.ncs script in my override folder. (His nss files are not included though.) Now I just need him to level up. So I need the nw_s2_animalcom.ncs modified to identify the AnimalSib (245) class.
// 'anico'
/*
console script.
Grants a Paladin the AnimalCompanion feat.
NOTE: This requires a modified summoning script ( nw_s2_animalcom ) to work.
- iType : the type of companion as referenced by row in Hen_Companion.2da
- sLabel : a first name for your animal companion
Example ...
`
debugmode 1
rs anico(0,"frank")
debugmode 0
`
that's a badger by the name of frank
To revert to a standard Animal Companion run this script like so:
rs anico(-1,"")
*/
void main(int iType, string sLabel)
{
object oPc = GetControlledCharacter(OBJECT_SELF);
if (iType == -1) // clear the companion variables
{
if (GetLocalInt(oPc, "AniCoType"))
{
SendMessageToPC(oPc, "<c=green>NOTICE :</c> Your Animal Companion has been cleared.");
DeleteLocalInt(oPc, "AniCoType");
DeleteLocalString(oPc, "AniCoLabel");
}
else
SendMessageToPC(oPc, "<c=green>NOTICE :</c> Your Animal Companion was not set so there's no point in clearing it.");
}
else if (GetLevelByClass(CLASS_TYPE_PALADIN, oPc))
{
SendMessageToPC(oPc, "<c=blue>WARNING :</c> What you have done will overrule any"
+ " Animal Companion that you can summon as a Druid or Ranger or Cleric."
+ " To revert that behavior rerun this script with parameters -1 and a"
+ " blank string. Your PC will however keep the Animal Companion feat"
+ " regardless of whether you had it before - but it won't work unless"
+ " your PC has a standard Animal Companion or you run this script to"
+ " reset your Paladin's companion.");
if (!GetHasFeat(FEAT_ANIMAL_COMPANION, oPc))
FeatAdd(oPc, FEAT_ANIMAL_COMPANION, FALSE, TRUE);
iType += 1; // have to increment so that the spellscript doesn't think "0" (unset) is a badger
SetLocalInt(oPc, "AniCoType", iType);
SetLocalString(oPc, "AniCoLabel", sLabel);
}
else
SendMessageToPC(oPc, "<c=red>ERROR :</c> ( anico ) You must have levels in the Paladin class.");
}
ps. the other 2da warnings are only about whitespace, which the engine basically ignores
pps. gotta drive mom around for her lottery tickets /lolz brb
I am pleased to announce the first functioning Beta of AnimalSib. I took the script files from the spells_assoc folder of the kL_MetaPrepa project and modified them for the AnimalSib class. After I compiled them, the Dinosaur companion began to level up normally! Specifically I modified the kl_cmi_anicom.nss script to include the lines:
This confirms that a custom Basic class can have both a familiar and an Animal companion.
Still got to clean some things up but I am looking forward to trying it out. Please give it a whirl and tell me what you think. I am assuming you still have a copy of the kL_MetaPrepa project available.
If not let me know and I will upload the compiled script.
// 'anico'
/*
console script.
Grants the AnimalCompanion feat.
NOTE: This requires a modified summoning script ( nw_s2_animalcom ) to work.
- iType : the type of companion as referenced by row in Hen_Companion.2da
- sLabel : a first name for your animal companion
Example ...
`
debugmode 1
rs anico(0,"frank")
debugmode 0
`
that's a badger by the name of frank
To revert to a standard Animal Companion run this script like so:
rs anico(-1,"")
*/
//
void main(int iType, string sLabel)
{
object oPc = GetControlledCharacter(OBJECT_SELF);
if (iType == -1) // clear the anico variables
{
if (GetLocalInt(oPc, "AniCoType"))
{
SendMessageToPC(oPc, "<c=green>NOTICE :</c> Your Animal Companion has been cleared.");
DeleteLocalInt(oPc, "AniCoType");
DeleteLocalString(oPc, "AniCoLabel");
}
else
SendMessageToPC(oPc, "<c=green>NOTICE :</c> Your Animal Companion was not set so there's no point in clearing it.");
}
else
{
SendMessageToPC(oPc, "<c=blue>WARNING :</c> What you have done will overrule any"
+ " Animal Companion that you can summon as a Druid or Ranger or Cleric."
+ " To revert that behavior rerun this script with parameters -1 and a"
+ " blank string. Your PC will however keep the Animal Companion feat"
+ " regardless of whether you had it before - but it won't work unless"
+ " your PC has a standard Animal Companion or you run this script to"
+ " reset your companion.");
if (!GetHasFeat(FEAT_ANIMAL_COMPANION, oPc))
FeatAdd(oPc, FEAT_ANIMAL_COMPANION, FALSE, TRUE);
iType += 1; // have to increment so that the spellscript doesn't think "0" (unset) is a badger
SetLocalInt(oPc, "AniCoType", iType);
SetLocalString(oPc, "AniCoLabel", sLabel);
}
}
//::///////////////////////////////////////////////
//:: Summon Animal Companion
//:: 'nw_s2_animalcom'
//:: Copyright (c) 2001 Bioware Corp.
//:://////////////////////////////////////////////
/*
This spellability summons an Animal Companion.
*/
// kevL 2019 apr 24 - adapted for use by any class; requires variables that are
// set by console script 'anico'
int GetAnimalTier(object oPC);
//
void main()
{
object oCaster = OBJECT_SELF;
int iType = GetLocalInt(oCaster, "AniCoType");
if (iType)
{
iType -= 1; // incremented when set; decrement to get the true reference
string sResref = Get2DAString("hen_companion", "BASERESREF_PREFIX", iType);
sResref += IntToString(GetAnimalTier(oCaster));
SummonAnimalCompanion(oCaster, sResref);
object oAnico = GetAssociate(ASSOCIATE_TYPE_ANIMALCOMPANION, oCaster);
if (GetIsObjectValid(oAnico))
{
string sLabel = GetLocalString(oCaster, "AniCoLabel");
SetFirstName(oAnico, sLabel);
}
else
SendMessageToPC(oCaster, "<c=red>ERROR :</c> ( nw_s2_animalcom ) Animal Companion is invalid.");
}
else
SummonAnimalCompanion(); // standard summon
}
//
int GetAnimalTier(object oPC)
{
return GetTotalLevels(oPC, FALSE) / 3 + 1;
}