hang on since you dont need to name it could you just create it
like this
_tank = _this select 0
_type = _this select 1
_tankpos = getpos _tank
_x = _tankpos select 0
_y = _tankpos select 1
"MAP_Sandbag_W22NFG" createvehicle [_x,(_y + 1),0]
"MAP_Sandbag_W22NFG" createvehicle [_x,(_y + 2),0]
"MAP_Sandbag_W22NFG" createvehicle [_x,(_y + 3),0]
"MAP_Sandbag_W22NFG" createvehicle [_x,(_y + 4),0]
"MAP_Sandbag_W22NFG" createvehicle [_x,(_y + 5),0]
"MAP_Sandbag_W22NFG" createvehicle [_x,(_y + 6),0]
"MAP_Sandbag_W22NFG" createvehicle [_x,(_y + 7),0]
"MAP_Sandbag_W22NFG" createvehicle [_x,(_y + 8),0]
ijust thought of that it fixed my problem with cam creating things but my error was slightly different