Skip to content

Instantly share code, notes, and snippets.

gm_fc_BU
gm_fc_BU_bgs
gm_fc_BU_civ
gm_fc_CS
gm_fc_CS_bgs
gm_fc_CS_civ
gm_fc_GC
gm_fc_GC_bgs
gm_fc_GC_civ
gm_fc_HU
@BaerMitUmlaut
BaerMitUmlaut / footprints.sqf
Created May 1, 2019 19:07
Permanent footprints
blue_footprints = [];
[{
private _footprints = player nearObjects ["#mark", 2];
{
private _p3d = (getModelInfo _x) select 1;
private _dir = direction _x;
private _pos = getPosASL _x;
_pos set [2, 0];
@BaerMitUmlaut
BaerMitUmlaut / ZeroGravity.sqf
Created May 24, 2019 08:30
Zero Gravity in Arma
private _vehicle = "B_MBT_01_cannon_F" createVehicle [0, 0, 0];
_vehicle setPosASL ((getPosASL player) vectorAdd [0, 10, 3]);
[{
params ["_args"];
_args params ["_vehicle", "_lastRun"];
private _delta = cba_missionTime - _lastRun;
private _force = [0, 0, getMass _vehicle * _delta * 9.8];
_vehicle addForce [_force, getCenterOfMass _vehicle];
@BaerMitUmlaut
BaerMitUmlaut / MapOverlay.sqf
Created April 5, 2020 15:06
Overlays a picture over the whole map with the map still being usable
mission_fnc_mapOverlayCache = [] call CBA_fnc_createNamespace;
mission_fnc_mapOverlay = {
params ["_map"];
_map drawIcon [
getMissionPath "map.paa",
[1, 1, 1, 1],
[worldSize / 2, worldSize / 2, 0],
640 / ctrlMapScale _map,
640 / ctrlMapScale _map,
@BaerMitUmlaut
BaerMitUmlaut / initPlayerLocal.sqf
Created March 14, 2023 22:00
Global Mobilization T-55 IR Searchlight
addUserActionEventHandler ["headlights", "Activate", {
private _vehicle = vehicle ACE_player;
if !(_vehicle isKindOf "gm_t55_base" && { ACE_player == gunner _vehicle }) exitWith {};
private _light = _vehicle getVariable ["bb_irlight", objNull];
if (!isNull _light) then {
_vehicle animate ["mainturret_searchlight_cover_unhide", 1, true];
deleteVehicle _light;
} else {
_vehicle animate ["mainturret_searchlight_cover_unhide", 0, true];