Jump to content

Recommended Posts

Update: 28 Feb @ 7:43pm

v1.18
-Random Loadout at respawn fixed

 

Vandeanson's Apocalypse Mod has received a couple of updates recently:

 

fixed:

- Multiplayer issue resolved, clients are now able to join a client hosted/dedicated server

- loadout at start fixed, works for all clients now

- loadout at respawn fixed, works for all clients now

- random respawn position finder fixed, works for all clients now. Still requires a basic respawn setup (plus the VA setting enabled of course;). For example below description.ext:

 

Spoiler

respawn = "INSTANT";
respawnButton = 1;
respawnDelay = 5;
respawnOnStart = -1;

 

 

unresolved issues:

- addactions only visible to host (if not dedicated), this affects: Hideouts, VA Custom Traders for explosives, ravage respawn tents and attachments, Helicrashsite cargo storage. A fix is WIP.

 

I am very happy that the essential MP hurdles have been taken and i ll get a fix for the addactions next.

Please feel free to test the mod and let me know how you like it.

 

Cheers

VA

 

  • Like 4

Share this post


Link to post
Share on other sites

Hi VD.  Since you are talking about using DBO Horses mod, I thought I would post a fix I found to a problem.  Currently when a unit dies while mounted on horse, the dead unit stays on horse and no other unit or player can use that horse.  The fix below detaches the rider and he ragdolls.  So you can now shoot a bandit out of the saddle and take his horse.  I put the following in my init.sqf file.

_n = [] spawn
{
	sleep 2;  // give time for mod stuff to initialize
	{
		_x removeAllEventHandlers "Killed";   
		_KilledEH = _x addEventHandler ["Killed", 
		{ 
			_unit = _this select 0; 
			    if !(isNull attachedTo _unit) then 
				{
					_unit switchMove "amovpsitmstpslowwrfldnon"; // low sitting animation so you don't see dude stand on horse before he ragdolls
					detach _unit;
					_xVel = selectRandom [-4,4];
					_unit setVelocityModelSpace [_xVel,0,-2]; // Push unit left or right so doesn't fall through horse.
				};
		}]; 
	} foreach allUnits;
};

 

  • Like 1
  • Thanks 2

Share this post


Link to post
Share on other sites
Just now, johnnyboy said:

Hi VD.  Since you are talking about using DBO Horses mod, I thought I would post a fix I found to a problem.  Currently when a unit dies while mounted on horse, the dead unit stays on horse and no other unit or player can use that horse.  The fix below detaches the rider and he ragdolls.  So you can now shoot a bandit out of the saddle and take his horse.  I put the following in my init.sqf file.


_n = [] spawn
{
	sleep 2;  // give time for mod stuff to initialize
	{
		_x removeAllEventHandlers "Killed";   
		_KilledEH = _x addEventHandler ["Killed", 
		{ 
			_unit = _this select 0; 
			    if !(isNull attachedTo _unit) then 
				{
					_unit switchMove "amovpsitmstpslowwrfldnon"; // low sitting animation so you don't see dude stand on horse before he ragdolls
					detach _unit;
					_xVel = selectRandom [-4,4];
					_unit setVelocityModelSpace [_xVel,0,-2]; // Push unit left or right so doesn't fall through horse.
				};
		}]; 
	} foreach allUnits;
};

 

Aah man that rocks, thank you!

Will check it out and add it:) 

 

Cheers 

VD

  • Thanks 1

Share this post


Link to post
Share on other sites
22 minutes ago, johnnyboy said:

The fix below detaches the rider and he ragdolls.

 

Nice johnnyboy ,

but maybe you should add an if is on horse then execute the code so this wont interfere with all the units right?

also i think maybe is better to do this with a missioneventhandler ?

  • Like 1

Share this post


Link to post
Share on other sites
9 minutes ago, GEORGE FLOROS GR said:

 

Nice johnnyboy ,

but maybe you should add an if is on horse then execute the code so this wont interfere with all the units right?

also i think maybe is better to do this with a missioneventhandler ?

I added to all units, because unit might start on foot, and get on horse later.   Sure there is room for improvement.  I'm just communicating the basic solution. If there is an "attached" or "enter uav" eventhandler that would be better.

  • Like 2

Share this post


Link to post
Share on other sites
1 minute ago, johnnyboy said:

If there is an "attached" or "enter uav" eventhandler that would be better.

Sure !

The horse , is a uav and not a vehicle ?!

  • Like 1

Share this post


Link to post
Share on other sites

The horse is a vehicle, but its based on Man object.  He has done some strange thing where he creates a UAV control for riding, so you are not "getting in horse vehicle".  But I think this eventhandler could do the trick (we sense the Dead Rider animation change).  I'll try that later.

this addEventHandler ["AnimStateChanged", {
	params ["_unit", "_anim"];
}];

 

  • Like 2

Share this post


Link to post
Share on other sites

Note:  I tried the AnimStateChanged EventHandler below and it did NOT work for me.  So I am sticking with the OnKilled eventHandler described in previous post.  That's all the time I'm willing to give this right now.
 

Spoiler

