Join for FREE | Take the Tour Lost Password?
[x]

deviantART

 




Program Life Basics; // Can life be like a program?
Uses
   LifeLib;
Var             
   Food, Sleep, Water, Love As Needs;
   Happiness As LifeStrength;
   Death As LifeWeakness;
   Age As Integer;
   Object Person
       Begin
            HasHealth As Status;
        End;        
Constants
   GoToSchool;
   GoToWork;
   StayHome;
  
Begin

   Death := Random(100); // We all know that the death is random.
   Happiness := 2 + Random(5); // Happiness is random too.

     Do
  
            // Should I go to school, work or stay home?      
        If Age < 18 Then
           GoToSchool;
        Else If Age < 50 Then
           GoToWork;
        Else
           StayHome;
        End;


           // Let's try to survive...!
        If Not Food Then
            Person.HasHealth := False
            Happiness := Happiness - 2
        Else
            Happiness := Happiness + 5
        End;
        If Not Water Then
            Person.HasHealth = False
            Happiness := Happiness - 2
        Else
            Happiness := Happiness + 5
        End;
        If Not Sleep Then
            Person.HasHealth := False
            Happiness := Happiness - 2
        Else
            Happiness := Happiness + 5
        End;
        

               // Let's put some love in the game.
        Read(Love);

         Select Case (Love)
             0 : Happiness := Happiness -  20; Break;
             1 : Happiness := Happiness -  10; Break;
             2 : Break;
             3 : Happiness := Happiness + 10; Break;
             4 : Happiness := Happiness + 15; Break;
         End Case;
       

              // Happy?       
        If  Happiness < -10 Then
            Death := -1                    // Suicide...
        Else If Happiness < 3 Then
            Person.HasHealth := False    // Get Sick...
        Else If Happiness > 80 Then
             Death := Death + 1         // Live Longer!
             Happiness := Happiness - 20
        End;

             // Am I sick?
        If Not Person.HasHealth Then
              GoToHospital
        End;
              
          
             // A year has passed.
      Age := Age + 1

     While (Age < Death);

             // Oops... Game Over.
     WriteLine('Memento Mori...');
     Readkey;
     WriteLine('Game Over');

End.

Procedure GoToHospital
Var
   Methods As GoodOrBad;

  Begin

          // Can I be saved?
    If Methods = Good Then
        Happiness := Happiness + 2
        Death := Death - 1
    Else If Methods = Bad Then
        Happiness = Happiness - 2
        Death := Death - 5
    End;
   
  End;
©2006-2009 ~Meryovi
:iconmeryovi:

Author's Comments

-- Version 2.0:
- Comments added / Comentarios añadidos.

Picture / Imagen: "Pascal Vir Ico" by Me.

Programming Languages / Lenguajes de Programación: Visual Basic & Turbo Pascal.

Serie: CyberPoetry

:::::

It was very difficult to categorize it...

Maybe it's too long, and some of you may not understand it...
Sorry! ^^;

Hope you like it! :)

~

Fue muy difícil categorizarlo...

Quizás es muy largo, y puede que algunos de ustedes no lo entiendan...
Disculpen! ^^;

Espero que les guste! :)

Daily Deviation

Given 2008-02-25

I was recently asked what exactly is cyber poetry. I respond with this Program Life Basics by =Meryovi. This is a fine and unique example of experimentation in poetry using the unconventional tool of code. (Featured by ^StJoan)

Comments


love 2 2 joy 3 3 wow 2 2 mad 0 0 sad 0 0 fear 0 0 neutral 0 0
:iconmeryovi:
Gracias, gracias.
No sé de dónde saque esa idea!!

Los lenguajes de programación son Pascal y un poco de C++...
Y si los tipos de variables existieran también corriera!! :giggle:
Hidden by Owner
:iconbladeace:
This is definatly intresting. I really like it. so Im faving it right now. :D

--
My enemies are without Honor. I bring them only Vengeance.. and Death.
:iconmeryovi:
:aww:
Thank you very much!!
:iconbladeace:
Your very welcome : )

--
My enemies are without Honor. I bring them only Vengeance.. and Death.
:iconmoonlight00:
Yu yuff! cuanta imaginacion. Muy bueno :) :+fav:

--
[Life's like the weather, you never know when it's gonna change]
:icon28colores:
pff que complicadooo :O_o:
:iconmischk:
Muy Bien!!
ya yo te dije en ITESA que te pasate con ese... :P

:+fav:
Si tu le enseñas ese programa a Florecita.:butterfly: te apueto a que te quita punto.

--
Add me!!


-Want more pageviews?GO HERE!!
:iconmeryovi:
Ejejejej.... =P

No debería, eso no es asunto de él. =P

Details

December 30, 2006
7.4 KB
3.9 KB
50×50

Statistics

217
306 [who?]
5,553 (0 today)
87 (0 today)

Site Map