Author Topic: Simple question from a beginner.  (Read 513 times)

Legacy_EvanWaveCaller

  • Newbie
  • *
  • Posts: 4
  • Karma: +0/-0
Simple question from a beginner.
« on: April 22, 2011, 05:00:03 am »


               I am a beginner at the toolset, and on my first module, I need the main quest giver to have a floating text above his head that says "Come over and talk to me". I ha
I have tried many different ways, but I can't figure it out. Any help is appreciated.
EDIT: I need it to appear when the pc enters the room. Thanks for helping.
               
               

               


                     Modifié par EvanWaveCaller, 22 avril 2011 - 04:09 .
                     
                  


            

Legacy_Aleron

  • Full Member
  • ***
  • Posts: 227
  • Karma: +0/-0
Simple question from a beginner.
« Reply #1 on: April 22, 2011, 05:04:45 am »


               It is the creature's name. That should be the easiest way to do it. Right click the creature, hit properties, and enter that text string for the name. Should appear over their head. Or that's how I'd do it thinking off hand. The pros here might have a better idea.
               
               

               
            

Legacy_Tassle_Hof

  • Newbie
  • *
  • Posts: 43
  • Karma: +0/-0
Simple question from a beginner.
« Reply #2 on: April 22, 2011, 01:37:36 pm »


               If you put a script on the OnEnter event of the area the PC is going into the text will appear over the NPC's head when the PC enters the room. Here is a sample script that I have used.

//Put this script OnEnter
void main()
{

object oPC = GetEnteringObject();

if (!GetIsPC(oPC)) return;

int DoOnce = GetLocalInt(OBJECT_SELF, GetTag(OBJECT_SELF));

if (DoOnce==TRUE) return;

SetLocalInt(OBJECT_SELF, GetTag(OBJECT_SELF), TRUE);

AssignCommand(GetObjectByTag("Zach"), ActionSpeakString("Come over and talk to me."));

}


Where it says GetObjectByTag("Zach") - enter the tag of your NPC you want to have saying it. This script is set so that it only happens once, the first time the PC enters the room. You can modify that to suit your needs. Hope this helps. BTW - Lilac Soul Script Generator is a wonderful tool for those of us just learning. I don't have a link right now but if you search the help threads it is in there.
               
               

               
            

Legacy_EvanWaveCaller

  • Newbie
  • *
  • Posts: 4
  • Karma: +0/-0
Simple question from a beginner.
« Reply #3 on: April 22, 2011, 07:11:34 pm »


               Thanks. That worked like a charm.