_n = [] spawn
{
	sleep 2;  // give time for mod stuff to initialize
	{
		_KilledEH = _x addEventHandler ["AnimStateChanged", 
		{ 
			params ["_unit", "_anim"]; 
			if (_anim == "kia_moto_driver1" ) then // This is the death animation used by horse rider
			{
				_unit switchMove "amovpsitmstpslowwrfldnon"; // low sitting animation so you don't see dude stand on horse before he ragdolls
				detach _unit;
				_xVel = selectRandom [-4,4];
				_unit setVelocityModelSpace [_xVel,0,-2]; // Push unit left or right so doesn't fall through horse.
			};
		}]; 
	} foreach allUnits;
};

 

Share this post


Link to post
Share on other sites

I just solved another bad problem with DBO horses.  When you mount a horse player gets an action "Release UAV Controls".  If you choose this action, your character is frozen, and no controls work.  Your mission is now ruined, and you must exit.  To solve this, put the following code in your init.sqf.  When you are controlling horse, you are attached to horse and cameraOn = Horse object.  When you are in stuck condition, you are attached to horse but cameraOn = player.  This loop senses the stuck condition, and then exits player properly from horse and returns control to player.

Spoiler

// **********************************************************
// When player accidentally chooses  "Release UAV Controls" option,
// player no longer has control of his unit, and mission is ruined.
// The code below senses this condition and exits player from horse
// he can remount if he wants.  
// **********************************************************
_n = [] spawn
{
    sleep 5;
    while {true} do
    {
        sleep 2;
        if ((cameraOn == player) and (animationState player == "horse_rider") and !(isNull attachedTo player)) then
        {
            sleep .5;
            // We check same condition twice because these conditions are true for a split second when player
            // chooses "Get Off" action.  By waiting a bit, we know player is truly stuck.
            if ((cameraOn == player) and (animationState player == "horse_rider") and !(isNull attachedTo player)) then
            {
                _horse = attachedTo player;
                player switchMove "";
                detach player;
                player setVelocityModelSpace [-2,0,-2];
                removeAllActions _horse; // remove get off action then add get on action
                _hossmount = _horse addaction ["GetOn","\dbo\dbo_horses\scripts\horse_mount.sqf",nil,1.5,true,true,"","true",4,false,""];
                _horse setobjecttexture [0,"\dbo\dbo_horses\data\tack_co.paa"];
                _horse setobjecttexture [1,""];
            };
        };
    };
};

 

  • Like 4

Share this post


Link to post
Share on other sites

Upcoming basebuilding feature for Vandeanson's Apocalypse:

 

 

  • Like 3
  • Thanks 2

Share this post


Link to post
Share on other sites

WOW! Once  that is in, scores of RAVAGERS will rejoice!  

  • Like 1
  • Haha 1

Share this post


Link to post
Share on other sites

That's really cool VD.  Note, you can set damage to MOST trees and see them fall.  I did that in JBOY_BushCutter for bushes and small palm trees.  To prove this out for you,  I wrote this test script below.  Run it from the debug console and walk up to trees and see them fall.  Now there are a few trees on Tanoa that will not fall, so I tried different ways to detect these trees.  I was hoping BoundingBoxReal height changed after damage set to 1 and tree falls (but it does not).  So I settled on comparing cursorObject to tree found before setDamage to 1.  If its the same tree, then the tree did not fall, and you can use your place holder dead tree in that case.

 

I tested this on Tanoa, Altis, and Chernarus.  So far I have found only a few trees on Tanoa that do not fall.

Spoiler

_n = [] spawn 
{ 
	while {true} do 
	{ 
		{
			if (_x distance2d player < 8) then
			{
				systemchat format ["damage BEFORE=%1,      tree=%2, cursorObject BEFORE=%3", damage _x,_x, cursorObject];
				_x setdamage 1;
				sleep .5;
				systemchat format ["damage AFTER=%1,       tree=%2, cursorObject BEFORE=%3", damage _x ,_x, cursorObject];
				if (cursorObject == _x) then
				{
					hideObjectGlobal _x;
					hintc format ["Hide this tree because will not fall when damage 1:  %1",_x];
				};
			};
		} foreach nearestTerrainObjects[player, ["Tree"], 200, true]; 
		sleep 2; 
	}; 
};

 

Note that I like your dead tree substitute solution as is, so no need to change it really.  But you might want to transition from fallen tree, to dead tree (after chopping trims off small branches) to wood pile.

 

I have one ARMA complaint about falling trees:  They always fall in the same direction!  The direction of the tree object has no effect on direction tree falls.

  • Like 3

Share this post


Link to post
Share on other sites

small info update regarding the basebuilding WIP mod:

- works on dedicated server

- works with GRAD persistence script: if you build a base - it will stay there after server restart 😉

- other players can not meddle with your building addactions. While you can move and deconstruct structures you have placed, others cant.

- if you move previously placed structures - the new position will be saved

 

Below a few proof of concept pits. all the walls and sandbag walls are built into that shack (roof pillars and concrete wall)

 

inside:

