Exemple #1
0
/**
 *
 *
 *  @author OLiver
 */
noFlag::noFlag(SerializedGameData* sgd, const unsigned int obj_id)
    : noRoadNode(sgd, obj_id),
      ani_offset(rand() % 20000), flagtype(FlagType(sgd->PopUnsignedChar()))
{
    for(unsigned char i = 0; i < 8; ++i)
        wares[i] = sgd->PopObject<Ware>(GOT_WARE);

    // BWUs laden
    for(unsigned char i = 0; i < MAX_BWU; ++i)
    {
        bwus[i].id = sgd->PopUnsignedInt();
        bwus[i].last_gf = sgd->PopUnsignedInt();
    }
}
fowFlag::fowFlag(SerializedGameData& sgd) :
    player(sgd.PopUnsignedChar()),
    flag_type(FlagType(sgd.PopUnsignedChar()))
{}
fowFlag::fowFlag(SerializedGameData& sgd)
    : color(sgd.PopUnsignedInt()), nation(Nation(sgd.PopUnsignedChar())), flag_type(FlagType(sgd.PopUnsignedChar()))
{}