Skip to content

Instantly share code, notes, and snippets.

View jameslkingsley's full-sized avatar

James Kingsley jameslkingsley

View GitHub Profile
component
{
this.datasource = application.site.datasource1;
this.cacheTimespan = createTimeSpan(0,0,1,0);
this.queries = [];
this.sorted = [];
this.params = [];
this.commands = {
"select" = [],
"update" = [],
/*
* Author: Kingsley
* Transports the given vehicle(s) to the given destination and unloads its infantry cargo
*
* Arguments:
* 0: Units <ARRAY>
* 1: Position <ARRAY>
* 2: Broadcast <BOOL>
*
* Return Value:
/*
* Author: Ed
* Night vision script
*
* Arguments:
* None
*
* Return Value:
* None
*
/*
* Author: Kingsley
* Draws all icons/lines needed in 3D space
* Called every frame from openEditor
*
* Arguments:
* None
*
* Return Value:
* None
["Air", "init", {
private _vehicle = _this select 0;
{
private _name = getText (_x >> "name");
_vehicle addAction [format ["Damage %1", _name], {
(_this select 0) setHit [(_this select 3), 1];
}, _name];
} forEach ("true" configClasses (configFile >> "CfgVehicles" >> typeOf _vehicle >> "HitPoints"));
}, true, [], true] call CBA_fnc_addClassEventHandler;
$(document).ready(function(e) {
$("#video-next, #video-prev").click(function(event) {
var index = (function(i){return (i < 0) ? 6 : (i > 6) ? 0 : i})($("#video-player").data("index") + $(this).data("dir"));
$("#video-player").attr({'data-index': index, 'src': (["https://youtube.com/embed/XFTR70j_8u0","https://youtube.com/embed/Eb_wyy_PaR0","https://youtube.com/embed/1C_n9RryuV0","https://youtube.com/embed/IsXmPVvXIjA","https://youtube.com/embed/eAoVwCSo_Qo","https://youtube.com/embed/KzuMTaiAr_0","https://youtube.com/embed/BZgtJcgfU4k"])[index]});
event.preventDefault();
});
});
$(document).ready(function(e) {
$('el').click(function(event) {
event.preventDefault();
});
});
params ["_unit","_damagedPart","_damageDone","_sourceUnit","_projectile"];
// Define to-be-damaged parts.
_meme = [meme1, meme2];
_tailrotor = "mala vrtule";
if (_projectile != "FakeAmmo") exitWith {_damageDone};
if (((random 100) / 100) <= 0.2) then {
{
_x setHit [_tailrotor, 0.8];
_x removeAllEventHandlers "HandleDamage";
.h-center {
text-align: center;
h1, h2, h3, h4, p {
text-align: inherit;
}
}
.v-center {
display: flex;
class acex_quickmount_enabled {
value = 1;
typeName = "BOOL";
force = 0;
};
class acex_quickmount_distance {
value = 4;
typeName = "SCALAR";
force = 0;
};