FCE128C20BF47934B31FDA7C64176C6F77138F2D

 

outside:

2503C663A01F459ED7C62B42A215773BB4B477DB

 

Outside 2 (ignore the hovering wall- i wanted to test smth, and it worked;)

 

147751B0E83F6A3149F7BCDF083938E2A48F159A

 

I m excited=)

 

cheers

vd

  • Like 4
  • Thanks 1

Share this post


Link to post
Share on other sites

@johnnyboy

 

Thanks for the help. 

Will check it out, it would be best to spawn in a replacement tree only as a fallback solution indeed! 

 

Yeah it would make sense to add in another transition layer, i agree. 

Im generally not happy with the burnt tree... Will see:) 

 

  • Like 1

Share this post


Link to post
Share on other sites

Someone on yt gave me a great idea regarding the basebuilding mod:

He stated that it would be better if you can not move the object to far from your body, its more realistic if you use "arms lenght" for placing stuff. 

In the above pics, i built to maximum height. Now i will add in scaffolding that you have to setup if you want to build high up:) 

 

 

  • Like 3

Share this post


Link to post
Share on other sites
51 minutes ago, Vandeanson said:

Someone on yt gave me a great idea regarding the basebuilding mod:

He stated that it would be better if you can not move the object to far from your body, its more realistic if you use "arms lenght" for placing stuff. 

In the above pics, i built to maximum height. Now i will add in scaffolding that you have to setup if you want to build high up:) 

 

 

That seams to be the realistic aproach and I love it!

  • Like 1

Share this post


Link to post
Share on other sites
2 hours ago, Vandeanson said:

147751B0E83F6A3149F7BCDF083938E2A48F159A

 

Look at all these busy little minions!   I'm too lazy to build that.  I think I will have a picnic on the over-watch hill  in my ghillie suit and watch these guys work.  When its done, I'll snipe them all and move in!

  • Like 1
  • Haha 3

Share this post


Link to post
Share on other sites

If only ravage has zombies that could take down structures , guess we will keep having to use Ryan’s until a solution is found

  • Haha 1

Share this post


Link to post
Share on other sites

Hiho all,
I am back at the project after a break. 
I am going to prioritize optimizing the mod in respect to general code but mainly FPS wise. The mod is currently to heavy on FPS i realize. Further I have found a solution for the remaining MP issues with addactions and traders and will implement those fixes as well.
This includes to rewrite quite a bit of the code. So it will take some time. 

Once this is done I plan to further extend the mod with the following features:
- basebuilding and crafting, including ressource gathering system
- own loot economy
- own survival system
- own temperature system
- cooking/hunting/farming system
- inclusion of GRAD persistency system
- HUD connected to the above features

I do understand that others have had a go at some of the above features, but for me the fun part is to come up with something from scratch. 

Cheers
VD
 

  • Like 4
  • Thanks 1

Share this post


Link to post
Share on other sites
1 hour ago, Vandeanson said:

Hiho all,
I am back at the project after a break. 
I am going to prioritize optimizing the mod in respect to general code but mainly FPS wise. The mod is currently to heavy on FPS i realize. Further I have found a solution for the remaining MP issues with addactions and traders and will implement those fixes as well.
This includes to rewrite quite a bit of the code. So it will take some time. 

Once this is done I plan to further extend the mod with the following features:
- basebuilding and crafting, including ressource gathering system
- own loot economy
- own survival system
- own temperature system
- cooking/hunting/farming system
- inclusion of GRAD persistency system
- HUD connected to the above features

I do understand that others have had a go at some of the above features, but for me the fun part is to come up with something from scratch. 

Cheers
VD
 

welcome back VD

it's me Piston 😄 you can contact me here if you want

  • Like 1

Share this post


Link to post
Share on other sites

Very nice! Have you considered doing something akin to fortifying an existing house?

Share this post


Link to post
Share on other sites
1 hour ago, zagr said:

Piston

Piston who? 

 

 

Kiddiiing, welcome to the topic:)) 

  • Haha 1

Share this post


Link to post
Share on other sites
47 minutes ago, CrazyCorky said:

Very nice! Have you considered doing something akin to fortifying an existing house?

The current version is pretty much free placement, so you can take elements to block off a window or door indeed, even place barbwire and camonettings. Any object can be added to the blueprints and ressource requirements can be added. 

The only problem right now is to block AI from walking through placed objects, due to the way how AI pathfinding works in Arma. Worst case I ll have to work with custom AI safe zones that assign a move away waypoint to close AI... WIP:) 

Share this post


Link to post
Share on other sites
10 minutes ago, Vandeanson said:

The only problem right now is to block AI from walking through placed objects, due to the way how AI pathfinding works in Arma. Worst case I ll have to work with custom AI safe zones that assign a move away waypoint to close AI... WIP:) 

Hey VD, I'm glad you're back at it.  When you solve this issue regarding ai walking through placed objects, please post it.  I have a big long cave I'm working on, and have an issue with AI clipping through walls.  I've tried invisible wall barriers but they aren't working 100%.  That scenario is now in my backlog, so no hurry on my end.

  • Thanks 1

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×