Exemple #1
0
void i_azoth(pob o)
{
    if (o->plus < 0) {
        mprint("The mercury was poisonous!");
        p_poison(25);
    }
    else if (o->plus == 0) {
        mprint("The partially enchanted azoth makes you sick!");
        Player.con = ((int) (Player.con / 2));
        calc_melee();
    }
    else if (o->blessing < 1) {
        mprint("The unblessed azoth warps your soul!");
        Player.pow = Player.maxpow = ((int) (Player.maxpow / 2));
        level_drain(random_range(10),"cursed azoth");
    }
    else {
        mprint("The azoth fills you with cosmic power!");
        if (Player.str > Player.maxstr*2) {
            mprint("The power rages out of control!");
            p_death("overdose of azoth");
        }
        else {
            heal(10);
            cleanse(1);
            Player.mana = calcmana()*3;
            toggle_item_use(TRUE);
            Player.str = (Player.maxstr++)*3;
            toggle_item_use(FALSE);
        }
    }
}
Exemple #2
0
void l_hedge(void)
{
  if (Player.patron == DRUID) print1("You move through the hedges freely.");
  else {
    print1("You struggle in the brambly hedge... ");
    switch(random_range(6)) {
    case 0: 
      print2("You are stabbed by thorns!");
      p_damage(random_range(6),NORMAL_DAMAGE,"a hedge");
      print3("The thorns were poisonous!");
      p_poison(random_range(12));
      break;
    case 1: 
      print2("You are stabbed by thorns!");
      p_damage(random_range(12),NORMAL_DAMAGE,"a hedge");
      break;
    case 2: 
      print2("You seem to have gotten stuck in the hedge.");
      Player.status[IMMOBILE]+=random_range(5)+1;
      break;
    case 3: 
      if (Player.possessions[O_CLOAK] != NULL) {
	print2("Your cloak was torn on the brambles!");
	dispose_lost_objects(1,Player.possessions[O_CLOAK]);
      }
      else print2("Ouch! These thorns are scratchy!");
      break;
    default: print2("You make your way through unscathed."); break;
    }
  }
}
Exemple #3
0
/* potion of neutralize poison */
void i_neutralize_poison(pob o)
{
    if (o->blessing > -1) {
        Objects[o->id].known = 1;
        mprint("You feel vital!");
        Player.status[POISONED] = 0;
    }
    else p_poison(random_range(20)+5);
}
Exemple #4
0
void i_perm_poison_resist(pob o)
{
  if (o->used) {
    if (o->blessing < 0) {
      Player.immunity[POISON] = 0;
      p_poison(100);
    }
    else {
      Player.immunity[POISON]++;
      if (Player.status[POISONED] > 0) {
	mprint("You feel much better now.");
	Player.status[POISONED] = 0;
      }
    }
  }
  else {
    Player.status[POISONED] = 0;
    Player.immunity[POISON]--;
  }
}
Exemple #5
0
void i_poison_food(pob o)
{
    mprint("This food was contaminated with cyanide!");
    p_poison(random_range(20)+5);
}
Exemple #6
0
void l_magic_pool(void)
{
  int possibilities=random_range(100);
  print1("This pool seems to be enchanted....");
  if (gamestatusp(MOUNTED)) {
    if (random_range(2)) {
      print2("Your horse is polymorphed into a fig newton.");
      resetgamestatus(MOUNTED);
    }
    else print2("Whatever it was, your horse enjoyed it....");
  }
  else  if (possibilities == 0) {
    print1("Oh no! You encounter the DREADED AQUAE MORTIS...");
    if (random_range(1000) < Player.level*Player.level*Player.level) {
      print2("The DREADED AQUAE MORTIS throttles you within inches....");
      print3("but for some reason chooses to let you escape.");
      gain_experience(500);
      Player.hp = 1;
    }
    else p_death("the DREADED AQUAE MORTIS!");
  }
  else if (possibilities < 25)
    augment(0);
  else if (possibilities < 30)
    augment(1);
  else if (possibilities < 60)
    augment(-1);
  else if (possibilities < 65)
    cleanse(1);
  else if (possibilities < 80) {
    if (Player.possessions[O_WEAPON_HAND] != NULL) {
      print1("You drop your weapon in the pool! It's gone forever!");
      dispose_lost_objects(1,Player.possessions[O_WEAPON_HAND]);
    }
    else print1("You feel fortunate.");
  }
  else if (possibilities < 90) {
    if (Player.possessions[O_WEAPON_HAND] != NULL) {
      print1("Your weapon leaves the pool with a new edge....");
      Player.possessions[O_WEAPON_HAND]->plus += random_range(10)+1;
      calc_melee();
    }
    else print1("You feel unfortunate.");
  }
  else if (possibilities < 95) {
    Player.hp += 10;
    print1("You feel healthier after the dip...");
  }
  else if (possibilities < 99) {
    print1("Oooh, a tainted pool...");
    p_poison(10);
  }
  else if (possibilities == 99) {
    print1("Wow! A pool of azoth!");
    heal(10);
    cleanse(1);
    Player.mana = calcmana()*3;
    Player.str = (Player.maxstr++)*3;
  }
  print2("The pool seems to have dried up.");
  Level->site[Player.x][Player.y].locchar = TRAP;
  Level->site[Player.x][Player.y].p_locf = L_TRAP_PIT;
  lset(Player.x, Player.y, CHANGED);
}