 for (var i = 0; i < spawnedEntities.length; i++) {
        var ent = spawnedEntities[i];
    ent.setMoveSpeed(0.4);
    ent.maxHealth = 40;
}

for (var i = 0; i < spawnedEntities.length; i++) {
        var ent = spawnedEntities[i];
    ent.texture = "/newmobs/boss1.png";
}