Testing/Debugging Hacks & Tips

Discussions about Coding and Scripting

Re: Testing/Debugging Hacks & Tips

Postby sektor2111 » Sat Jul 21, 2018 7:52 pm

Another subject.
MH-LandsOfNapali is not only a Map with an Insane number of paths, but I think I got a Hint around some of those looping spots, where Bot is skating between to closer points and... Engine will not deal with paths created by itself - I doubt for other methods used. After setting up stuff for extra "editing eye" if I can use this term, take a look at these two:
IsThisNormal.PNG
Is This Normal ? PreviousPath do seems common for both these points.
I did random checks around and I did not see two other points to have the same previous path. Probably this explains why Bot is skating there, MBot_G in testing stage do seems to randomly get over that crap. Another spot where Bots were going nasty at random is the start where I could figure another surprise:
IsThisNormal_01.PNG
5 PlayerStart around are referencing PlayerStart1. This is another random bad spot.
Let me guess... Some Editor does need a bit of Love I'm guessing...

Anyway... new Paths Network running with only 762 NavigationPoint Actors works better so far.
User avatar
sektor2111
Godlike
 
Posts: 3457
Joined: Sun May 09, 2010 6:15 pm
Location: vect(1,1,1)

Re: Testing/Debugging Hacks & Tips

Postby sektor2111 » Sun Aug 12, 2018 7:24 pm

Bumping ball. Subject: Mapping heavy routes or lifts using XC_Engine.
Snippet below belongs to functions called for spreading navigation points toward lifts and false lifts routes for getting various "geronimo" jumps from A.I. - original map had nothing here, it was messed up. Functions are wrapped without "GoTo" (I haven't got any damage accordingly but... nvm) and without any "return", that simple.
Code: Select all
final function SetLiftExit(LiftExit AnExit, name LiftTag, optional name LiftTrigger)
{
   local bool bInvalidPoint;

   bInvalidPoint = ( AnExit == None || AnExit.bDeleteMe || !AnExit.IsA('LiftExit') || LiftTag == '' );

   if ( !bInvalidPoint )
   {
      AnExit.LiftTag = LiftTag;
      if ( LiftTrigger != '' )
         AnExit.LiftTrigger = LiftTrigger;
      AnExit.PostBeginPlay(); //restart it in order to gain properties correctly
      log(AnExit.Name@has been added at@AnExit.Location);
   }
   else
      Warn("LiftExit or LiftTag undefined. A.I. for this Lift won't work properly.");
   bInvalidPoint = False;
}

final function SetLiftCenter(LiftCenter ACenter, name LiftTag, optional name LiftTrigger, optional float MaxZDiffAdd)
{
   local bool bInvalidPoint;

   bInvalidPoint = ( ACenter == None || ACenter.bDeleteMe || !ACenter.IsA('LiftCenter') || LiftTag == '' );

   if ( !bInvalidPoint )
   {
      ACenter.LiftTag = LiftTag;
      if ( LiftTrigger != '' )
         ACenter.LiftTrigger = LiftTrigger;
      if ( MaxZDiffAdd != 0 )
         ACenter.MaxZDiffAdd = MaxZDiffAdd;
      ACenter.PostBeginPlay();
      log(ACenter.Name@has been added at@ACenter.Location@having as Lift@ACenter.Base@.);
   }
   else
      Warn("LiftCenter or LiftTag undefined. A.I. for this Lift won't work properly.");
   bInvalidPoint = False;
}
Stages for these are delayed with about 0.3 seconds; during this time Movers/Doors are moved to hell for releasing space and making reachable the rest of routes tested by Mr. Scout. When Mr. Scout will finish tests and connections, movers are moved back into the original place and additional points are depleted for connecting any possible lift, this map is not having lifts but some funky door set as a ramp which will need another deal because it has to be navigable AFTER opening. Original Network being too loaded will be completely removed else code will be very long writing stuff for each bad point and wasting time writing connections. Reconfiguration of a new Network is a better option. LiftCenter and LiftExit types used are not bStatic in order to spawn properly. In about 1-2 seconds map will have a new Navigation Network with Points having BOT collision type not Skaarj collision type as Editor does. Less priority tasks are done later as long as are not an emergency, eg: toggling routes using some actors for this task and their triggers more or less connected with map's mechanics depending on situation.
The rest of adds are going to be tested multiple times before other debates.
User avatar
sektor2111
Godlike
 
Posts: 3457
Joined: Sun May 09, 2010 6:15 pm
Location: vect(1,1,1)

Previous

Return to Coding, Scripting

Who is online

Users browsing this forum: No registered users and 3 guests