The backdrop here is: The PC wakes up on a beach with no memory (except for name, race and class) or equipment,.
As such I've decided that most PC's will start off with an alignment of N, but certain classes (as you know) has alignment restrictions, so a paladin has to be LG. But how can I identify the class of the PC? If they are higher than lvl 1 they will not enter at the same spot as newly created char, so multi-classing should not be an issue here.
the Script so far is like this.... with thx to Morbane for the removal of items
void main()
{
object oPC = GetEnteringObject();
if(GetLocalInt(oPC, "looseitems") == TRUE) return;
object oFM = GetFirstFactionMember(oPC, FALSE);
object oItem = GetFirstItemInInventory(oFM);
while (GetIsObjectValid(oFM))
{
while (GetIsObjectValid(oItem))
{
DestroyObject(oItem, 0.0f, FALSE);
oItem = GetNextItemInInventory(oFM);
}
int nSlot = 0;
while ( nSlot <= NUM_INVENTORY_SLOTS )
{
object oItem = GetItemInSlot(nSlot, oFM);
if (GetIsObjectValid(oItem))
{
DestroyObject(oItem, 0.0f, 0);
}
nSlot++;
}
oFM = GetNextFactionMember(oFM, FALSE);
}
/*
This should be in a conditional, class related (Paladin, Warlock)
switch(oPC, nclass)
{
case class_TYPE_MONK :
{
AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
AdjustAlignment(oPC, ALIGNMENT_LAWFUL, 50);
}
case class_TYPE_WARLOCK:
{
AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
AdjustAlignment(oPC, ALIGNMENT_CHAOTIC, 50);
}
case class_TYPE_FIGHTER: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_BARBARIAN: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_BARD: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_CLERIC: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_DRUID: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_FAVORED_SOUL: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_RANGER: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_ROGUE: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_SORCERER: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_SPIRIT_SHAMAN: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
case class_TYPE_WIZARD: AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 50);
}
*/
SetLocalInt(oPC, "looseitems", TRUE);
}
I just have no idea how to implement the alignment adjustment... as no function seems to get the class type
Any input is welcome





Retour en haut







