Page 1 of 1
Race Check
Posted: Wed Nov 05, 2003 11:18 pm
by Sili
Is it possible for an NPC to do a race check within a conversation?
ex.
NPC- Hello.
PC- Can I ask a question?
NPC- Yes. (if the PC is dwarven)
conversation continues
else
NPC- No. (if the PC is not dwarven)
conversation ends
Sili
Re: Race Check
Posted: Wed Nov 05, 2003 11:26 pm
by Aloro
Sili wrote:Is it possible for an NPC to do a race check within a conversation?
ex.
NPC- Hello.
PC- Can I ask a question?
NPC- Yes. (if the PC is dwarven)
conversation continues
else
NPC- No. (if the PC is not dwarven)
conversation ends
Sili
Sure.
Oh, wait, you wanted more than just an answer, didn't you?
* sighs *
OK, what ya do is something like this (pseudocode written at the office):
Code: Select all
int StartingConditional()
{
object oPC = GetPCSpeaker();
int iRace = GetRacialType(oPC);
if (iRace = RACIAL_TYPE_DWARF) return TRUE;
else return FALSE;
}
Put that in the starting conditional, and whatever it's attached to will be spoken only to dwarves.
- Aloro