civarray = ["civ1","civ2","civ3","civ4","civ5","civ6","civ7","civ8","civ9","civ10","civ11","civ12","civ13","civ14","civ15"]
{call format ["?(player"=="%1) : %1_actionstats = %1 addAction [""Stats [%1]"",""Scripts/Players/PlayerStats.sqs""]", _x]} forEach civarray
This works without the "?(player==%1) : " but when you walk close to a civ, then you get their command which I want to be private.......I added the ""s around the == because otherwise it gave an error...
Josh
Got it
{call format ["if (player == %1) then {%1_actionstats = %1 addAction [""Stats [%1]"",""Scripts/Players/PlayerStats.sqs""]}", _x]} forEach civarray