Jump to content

Headless Client AI w/Epoch [WIP]


Shizweak

Recommended Posts

  • 2 weeks later...

Im glad I found this thread as I have literally seen no headless client on any servers even though I've been successfully running one with highly customized Sarge AI/missions/static AI (using some DZAI ideas/code) since September until recently my server has been discontinued due to owner network issues (our server was in-house on dedicated line). 

 

My friend from Spain has a spanish community in which he now is temporarily hosting my mission file with Headless Client and all custom mission/AI work you wont find anywhere else(check link below for full core list).  The mission file is highly modified and if you can yank out the Sarge AI portion and other portions, you may be able to use some of the ideas from it.  I plan on releasing it sometime in future when we get our server going again and I get permission for any code utilized/original authors work (this could be until january)

 

His server is 91.121.120.193:3023 and he is running DayZ 1761 + Namalsk 0741.  Its super stable and this was the Full Core Feature List of those files. 

 

Glad I can help if only temporary, I hope to see HC on most servers.

 

BTW, can HFB and DayZ.ST servers host Headless client?  I know they dont use Virtual Machines so would this be possible through FTP access?

 

Thanks!

Link to comment
Share on other sites

  • 3 weeks later...

Have just got a new and improved Bus Service running using a HC. Have been doing some investigation into vehicle / driver ownership (locality) as monitoring the bus has proven to be a real pain (am still struggling with getting the junk in the road detected).

 

An interesting thing I found. I am creating the vehicle with the server then getting the HC to find it, spawn a driver and then get the driver to board and do his thing. The Bus is owned by the server right up to the point where the driver gets in, at which point, ownership is transferred automatically to the HC. The server keeps a handle on it as it can monitor the state of the bus but doesn't seem to be able to interact with it. The auto refuel script picks up that the bus is low on fuel but fails to add fuel to it..

 

Waypoints that are created by the HC still remain under ownership of the server, as far as I can tell (they are arrays not objects so no way to be entirely sure). This would explain why they are lost when transferring ownership, of 'some unit' following them, away from the server when the server created the WPs. Is ok if the client/HC creates them first though. Reason I think this is because a bit of code included in setWaypointStatements includes a diag_log which still works even though the HC created them. Have tried getting the HC to do a diag_log separately and it doesn't work, as to be expected..

 

From that am experimenting with transferring ownership of my driver back to the server if he loses connection for some reason. Even with the settings in description.ext I have still lost him (HC) before, I suspect to zombies. Though now he is a civilian, hoping that helps..

 

Locality, you gotta love it... or end up pulling your hair out and headbutting the screen repeatedly. What I would really like is a server owned bus that is driven by an HC owned driver, don't think that is going to be possible though..

Link to comment
Share on other sites

Thanks for your reply, will try to play around a bit more then.

 

 

Hrm, wouldn't it be possible to just grab !"addons\SARGE" for example to filter out all calls/settings from that folder, oder do does kinda filters only work in scripts.txt?

 

€dit: Got it working as a WIP to spawn AI with and w/o HC.

 

HC present:

AI-HC.jpg

Aggro was out of this world :D / Responsetime aswell, when I ported myself in from ~10km away it took the whole group around 10secs to be fully aware of my position, the first couple shot me after just 2 secs :D

Had red chains when getting there, but that was expected with this amount of AI / synching and my lousy Internet :(

(It looks like less AI compared to the screenshot below, but I had the others to my left. It was the exact same code that was used with/without HC so...)

 

Server is all alone:

AI-no-HC.jpg

 

Aggro was 3-4 AI per 10 seconds / responsetime ~15-45secs / No red Chains but all in all a big lagfest

 

What is that server load script that you're running there?

Link to comment
Share on other sites

I'm looking for some help in getting this setup for DZAI.  I am running a VDS server and the performance was acceptable at first but with further additions of AI strongholds and an expanding player base I need to try to offload the AI.  Any help would be appreciated.

Link to comment
Share on other sites

  • 3 weeks later...
  • 4 weeks later...

Yo.
If anyone of you pro scripters was willing to help a complete fresher with setting up that headless client, I'd be really and truely thankful. If anyone's interested hit me up either on PM or skype: velociraptorjoki. I'm struggling with it, and it's very important for me that it works. Cheers :)

Link to comment
Share on other sites

  • 1 month later...

I seemed to have made this almost work!

 

I get a popup that says 'Addon 'sauerland' requires addon 'Chernarus' that i have to click ok before he gets into the game.

 

He is not invisible and can be killed. Is it possible I missed a step?

