jts_2009 96 Posted March 20, 2016 I tried to create a zombie (Zombie & Demons mod). Looks like they work fine. But they doesn't move. The zombie can turn right or left, but he can't move. I read, that if you create unit with this command - he will have an animal logic. Is there a way to make him act like normal unit...? Command 'createUnit' is not an option, because of the limit. You can't create so much zombies like in dayz with that... Anyone knows maybe the solution...? :) Share this post Link to post Share on other sites
jts_2009 96 Posted March 20, 2016 code? There is no code. I just create him with that command. createAgent Currently testing it in a trigger: null = createAgent ["RyanZombieC_man_1", position gs1, [], 0, "NONE"]; Share this post Link to post Share on other sites
barbolani 198 Posted March 20, 2016 I am far from being an expert, but I suppose Dayz Zombies are createUnit, it's just a matter of monitoring how many zombies are spawned in map. Proper zombie FSM will be less CPU expensive so I guess the max amount of zombies exceeds the typical Arma AI limit (no search for cover, enemy awareness less intensive). Anyway I remember KillzoneKid had some tutorial on scripting createAgent units. 1 Share this post Link to post Share on other sites
jts_2009 96 Posted March 20, 2016 I am far from being an expert, but I suppose Dayz Zombies are createUnit, it's just a matter of monitoring how many zombies are spawned in map. Proper zombie FSM will be less CPU expensive so I guess the max amount of zombies exceeds the typical Arma AI limit (no search for cover, enemy awareness less intensive). Anyway I remember KillzoneKid had some tutorial on scripting createAgent units. In DayZ, the zombies are created with 'createAgent' 1 Share this post Link to post Share on other sites
das attorney 858 Posted March 20, 2016 ^ yup edit: @jts_2009: You can disable their inbuilt FSM's with: agent = createAgent ["ryanzombieclassname", position player, [], 0, "FORM"]; agent disableAI "fsm"; (You might not need to disable the AI - check the config entries for "fsmDanger" and "fsmFormation" and see if they are already empty). Then you would need to write an FSM or script to control the zombie. Here's what they use in Dayz currently: https://github.com/DayZMod/DayZ/blob/Development/SQF/dayz_code/system/zombie_agent.fsm Use it as reference and substitute in Ryans anims for attacks etc. I'm not sure if that would work out of the box in Arma 3 as there have been some changes to commands etc and also bear in mind that moveTo was (and still might be) broken for agents. Share this post Link to post Share on other sites
jts_2009 96 Posted March 20, 2016 Then you would need to write an FSM or script to control the zombie. Here's what they use in Dayz currently: Yes, but the problem is, that the zombies should not move, until they don't know about player presence. I took command 'knowsAbout', but the result is always 'false' Share this post Link to post Share on other sites
haleks 8212 Posted March 20, 2016 knowsAbout doesn't work on agents, you need to emulate that yourself. Share this post Link to post Share on other sites
das attorney 858 Posted March 20, 2016 You're doing something wrong then. Knowsabout should only return a number, not bool. From the wiki: Return value: Number in the range of 0 - 4, where 4 is max knowledge https://community.bistudio.com/wiki/knowsAbout edit: ninja'd by Haleks Try neartargets (iirc that worked in Dayz) or write your own with lineIntersects /checkVisibility Share this post Link to post Share on other sites
jts_2009 96 Posted March 20, 2016 You're doing something wrong then. Knowsabout should only return a number, not bool. From the wiki: Return value: Number in the range of 0 - 4, where 4 is max knowledge https://community.bistudio.com/wiki/knowsAbout edit: ninja'd by Haleks Try neartargets (iirc that worked in Dayz) or write your own with lineIntersects /checkVisibility Thats doesn't matter if number or bool, the result is bad. It was just a quick-check with: hint str (s1 knowsAbout player > 1) It return always false. hint str (s1 knowsAbout player) returns 0 Share this post Link to post Share on other sites
das attorney 858 Posted March 20, 2016 Thats doesn't matter if number or bool, the result is bad. It was just a quick-check with: hint str (s1 knowsAbout player > 1) It return always false. hint str (s1 knowsAbout player) returns 0 Ah ok fair enough, I didn't know you were comparing to another value. From what you wrote, it sounded like the command was returning a bool. Share this post Link to post Share on other sites
sarogahtyp 1108 Posted March 20, 2016 look at this topic to get an idea how to check visibility: https://forums.bistudio.com/topic/189068-los-line-of-sight/ i would not use checkVisibility but i described it there Share this post Link to post Share on other sites
jts_2009 96 Posted March 20, 2016 look at this topic to get an idea how to check visibility: https://forums.bistudio.com/topic/189068-los-line-of-sight/ i would not use checkVisibility but i described it there Thanks. I found new problem now. Zombie don't attack me, if I not shoot. Well, sometimes he attacks if I not shooting, but it's very rarely. So I think that thing with createAgent is bad idea. Will to have probably use createunit, but Im not sure about limitation... How much units I can create for 1 commander, anyone know..? If I create them periodically, 24 hours. 100 per hour. (Of course they will be deleted under specific conditions) Share this post Link to post Share on other sites
thesnypr 38 Posted October 30, 2016 hi do you found a solution? for me im using _typezombiesR2= ["RyanZombieB_Soldier_02_f_1_1slowOpfor","RyanZombieC_man_1slowOpfor"] call BIS_fnc_selectRandom; _spawnPoszr2 = [getpos player, 100, 200, 0, 0, 0, 0] call BIS_fnc_findSafePos; _groupzombr2 = createGroup east;// create the group east can be independent,west _unitzombr2 = _groupzombr2 createUnit [_typezombiesR2,_spawnPoszr2, [], 0, "none"] ; createUnit is always what i m using but you need to impement some function module in editor like roaming option .... you may (i think) also take care to the side if you are east or west by adding this on init mission file or by adding addrating -20000; civilian setFriend [east, 0]; civilian setFriend [west, 0]; civilian setFriend [resistance, 0]; west setFriend [resistance, 0]; east setFriend [resistance, 0]; resistance setFriend [east, 0]; resistance setFriend [west, 0]; resistance setFriend [civilian, 0]; hope it help... https://forums.bistudio.com/topic/196652-survival-open-world/ Share this post Link to post Share on other sites
phronk 898 Posted October 30, 2016 If you actually look at the DayZ mod code from ArmA 2, they are agents and have a custom FSM (Made with the FSM editor). It's probably also doable with createUnit and just execute the FSMs on them, similar to the ALICE modules from ArmA 2:OA. 1 Share this post Link to post Share on other sites