A

Ashi2017

Member

Last active 6 years ago

  1. 6 years ago
    Sun Dec 10 12:31:10 2017

    Hi everyone,

    I was wondering if anyone with scripting experience would be able to help me.

    Imagine I have three markers (marker1, marker2, and marker3) at various points on a map. Here's what I want to happen;

    • Every 10 minutes or so, getdominantfaction is called for every marker
    • An infantry squad of the dominant side is spawned at the center of the marker
    - I don't want Alive to take control of this group, I simply want them to stay there and defend
    • The previously spawned squad (if one exists) is removed (preventing units from pilling up over time)

    I beleive for maintainability, I could put the code in an sqf file, and just have that file called every 10 minutes or so (I have a lot more than 3 markers so I would like to maximise maintainability going forward).

    Thanks everyone.

  2. Sun Dec 10 11:05:37 2017
    A Ashi2017 started the conversation Force virtual units to spawn in a certain area?.

    Hi all,

    Is there a way to force Alive to spawn virtualised units (as if they were in range of the player), but in a custom location (such as a marker/trigger).

    Imagine I have a marker over a small town. I would like the units that pass through that town to spawn in and fight (even if the player is on the other side of the map - meaning they would normally be virtual units). If possible I'd like to have them be virtualised again if they move out of the marker/area.

    Thanks!

  3. Tue Aug 15 19:14:33 2017

    Thanks Savage :)

  4. Wed Aug 9 15:30:18 2017

    Thanks for the response guys.

    I'll give that a try marceldev89, thanks!

    Yeah that would be cool Tupolov. Can mission makers influence what appears on the tablet, or do you mean for a future ALiVE update?

    Some kind of battle report screen would be a nice addition, showing information such as the number of objectives in the mission, which faction controls how many etc (raw numbers and a percentage breakdown etc). I know we can see the objectives on the intel screen but I don't believe it gives any raw numbers.

    It would be a nice addition for stats junkies at least :D

  5. Sun Aug 6 20:37:54 2017

    WHAT I'M TRYING TO ACHIEVE


    OK, so, I'm currently writing a script that will achieve the following;

    Every 5 minutes (arbitrary number) the AI will post in side chat a "Battlefield Update" showing the current force pool and current number of profiles for BLUFOR.

    However, I cannot for the life of me get it to pickup the values for force pool and profile count.

    Some things to consider:

    • I'd like this to show for every player in the game (hence the initPlayerLocal.sqf)
    • If possible, I'd like this to run regardless of host type (i.e. a dedicated server or someone just hosting a multiplayer game from within the client)

    MY CURRENT CODE


    In my initPlayerLocal.sqf (this just pulls from a param, the host can turn these updates on/off;

    // Battlefield updates Param
    if ((paramsArray select 12) == 1) then
    {
    [] execVM "battleUpdates.sqf";
    };

    In battleUpdates.sqf;

    // Get number of BLUFOR profiles
    _profilesBySide = [ALiVE_profileHandler,"profilesBySide"] call ALIVE_fnc_hashGet;
    _profilesBySide = _profilesBySide select 1;
    
    // Get current BLUFOR force pool
    _currentBLUFORForcepool = [ALIVE_globalForcePool,"BLU_F"] call ALIVE_fnc_hashGet;
    
    // While loop to display chat from HQ using above variables
    while {true} do {
    
    	sleep 10;
    	[west, "HQ"] sideChat "BATTLEFIELD STATUS UPDATE";
    	[west, "HQ"] sideChat "We have " + str _profilesBySide + " units currently deployed in the AO. Our reinforcement pool currently stands at " + str _currentBLUFORForcepool + ".";
    
    		if (_currentBLUFORForcepool < 20) then {
    			[west, "HQ"] sideChat "Our reinforcement pool is low soldier!";
    		};
    
    		if (_currentBLUFORForcepool > 100) then {
    			[west, "HQ"] sideChat "We have a surplus of reinforcements. Put them to work soldier!";
    		};
    
    };

    The problem

    The error I get is _currentBLUFORForcepool and _profilesBySide are undefined, even though they are defined at the top of the file?

    I really appreciate anyone who can help me with this :)

    Thanks all!

  6. Sun Aug 6 17:59:55 2017

    Yeah I understand completely HeroesandvillainsOS, just thought I'd bring it up.

    More of a personal frustration that I keep forgetting to change it to "Join player squad" ;)

    Thanks for mentioning Spyders addons BTW, started incorporating them in my mission just now :) I'm using the recruit/vehicle/gear addons so that players can request things in the main BLUFOR base without having to dip into the force pool. Only when they're out in the field do they need to request stuff from logistics. Working nicely so far :)

  7. Sun Aug 6 14:35:38 2017

    This might be a lot of effort, but why not have a dropdown on the module itself for people to choose the default for their particular mission (perhaps even allow us to enable/disable one option or another entirely)?

    That way, it doesn't get in the way of personal preference, at least for mission makers that is.

  8. Sun Aug 6 14:27:44 2017

    Thanks for the discussion guys.

    I actually followed marceldev89's advice and posted it as an idea on Github (before I saw your response Friznit). Feel free to do what you want with the issue Friznit, just wanted to throw it out there and see what people thought. :)

    I may look into Spyder Addons HeroesandvillainsOS :), maybe that will help with my issue of constantly forgetting to change the reinforcement type :P

  9. Sat Aug 5 18:44:57 2017

    So by default, each unit/group in your payload that you request through Logistics is set to "Reinforce". However, 99% of the time, when I use this menu, it's to request units or vehicles for myself (i.e. I want to add them to my squad).

    Is there a way I can set/override the default for my particular mission?

    Cheers!

  10. Fri Aug 4 21:56:50 2017
    A Ashi2017 started the conversation Access some ALiVE options with mission params?.

    Hi all,

    Is it possible to access some ALiVE options for use in mission parameters?

    I currently have the usual mission params in place, like Stamina, start time of day, starting weather etc.

    But I was wondering if I could connect to various aspects of ALiVE to give players of my Workshop mission an easy way of tailoring friendly/enemy force size (let's say the "Force Size" attribute of my BLUFOR mil placement module)?

    Cheers!
    Ash

View more