please help me!!!

Topics regarding Scripting with Reality Factory
Post Reply
User avatar
BLACK_PHOENIX
Posts: 126
Joined: Wed Sep 27, 2006 6:42 am

please help me!!!

Post by BLACK_PHOENIX »

how can i make a sript that for example :

i have a base lvl (like a hub where i choose a certain mission) and i have a selection of missions but only one is available. then i play the first lvl, finish and return to base lvl. then the second mission is available now becuase i finished the first lvl. etc.

i want a mission by mission script but instead of going in order i choose what mission i want form lets say a npc in a base lvl where i return after each mission.(i also want it so that a mission cant be played unless the previous is finished)

please help. :cry:
User avatar
jonas
Posts: 779
Joined: Tue Jul 05, 2005 5:43 pm
Location: Texas, USA
Contact:

Post by jonas »

So you don't want the npc to have the option available intill the level is finished right?

You would have a level controller script. In the level controller script you can have an eventstate start and have it set to false. When the mission is completed it changes the eventstate to true. Then you have your pawn waiting for the eventstate to become true, once it does the conversation becomes available.
scripting_lc.s wrote: WaitFlag[()
{
self.ThinkTime = 0.1;

if(GetEventState("ForceCamera1")=false)
{ self.think = "CheckDistance"; }
else
{ self.think = "WaitFlag"; }
}]
scripting_virgil.s wrote: Spawn[()
{
//Console(true);
SetEventState("ForceCamera1", true);
SetHudDraw(false);
Scale(1.15);
MoveForward("Walk", SPEED, 45, "");
RotateMove("", SPEED, SPEED, 0, -40, 0, "");
MoveForward("", SPEED, 100, "");
RotateMove("", SPEED, SPEED, 0, -70, 0, "");

ShowTextDelay(1, "Nout", "Idle", "Hello,<CR>My name is Nout.", FONT, 2, "", 0, -150, "left", 255);
ShowTextDelay(2, "Nout", "Idle", "This is a small demo showing<CR>some of the new scripting features", FONT, 2, "", 0, -150, "left", 255);
ShowTextDelay(3, "Nout", "Idle", "Note the multi-line feature<CR>and alignments in this text!", FONT, 2, "", 0, -150, "left", 255);
ShowTextDelay(4, "Nout", "Idle", "Just sit back and watch...", FONT, 2, "", 0, -150, "left", 255);
SetFlag(1, true); //Start up Rob to walk in
NewOrder("WaitForRob");
}]
and instead of doing it like they did and having the level controller wait you could have the pawn wait.

You also might try using flags.

I hope that helps.
Jonas

Focused, hard work is the real key to success. Keep your eyes on the goal, and just keep taking the next step towards completing it. If you aren't sure which way to do something, do it both ways and see which works better. - John Carmack
User avatar
BLACK_PHOENIX
Posts: 126
Joined: Wed Sep 27, 2006 6:42 am

Post by BLACK_PHOENIX »

thanks.

but i still have questions:

1. what do i do so that when i come up to the pawn, the pawn does not ask me until i press a key eg. shift



2. how do i do it so that a message/image comes up on top of the pawns saying talk. then i click the actual image/message and it opens up a mission menu. i want the message to face me at all times. i also want it so that the message only comes up when im within 10 texels away from the pawn.


3. i wnt the pawn to appear on my radar as an ally(green). the same as Q2 but how can i make it so that i come up to the pawn and click on him. then the mission menu comes up

4. how can i have no weapons(1st p-m) in a certain lvl.
Post Reply