Skip to content

Commit

Permalink
[WIP] Fix script errors reporting wrong line numbers (#937)
Browse files Browse the repository at this point in the history
* fnc_currentUnit

* common

* accessory

* ai

* arrays

* diagnostic

* events

* hashes 1

* jr

* keybinding

* modules

* music

* network

* settings

* statemachine

* strings

* ui

* vectors

* xeh

* Manual fixups

* delete whitespace

* remove whitespace, weird formatting

* return value formatting

* whitespace, macro formatting

* formatting white space, fix a macro position

* move a include to fix error line numbers

* remove whitespace

* move a macro, whitespace, formatting

* formatting

* fix formatting

* fix formatting

* formatting

* formatting
  • Loading branch information
dedmen authored and commy2 committed Jun 30, 2018
1 parent 04b12f8 commit fbd59d2
Show file tree
Hide file tree
Showing 266 changed files with 285 additions and 381 deletions.
2 changes: 1 addition & 1 deletion addons/accessory/fnc_switchAttachment.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_accessory_fnc_switchAttachment
Expand All @@ -20,7 +21,6 @@ Examples:
Author:
Robalo, optimized by Anton
---------------------------------------------------------------------------- */
#include "script_component.hpp"

params ["_itemType", "_switchTo"];

Expand Down
2 changes: 1 addition & 1 deletion addons/ai/fnc_addWaypoint.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_addWaypoint
Expand Down Expand Up @@ -31,7 +32,6 @@ Author:
Rommel
---------------------------------------------------------------------------- */
#include "script_component.hpp"
params [
"_group",
"_position",
Expand Down
2 changes: 1 addition & 1 deletion addons/ai/fnc_clearWaypoints.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_clearWaypoints
Expand All @@ -19,7 +20,6 @@ Author:
SilentSpike
---------------------------------------------------------------------------- */
#include "script_component.hpp"
params [["_group", grpNull, [grpNull, objNull]]];
_group = _group call CBA_fnc_getGroup;

Expand Down
3 changes: 1 addition & 2 deletions addons/ai/fnc_taskAttack.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_taskAttack
Expand Down Expand Up @@ -25,8 +26,6 @@ Author:
---------------------------------------------------------------------------- */

#include "script_component.hpp"

params ["_group", "_position", ["_radius", 0], ["_override", false]];

_group = _group call CBA_fnc_getGroup;
Expand Down
3 changes: 1 addition & 2 deletions addons/ai/fnc_taskPatrol.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_taskPatrol
Expand Down Expand Up @@ -33,8 +34,6 @@ Author:
---------------------------------------------------------------------------- */

#include "script_component.hpp"

params [
["_group", grpNull, [grpNull, objNull]],
["_position", [], [[], objNull, grpNull, locationNull], [2, 3]],
Expand Down
2 changes: 1 addition & 1 deletion addons/ai/fnc_taskSearchArea.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_taskSearchArea
Expand Down Expand Up @@ -30,7 +31,6 @@ Examples:
Author:
SilentSpike 2015-08-17
---------------------------------------------------------------------------- */
#include "script_component.hpp"
params [
["_group", objNull, [objNull,grpNull]],
["_area", "", ["",objNull, locationNull,[]], 5],
Expand Down
2 changes: 1 addition & 1 deletion addons/ai/fnc_waypointGarrison.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Script: fnc_waypointGarrison
Expand All @@ -21,7 +22,6 @@ Examples:
Author:
commy2
---------------------------------------------------------------------------- */
#include "script_component.hpp"

#define POP_RAND(array) (array deleteAt floor random count array)

Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_filter.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_filter
Expand Down Expand Up @@ -32,7 +33,6 @@ Examples:
Author:
Spooner, commy2
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(filter);

params [["_array", [], [[]]], ["_filter", {_x}, [{}]], ["_inPlace", false, [false]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_findMax.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_findMax
Expand All @@ -21,7 +22,6 @@ Author:
joko // Jonas, commy2, Dorbedo
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(findMax);

[_this] params [["_array", [], [[]]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_findMin.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_findMin
Expand All @@ -21,7 +22,6 @@ Author:
joko // Jonas, commy2, Dorbedo
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(findMin);

[_this] params [["_array", [], [[]]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_findNil.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_findNil
Expand All @@ -18,7 +19,6 @@ Returns:
Author:
joko // Jonas
---------------------------------------------------------------------------- */
#include "script_component.hpp"

[_this] params [["_array", [], [[]]]];

Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_findNull.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_findNull
Expand All @@ -18,7 +19,6 @@ Returns:
Author:
joko // Jonas
---------------------------------------------------------------------------- */
#include "script_component.hpp"

[_this] params [["_array", [], [[]]]];

Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_findTypeName.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_findTypeName
Expand All @@ -19,7 +20,6 @@ Returns:
Author:
joko // Jonas
---------------------------------------------------------------------------- */
#include "script_component.hpp"

#define TYPENAMES ["ARRAY", "BOOL", "CODE", "CONFIG", "CONTROL", "DISPLAY", "GROUP", "LOCATION", "OBJECT", "SCALAR", "SCRIPT", "SIDE", "STRING", "TASK", "TEXT", "TEAM_MEMBER", "NAMESPACE"]

Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_findTypeOf.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_findTypeOf
Expand All @@ -21,7 +22,6 @@ Returns:
Author:
joko // Jonas
---------------------------------------------------------------------------- */
#include "script_component.hpp"

scopeName "main";

Expand Down
3 changes: 1 addition & 2 deletions addons/arrays/fnc_getArrayDiff.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_getArrayDiff
Expand All @@ -20,8 +21,6 @@ Author:
---------------------------------------------------------------------------- */

#include "script_component.hpp"

#define NULL "$null$"

params ["_arrayA", "_arrayB"];
Expand Down
3 changes: 1 addition & 2 deletions addons/arrays/fnc_inject.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_inject
Expand Down Expand Up @@ -33,8 +34,6 @@ Author:
Spooner
---------------------------------------------------------------------------- */

#include "script_component.hpp"

SCRIPT(inject);

// -----------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_insert.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_insert
Expand All @@ -24,7 +25,6 @@ Examples:
Author:
654wak654
---------------------------------------------------------------------------- */
#include "script_component.hpp"
#define ARRAY_ELEMENT_LIMIT 1E7
SCRIPT(insert);

Expand Down
3 changes: 1 addition & 2 deletions addons/arrays/fnc_join.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_join
Expand Down Expand Up @@ -29,8 +30,6 @@ Author:
Spooner
---------------------------------------------------------------------------- */

#include "script_component.hpp"

SCRIPT(join);

// ----------------------------------------------------------------------------
Expand Down
3 changes: 1 addition & 2 deletions addons/arrays/fnc_reject.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_reject
Expand All @@ -21,8 +22,6 @@ Author:
MuzzleFlash
---------------------------------------------------------------------------- */

#include "script_component.hpp"

SCRIPT(reject);

// ----------------------------------------------------------------------------
Expand Down
3 changes: 1 addition & 2 deletions addons/arrays/fnc_select.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_select
Expand All @@ -21,8 +22,6 @@ Author:
MuzzleFlash
---------------------------------------------------------------------------- */

#include "script_component.hpp"

SCRIPT(select);

// ----------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_shuffle.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_shuffle
Expand All @@ -24,7 +25,6 @@ Author:
toadlife (version 1.01) http://toadlife.net
rewritten by Spooner, Dorbedo
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(shuffle);

params [["_array", [], [[]]], ["_inPlace", false, [false]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/arrays/fnc_sortNestedArray.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_sortNestedArray
Expand All @@ -23,7 +24,6 @@ Returns:
Author:
commy2
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(sortNestedArray);

params [["_array", [], [[]]], ["_index", 0, [0]], ["_order", true, [false]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/common/fnc_actionArgument.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_actionArgument
Expand All @@ -16,7 +17,6 @@ Examples:
Author:
Rommel
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(actionArgument);

params ["_target", "_caller", "_id", "_arguments"];
Expand Down
2 changes: 1 addition & 1 deletion addons/common/fnc_addBackpackCargo.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_addBackpackCargo
Expand Down Expand Up @@ -28,7 +29,6 @@ Examples:
Author:
commy2
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(addBackpackCargo);

params [["_container", objNull, [objNull]], ["_item", "", [""]], ["_count", 1, [0]], ["_verify", false, [false]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/common/fnc_addBinocularMagazine.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_addBinocularMagazine
Expand All @@ -23,7 +24,6 @@ Examples:
Author:
commy2
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(addBinocularMagazine);

params [["_unit", objNull, [objNull]], ["_magazine", "", [""]], ["_ammo", nil, [0]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/common/fnc_addItem.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_addItem
Expand All @@ -23,7 +24,6 @@ Examples:
Author:
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(addItem);

params [["_unit", objNull, [objNull]], ["_item", "", [""]], ["_verify", false, [false]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/common/fnc_addItemCargo.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_addItemCargo
Expand Down Expand Up @@ -28,7 +29,6 @@ Examples:
Author:
commy2
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(addItemCargo);

params [["_container", objNull, [objNull]], ["_item", "", [""]], ["_count", 1, [0]], ["_verify", false, [false]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/common/fnc_addMagazine.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_addMagazine
Expand All @@ -24,7 +25,6 @@ Examples:
Author:
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(addMagazine);

params [["_unit", objNull, [objNull]], ["_item", "", [""]], ["_ammo", -1, [0]], ["_verify", false, [false]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/common/fnc_addMagazineCargo.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_addMagazineCargo
Expand Down Expand Up @@ -28,7 +29,6 @@ Examples:
Author:
---------------------------------------------------------------------------- */
#include "script_component.hpp"
SCRIPT(addMagazineCargo);

params [["_container", objNull, [objNull]], ["_item", "", [""]], ["_count", 1, [0]], ["_verify", false, [false]]];
Expand Down
2 changes: 1 addition & 1 deletion addons/common/fnc_addPerFrameHandler.sqf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "script_component.hpp"
/* ----------------------------------------------------------------------------
Function: CBA_fnc_addPerFrameHandler
Expand Down Expand Up @@ -25,7 +26,6 @@ Examples:
Author:
Nou & Jaynus, donated from ACRE project code for use by the community; commy2
---------------------------------------------------------------------------- */
#include "script_component.hpp"

params [["_function", {}, [{}]], ["_delay", 0, [0]], ["_args", []]];

Expand Down
Loading

0 comments on commit fbd59d2

Please sign in to comment.