public void update(Game game)
    {
        if(start == -1)
            start = game.getGameTick();

        float rollDie = game.getRandomGenerator().nextFloat();
        if(((start+game.getGameTick()) % cooldown == 0) && rollDie < prob)
        {
            VGDLSprite newSprite = game.addSprite(itype, this.getPosition());
            if(newSprite != null) {
                counter++;

                //We set the orientation given by default it this was passed.
                if(!(spawnorientation.equals(Types.DNONE)))
                    newSprite.orientation = spawnorientation.copy();
                //If no orientation given, we set the one from the spawner.
                else if (newSprite.orientation.equals(Types.DNONE))
                    newSprite.orientation = this.orientation.copy();
            }
        }

        super.update(game);

        if(total > 0 && counter >= total)
        {
            //boolean variable set to false to indicate the sprite was not transformed
            game.killSprite(this, false);
        }
    }