DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400

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

See our Wiki for more about Rational R1000/400

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦f6ccf750d⟧ Ada Source

    Length: 6144 (0x1800)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, procedure Jeu_D_Aventures, seg_048a15

Derivation

└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
    └─ ⟦5a81ac88f⟧ »Space Info Vol 1« 
        └─⟦this⟧ 

E3 Source Code



with Text_Io;  
with Compilateur;
with Interpreteur, Moteur, Actions;
with Affichage;  
with Disque;
with Quate;
use Quate;

with Initialisation;

procedure Jeu_D_Aventures is

    Le_Fichier : String (1 .. 80) := (others => ' ');  
    Length : Natural;
    Ok : Boolean := True;  
    Reponse : Boolean := True;
    Etat_Courant : Etat_Jeu := Continuer;
    La_Question : Type_De_Demande := Fin_De_Jeu;

    function Question_O_N return Boolean is
        Reponse : Character;  
    begin  
        loop  
            Text_Io.Set_Input (Text_Io.Standard_Input);
            Text_Io.Get (Reponse);
            if Reponse = 'o' or Reponse = 'O' then
                return True;  
            else
                if Reponse = 'n' or Reponse = 'N' then
                    return False;
                end if;
            end if;
            Text_Io.Skip_Line;
        end loop;
    end Question_O_N;

begin
    Text_Io.Put ("Nom du fichier : ");
    Text_Io.Get_Line (Le_Fichier, Length);
    Text_Io.Put_Line ("");
    if Le_Fichier (1 .. Length) = "init" then
        Initialisation;
        Ok := True;
    else
        Ok := Compilateur (Le_Fichier (1 .. Length));
    end if;
    if Ok then
        Text_Io.Put
           ("Voulez-vous recommencer sur ancienne partie sauvegardee (o/n) ? ");
        if Question_O_N then
            Disque.Restauration;
        end if;
        Affichage.Creation;
        Affichage.Les_Infos;
        while (Etat_Courant = Continuer) loop  
            while (Etat_Courant = Continuer) loop
                La_Question := Interpreteur.Analyser;
                Moteur.Traiter (La_Question, Etat_Courant);
                case Etat_Courant is
                    when Arreter =>
                        Text_Io.Put_Line ("Jeu arrete");
                        Text_Io.Put
                           ("Voulez-vous sauvegarder la partie (o/n) ? ");  
                        if Question_O_N then
                            Disque.Sauvegarde;
                        end if;
                    when Continuer =>
                        null;
                    when Terminer =>
                        null;
                end case;
                Affichage.Les_Infos;
            end loop;
--            if Etat_Courant = Terminer or Etat_Courant = Arreter then
--                Text_Io.Put
--                   ("Voulez-vous recommencer une nouvelle partie (o/n) ? ");
--                if Question_O_N then
--                    Etat_Courant := Continuer;
--                end if;
--            end if;
        end loop;
        Text_Io.Get_Line (Le_Fichier, Length);
        Affichage.Destruction;  
    else
        Text_Io.Put_Line ("Erreur de compilation du monde ...");
    end if;
    Text_Io.Put_Line ("... Fin de jeu ...");

end Jeu_D_Aventures;


E3 Meta Data

    nblk1=5
    nid=5
    hdr6=6
        [0x00] rec0=27 rec1=00 rec2=01 rec3=03e
        [0x01] rec0=1a rec1=00 rec2=03 rec3=020
        [0x02] rec0=1b rec1=00 rec2=04 rec3=000
        [0x03] rec0=04 rec1=00 rec2=02 rec3=000
        [0x04] rec0=80 rec1=00 rec2=00 rec3=100
    tail 0x21545f3e2865a52771caf 0x42a00088462060003
Free Block Chain:
  0x5: 0000  00 02 03 fc 80 32 20 28 22 56 6f 75 6c 65 7a 2d  ┆     2 ("Voulez-┆
  0x2: 0000  00 00 00 24 80 01 3b 01 00 00 00 00 14 65 6e 64  ┆   $  ;      end┆