Link to comment
Share on other sites

Assuming you have an entry for headless client in mission.sqm
 
Like the following from my mission.sqm:
 

version=11;
class Mission
{
        <other stuff blah blah............>

	class Groups
	{
		items=3;

                <other group items 1 and 2 .... blah......>

                class Item2
		{
			side="CIV";
			class Vehicles
			{
				items=1;
				class Item0
				{
					position[]={4078.8516,30.836605,4757.7241};
					id=0;
					side="CIV";
					vehicle="Survivor1_DZ";
					player="PLAYER COMMANDER";
					skill=0.60000002;
					text="HeadlessClient";
					init="this allowDamage false";
					description="HeadlessClient";
					name="HeadlessClient";
					forceHeadlessClient=1;
				};
			};
		};
         };
};

The init="this allowDamage false"; can be expanded to include callouts to "this enablesimulation false; this hideObjectGlobal true" and other things that will affect the vehicle for the HC at the moment it is created.

Link to comment
Share on other sites

Ahh excellent thanks. Im going to keep at it. I added a omma where i shouldnt have. Now that its fixed, i lose connectivity to the server as soon as the HC connects :(

 

HC RPT has 189k lines of warnings about config.bin entries heh groovy.

 

EDIT: Hmm pbo starts downloading and dies at 35kb and complains about my modified file. I see the rolling hive log and the server boots up, but it wont let me in. I also see that civilian is now activated with one slot for headless client.

Link to comment
Share on other sites

Assuming you have an entry for headless client in mission.sqm

 

Like the following from my mission.sqm:

 

version=11;
class Mission
{
        <other stuff blah blah............>

	class Groups
	{
		items=3;

                <other group items 1 and 2 .... blah......>

                class Item2
		{
			side="CIV";
			class Vehicles
			{
				items=1;
				class Item0
				{
					position[]={4078.8516,30.836605,4757.7241};
					id=0;
					side="CIV";
					vehicle="Survivor1_DZ";
					player="PLAYER COMMANDER";
					skill=0.60000002;
					text="HeadlessClient";
					init="this allowDamage false";
					description="HeadlessClient";
					name="HeadlessClient";
					forceHeadlessClient=1;
				};
			};
		};
         };
};

The init="this allowDamage false"; can be expanded to include callouts to "this enablesimulation false; this hideObjectGlobal true" and other things that will affect the vehicle for the HC at the moment it is created.

 

In your DZAI instructions it shows this:

 

    if (isServer || hasInterface) then {
        call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf";    //Compile regular functions
    }; // headless clients are like isDedicated for some things. No compiles needed from dayz_code init
 
Should it be && instead of ||?
Link to comment
Share on other sites

 

In your DZAI instructions it shows this:

 

    if (isServer || hasInterface) then {
        call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf";    //Compile regular functions
    }; // headless clients are like isDedicated for some things. No compiles needed from dayz_code init
 
Should it be && instead of ||?

 

 

No.  compiles.sqf is only necessary on a regular client or a server, not a headless client.

 

... i lose connectivity to the server as soon as the HC connects :(

 

Ummmm.  If you are running your headless client off the same cdkey or steam account as your regular client, then you have to disable ArmA's and Battleye's checks for multiple logins with same key.  I don't remember exactly what BE checks and how to fix, but in server.cfg it is kickduplicate = 0;

 

If you are serious about headless client in the long run, and want to run it on a production server, you may need to invest in another cdkey or steam account for each HC instance.

Link to comment
Share on other sites

I have the client using a seperate key.

 

EDIT: I did narrow it down to the mission.sqm, as soon as i add the two new items server will not get past loading screen. I did change group items to 3 and civilian and headless client show up in lobby.

Link to comment
Share on other sites

  • 1 month later...

I have my HC working... been trying for two days to get WAI to run with it in MPMission with no luck. I get pretty close but some things won't work (markers,hive writes, etc). I see some servers include things outside of the mission for example: [] execVM "\z\addons\headless\init.sqf";

But I get: Warning Message: Script z\addons\headless\init.sqf not found. I'm not actually sure where it's looking for this file at.

Anyone have WAI going on a HC?

Link to comment
Share on other sites

  • 2 weeks later...

The headless client is really an amazing thing i don't understand why more server are using this, it could improve it so much and cause a lot less headaches for players.

 

What my question is, is it possible to somehow load all the object on the headless client since these take in all the resource.

So all the epoch build walls/floors, Vehicles and like custom buildings?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×
×
  • Create New...