Scenario:
1 Area
2 Plots
1 Script assigned to the Area.
I want to change the flag to a plot flag via script. However the problem is I can't capture which plot is firing the event. The example below works fine if only one plot existed. In my experience I cannot have one switch statement contain plot flags from 2 distinct plots. If you do this the variable nFlag(The bit flag # being affected) will run into a problem because of duplicate Plot Flags. Therefore i'm assuming i'll need to have two switch statements (one for each Plot) and use a condition to determine which Plot is firing/calling the event. I tried using the Plot GUID but no luck so far. I'm guessing this is easy and i'm just missing something. So if someone can shed some light on this one i would greatly appreciate it. Thanks again
Example:
int StartingConditional()
{
event ev = GetCurrentEvent(); // Gets Current Event Type
int nEventType = GetEventType(ev); // Set event to nEventType
int nEventHandled = FALSE; //keep track of whether the event has been handled
string strPlot = GetEventString(ev, 0); // Plot GUID ----> Tried to use this but could not get it to work
int nFlag = GetEventInteger(ev, 1); // The bit flag # being affected
int nResult = FALSE; // used to return value for DEFINED GET events
object oPC = GetHero();
object oParty = GetParty(oPC);
plot_GlobalPlotHandler(ev); // any global plot operations
if(nEventType == EVENT_TYPE_SET_PLOT) // actions -> normal flags only
{
int nValue = GetEventInteger(ev, 2);
int nOldValue = GetEventInteger(ev, 3);
switch(nFlag) // for Plot 1
{
case QUEST_ACCEPT:
{UT_TeamAppears(1);}
}
Modifié par Tensor07, 29 décembre 2009 - 09:10 .





Retour en haut






