Jump to content

area transition to coordinates


Recommended Posts

I need my pc to transition to an existing area without using a waypoint. how would I go about doing that using coordinates instead?
Link to comment
Share on other sites

I made a duplicate of the storage caves and need it to accessible during the broken circle quest. thereebis no waypoint at the out from that door like there is in the mage origin. so I'm trying to do it like in that tutorial. haven't tested it yet tho.
Link to comment
Share on other sites

tried it and it worked like a charm. went into the storage caves, killed a slew of demons, exited and everyone, including Wynn who I was secretly hoping would wind up lost somewhere in the void, landed right where they were supposed to. yay! so if anyone ever has this problem, there's your solution. :)
Link to comment
Share on other sites

:wallbash: :wallbash: :wallbash: :wallbash:

 

Because I can't leave things alone. I created a more simple solution. I had this issue for a quest that I created in Lothering. After exiting the house, I selected the nearest waypoint. That meant that the entire Party was face planted against a well, but it was 'close enough'. I was sure that there was a way to relocate the entire Party, but I wasn't going to fuss with it because it wasn't really hurting anything.

 

So step 1, as it was in the link you provided:

Set a flag indicating that the GW & Party are in the "Area" that will be transitioned FROM.

This can be done in an a script associated with an object, but I set the flag in a trigger that the GW has to activate on entering my new area.

 

In the PRCSCR file....

I have some standard variables defined at the top of all of my PRCSCR files so the naming convention changes a bit and I could have done things a bit more efficiently if I hadn't needed those 'standard' variables for other things. But no harm having a LITTLE redundancy :teehee:

 

standard variable declarations:

object   oPC    = GetHero();
location iLoc   = GetLocation(oPC);
object   oArea  = GetAreaFromLocation(iLoc);
int      areaid = GetAreaID(oArea);

I didn't see a reason to add a placeable since I already knew what area the GW et all were transitioning to and it is the only PRCSCR that is going to look for that particular lag so I wrote...

if (WR_GetPlotFlag(PLT_filename, NAME_OF_FLAG))
{
     location oPCLocation = Location(oArea, Vector(289.24, 251.42, 0.63), -47.96); 
     object[] oPCParty    = GetPartyList();
     int      nindex;

     WR_SetPlotFlag(PLT_filename, NAME_OF_FLAG, FALSE);

     SetLocation(oPC, oPCLocation);    // Location of GW
     
     // Sets Positions of rest of Party
     for (nindex = 1; nindex <GetArraySize(oPCParty); nindex++)
     {
          AddCommand(oPCParty[nindex], CommandJumpToLocation(oPCLocation));
     }
}

Note that I started the counter in my 'for loop' as beginning at '1'. The GW/PC is always (as far as I can tell) the '0' array element.

 

 

And this does work (a straight copy/paste may not work since I typed this in rather than copy/paste) so my GW et al are no longer face planted into the well :tongue:

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...