DataMuseum.dk

Presents historical artifacts from the history of:

DKUUG/EUUG Conference tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about DKUUG/EUUG Conference tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download
Index: T i

⟦1deb597e5⟧ TextFile

    Length: 1356 (0x54c)
    Types: TextFile
    Names: »initround.c«

Derivation

└─⟦b20c6495f⟧ Bits:30007238 EUUGD18: Wien-båndet, efterår 1987
    └─⟦this⟧ »EUUGD18/General/Ogre/initround.c« 

TextFile

#include "ext.h"

init_round()
{

    int i;

    for(i = 0; i < n_units; i++) {

        unit[i].moves_left = unit[i].movement;
        if(unit[i].status == DISABLED) {
            unit[i].status = OK;
            update_hex(unit[i].l_hex, unit[i].r_hex);
        }
        unit[i].range_to_ogre =
            range(ogre.l_hex, ogre.r_hex, unit[i].l_hex, unit[i].r_hex);

    }

}

init_move_ogre()
{

    int i;

    for(i = 0; i < n_units; i++) {

        unit[i].range_to_ogre =
            range(ogre.l_hex, ogre.r_hex, unit[i].l_hex, unit[i].r_hex);

    }

}

init_def_attack()
{

    int i;

    for(i = 0; i < n_units; i++) {

        if(unit[i].status == OK) {
            unit[i].fired = FALSE;
            unit[i].range_to_ogre =
                range(ogre.l_hex, ogre.r_hex, unit[i].l_hex, unit[i].r_hex);
        }

    }

}

init_ogre_attack()
{

    int i;

    for(i = 0; i < n_units; i++) {

            unit[i].fired = 0;
            unit[i].range_to_ogre =
                range(ogre.l_hex, ogre.r_hex, unit[i].l_hex, unit[i].r_hex);

    }

}

init_gev2()
{
    int i;

    for(i = 0; i < n_units; i++)
        if(unit[i].status == OK && unit[i].type == GEV)
            unit[i].moves_left = 3;

}

display_range(i)
{

    movecur(18, 0); eeol();
    printf("range from unit %d to Ogre %d.", i, unit[i].range_to_ogre);
    cycle();

}