lfnetwork.com mark read register faq members calendar

Thread: On enter scripts and booleans
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 06-26-2013, 12:04 AM   #1
Canderis
Mercenary
 
Canderis's Avatar
 
Join Date: Jun 2008
Location: Unknown
Posts: 2,503
Current Game: Skyrim
Veteran Modder Helpful! 
On enter scripts and booleans

Code:
void main () 
{
   SendMessageToPC(OBJECT_SELF,"I Fired");

   if (GetGlobalBoolean("EXQ_EV1") == TRUE) { 
        SendMessageToPC(OBJECT_SELF,"I Fired2");


     }
   else
     {
        SendMessageToPC(OBJECT_SELF,"I Fired3");

     }


        SendMessageToPC(OBJECT_SELF,"I Fired4");
}
Why do none of those feedback messages arrive but if i put code in to remove an npc in the conditional it removes them? Also it seems to always remove them when the condition should be false by default.




Canderis is offline   you may: quote & reply,
Old 06-26-2013, 12:29 AM   #2
VarsityPuppet
Master of Puppets
 
VarsityPuppet's Avatar
 
Join Date: May 2009
Location: MN
Posts: 1,248
Current Game: Chrono Trigger
Contest winner - Modding Forum Veteran Veteran Modder Helpful! 
OBJECT_SELF should be GetFirstPC()


Also, if (GetGlobalBoolean("EXQ_EV1") == TRUE) should be just if (GetGlobalBoolean("EXQ_EV1"))

Tends to work better that way

VarsityPuppet is offline   you may: quote & reply,
Old 06-26-2013, 01:03 AM   #3
Canderis
Mercenary
 
Canderis's Avatar
 
Join Date: Jun 2008
Location: Unknown
Posts: 2,503
Current Game: Skyrim
Veteran Modder Helpful! 
Code:
void main () 
{

   object oPC = GetFirstPC();
   object oCaller = GetObjectByTag("n_db2");


   if (!GetGlobalBoolean("EXQ_EV1")) { 

       AssignCommand(oCaller, ActionStartConversation(oPC, "exq_dlg01"));
       SetGlobalBoolean("EXQ_EV1", TRUE);

     }
   else
     {
        DestroyObject(GetObjectByTag("n_db1"));
        DestroyObject(GetObjectByTag("n_db2"));
        DestroyObject(GetObjectByTag("n_db3"));
        SetLocked(GetObjectByTag("m55aa_elv01"),FALSE);
        SendMessageToPC(GetFirstPC(),"I Fired2");
     }


        SendMessageToPC(GetFirstPC(),"I Fired1");
}
So this is the new version of the code, now when this fires, it should be doing the if not the else, the module loads up black. Any ideas?




Canderis is offline   you may: quote & reply,
Old 06-26-2013, 11:19 AM   #4
VarsityPuppet
Master of Puppets
 
VarsityPuppet's Avatar
 
Join Date: May 2009
Location: MN
Posts: 1,248
Current Game: Chrono Trigger
Contest winner - Modding Forum Veteran Veteran Modder Helpful! 
SetGlobalFadeIn?

VarsityPuppet is offline   you may: quote & reply,
Old 06-26-2013, 01:54 PM   #5
Canderis
Mercenary
 
Canderis's Avatar
 
Join Date: Jun 2008
Location: Unknown
Posts: 2,503
Current Game: Skyrim
Veteran Modder Helpful! 
Nada.


EDIT: I got it fixed. I moved the change to a different script.





Last edited by Canderis; 06-26-2013 at 02:45 PM.
Canderis 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 > On enter scripts and booleans

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 01:32 AM.

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