lfnetwork.com mark read register faq members calendar

Thread: Help with a Jump party script
Thread Tools Display Modes
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Old 01-28-2009, 11:32 PM   #1
DarthStoney
To bed. I'm old and tired
 
DarthStoney's Avatar
 
Join Date: Apr 2006
Posts: 506
Contest winner - Modding Veteran Modder Helpful! 
Help with a Jump party script

I need a little help with a script,what I am trying to do is during a cutscene is to "hide" the PC and party members by moving them out of site. The script to remove them works fine. The issue is trying to put them back the original position doesn't work.
Here is the 1st move script which works fine
Code:
location ST_GetLoc(string sWP);
void ST_JumpToPoint(string sWP, object oJumper=OBJECT_SELF);


void main() {
        object oPC = GetFirstPC();
        object oParty1 = GetPartyMemberByIndex(0);
        object oParty2 = GetPartyMemberByIndex(1);
        object oParty3 = GetPartyMemberByIndex(2);
        
        SetLocked(GetObjectByTag("DroidPlanetDoor01"),FALSE);
        CreateObject(OBJECT_TYPE_CREATURE,"stunt_sith804",Location(Vector(189.91469,144.69569,33.13980),0.0f));
        CreateObject(OBJECT_TYPE_PLACEABLE,"stunt_sec_attack",Location(Vector(178.14030,136.05354,33.13981),0.0f));

        CreateObject(OBJECT_TYPE_PLACEABLE,"scene1",Location(Vector(177.33075,137.53647,33.13981),0.0f));
        CreateObject(OBJECT_TYPE_PLACEABLE,"scene2",Location(Vector(180.27837,133.48473,33.13981),0.0f));
        CreateObject(OBJECT_TYPE_PLACEABLE,"scene3",Location(Vector(184.71681,136.87610,33.13981),0.0f));
        CreateObject(OBJECT_TYPE_PLACEABLE,"scene4",Location(Vector(193.99925,133.94115,33.13980),0.0f));

        SetGlobalFadeOut (0.0, 1.0);
        
        object oDroid = CreateObject(OBJECT_TYPE_CREATURE, "stunt_sec_cs03", ST_GetLoc("WP_droid"));
         
        CancelCombat(oParty1);
        CancelCombat(oParty2);
        CancelCombat(oParty3);
                
        DelayCommand(1.0, ST_JumpToPoint("WP_spybc1", oParty2));
        DelayCommand(1.0, ST_JumpToPoint("WP_spybc2", oParty3));
        DelayCommand(1.1, ST_JumpToPoint("WP_spybc",  oParty1));
        
        AssignCommand(oDroid, ClearAllActions());
        DelayCommand(1.3,AssignCommand(oDroid,ActionStartConversation(oPC,"sec_record1",CONVERSATION_TYPE_CINEMATIC)));
    }

location ST_GetLoc(string sWP) {
    return GetLocation(GetObjectByTag(sWP));
}


void ST_JumpToPoint(string sWP, object oJumper=OBJECT_SELF) {
    AssignCommand(oJumper, JumpToLocation( ST_GetLoc(sWP) ));
}
I was trying a variation of this to move them back but its not working
Code:
location ST_GetLoc(string sWP);
void ST_JumpToPoint(string sWP, object oJumper=OBJECT_SELF);


void main() {
        object oPC = GetFirstPC();
        object oParty1 = GetPartyMemberByIndex(0);
        object oParty2 = GetPartyMemberByIndex(1);
        object oParty3 = GetPartyMemberByIndex(2);
        
        CancelCombat(oParty1);
        CancelCombat(oParty2);
        CancelCombat(oParty3);
                
        DelayCommand(1.0, ST_JumpToPoint("WP_home1", oParty2));
        DelayCommand(1.0, ST_JumpToPoint("WP_home2", oParty3));
        DelayCommand(1.1, ST_JumpToPoint("WP_home",  oParty1));
    }

location ST_GetLoc(string sWP) {
    return GetLocation(GetObjectByTag(sWP));
}


void ST_JumpToPoint(string sWP, object oJumper=OBJECT_SELF) {
    AssignCommand(oJumper, JumpToLocation( ST_GetLoc(sWP) ));
}
Solved problem: just needed to remove Delaycommand and everything works now.


Last edited by DarthStoney; 01-29-2009 at 12:47 PM. Reason: Solved porblem
DarthStoney is offline   you may: quote & reply,
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Go Back   LucasForums > Network > Knights of the Old Republic > Editing / Modding > Holowan Laboratories > Help with a Jump party script

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:02 AM.

LFNetwork, LLC ©2002-2011 - All rights reserved.
Powered by vBulletin®
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.