public void csPayUpkeep(Random random, ChangeSet cs) {
        Disaster bankruptcy = getSpecification().getDisaster(Disaster.BANKRUPTCY);
        int upkeep = 0;
        for (Settlement settlement : settlements) {
            upkeep += settlement.getUpkeep();
        }
        if (getGold() >= upkeep) {
            modifyGold(-upkeep);
            if (isBankrupt()) {
                setBankrupt(false);
                // the only effects of a disaster that can be reversed
                // are the modifiers
                for (RandomChoice<Effect> effect: bankruptcy.getEffects()) {
                    for (Modifier modifier : effect.getObject().getModifiers()) {
                        cs.addFeatureChange(this, this, modifier, false);
                    }
                }
                cs.addMessage(See.only(this),
                              new ModelMessage(ModelMessage.MessageType.GOVERNMENT_EFFICIENCY,
                                               "model.disaster.bankruptcy.stop", this));
            }
        } else {
            modifyGold(-getGold());
            if (!isBankrupt()) {
                setBankrupt(true);
                csApplyDisaster(random, cs, null, bankruptcy);
                cs.addMessage(See.only(this),
                              new ModelMessage(ModelMessage.MessageType.GOVERNMENT_EFFICIENCY,
                                               "model.disaster.bankruptcy.start", this));
            }
        }
        cs.addPartial(See.only(this), this, "bankrupt");
        cs.addPartial(See.only(this), this, "gold");
    }