Jump to content
Sign in to follow this  
boby91

Unit surrender (ace3)

Recommended Posts

Posts: 19

Rank:

Level: Member

Country: cz

Location:

Occupation:

Age:

In-game name:

#1 Posted at 2016-12-02 18:32

Hi, I have one little problem. I dont want to use trigger. I d like to use waypoint (on act) from different unit..

When some unit activate his waypoint, i want to make two units as surrenders.

I wan to use ACE3 script, which is here (http://ace3mod.com/wiki/framework/events-framework.html) -- ace_captives_setSurrendered [_unit, _state(BOOL)] Target Callable Sets a unit to either start or stop surrendering.

I tried to make it work, but without success. :( Cant find right syntax.

Can someone help pls.

Share this post


Link to post
Share on other sites

Documentation is clear how to use it.

_handle = [_unit, true] call ace_captives_setSurrendered;
  • Like 1

Share this post


Link to post
Share on other sites

Yeah, I've already tried this syntax, but its not working. Maybe its not possible to do it this way and I have to use trigger with ACE modul for surrender... :(

Share this post


Link to post
Share on other sites

This is necromancy of the highest order, but just in case someone randomly googles it like I did, the reason it didn't work was because the ACE documentation used the wrong function name. The below works.

[_unit, true] call ace_captives_fnc_setSurrendered;

 

Share this post


Link to post
Share on other sites
On 26.2.2018 at 3:46 AM, T.Fork said:

the reason it didn't work was because the ACE documentation used the wrong function name.

Nope.

 

On 3.12.2016 at 1:11 PM, M1ke_SK said:

Documentation is clear how to use it.


_handle = [_unit, true] call ace_captives_setSurrendered;

Nope.

 

https://ace3mod.com/wiki/framework/events-framework.html#25-captives-ace_captives

 

It is a Event. Not a function.

 

https://ace3mod.com/wiki/framework/events-framework.html#321-local-event

That's how you call Events.

 

["ACE_captives_setSurrendered", [_unit, true], _unit] call CBA_fnc_targetEvent;

Why targetEvent? Because it says Locality is Target.

Share this post


Link to post
Share on other sites

note for ACE member who write documentation: next time try to write documentation for humans, not robots and don't be lazy about it. I know from experience that documentation is done in hurry at last minute or not at all.

  • Haha 1

Share this post


Link to post
Share on other sites
8 minutes ago, M1ke_SK said:

note for ACE member who write documentation: next time try to write documentation for humans, not robots and don't be lazy about it. I know from experience that documentation is done in hurry at last minute or not at all.

 

There is no "ACE member who write documentation". It's open-source and written by many collaborators. Yes. Open-source. Meaning you can fix it if you don't like something.

Also there is a clear example on how events work at the bottom of the page.

And the first text line on the page says "Event handlers in ACE3 are implemented through CBA’s Event System.".

 

If you would just read that page instead of assuming what something on there might do or might be used for, you wouldn't have a problem understanding it.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×