Search the Community
Showing results for tags 'scheduler'.
Found 5 results
-
Hello everyone. Let's say I'm running a mission that currently has over 1000 running scripts (diag_activeScripts#0 > 1000): for"_i" from 0 to 1000 do { [] spawn { while {true} do { for "_i" from 0 to 50000 do {true} } } } Each iteration of every script requires about 20 ms to complete, which is well above the scheduler's execution time limit (3 ms). This practically means that if my game is running @60 FPS (16.6 ms per frame) and I have a script at the 1001st position in the queue, it will be executed at least over ~17 seconds later! And this is just the first iteration of my script. There will be a ~17s delay between each iteration. This is only a stress test of course, but still I'd rather my scripts were executed ASAP. I don't mean like 'call', because my scripts are way too demanding for calling. They have to be executed in the scheduled environment. I can think of a dirty method (using a perFrame eventHandler, and executing the code bit by bit), but I was hoping for a more straightforward solution. Does anyone know a way?
-
How to "call" script from Scheduled environment?
Leopard20 posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hey guys. Does anyone know a way to "call" a function/script from the scheduled environment? In other words, let's say I've already spawned a script: 0 spawn { call MY_fnc_TEST } Any function called inside this script will obviously get executed in the scheduled environment (canSuspend). But I want it to get called in the unscheduled environment. One way I know is to do something like this: 0 spawn { OnEachFrame {call MY_fnc_TEST; onEachFrame ""}; } which is quite awkward. Plus the function will not get executed before the rest of the script (it gets called in the next frame). This can be verified using: AAA = 1; 0 spawn { onEachFrame {AAA = AAA + 1; onEachFrame ""}; AAA = AAA/2 }; This gives AAA = 1.5 instead of 1. Does anyone know a better way?! -
ArmA Remote Admin is a web-based administration tool for server operators looking to manage multiple servers at a time, create automatic restarts, access their RCon from everywhere, handle ban-lists with up to thousends of entries, remove players under certain conditions such as gametime, account age, proxies, VAC-bans and more What is ArmA Remote Admin? ArmA Remote Admin consists of our cloud-based system and your local ARA-client which communicates with our masterserver. Given we have a running application on your machine, ARA benefits from it by allowing you to directly restart your gameserver through the dashboard, track information such as CPU-usage and memory usage and in the future use it to download/install and maintain workshop mods, provide missionfiles for automatic exchange on the gameserver on the next occasion and more. ArmA Remote Admin was written to replace other (sometimes deprecated) systems such as ASM and BEC. Server Setup Tired of installing ArmA 3 servers yourself? ArmA Remote Admin takes care of everything from downloading the latest files over installing all Visual C++ Redistributables to setting up your BattlEye. Server Updates Update your gameserver to the newest ArmA 3 version within seconds by pressing a single button. Scheduler Use the scheduler to create automatic restarts of your gameserver, run any application at specific times and send messages/raw commands via RCon. System Failure Handling Restart your gameserver when it crashes/becomes unavailable to players or execute your own routine application. Steam Workshop Support Use ArmA Remote Admin to install mods from the Steam Workshop directly on your server. (Live-)Metrics View certain metrics such as CPS, FPS, object count and player count live and up to 3 days afterwards. Server Interaction Restart/Start/Stop your gameserver from the webinterface and either directly let ARA restart your gameserver or run custom applications if necessary. Remote Console Access your RCon from the webinterface, view all available data of connected players, view notes/tracing information of players and more. Permission Sharing Add other members to your dashboard, create permission groups and give your staff access to everything they need without handing out passwords for your RCon or dedicated server. Proxy Detection And Account Validation Automatically detect proxies and remove players under certain conditions such as minimum gametime in minutes, minimum amount of games on their Steam account, Steam account creation date and more. Whitelists/Reserved Slots Add whitelists/reserved slots to your gameservers and handle the whitelisted players from the dashboard. No more file editing or restarts required. All changes go live instantly. Web-Logs View everything your administrators do with the dashboard to trace back bans, messages and more. Player Tracing And Notes Create notes for GUIDs to never forget something about a player and view when the player played, for how long, on which server and with what name. Features To Come ArmA Remote Admin will receive updates and new features in the future. Planned is (for example) - Mod support: Download/Update/Maintain mods from the workshop Has been added - Automatic missionfile update deployment: Deploy new missionfiles automatically on the next occasion If you have any wishes as to what ArmA Remote Admin should receive as an update, please don't hesitate to post your suggestion here. Interested? For more information visit our website www.armaremoteadmin.com
- 17 replies
-
- 7
-
- administration
- remote
-
(and 5 more)
Tagged with:
-
A tiny script to measure SQF scheduler load
Sparker posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
I couldn't find any script/tool/addon which would provide such a basic functionality: how much is ARMA's SQF scheduler loaded right now? Can I run a check every X milliseconds, with the given other scripts running in background? When we are spawning many different SQF scripts with infinite loops we want to know how much the SQF scheduler is loaded with these scripts. Typically we would try to force the scheduler to execute a simple script and observe the delay between spawning the script and its output. For instance you could spawn a lightning with Zeus and estimate the delay. How it works: The script I suggest uses the same idea: it runs an infinite loop, where it tries to execute a piece of code as often as the scheduler lets and measuring time intervals between executions. If the scheduler is flooded with many heavy scripts then sequential executions of our tiny script will happen less often. The script also performs exponential averaging of measured intervals. What it shows: It shows the delay between executions described above. The delay can help us understand the maximum frequency at which your loops can run(average). It also outputs the overload, measured in percents, which is equal to: overload=100*game FPS*delay=100*game_FPS/SQF_FPS. So if the "overload" is around100%, SQF scripts are running at roughly the game's frame rate. If it is 200%, then spawned SQF scripts are running at half the game's frame rate, and so on. Why not just measure performance of single scripts with standard methods? Maybe you are running other people's scripts in the mission, or you want to get an overview, how much load all the scripts produce. How to use it: Run this locally: Measurements will be output to system chat. You can fine-tune _a to perform smaller or bigger averaging (smaller _a -> bigger averaging). [] spawn { sl_prev = time; private _i = 0; private _ds = 0; // Smoothed value of delta private _a = 0.009; // private _N = 30; while {true} do { sleep 0.001; private _t = time; // Get current time private _delta = _t - sl_prev; // Calculate time passed since previous measurement sl_prev = _t; // Store the new time back _ds = _a * _delta + (1-_a)*_ds; // Exponential averaging //Output value every N measurements _i = _i + 1; if (_i == _N) then { _i = 0; private _overloadPercent = round(100*diag_fps*_ds); systemChat ((format ["Scheduler delay: %1 ms, overload: %2", round(_ds*1000), _overloadPercent]) + "%"); // Calculate new value for N to produce outputs every 0.5 seconds _N = ceil(0.5/_ds); }; }; If you want to quickly test the script here's a dummy load you can use. Just run it a few times: for [{_i=0}, {_i<5}, {_i=_i+1}] do { [] spawn { sleep random 1; while {true} do { sleep 0.5; private _a = []; //6 ms @ Core i7 3770 _a set [70, 0]; _a = _a apply {2}; { private _sum = 0; { _sum = _sum + _x; }forEach _a; } forEach _a; }; }; }; Please share what you think about this! -
Scheduler load percentage for spawned scripts
Sparker posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hello! As ARMA's scripts spawned inside the scheduler behave as separate threads, it seems logical to me to have a way to estimate how much percents of total scheduler run time is taken by every spawned script, similar to what a task manager in any OS shows for started processes. Am I missing something, or is there really no such feature in ARMA? Thanks!