That is experiment.Barbie wrote:I'd not use Title but the map name here - Title is not necessary unique among a set of maps...Code: Select all
if(Level.Title == AnyTweaker[i].MapTitle)
Ofc I am going to use Map names instead of title.
That is experiment.Barbie wrote:I'd not use Title but the map name here - Title is not necessary unique among a set of maps...Code: Select all
if(Level.Title == AnyTweaker[i].MapTitle)
Code: Select all
class NoLost expands Actor;
var() float Interval;
var() int RangeRun;
var bool bGoodSet, bReady;
event PostBeginPlay()
{
if ( Interval > 4.00 )
bGoodSet=True;
else log (Self.Name$" >> Check Settings, Bad move!");
}
function CheckLost()
{
local Bot aBotyMan;
local PathNode N, N1;
local int BestPointDist;
BestPointDist = RangeRun;
foreach AllActors (class 'Bot', aBotyMan)
{
if ( !aBotyMan.bHidden && aBotyMan.Health > 0
&& aBotyMan.Enemy == None && aBotyMan.Orders != 'Follow'
&& aBotyMan.MoveTarget == None && aBotyMan.IsInstate('Wandering') )
{
if ( !NearbyNode(aBotyMan) )
{
foreach RadiusActors ( class 'PathNode', N, RangeRun , ABotyMan.Location)
{
if (VSize(N.Location-aBotyMan.Location) <= BestPointDist && FastTrace(N.Location,aBotyMan.Location))
{
N1 = N;
BestPointDist = Vsize(N.Location - aBotyMan.Location);
}
}
if ( N1 != None && aBotyMan.FastTrace(N1.Location,aBotyMan.Location))
{
aBotyMan.Target = N1;
aBotyMan.MoveTarget = N1;
aBotyMan.bCamping = False;
aBotyMan.PlayRunning();
aBotyMan.GotoState('Roaming','SpecialNavig');
}
}
}
}
}
function bool NearbyNode(Bot aBotyMan)
{
local bool bIsNearby;
local Pathnode P;
bIsNearby = False;
foreach RadiusActors( class 'PathNode',P,500,aBotyMan.Location )
{
if ( FastTrace(P.Location,aBotyMan.Location) )
{
bIsNearby = True;
break;
}
}
return bIsNearby;
}
state FixSeeker
{
Begin:
Sleep(3.00);
DoLooping:
if ( !Level.Game.bGameEnded && bGoodSet )
CheckLost();
else
Goto('TheEnd');
Sleep(Interval);
Goto('DoLooping');
TheEnd:
}
defaultproperties
{
InitialState=FixSeeker
}
Indeed here I might try to avoid <taken> targets (in hoping to not see engine mooing at me - because will need other heavy check then). The goal on purpose was to be more interested about loading weaponry and using even translocator for speed. But I might do small changes. The truth is that I did not love in Deck16][ their less interest for PulseGun (only in combat they were being interested about it) else even BotyMan3 proved me what dumb pathing was done there in some spots (around minigun). I might think well at some solution against triangle looping as that Deck does... because so far it was a harder job, maybe adding cost temporary for spots which are too often roamed for being interested in alternate routes... heck new variables new resets...OjitroC wrote: also it may attempt to follow the player or another bot up on to a box or ledge, resulting in a telefragging.
They're certainly more interested in loading weaponry now - also, now you mention it, I do notice MBot_C using the translocator for speed, to get on to a ramp from the ground for example - just have to make sure that you're not too close when they do.sektor2111 wrote:The goal on purpose was to be more interested about loading weaponry and using even translocator for speed.
Code: Select all
if((MyTranslocator != None) && !Region.Zone.bWaterZone && PlayerReplicationInfo.HasFlag == None)
{
if(RouteCache[2] != None && !RouteCache[2].Region.Zone.bWaterZone)
{
if(VSize(RouteCache[2].Location - Location) > 500 && VSize(RouteCache[2].Location - Location) < 910 && FastTrace(RouteCache[2].Location, Location))
{
TranslocateToTarget2(RouteCache[2]);
return;
}
}
}
Code: Select all
function TranslocateToTarget2(Actor Destn)
{
foreach AllActors(class'TranslocatorTarget',TT)
{
if(TT != None && TT.Instigator == Self && TT.Instigator != None )
{
PlaySound(MyTranslocator.AltFireSound);
//TT.LifeSpan = 1.0;
TT.Destroy();
}
}
PendingWeapon = MyTranslocator;
MyTranslocator.DesiredTarget = Destn;
//if ( Weapon == None )
//ChangedWeapon();
if ( Weapon != PendingWeapon )
Weapon.PutDown();
else
MyTranslocator.PlayPostSelect();
MoveTarget = Destn;
DesiredRotation = Rotator(MoveTarget.Location - Location);
}
Code: Select all
defaultproperties
{
CarcassType=Class'Botpack.TMale1Carcass'
drown=Sound'Botpack.MaleSounds.(All).drownM02'
breathagain=Sound'Botpack.MaleSounds.(All).gasp02'
HitSound3=Sound'Botpack.MaleSounds.(All).injurM04'
HitSound4=Sound'Botpack.MaleSounds.(All).injurH5'
Deaths(0)=Sound'Botpack.MaleSounds.(All).deathc1'
Deaths(1)=Sound'Botpack.MaleSounds.(All).deathc51'
Deaths(2)=Sound'Botpack.MaleSounds.(All).deathc3'
Deaths(3)=Sound'Botpack.MaleSounds.(All).deathc4'
Deaths(4)=Sound'Botpack.MaleSounds.(All).deathc53'
Deaths(5)=Sound'Botpack.MaleSounds.(All).deathc53'
GaspSound=Sound'Botpack.MaleSounds.(All).hgasp1'
UWHit1=Sound'Botpack.MaleSounds.(All).UWinjur41'
UWHit2=Sound'Botpack.MaleSounds.(All).UWinjur42'
LandGrunt=Sound'Botpack.MaleSounds.(All).land01'
JumpSound=Sound'Botpack.MaleSounds.(All).jump1'
VoicePackMetaClass="BotPack.VoiceMale"
HitSound1=Sound'Botpack.MaleSounds.(All).injurL2'
HitSound2=Sound'Botpack.MaleSounds.(All).injurL04'
Die=Sound'Botpack.MaleSounds.(All).deathc1'
}
Code: Select all
defaultproperties
{
CarcassType=Class'Botpack.TMale1Carcass'
drown=Sound'Botpack.drownM02'
breathagain=Sound'Botpack.gasp02'
HitSound3=Sound'Botpack.injurM04'
HitSound4=Sound'Botpack.injurH5'
Deaths(0)=Sound'Botpack.deathc1'
Deaths(1)=Sound'Botpack.deathc51'
Deaths(2)=Sound'Botpack.deathc3'
Deaths(3)=Sound'Botpack.deathc4'
Deaths(4)=Sound'Botpack.deathc53'
Deaths(5)=Sound'Botpack.deathc53'
GaspSound=Sound'Botpack.hgasp1'
UWHit1=Sound'Botpack.UWinjur41'
UWHit2=Sound'Botpack.UWinjur42'
LandGrunt=Sound'UnrealShare.Male.MLand3'
JumpSound=Sound'Botpack.jump1'
VoicePackMetaClass="BotPack.VoiceMale"
HitSound1=Sound'Botpack.injurL2'
HitSound2=Sound'Botpack.injurL04'
Die=Sound'Botpack.deathc1'
}
Code: Select all
function TranslocateToTarget(Actor Destn)
{
local float Distance;
PendingWeapon = MyTranslocator;
MyTranslocator.DesiredTarget = Destn;
if ( Weapon == None )
ChangedWeapon();
else if ( Weapon != PendingWeapon )
Weapon.PutDown();
else
MyTranslocator.PlayPostSelect();
MoveTarget = Destn;
DesiredRotation = rotator(MoveTarget.Location - Location);
Distance = VSize(MoveTarget.Location - Location);
if ( Enemy == None || (Enemy != None && !LineOfSightTo(Enemy)) )
SpecialPause = (Distance*1.7)/450; //Presuming at 500 we need 1.7 seconds then... for 1100 need more
// SpecialPause = 1.5; //Drop this in toilette
}
Code: Select all
JL3160:
if ( MoveTarget != None && !MoveTarget.IsA('Teleporter') )
{
if ( MoveTarget.Base == None
&& MoveTarget.Location.Z > Location.Z + CollisionHeight + MaxStepHeight
&& LineOfSightTo(MoveTarget) && MoveTarget.Location.Z - Location.Z < 801
&& !FastTrace(FootRegion.Zone.Location, MoveTarget.Location+vect(0,0,-20)) )
{
if ( bCanTranslocate && !MoveTarget.Region.Zone.bWaterZone && !HeadRegion.Zone.bWaterZone )
TranslocateToTarget(MoveTarget);
}
}