mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
24 lines
488 B
Plaintext
24 lines
488 B
Plaintext
/*
|
|
* Author: commy2
|
|
* Removes the brackets around a code and returns the code as a string. It does nothing if the code is already a string.
|
|
*
|
|
* Arguments:
|
|
* 0: Code <CODE, STRING>
|
|
*
|
|
* Return value:
|
|
* Code <STRING>
|
|
*
|
|
* Public: Yes
|
|
*/
|
|
#include "script_component.hpp"
|
|
|
|
params ["_function"];
|
|
|
|
if (typeName _function == "STRING") exitWith {_function};
|
|
|
|
_function = toArray str _function;
|
|
_function deleteAt 0;
|
|
_function deleteAt (count _function - 1);
|
|
|
|
toString _function // return
|