Back to index

freedink-data  1.08.20080920
S3-ST2P.c
Go to the documentation of this file.
00001 void main( void )
00002 {
00003  int &mom;
00004  &mom = random(3,1)
00005  if (&mom == 1)
00006  {
00007   say_stop("`1Good day sir.", &current_sprite);
00008  }
00009 }
00010 
00011 void hit( void )
00012 {
00013 int &rcrap = sp_pseq(&missle_source, -1);
00014 int &scrap = compare_weapon("item-b1");
00015 &scrap += compare_weapon("item-b2");
00016 &scrap += compare_weapon("item-b3");
00017 if (&rcrap == -1)
00018 {
00019 if (&scrap > 0)
00020 {
00021        say("`1See, now that pierced my lung! Ouch!", &current_sprite);
00022        return;
00023 }
00024 }
00025 say("`1That hurts and all, but you could be doing much more damage with a bow!", &current_sprite);
00026 }
00027 
00028 void buy( void )
00029 {
00030 buy:
00031 int &junk = free_items();
00032 say_stop("Well, despite the highway robbery, I'd like to get a bow.", 1);
00033 if (&junk < 1)
00034  {
00035   choice_start()
00036   set_y 240
00037   title_start();
00038 You are carrying too much.
00039   title_end();
00040   "Ok"
00041   choice_end()
00042   return;
00043  }
00044 
00045 if (&gold < 1000)
00046  {
00047   say_stop("`1I'm sorry sir, but you DON'T have enough gold!", &current_sprite);
00048   wait(250);
00049   say_stop("Whoops, sorry about that.", 1);
00050   unfreeze(1);
00051   unfreeze(&current_sprite);
00052   return;
00053  }
00054 
00055 &gold -= 1000;
00056 
00057  say_stop("`1Excellent sir!  I'm sure you won't be disappointed.", &current_sprite);
00058  wait(250);
00059  say_stop("Yeah, well I'll let ya know.", 1);
00060    wait(250);
00061    say_stop("`1One more thing.. if you hold down the button you will draw", &current_sprite);
00062    wait(250);
00063    say_stop("`1your bow back farther, thus hitting harder.  No refunds.  Enjoy!", &current_sprite);
00064  add_item("item-b1",438, 8);
00065  unfreeze(1);
00066  unfreeze(&current_sprite);
00067 
00068 }
00069 
00070 void talk( void )
00071 {
00072  freeze(1);
00073  freeze(&current_sprite);
00074  choice_start()
00075  "Ask about Bows"
00076  "Buy a Bow and some arrows for $1000"
00077  "Leave"
00078  choice_end()
00079   if (&result == 1)
00080   {
00081 
00082 int &hasbow = count_item("item-b1");
00083    if (&hasbow > 0)
00084    {
00085    say_stop("Well, you talked me into it and I bought one.", 1);
00086    wait(250);
00087    say_stop("`1You will love your new bow, sir!", &current_sprite);
00088    wait(250);
00089    say_stop("Any tips on using it?", 1);
00090    wait(250);
00091    say_stop("`1Well... There is an old man who has a place on the beach near", &current_sprite);
00092    wait(250);
00093    say_stop("`1here who can teach you bow lore.  This will give you triple", &current_sprite);
00094    wait(250);
00095    say_stop("`1damage.. when it works.", &current_sprite);
00096    wait(250);
00097    say_stop("Cool!  How will I know his house?", 1);
00098    wait(250);
00099    say_stop("`1It's sort of hidden.", &current_sprite);
00100 
00101  unfreeze(1);
00102  unfreeze(&current_sprite);
00103  return;
00104 
00105    }
00106 
00107    say_stop("Good day.", 1);
00108    wait(250);
00109    say_stop("`1To you too sir, I am Arturous, at your service.", &current_sprite);
00110    wait(250);
00111    say_stop("Yes well, I was wondering how much you sold your bows for?", 1);
00112    wait(250);
00113    say_stop("`1My current price for a bow and arrows is 1000 gold.", &current_sprite);
00114    wait(250);
00115    say_stop("MAN!  Don't you think that's a little steep??", 1);
00116    wait(250);
00117    say_stop("`1Not at all, my quality is superb.", &current_sprite);
00118    wait(250);
00119    say_stop("Damn better be!", 1);
00120   }
00121   if (&result == 2)
00122   {
00123    goto buy;
00124   }
00125  unfreeze(1);
00126  unfreeze(&current_sprite);
00127 }