OK, based upon what limited information you gave me, here is your fix, I hope...
void main()
{
object oPC = GetLastPerceived();
if (!GetIsPC(oPC))
{return;}
float fDelay = 0.0; // By default there is NO delay.
// NOTE: Delays are in Seconds! 2.5 = 2 seconds and One Half of a seconds
string sSpeakString;
if (!GetIsInCombat() && GetLastPerceptionSeen() && !IsInConversation(OBJECT_SELF))
{
switch (d6())
{
case 1:
{ fDelay = 1.1; // NOTE: You need to set the delay time for EACH Case!
sSpeakString = "Oh look what I found in my bag.";} break;
case 2:
{ fDelay = 1.2; sSpeakString = "Hey Mr, did you drop this?";} break;
case 3:
{ fDelay = 1.3; sSpeakString = "I am so bored"; }break;
case 4:
{ fDelay = 1.4; sSpeakString = "Any Dwagons to hunt here?"; }break;
case 5:
{ fDelay = 1.5; sSpeakString = "That ring is nice and shiny!"; }break;
case 6:
{ fDelay = 1.6; sSpeakString = "Hey Fizban, how about some fireworks?"; }break;
}
DelayCommand(fDelay, SpeakString(sSpeakString, TALKVOLUME_TALK));
}
Modifié par _Guile, 30 août 2011 - 12:00 .