Jump to content

A24 feedback.


Asger
 Share

Recommended Posts

6 hours ago, wowgetoffyourcellphone said:

Can I advocate once again for an "aggression range" that is separate from vision range? It's the range by which a unit will actively attack another unit or structure. It can be a separate number or a percentage of vision range (kinda like the relationship between walk speed and run speed). Stances would then adjust this range. So, Aggressive would be at 90% of vision range, Defensive would be at 50% of vision range. Point would be to make units easier to control and act less maniacally. 

This is already how it works in-game? Just that violent and aggressive is 100% vision range, but violent will keep chasing when the player still sees the adversary. Defensive has a query range of 50% of the vision range :)

That being said, improvements can be done for sure.

Link to comment
Share on other sites

17 minutes ago, Freagarach said:

This is already how it works in-game? Just that violent and aggressive is 100% vision range, but violent will keep chasing when the player still sees the adversary. Defensive has a query range of 50% of the vision range :)

That being said, improvements can be done for sure.

Is there somewhere where I can edit aggressive to 90% vision range? :) 

Link to comment
Share on other sites

UnitAI \o/

Spoiler

Include a file in your components folder, called UnitAI_DE.js (or something alike), with the following content:

Spoiler


UnitAI.prototype.GetQueryRange = function(iid)
{
	let ret = { "min": 0, "max": 0 };

	let cmpVision = Engine.QueryInterface(this.entity, IID_Vision);
	if (!cmpVision)
		return ret;
	let visionRange = cmpVision.GetRange();

	if (iid === IID_Vision)
	{
		ret.max = visionRange;
		return ret;
	}

	if (this.GetStance().respondStandGround)
	{
		let range = this.GetRange(iid);
		if (!range)
			return ret;
		ret.min = range.min;
		ret.max = Math.min(range.max, visionRange);
	}
	else if (this.GetStance().respondChase)
		ret.max = visionRange * 0.9; // << This has changed.
	else if (this.GetStance().respondHoldGround)
	{
		let range = this.GetRange(iid);
		if (!range)
			return ret;
		ret.max = Math.min(range.max + visionRange / 2, visionRange);
	}
	// We probably have stance 'passive' and we wouldn't have a range,
	// but as it is the default for healers we need to set it to something sane.
	else if (iid === IID_Heal)
		ret.max = visionRange;

	return ret;
};

Note this also affects violent stance.

 

 

  • Thanks 1
Link to comment
Share on other sites

On 22/02/2021 at 1:48 PM, faction02 said:

Woodcutting behavior is sometimes "weird".

IT seems that when a tree is depleted, the units are searching for the next nearest tree to the spot where the last tree was rather than the most efficient one (the nearest tree to the dropsite). 

As a result, units are sometimes drawn far away from the forest by a couple of isolated trees.

 

Fixed in SVN (so for A25).
(For fun: it was commit r25000.)

  • Like 2
Link to comment
Share on other sites

8 minutes ago, Freagarach said:

Fixed in SVN (so for A25).
(For fun: it was commit r25000.)

Nice1

Another thing I noticed was that woodcutters tend to stick to the exact same species or type of tree. For instance if they are tasked to chop a bush, they will stick to bushes instead of going then next to the nearest tree. Anyone else see this too? 

Link to comment
Share on other sites

7 minutes ago, wowgetoffyourcellphone said:

Nice1

Another thing I noticed was that woodcutters tend to stick to the exact same species or type of tree. For instance if they are tasked to chop a bush, they will stick to bushes instead of going then next to the nearest tree. Anyone else see this too? 

I have not noticed it as you are describing it, but I have seen that they go to places far away for reasons that I do not yet understand.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...