Page 1 of 1

I'm Looking Around

Posted: Sun May 10, 2020 11:34 pm
by Nelsona
Exactly... why wasting time for setting up a DefensePoint into the right direction ? Why not being more unpredictable and looking around instead of reacting like a robot doing the same thing all time ? This is... some YourLevel or whatever MyLevel:

Code: Select all

class SearchDefensePoint expands DefensePoint;

var() int RRate;

event PreBeginPlay()
{
	Super.PreBeginPlay();
	InitialState = 'Tracking';
	bFixedRotationDir = True;
}

state() Tracking
{
Begin:
	Sleep(1);
	if ( Physics != PHYS_Rotating )
		SetPhysics(PHYS_Rotating);
Loop:
	RRate = RandRange(-13000,13000);
	RotationRate.Yaw = RRate;
	lookdir = 2000 * vector(Rotation);
	Sleep(1);
	GoTo('Loop');
}
Anyone knowing what is this ?
If this is an open area, in which direction do I need to look ?
Answer: Everywhere, enemy can be everywhere... lol.

Re: I'm Looking Around

Posted: Sun May 10, 2020 11:37 pm
by SC]-[WARTZ_{HoF}
That was in a map under mylevel. You come across some strange things in maps.

Re: I'm Looking Around

Posted: Sun May 10, 2020 11:40 pm
by Nelsona
I wrote this a few minutes ago... Niiice.

Re: I'm Looking Around

Posted: Mon May 11, 2020 1:40 am
by SC]-[WARTZ_{HoF}
I see now. Thought this was something you found. Didn’t know you wrote it.

Re: I'm Looking Around

Posted: Mon May 11, 2020 2:28 pm
by Nelsona
Nope, I found a waste of time task for rotating an ambush point whatever defense into the right direction - still failing to see enemy coming from a direction and causing a permanent "security" flaw at Base. We have Defender turning from time to time looking... where Engine wants - not me, that mapper bugs creator, lol.
This is what I wanted a few days ago, but using rotation did not help until I studied code. I realized that "lookdir" must be updated for dynamic guarding. For update I went at using a RANDOM stuff less predictable as sprite even if it's used "showall". Now guards are looking around...
Note: This NavigationPoint must NOT BE bStatic as default property but it can be bNoDelete for saving network and not being ruined and damaging navigation. If it's being properly set, it works properly.

Re: I'm Looking Around

Posted: Mon May 11, 2020 2:43 pm
by Nelsona
Other chapter - ahemm

Get The Flag !
Oops, it's not here ? No, it's elsewhere maybe RedBase and/or BlueBase have two/three places randomly sorted for their flags - enemy is participating at lottery.
Jerky lottery won't work in games using CTFFlagTracker whatever mutator, because this one helps human at finding Flag with any matter.
So it might not be the best idea... it's only in theory so far.