1 /* SCCS Id: @(#)tech.c 3.2 98/Oct/30 */
2 /* Original Code by Warren Cheung (Basis: spell.c, attrib.c) */
3 /* Copyright (c) M. Stephenson 1988 */
4 /* NetHack may be freely redistributed. See license for details. */
6 /* All of the techs from cmd.c are ported here */
11 /* #define DEBUG */ /* turn on for diagnostics */
13 static boolean
gettech(int *);
14 static boolean
dotechmenu(int, int *);
15 static void doblitzlist(void);
16 static int techeffects(int);
17 static int mon_to_zombie(int);
18 STATIC_PTR
int tinker(void);
19 STATIC_PTR
int charge_saber(void);
20 STATIC_PTR
int draw_energy(void);
21 static const struct innate_tech
* role_tech(void);
22 static const struct innate_tech
* race_tech(void);
23 static int doblitz(void);
24 static int blitz_chi_strike(void);
25 static int blitz_e_fist(void);
26 static int blitz_pummel(void);
27 static int blitz_g_slam(void);
28 static int blitz_dash(void);
29 static int blitz_power_surge(void);
30 static int blitz_spirit_bomb(void);
31 static int blitz_combo_strike(void);
32 static int blitz_draining_punch(void);
33 static void maybe_tameX(struct monst
*);
35 static NEARDATA schar delay
; /* moves left for tinker/energy draw */
36 static NEARDATA
const char revivables
[] = { ALLOW_FLOOROBJ
, FOOD_CLASS
, 0 };
37 static const char all_count
[] = { ALLOW_COUNT
, ALL_CLASSES
, 0 };
38 static const char allnoncount
[] = { ALL_CLASSES
, 0 };
39 static NEARDATA
const char recharge_type
[] = { ALLOW_COUNT
, ALL_CLASSES
, 0 };
42 * Do try to keep the names <= 25 chars long, or else the
43 * menu will look bad :B WAC
46 STATIC_OVL NEARDATA
const char *tech_names
[] = {
73 "ward against lightning",
108 "spirituality check",
119 "intrinsic roulette",
158 "energy conservation",
163 "intensive training",
174 "intrinsic sacrifice",
189 "high-heeled sneakers",
193 "use the force luke",
202 "shut that bitch up",
221 "implanted symbiosis",
223 "generate offspring",
227 "grenades of course",
247 "participation loss",
260 "coronation/culmination",
261 "restore life levels",
285 "extreme sturdiness",
290 "hardcore alienization",
297 static const struct innate_tech
299 arc_tech
[] = { { 1, T_RESEARCH
, 1},
301 ass_tech
[] = { { 1, T_CUTTHROAT
, 1},
302 { 25, T_BLOOD_RITUAL
, 1},
304 lad_tech
[] = { { 1, T_ATTIRE_CHARM
, 1},
306 gee_tech
[] = { { 15, T_ZAP_EM
, 1},
308 fnc_tech
[] = { { 1, T_CRIT_STRIKE
, 1},
309 { 1, T_EDDY_WIND
, 1},
311 fig_tech
[] = { { 1, T_BERSERK
, 1},
312 { 4, T_CONCENTRATING
, 1},
313 { 8, T_IRON_SKIN
, 1},
314 { 10, T_SHIELD_BASH
, 1},
317 sex_tech
[] = { { 1, T_ATTIRE_CHARM
, 1},
318 { 1, T_POKE_BALL
, 1},
319 { 26, T_SUMMON_PET
, 1},
321 zoo_tech
[] = { { 12, T_SUMMON_PET
, 1},
323 jes_tech
[] = { { 10, T_CARD_TRICK
, 1},
324 { 30, T_EGG_BOMB
, 1},
326 stu_tech
[] = { { 1, T_LIQUID_LEAP
, 1},
327 { 1, T_JEDI_JUMP
, 1},
329 { 15, T_EDDY_WIND
, 1},
331 gun_tech
[] = { { 1, T_CREATE_AMMO
, 1},
334 mar_tech
[] = { { 1, T_CREATE_AMMO
, 1},
336 cli_tech
[] = { { 16, T_SURGERY
, 1},
338 wom_tech
[] = { { 20, T_ATTIRE_CHARM
, 1},
339 { 26, T_CARD_TRICK
, 1},
341 ana_tech
[] = { { 1, T_CREATE_AMMO
, 1},
342 { 1, T_DECONTAMINATE
, 1},
343 { 10, T_SKILLOMORPH
, 1},
344 { 20, T_TERRAIN_CLEANUP
, 1},
346 lib_tech
[] = { { 1, T_RESEARCH
, 1},
347 { 14, T_SPELL_SPAM
, 1},
348 { 20, T_RECHARGE
, 1},
349 { 20, T_WONDERSPELL
, 1},
351 med_tech
[] = { { 1, T_TELEKINESIS
, 1},
352 { 1, T_ON_THE_SAME_TEAM
, 1},
353 { 10, T_POLYFORM
, 1},
354 { 15, T_SPIRITUALITY_CHECK
, 1},
356 dol_tech
[] = { { 1, T_ATTIRE_CHARM
, 1},
358 { 10, T_POKE_BALL
, 1},
359 { 20, T_SUMMON_PET
, 1},
360 { 25, T_CARD_TRICK
, 1},
362 ama_tech
[] = { { 1, T_FLURRY
, 1},
364 { 5, T_CRIT_STRIKE
, 1},
366 { 18, T_CONCENTRATING
, 1},
367 { 20, T_SKILLOMORPH
, 1},
368 { 25, T_ATTIRE_CHARM
, 1},
370 art_tech
[] = { { 10, T_DIAMOND_BARRIER
, 1},
371 { 15, T_TERRAIN_CLEANUP
, 1},
372 { 18, T_POLYFORM
, 1},
373 { 20, T_BLOOD_RITUAL
, 1},
375 rin_tech
[] = { { 1, T_BLINK
, 1},
376 { 1, T_LUCKY_GAMBLE
, 1},
379 bos_tech
[] = { { 1, T_FLURRY
, 1},
380 { 1, T_DOUBLE_THROWNAGE
, 1},
382 { 10, T_ENT_S_POTION
, 1},
384 { 30, T_TELEKINESIS
, 1},
387 bul_tech
[] = { { 6, T_IRON_SKIN
, 1},
390 sta_tech
[] = { { 4, T_SKILLOMORPH
, 1},
391 { 12, T_DECONTAMINATE
, 1},
392 { 16, T_DIAMOND_BARRIER
, 1},
394 { 26, T_SPELL_SPAM
, 1},
397 ord_tech
[] = { { 1, T_PRACTICE
, 1},
398 { 1, T_TURN_UNDEAD
, 1},
399 { 5, T_CONCENTRATING
, 1},
400 { 8, T_DOUBLE_THROWNAGE
, 1},
402 { 12, T_EDDY_WIND
, 1},
405 dun_tech
[] = { { 1, T_CUTTHROAT
, 1},
406 { 5, T_CONCENTRATING
, 1},
407 { 10, T_CRIT_STRIKE
, 1},
408 { 15, T_SHIELD_BASH
, 1},
409 { 20, T_RAISE_ZOMBIES
, 1},
410 { 25, T_BLOOD_RITUAL
, 1},
413 alt_tech
[] = { { 1, T_BLESSING
, 1},
414 { 1, T_SIGIL_CONTROL
, 1},
415 { 1, T_SIGIL_TEMPEST
, 1},
416 { 1, T_SIGIL_DISCHARGE
, 1},
417 { 1, T_DRAW_ENERGY
, 1},
418 { 1, T_POWER_SURGE
, 1},
420 { 10, T_CHI_STRIKE
, 1},
421 { 15, T_WONDERSPELL
, 1},
426 tha_tech
[] = { { 5, T_DAZZLE
, 1},
427 { 10, T_WARD_FIRE
, 1},
428 { 10, T_DRAW_ENERGY
, 1},
429 { 10, T_IRON_SKIN
, 1},
430 { 15, T_LIQUID_LEAP
, 1},
431 { 15, T_WARD_ELEC
, 1},
432 { 20, T_WARD_COLD
, 1},
433 { 20, T_POWER_SURGE
, 1},
434 { 20, T_EDDY_WIND
, 1},
435 { 27, T_SPELL_SPAM
, 1},
438 gof_tech
[] = { { 1, T_DRAW_BLOOD
, 1},
439 { 1, T_CALM_STEED
, 1},
441 { 1, T_TURN_UNDEAD
, 1},
442 { 1, T_CREATE_AMMO
, 1},
443 { 1, T_ATTIRE_CHARM
, 1},
444 { 1, T_BLOOD_RITUAL
, 1},
448 { 20, T_RAISE_ZOMBIES
, 1},
450 { 30, T_TELEKINESIS
, 1},
452 dru_tech
[] = { { 1, T_BOOZE
, 1}, /* drunk */
453 { 20, T_ENT_S_POTION
, 1},
455 drd_tech
[] = { { 7, T_ENT_S_POTION
, 1},
456 { 18, T_SPELL_SPAM
, 1},
457 { 28, T_ON_THE_SAME_TEAM
, 1},
459 sof_tech
[] = { { 5, T_ZAP_EM
, 1},
462 jan_tech
[] = { { 1, T_IRON_SKIN
, 1},
463 { 1, T_CONCENTRATING
, 1},
464 { 1, T_TERRAIN_CLEANUP
, 1},
467 sma_tech
[] = { { 1, T_CREATE_AMMO
, 1},
468 { 10, T_PRACTICE
, 1},
470 { 15, T_CHARGE_SABER
, 1},
472 sto_tech
[] = { { 1, T_BERSERK
, 1},
474 { 5, T_SKILLOMORPH
, 1},
476 { 12, T_DOUBLE_THROWNAGE
, 1},
478 { 20, T_SIGIL_TEMPEST
, 1},
479 { 24, T_EDDY_WIND
, 1},
481 cra_tech
[] = { { 1, T_ZAP_EM
, 1},
482 { 10, T_CARD_TRICK
, 1},
483 { 15, T_RESEARCH
, 1},
484 { 20, T_RECHARGE
, 1},
485 { 30, T_DOUBLE_TROUBLE
, 1},
487 fir_tech
[] = { { 12, T_RECHARGE
, 1},
489 yau_tech
[] = { { 2, T_BLOOD_RITUAL
, 1},
490 { 8, T_CRIT_STRIKE
, 1},
491 { 10, T_SIGIL_DISCHARGE
, 1},
492 { 12, T_CHI_HEALING
, 1},
494 { 18, T_DRAW_ENERGY
, 1},
495 { 25, T_TELEKINESIS
, 1},
497 gam_tech
[] = { { 1, T_CONCENTRATING
, 1},
498 { 13, T_LUCKY_GAMBLE
, 1},
499 { 20, T_SUMMON_PET
, 1},
500 { 30, T_RESET_TECHNIQUE
, 1},
502 joc_tech
[] = { { 1, T_CALM_STEED
, 1},
505 gla_tech
[] = { { 5, T_SHIELD_BASH
, 1},
506 { 10, T_IRON_SKIN
, 1},
508 bar_tech
[] = { { 1, T_BERSERK
, 1},
509 { 8, T_DOUBLE_THROWNAGE
, 1},
510 { 10, T_CONCENTRATING
, 1},
511 { 10, T_IRON_SKIN
, 1},
512 { 20, T_EDDY_WIND
, 1},
514 noo_tech
[] = { { 1, T_BERSERK
, 1},
515 { 8, T_DOUBLE_THROWNAGE
, 1},
516 { 10, T_CONCENTRATING
, 1},
517 { 10, T_IRON_SKIN
, 1},
518 { 20, T_EDDY_WIND
, 1},
520 blo_tech
[] = { { 1, T_EDDY_WIND
, 1},
521 { 10, T_BLOOD_RITUAL
, 1},
523 gol_tech
[] = { { 1, T_VANISH
, 1},
526 ble_tech
[] = { { 1, T_SURGERY
, 1},
527 { 1, T_HEAL_HANDS
, 1},
528 { 1, T_DRAW_BLOOD
, 1},
529 { 10, T_CHI_HEALING
, 1},
531 { 30, T_BLOOD_RITUAL
, 1},
533 mid_tech
[] = { { 1, T_RAGE
, 1},
535 psy_tech
[] = { { 1, T_ZAP_EM
, 1},
536 { 2, T_TURN_UNDEAD
, 1},
537 { 7, T_REINFORCE
, 1},
539 { 12, T_SIGIL_CONTROL
, 1},
540 { 15, T_SPIRITUALITY_CHECK
, 1},
541 { 18, T_DRAW_ENERGY
, 1},
542 { 18, T_SPELL_SPAM
, 1},
543 { 20, T_SPIRIT_BOMB
, 1},
544 { 24, T_BLESSING
, 1},
545 { 28, T_SUMMON_PET
, 1},
547 sag_tech
[] = { { 4, T_SPELL_SPAM
, 1},
549 spa_tech
[] = { { 1, T_REINFORCE
, 1},
552 { 8, T_WARD_FIRE
, 1},
553 { 10, T_CHARGE_SABER
, 1},
554 { 11, T_WARD_COLD
, 1},
555 { 14, T_WARD_ELEC
, 1},
556 { 20, T_DRAW_ENERGY
, 1},
558 cam_tech
[] = { { 12, T_CREATE_AMMO
, 1},
559 { 26, T_RECHARGE
, 1},
561 qua_tech
[] = { { 12, T_ZAP_EM
, 1},
563 gan_tech
[] = { { 1, T_CREATE_AMMO
, 1},
564 { 1, T_LUCKY_GAMBLE
, 1},
566 emp_tech
[] = { { 1, T_SURGERY
, 1},
567 { 1, T_REINFORCE
, 1},
568 { 1, T_HEAL_HANDS
, 1},
569 { 1, T_CALM_STEED
, 1},
570 { 3, T_CHI_HEALING
, 1},
571 { 5, T_TURN_UNDEAD
, 1},
572 { 7, T_DRAW_BLOOD
, 1},
574 { 10, T_DRAW_ENERGY
, 1},
575 { 15, T_SPIRITUALITY_CHECK
, 1},
576 { 18, T_PREACHING
, 1},
577 { 20, T_ATTIRE_CHARM
, 1},
578 { 20, T_ENT_S_POTION
, 1},
580 { 30, T_WONDERSPELL
, 1},
582 nuc_tech
[] = { { 1, T_DECONTAMINATE
, 1},
583 { 14, T_PERMAMORPH
, 1},
585 for_tech
[] = { { 20, T_PERMAMORPH
, 1},
587 gen_tech
[] = { { 12, T_PREACHING
, 1},
589 mam_tech
[] = { { 1, T_REINFORCE
, 1},
592 { 1, T_SPELL_SPAM
, 1},
593 { 10, T_CONCENTRATING
, 1},
594 { 10, T_POWER_SURGE
, 1},
595 { 15, T_WONDERSPELL
, 1},
596 { 18, T_TELEKINESIS
, 1},
598 sco_tech
[] = { { 25, T_DIAMOND_BARRIER
, 1},
600 wal_tech
[] = { { 1, T_DIAMOND_BARRIER
, 1},
602 off_tech
[] = { { 10, T_ON_THE_SAME_TEAM
, 1},
604 wei_tech
[] = { { 2, T_POLYFORM
, 1},
605 { 3, T_SIGIL_DISCHARGE
, 1},
608 { 8, T_LUCKY_GAMBLE
, 1},
609 { 9, T_SUMMON_TEAM_ANT
, 1},
610 { 10, T_CARD_TRICK
, 1},
611 { 11, T_CALM_STEED
, 1},
612 { 14, T_HARDCORE_ALIENIZATION
, 1},
613 { 17, T_RAISE_ZOMBIES
, 1},
614 { 18, T_DIAMOND_BARRIER
, 1},
615 { 19, T_CHI_STRIKE
, 1},
616 { 20, T_PREACHING
, 1},
619 { 24, T_EVISCERATE
, 1},
620 { 29, T_WORLD_FALL
, 1},
621 { 30, T_TURN_UNDEAD
, 1},
623 loc_tech
[] = { { 15, T_DIAMOND_BARRIER
, 1},
625 roc_tech
[] = { { 1, T_EGG_BOMB
, 1},
628 cel_tech
[] = { { 6, T_SPELL_SPAM
, 1},
629 { 10, T_TERRAIN_CLEANUP
, 1},
630 { 24, T_PERMAMORPH
, 1},
632 ast_tech
[] = { { 5, T_FLURRY
, 1},
633 { 6, T_SIGIL_CONTROL
, 1},
634 { 8, T_SHIELD_BASH
, 1},
635 { 10, T_REINFORCE
, 1},
637 { 12, T_RESEARCH
, 1},
638 { 18, T_SIGIL_TEMPEST
, 1},
639 { 18, T_CHARGE_SABER
, 1},
641 { 20, T_WORLD_FALL
, 1},
642 { 24, T_DECONTAMINATE
, 1},
644 { 24, T_DRAW_ENERGY
, 1},
645 { 25, T_SIGIL_DISCHARGE
, 1},
646 { 25, T_SKILLOMORPH
, 1},
647 { 28, T_TERRAIN_CLEANUP
, 1},
649 { 30, T_LIQUID_LEAP
, 1},
651 dea_tech
[] = { { 1, T_WORLD_FALL
, 1},
653 { 1, T_BLOOD_RITUAL
, 1},
654 { 18, T_SPELL_SPAM
, 1},
656 div_tech
[] = { { 15, T_POLYFORM
, 1},
658 cav_tech
[] = { { 1, T_PRIMAL_ROAR
, 1},
659 { 10, T_SHIELD_BASH
, 1},
660 { 20, T_POLYFORM
, 1},
662 dem_tech
[] = { { 1, T_PRIMAL_ROAR
, 1},
663 { 25, T_PREACHING
, 1},
665 sli_tech
[] = { { 1, T_LIQUID_LEAP
, 1},
666 { 4, T_SPIRITUALITY_CHECK
, 1},
667 { 6, T_HEAL_HANDS
, 1},
668 { 10, T_LUCKY_GAMBLE
, 1},
669 { 12, T_WORLD_FALL
, 1},
670 { 15, T_TELEKINESIS
, 1},
671 { 18, T_IRON_SKIN
, 1},
672 { 19, T_SUMMON_TEAM_ANT
, 1},
673 { 21, T_DECONTAMINATE
, 1},
674 { 23, T_RECHARGE
, 1},
676 { 26, T_ROCK_TO_POISON
, 1},
677 { 28, T_POLYFORM
, 1},
678 { 30, T_EGG_BOMB
, 1},
680 erd_tech
[] = { { 1, T_CRIT_STRIKE
, 1},
681 { 10, T_PRACTICE
, 1},
682 { 20, T_ATTIRE_CHARM
, 1},
684 brd_tech
[] = { { 1, T_PRIMAL_ROAR
, 1},
686 { 15, T_ON_THE_SAME_TEAM
, 1},
689 hus_tech
[] = { { 20, T_ROCK_TO_POISON
, 1},
691 aci_tech
[] = { { 1, T_REINFORCE
, 1},
692 { 3, T_POWER_SURGE
, 1},
693 { 5, T_DRAW_ENERGY
, 1},
694 { 7, T_SIGIL_CONTROL
, 1},
695 { 10, T_SIGIL_TEMPEST
, 1},
696 { 10, T_SPELL_SPAM
, 1},
697 { 18, T_ROCK_TO_POISON
, 1},
698 { 20, T_SIGIL_DISCHARGE
, 1},
700 fla_tech
[] = { { 1, T_REINFORCE
, 1},
701 { 3, T_POWER_SURGE
, 1},
702 { 5, T_DRAW_ENERGY
, 1},
703 { 8, T_SPELL_SPAM
, 1},
704 { 10, T_SIGIL_TEMPEST
, 1},
705 { 20, T_SIGIL_DISCHARGE
, 1},
707 ele_tech
[] = { { 1, T_REINFORCE
, 1},
708 { 3, T_POWER_SURGE
, 1},
709 { 5, T_DRAW_ENERGY
, 1},
710 { 7, T_SIGIL_CONTROL
, 1},
711 { 10, T_SPELL_SPAM
, 1},
712 { 10, T_SIGIL_TEMPEST
, 1},
713 { 20, T_SIGIL_DISCHARGE
, 1},
715 psn_tech
[] = { { 1, T_REINFORCE
, 1},
716 { 1, T_SIGIL_CONTROL
, 1},
717 { 1, T_SIGIL_TEMPEST
, 1},
718 { 1, T_SIGIL_DISCHARGE
, 1},
719 { 1, T_ROCK_TO_POISON
, 1},
720 { 3, T_POWER_SURGE
, 1},
721 { 5, T_DRAW_ENERGY
, 1},
723 { 14, T_SPELL_SPAM
, 1},
725 hea_tech
[] = { { 1, T_SURGERY
, 1},
726 { 10, T_ENT_S_POTION
, 1},
728 { 30, T_ON_THE_SAME_TEAM
, 1},
730 ice_tech
[] = { { 1, T_REINFORCE
, 1},
731 { 5, T_DRAW_ENERGY
, 1},
732 { 8, T_SPELL_SPAM
, 1},
733 { 10, T_SIGIL_TEMPEST
, 1},
734 { 12, T_POWER_SURGE
, 1},
735 { 20, T_SIGIL_DISCHARGE
, 1},
737 jed_tech
[] = { { 1, T_JEDI_JUMP
, 1},
738 { 5, T_CHARGE_SABER
, 1},
739 { 8, T_TELEKINESIS
, 1},
740 { 15, T_SHIELD_BASH
, 1},
741 { 25, T_SPIRITUALITY_CHECK
, 1},
743 kni_tech
[] = { { 1, T_TURN_UNDEAD
, 1},
744 { 1, T_HEAL_HANDS
, 1},
745 { 1, T_SHIELD_BASH
, 1},
746 { 26, T_SPELL_SPAM
, 1},
749 car_tech
[] = { { 1, T_CARD_TRICK
, 1},
750 { 15, T_LUCKY_GAMBLE
, 1},
753 dra_tech
[] = { { 10, T_PRIMAL_ROAR
, 1},
754 { 15, T_ON_THE_SAME_TEAM
, 1},
755 { 20, T_CALM_STEED
, 1},
756 { 30, T_SUMMON_PET
, 1},
759 com_tech
[] = { { 2, T_SHIELD_BASH
, 1},
761 { 15, T_CONCENTRATING
, 1},
763 { 25, T_SPIRIT_BOMB
, 1},
766 fjo_tech
[] = { { 5, T_SURGERY
, 1},
767 { 10, T_LIQUID_LEAP
, 1},
768 { 20, T_REINFORCE
, 1},
772 pra_tech
[] = { { 1, T_RESEARCH
, 1},
773 { 14, T_ON_THE_SAME_TEAM
, 1},
775 { 25, T_RECHARGE
, 1},
778 eme_tech
[] = { { 10, T_RAGE
, 1},
781 sym_tech
[] = { { 12, T_TERRAIN_CLEANUP
, 1},
784 but_tech
[] = { { 15, T_SUMMON_PET
, 1},
785 { 20, T_ATTIRE_CHARM
, 1},
788 dan_tech
[] = { { 1, T_BLITZ
, 1},
790 { 3, T_IRON_SKIN
, 1},
792 { 7, T_SHIELD_BASH
, 1},
793 { 9, T_DIAMOND_BARRIER
, 1},
794 { 11, T_SIGIL_DISCHARGE
, 1},
795 { 13, T_SPIRIT_BOMB
, 1},
798 { 20, T_ATTIRE_CHARM
, 1},
799 { 22, T_TERRAIN_CLEANUP
, 1},
800 { 25, T_CHI_STRIKE
, 1},
801 { 27, T_JEDI_JUMP
, 1},
802 { 30, T_CHI_HEALING
, 1},
805 kor_tech
[] = { { 1, T_DOUBLE_THROWNAGE
, 1},
808 pre_tech
[] = { { 1, T_TERRAIN_CLEANUP
, 1},
811 sec_tech
[] = { { 1, T_RECHARGE
, 1},
813 { 10, T_CHARGE_SABER
, 1},
814 { 12, T_REINFORCE
, 1},
815 { 20, T_RESEARCH
, 1},
817 { 24, T_CREATE_AMMO
, 1},
819 { 28, T_POLYFORM
, 1},
820 { 30, T_BLOOD_RITUAL
, 1},
823 dia_tech
[] = { { 1, T_REINFORCE
, 1},
824 { 1, T_CRIT_STRIKE
, 1},
825 { 1, T_SHIELD_BASH
, 1},
826 { 6, T_WARD_FIRE
, 1},
827 { 6, T_TELEKINESIS
, 1},
828 { 10, T_PRACTICE
, 1},
829 { 12, T_WARD_COLD
, 1},
830 { 12, T_DOUBLE_THROWNAGE
, 1},
832 { 18, T_WARD_ELEC
, 1},
834 { 18, T_IRON_SKIN
, 1},
835 { 18, T_CONCENTRATING
, 1},
836 { 20, T_SPELL_SPAM
, 1},
837 { 24, T_TURN_UNDEAD
, 1},
839 { 30, T_PRIMAL_ROAR
, 1},
841 { 30, T_EDDY_WIND
, 1},
844 occ_tech
[] = { { 1, T_SIGIL_DISCHARGE
, 1},
846 { 12, T_REINFORCE
, 1},
847 { 15, T_SPELL_SPAM
, 1},
848 { 16, T_RESEARCH
, 1},
849 { 18, T_SPIRITUALITY_CHECK
, 1},
850 { 20, T_BLOOD_RITUAL
, 1},
851 { 24, T_POWER_SURGE
, 1},
854 emn_tech
[] = { { 1, T_E_FIST
, 1},
855 { 1, T_SIGIL_CONTROL
, 1},
856 { 5, T_WARD_COLD
, 1},
857 { 8, T_REINFORCE
, 1},
858 { 8, T_SPELL_SPAM
, 1},
859 { 10, T_WARD_ELEC
, 1},
860 { 12, T_TERRAIN_CLEANUP
, 1},
861 { 15, T_WARD_FIRE
, 1},
862 { 20, T_ENT_S_POTION
, 1},
865 cha_tech
[] = { { 1, T_SIGIL_TEMPEST
, 1},
866 { 4, T_REINFORCE
, 1},
867 { 10, T_LUCKY_GAMBLE
, 1},
868 { 12, T_PERMAMORPH
, 1},
869 { 18, T_EDDY_WIND
, 1},
870 { 20, T_WORLD_FALL
, 1},
871 { 22, T_EVISCERATE
, 1},
872 { 24, T_SPIRIT_BOMB
, 1},
875 jus_tech
[] = { { 1, T_PREACHING
, 1},
877 { 12, T_CONCENTRATING
, 1},
878 { 16, T_SHIELD_BASH
, 1},
879 { 19, T_SPELL_SPAM
, 1},
882 pal_tech
[] = { { 1, T_TURN_UNDEAD
, 1},
883 { 1, T_HEAL_HANDS
, 1},
884 { 1, T_SHIELD_BASH
, 1},
885 { 1, T_SPIRITUALITY_CHECK
, 1},
886 { 1, T_PREACHING
, 1},
887 { 18, T_CONCENTRATING
, 1},
890 wan_tech
[] = { { 1, T_RECHARGE
, 1},
891 { 30, T_WORLD_FALL
, 1},
894 war_tech
[] = { { 1, T_CONCENTRATING
, 1},
895 { 10, T_SHIELD_BASH
, 1},
896 { 24, T_IRON_SKIN
, 1},
899 sci_tech
[] = { { 1, T_RESEARCH
, 1},
902 { 20, T_SUMMON_TEAM_ANT
, 1},
903 { 25, T_DRAW_ENERGY
, 1},
904 { 30, T_EGG_BOMB
, 1},
906 sha_tech
[] = { { 1, T_LIQUID_LEAP
, 1},
907 { 15, T_POLYFORM
, 1},
910 sla_tech
[] = { { 1, T_SUMMON_PET
, 1},
911 { 12, T_LUCKY_GAMBLE
, 1},
914 mon_tech
[] = { { 1, T_PUMMEL
, 1},
917 { 2, T_CHI_STRIKE
, 1},
918 { 4, T_CHI_HEALING
, 1},
919 { 5, T_PREACHING
, 1},
921 { 8, T_DRAW_ENERGY
, 1},
923 { 11, T_WARD_FIRE
, 1},
924 { 13, T_WARD_COLD
, 1},
925 { 15, T_WARD_ELEC
, 1},
926 { 17, T_SPIRIT_BOMB
, 1},
927 { 20, T_POWER_SURGE
, 1},
930 sup_tech
[] = { { 18, T_PUMMEL
, 1},
933 { 18, T_CHI_STRIKE
, 1},
934 { 18, T_CHI_HEALING
, 1},
937 { 18, T_SPIRIT_BOMB
, 1},
938 { 18, T_IRON_SKIN
, 1},
939 { 18, T_CONCENTRATING
, 1},
940 { 18, T_DOUBLE_THROWNAGE
, 1},
941 { 18, T_SHIELD_BASH
, 1},
944 sai_tech
[] = { { 1, T_PUMMEL
, 1},
947 { 2, T_CHI_STRIKE
, 1},
948 { 4, T_CHI_HEALING
, 1},
950 { 8, T_DRAW_ENERGY
, 1},
951 { 8, T_CONCENTRATING
, 1},
953 { 11, T_WARD_FIRE
, 1},
954 { 13, T_WARD_COLD
, 1},
955 { 15, T_WARD_ELEC
, 1},
956 { 17, T_SPIRIT_BOMB
, 1},
957 { 20, T_POWER_SURGE
, 1},
958 { 24, T_EDDY_WIND
, 1},
961 psi_tech
[] = { { 1, T_PUMMEL
, 1},
963 { 2, T_CHI_STRIKE
, 1},
964 { 4, T_CHI_HEALING
, 1},
966 { 7, T_SPELL_SPAM
, 1},
967 { 8, T_DRAW_ENERGY
, 1},
968 { 8, T_TELEKINESIS
, 1},
970 { 11, T_WARD_FIRE
, 1},
971 { 13, T_WARD_COLD
, 1},
972 { 15, T_WARD_ELEC
, 1},
973 { 15, T_ATTIRE_CHARM
, 1},
974 { 17, T_SPIRIT_BOMB
, 1},
975 { 20, T_POWER_SURGE
, 1},
976 { 30, T_PERMAMORPH
, 1},
978 pok_tech
[] = { { 1, T_POKE_BALL
, 1},
980 { 3, T_SPIRITUALITY_CHECK
, 1},
982 { 5, T_WARD_FIRE
, 1},
983 { 7, T_SHIELD_BASH
, 1},
985 { 9, T_WARD_COLD
, 1},
986 { 10, T_RAISE_ZOMBIES
, 1},
987 { 11, T_LUCKY_GAMBLE
, 1},
989 { 13, T_WARD_ELEC
, 1},
990 { 15, T_CREATE_AMMO
, 1},
992 { 17, T_EGG_BOMB
, 1},
993 { 18, T_WORLD_FALL
, 1},
994 { 19, T_SPELL_SPAM
, 1},
995 { 20, T_DRAW_ENERGY
, 1},
996 { 21, T_RECHARGE
, 1},
997 { 22, T_RESEARCH
, 1},
998 { 23, T_POLYFORM
, 1},
999 { 24, T_EDDY_WIND
, 1},
1001 { 26, T_SUMMON_TEAM_ANT
, 1},
1002 { 27, T_BLESSING
, 1},
1004 { 29, T_SPIRIT_BOMB
, 1},
1005 { 30, T_POWER_SURGE
, 1},
1007 nec_tech
[] = { { 1, T_REINFORCE
, 1},
1008 { 1, T_RAISE_ZOMBIES
, 1},
1009 { 10, T_POWER_SURGE
, 1},
1010 { 15, T_SIGIL_TEMPEST
, 1},
1011 { 25, T_BLOOD_RITUAL
, 1},
1013 abu_tech
[] = { { 1, T_CONCENTRATING
, 1},
1014 { 1, T_IRON_SKIN
, 1},
1016 pri_tech
[] = { { 1, T_TURN_UNDEAD
, 1},
1017 { 1, T_BLESSING
, 1},
1018 { 1, T_PREACHING
, 1},
1019 { 1, T_SPIRITUALITY_CHECK
, 1},
1020 { 22, T_SPELL_SPAM
, 1},
1021 { 24, T_BLOOD_RITUAL
, 1},
1023 che_tech
[] = { { 1, T_TURN_UNDEAD
, 1},
1024 { 1, T_BLESSING
, 1},
1025 { 1, T_HEAL_HANDS
, 1},
1026 { 1, T_SPIRITUALITY_CHECK
, 1},
1027 { 1, T_PREACHING
, 1},
1029 ran_tech
[] = { { 1, T_FLURRY
, 1},
1031 aug_tech
[] = { { 1, T_TELEKINESIS
, 1},
1032 { 1, T_SPELL_SPAM
, 1},
1033 { 5, T_WONDERSPELL
, 1},
1034 { 10, T_SPIRITUALITY_CHECK
, 1},
1035 { 15, T_CARD_TRICK
, 1},
1036 { 20, T_DIAMOND_BARRIER
, 1},
1038 elp_tech
[] = { { 1, T_FLURRY
, 1},
1040 rog_tech
[] = { { 1, T_CRIT_STRIKE
, 1},
1041 { 15, T_CUTTHROAT
, 1},
1043 sam_tech
[] = { { 1, T_KIII
, 1},
1044 { 6, T_SHIELD_BASH
, 1},
1045 { 18, T_IRON_SKIN
, 1},
1046 { 18, T_CONCENTRATING
, 1},
1047 { 30, T_BLOOD_RITUAL
, 1},
1049 cyb_tech
[] = { { 1, T_KIII
, 1},
1051 { 6, T_SHIELD_BASH
, 1},
1052 { 8, T_CUTTHROAT
, 1},
1053 { 10, T_CHARGE_SABER
, 1},
1054 { 12, T_CRIT_STRIKE
, 1},
1055 { 18, T_IRON_SKIN
, 1},
1056 { 18, T_CONCENTRATING
, 1},
1057 { 30, T_BLOOD_RITUAL
, 1},
1059 gro_tech
[] = { { 1, T_KIII
, 1},
1060 { 1, T_CREATE_AMMO
, 1},
1061 { 6, T_SHIELD_BASH
, 1},
1062 { 18, T_IRON_SKIN
, 1},
1063 { 18, T_CONCENTRATING
, 1},
1064 { 30, T_BLOOD_RITUAL
, 1},
1066 nin_tech
[] = { { 5, T_DOUBLE_THROWNAGE
, 1},
1067 { 25, T_EDDY_WIND
, 1},
1069 tou_tech
[] = { /* Put Tech here */
1071 tra_tech
[] = { { 1, T_ATTIRE_CHARM
, 1},
1072 { 17, T_SUMMON_PET
, 1},
1074 kur_tech
[] = { { 1, T_ATTIRE_CHARM
, 1}, /* also used for prostitute */
1076 dis_tech
[] = { { 5, T_BERSERK
, 1},
1080 { 22, T_ON_THE_SAME_TEAM
, 1},
1082 mas_tech
[] = { { 1, T_DIAMOND_BARRIER
, 1}, /* mason */
1084 xel_tech
[] = { { 4, T_SPELL_SPAM
, 1},
1085 { 6, T_EVISCERATE
, 1},
1086 { 8, T_CRIT_STRIKE
, 1},
1089 { 10, T_BLOOD_RITUAL
, 1},
1090 { 12, T_RESEARCH
, 1},
1091 { 16, T_ROCK_TO_POISON
, 1},
1092 { 18, T_TELEKINESIS
, 1},
1093 { 20, T_REINFORCE
, 1},
1094 { 24, T_POLYFORM
, 1},
1095 { 25, T_EGG_BOMB
, 1},
1096 { 26, T_PERMAMORPH
, 1},
1097 { 30, T_SKILLOMORPH
, 1},
1099 trs_tech
[] = { { 1, T_ATTIRE_CHARM
, 1},
1100 { 17, T_SUMMON_PET
, 1},
1102 act_tech
[] = { { 1, T_REINFORCE
, 1},
1104 { 8, T_ON_THE_SAME_TEAM
, 1},
1106 { 10, T_PREACHING
, 1},
1107 { 25, T_TERRAIN_CLEANUP
, 1},
1109 top_tech
[] = { { 1, T_ATTIRE_CHARM
, 1},
1110 { 10, T_CREATE_AMMO
, 1},
1111 { 20, T_LIQUID_LEAP
, 1},
1112 { 30, T_POLYFORM
, 1},
1114 fai_tech
[] = { { 1, T_ATTIRE_CHARM
, 1},
1115 { 29, T_CREATE_AMMO
, 1},
1117 und_tech
[] = { { 1, T_TURN_UNDEAD
, 1},
1118 { 1, T_PRACTICE
, 1},
1119 { 10, T_IRON_SKIN
, 1},
1121 unb_tech
[] = { { 1, T_TURN_UNDEAD
, 1},
1122 { 1, T_PRACTICE
, 1},
1123 { 3, T_SHIELD_BASH
, 1},
1124 { 6, T_IRON_SKIN
, 1},
1125 { 6, T_CONCENTRATING
, 1},
1126 { 12, T_DOUBLE_THROWNAGE
, 1},
1127 { 15, T_RECHARGE
, 1},
1128 { 18, T_EDDY_WIND
, 1},
1129 { 20, T_DECONTAMINATE
, 1},
1131 unt_tech
[] = { { 1, T_TURN_UNDEAD
, 1},
1132 { 5, T_BLOOD_RITUAL
, 1},
1133 { 14, T_SPIRITUALITY_CHECK
, 1},
1135 val_tech
[] = { { 1, T_PRACTICE
, 1},
1136 { 9, T_CONCENTRATING
, 1},
1137 { 14, T_RECHARGE
, 1},
1138 { 20, T_IRON_SKIN
, 1},
1140 lun_tech
[] = { { 1, T_EVISCERATE
, 1},
1141 { 10, T_BERSERK
, 1},
1144 { 1, T_CALM_STEED
, 1},
1145 { 8, T_IRON_SKIN
, 1},
1146 { 17, T_EDDY_WIND
, 1},
1147 { 25, T_SUMMON_PET
, 1},
1149 wiz_tech
[] = { { 1, T_REINFORCE
, 1},
1150 { 3, T_DRAW_ENERGY
, 1},
1151 { 5, T_POWER_SURGE
, 1},
1152 { 7, T_SIGIL_CONTROL
, 1},
1153 { 14, T_SIGIL_TEMPEST
, 1},
1154 { 20, T_SIGIL_DISCHARGE
, 1},
1158 /* dummy, for copypasting into new races --Amy */
1160 dummy_tech[] = { { 1, T_APPRAISAL, 1},
1161 { 1, T_PANIC_DIGGING, 1},
1162 { 1, T_PHASE_DOOR, 1},
1163 { 1, T_INVOKE_DEITY, 1},
1164 { 15, T_SECURE_IDENTIFY, 1},
1168 red_tech
[] = { { 1, T_APPRAISAL
, 1},
1169 { 1, T_PANIC_DIGGING
, 1},
1170 { 1, T_PHASE_DOOR
, 1},
1171 { 1, T_INVOKE_DEITY
, 1},
1172 { 15, T_SECURE_IDENTIFY
, 1},
1173 { 18, T_HARDCORE_ALIENIZATION
, 1},
1176 sdi_tech
[] = { { 1, T_APPRAISAL
, 1},
1177 { 1, T_PANIC_DIGGING
, 1},
1178 { 1, T_PHASE_DOOR
, 1},
1179 { 1, T_INVOKE_DEITY
, 1},
1184 { 15, T_SECURE_IDENTIFY
, 1},
1185 { 20, T_DRAW_ENERGY
, 1},
1186 { 25, T_SPIRIT_BOMB
, 1},
1189 she_tech
[] = { { 1, T_APPRAISAL
, 1},
1190 { 1, T_PANIC_DIGGING
, 1},
1191 { 1, T_PHASE_DOOR
, 1},
1192 { 1, T_INVOKE_DEITY
, 1},
1193 { 15, T_SECURE_IDENTIFY
, 1},
1194 { 20, T_SPELL_SPAM
, 1},
1197 mzi_tech
[] = { { 1, T_APPRAISAL
, 1},
1198 { 1, T_PANIC_DIGGING
, 1},
1199 { 1, T_PHASE_DOOR
, 1},
1200 { 1, T_INVOKE_DEITY
, 1},
1201 { 10, T_SPELL_SPAM
, 1},
1202 { 15, T_SECURE_IDENTIFY
, 1},
1205 bre_tech
[] = { { 1, T_APPRAISAL
, 1},
1206 { 1, T_PANIC_DIGGING
, 1},
1207 { 1, T_PHASE_DOOR
, 1},
1208 { 1, T_INVOKE_DEITY
, 1},
1209 { 15, T_SECURE_IDENTIFY
, 1},
1210 { 20, T_SPELL_SPAM
, 1},
1213 arg_tech
[] = { { 1, T_HEAL_HANDS
, 1},
1214 { 1, T_PANIC_DIGGING
, 1},
1215 { 1, T_APPRAISAL
, 1},
1216 { 1, T_PHASE_DOOR
, 1},
1217 { 1, T_INVOKE_DEITY
, 1},
1218 { 15, T_SECURE_IDENTIFY
, 1},
1220 coc_tech
[] = { { 1, T_EGG_BOMB
, 1},
1221 { 1, T_APPRAISAL
, 1},
1222 { 1, T_PANIC_DIGGING
, 1},
1223 { 1, T_PHASE_DOOR
, 1},
1224 { 1, T_INVOKE_DEITY
, 1},
1225 { 15, T_SECURE_IDENTIFY
, 1},
1227 hca_tech
[] = { { 1, T_APPRAISAL
, 1},
1228 { 1, T_PANIC_DIGGING
, 1},
1229 { 1, T_PHASE_DOOR
, 1},
1230 { 1, T_INVOKE_DEITY
, 1},
1231 { 1, T_PREACHING
, 1},
1232 { 15, T_SECURE_IDENTIFY
, 1},
1233 { 20, T_HARDCORE_ALIENIZATION
, 1},
1235 sly_tech
[] = { { 1, T_APPRAISAL
, 1},
1236 { 1, T_PANIC_DIGGING
, 1},
1237 { 1, T_PHASE_DOOR
, 1},
1238 { 1, T_INVOKE_DEITY
, 1},
1239 { 1, T_PREACHING
, 1},
1240 { 1, T_HARDCORE_ALIENIZATION
, 1},
1241 { 15, T_SECURE_IDENTIFY
, 1},
1243 azt_tech
[] = { { 1, T_APPRAISAL
, 1},
1244 { 1, T_PANIC_DIGGING
, 1},
1245 { 1, T_PHASE_DOOR
, 1},
1246 { 1, T_INVOKE_DEITY
, 1},
1247 { 1, T_PREACHING
, 1},
1248 { 15, T_SECURE_IDENTIFY
, 1},
1250 dop_tech
[] = { { 1, T_LIQUID_LEAP
, 1},
1251 { 1, T_APPRAISAL
, 1},
1252 { 1, T_PANIC_DIGGING
, 1},
1253 { 1, T_PHASE_DOOR
, 1},
1254 { 1, T_INVOKE_DEITY
, 1},
1255 { 15, T_SECURE_IDENTIFY
, 1},
1257 dwa_tech
[] = { { 1, T_RAGE
, 1},
1258 { 1, T_APPRAISAL
, 1},
1259 { 1, T_PANIC_DIGGING
, 1},
1260 { 1, T_PHASE_DOOR
, 1},
1261 { 1, T_INVOKE_DEITY
, 1},
1262 { 15, T_SECURE_IDENTIFY
, 1},
1264 cur_tech
[] = { /* Put Tech here */
1265 { 1, T_BLESSING
, 1},
1266 { 1, T_APPRAISAL
, 1},
1267 { 1, T_PANIC_DIGGING
, 1},
1268 { 1, T_PHASE_DOOR
, 1},
1269 { 1, T_INVOKE_DEITY
, 1},
1270 { 15, T_SECURE_IDENTIFY
, 1},
1272 imp_tech
[] = { { 1, T_APPRAISAL
, 1},
1273 { 1, T_PANIC_DIGGING
, 1},
1274 { 1, T_PHASE_DOOR
, 1},
1275 { 1, T_INVOKE_DEITY
, 1},
1276 { 10, T_PREACHING
, 1},
1277 { 15, T_SECURE_IDENTIFY
, 1},
1279 swi_tech
[] = { { 1, T_APPRAISAL
, 1},
1280 { 1, T_PANIC_DIGGING
, 1},
1281 { 1, T_PHASE_DOOR
, 1},
1282 { 1, T_INVOKE_DEITY
, 1},
1283 { 1, T_CREATE_AMMO
, 1},
1284 { 15, T_SECURE_IDENTIFY
, 1},
1287 tay_tech
[] = { { 1, T_APPRAISAL
, 1},
1288 { 1, T_PANIC_DIGGING
, 1},
1289 { 1, T_PHASE_DOOR
, 1},
1290 { 1, T_INVOKE_DEITY
, 1},
1294 { 15, T_SECURE_IDENTIFY
, 1},
1297 spd_tech
[] = { { 1, T_APPRAISAL
, 1},
1298 { 1, T_PANIC_DIGGING
, 1},
1299 { 1, T_PHASE_DOOR
, 1},
1300 { 1, T_INVOKE_DEITY
, 1},
1301 { 12, T_PREACHING
, 1},
1302 { 15, T_SECURE_IDENTIFY
, 1},
1304 elf_tech
[] = { /* Put Tech here */
1305 { 1, T_APPRAISAL
, 1},
1306 { 1, T_PANIC_DIGGING
, 1},
1307 { 1, T_PHASE_DOOR
, 1},
1308 { 1, T_INVOKE_DEITY
, 1},
1309 { 15, T_SECURE_IDENTIFY
, 1},
1311 kop_tech
[] = { { 1, T_APPRAISAL
, 1},
1312 { 1, T_PANIC_DIGGING
, 1},
1313 { 1, T_PHASE_DOOR
, 1},
1314 { 1, T_INVOKE_DEITY
, 1},
1315 { 10, T_ON_THE_SAME_TEAM
, 1},
1316 { 15, T_SECURE_IDENTIFY
, 1},
1318 gno_tech
[] = { { 1, T_VANISH
, 1},
1319 { 1, T_APPRAISAL
, 1},
1320 { 1, T_PANIC_DIGGING
, 1},
1321 { 1, T_PHASE_DOOR
, 1},
1322 { 1, T_INVOKE_DEITY
, 1},
1324 { 15, T_SECURE_IDENTIFY
, 1},
1326 anc_tech
[] = { { 1, T_APPRAISAL
, 1},
1327 { 1, T_PANIC_DIGGING
, 1},
1328 { 1, T_PHASE_DOOR
, 1},
1329 { 1, T_INVOKE_DEITY
, 1},
1330 { 11, T_CONCENTRATING
, 1},
1331 { 15, T_SECURE_IDENTIFY
, 1},
1333 dee_tech
[] = { { 1, T_APPRAISAL
, 1},
1334 { 1, T_PANIC_DIGGING
, 1},
1335 { 1, T_PHASE_DOOR
, 1},
1336 { 1, T_INVOKE_DEITY
, 1},
1337 { 10, T_BLOOD_RITUAL
, 1},
1338 { 15, T_SECURE_IDENTIFY
, 1},
1340 nea_tech
[] = { { 1, T_APPRAISAL
, 1},
1341 { 1, T_PANIC_DIGGING
, 1},
1342 { 1, T_PHASE_DOOR
, 1},
1343 { 1, T_INVOKE_DEITY
, 1},
1345 { 15, T_SECURE_IDENTIFY
, 1},
1347 and_tech
[] = { { 1, T_APPRAISAL
, 1},
1348 { 1, T_PANIC_DIGGING
, 1},
1349 { 1, T_PHASE_DOOR
, 1},
1350 { 1, T_INVOKE_DEITY
, 1},
1351 { 10, T_CREATE_AMMO
, 1},
1352 { 15, T_SKILLOMORPH
, 1},
1353 { 15, T_SECURE_IDENTIFY
, 1},
1354 { 20, T_CHARGE_SABER
, 1},
1356 sho_tech
[] = { { 1, T_APPRAISAL
, 1},
1357 { 1, T_PANIC_DIGGING
, 1},
1358 { 1, T_PHASE_DOOR
, 1},
1359 { 1, T_INVOKE_DEITY
, 1},
1360 { 8, T_ON_THE_SAME_TEAM
, 1},
1361 { 15, T_SECURE_IDENTIFY
, 1},
1363 bga_tech
[] = { { 1, T_APPRAISAL
, 1},
1364 { 1, T_PANIC_DIGGING
, 1},
1365 { 1, T_PHASE_DOOR
, 1},
1366 { 1, T_INVOKE_DEITY
, 1},
1367 { 15, T_SECURE_IDENTIFY
, 1},
1368 { 15, T_CONCENTRATING
, 1},
1369 { 20, T_TERRAIN_CLEANUP
, 1},
1371 dvp_tech
[] = { { 1, T_APPRAISAL
, 1},
1372 { 1, T_PANIC_DIGGING
, 1},
1373 { 1, T_PHASE_DOOR
, 1},
1374 { 1, T_INVOKE_DEITY
, 1},
1375 { 1, T_RESET_TECHNIQUE
, 1},
1376 { 1, T_SKILLOMORPH
, 1},
1377 { 1, T_TERRAIN_CLEANUP
, 1},
1378 { 5, T_RESEARCH
, 1},
1379 { 10, T_DIAMOND_BARRIER
, 1},
1380 { 15, T_SECURE_IDENTIFY
, 1},
1381 { 20, T_TURN_UNDEAD
, 1},
1382 { 20, T_WORLD_FALL
, 1},
1384 bur_tech
[] = { { 1, T_APPRAISAL
, 1},
1385 { 1, T_PANIC_DIGGING
, 1},
1386 { 1, T_PHASE_DOOR
, 1},
1387 { 1, T_INVOKE_DEITY
, 1},
1388 { 10, T_WARD_FIRE
, 1},
1389 { 15, T_SECURE_IDENTIFY
, 1},
1390 { 20, T_SPIRIT_BOMB
, 1},
1392 gre_tech
[] = { { 1, T_APPRAISAL
, 1},
1393 { 1, T_PANIC_DIGGING
, 1},
1394 { 1, T_PHASE_DOOR
, 1},
1395 { 1, T_INVOKE_DEITY
, 1},
1397 { 15, T_SECURE_IDENTIFY
, 1},
1399 sti_tech
[] = { { 1, T_APPRAISAL
, 1},
1400 { 1, T_PANIC_DIGGING
, 1},
1401 { 1, T_PHASE_DOOR
, 1},
1402 { 1, T_INVOKE_DEITY
, 1},
1403 { 1, T_RECHARGE
, 1},
1404 { 15, T_SECURE_IDENTIFY
, 1},
1406 thu_tech
[] = { { 1, T_APPRAISAL
, 1},
1407 { 1, T_PANIC_DIGGING
, 1},
1408 { 1, T_PHASE_DOOR
, 1},
1409 { 1, T_INVOKE_DEITY
, 1},
1410 { 1, T_WARD_ELEC
, 1},
1411 { 15, T_SECURE_IDENTIFY
, 1},
1413 jav_tech
[] = { { 1, T_APPRAISAL
, 1},
1414 { 1, T_PANIC_DIGGING
, 1},
1415 { 1, T_PHASE_DOOR
, 1},
1416 { 1, T_INVOKE_DEITY
, 1},
1417 { 1, T_DOUBLE_THROWNAGE
, 1},
1418 { 15, T_SECURE_IDENTIFY
, 1},
1420 wis_tech
[] = { { 1, T_APPRAISAL
, 1},
1421 { 1, T_PANIC_DIGGING
, 1},
1422 { 1, T_PHASE_DOOR
, 1},
1423 { 1, T_INVOKE_DEITY
, 1},
1424 { 1, T_DOUBLE_THROWNAGE
, 1},
1426 { 15, T_SECURE_IDENTIFY
, 1},
1427 { 15, T_WONDERSPELL
, 1},
1428 { 22, T_POLYFORM
, 1},
1430 roh_tech
[] = { { 1, T_APPRAISAL
, 1},
1431 { 1, T_PANIC_DIGGING
, 1},
1432 { 1, T_PHASE_DOOR
, 1},
1433 { 1, T_INVOKE_DEITY
, 1},
1435 { 15, T_SECURE_IDENTIFY
, 1},
1436 { 20, T_IRON_SKIN
, 1},
1438 sal_tech
[] = { { 1, T_APPRAISAL
, 1},
1439 { 1, T_PANIC_DIGGING
, 1},
1440 { 1, T_PHASE_DOOR
, 1},
1441 { 1, T_INVOKE_DEITY
, 1},
1443 { 15, T_SECURE_IDENTIFY
, 1},
1445 din_tech
[] = { { 1, T_APPRAISAL
, 1},
1446 { 1, T_PANIC_DIGGING
, 1},
1447 { 1, T_PHASE_DOOR
, 1},
1448 { 1, T_INVOKE_DEITY
, 1},
1450 { 15, T_SECURE_IDENTIFY
, 1},
1451 { 16, T_EDDY_WIND
, 1},
1453 faw_tech
[] = { { 1, T_APPRAISAL
, 1},
1454 { 1, T_PANIC_DIGGING
, 1},
1455 { 1, T_PHASE_DOOR
, 1},
1456 { 1, T_INVOKE_DEITY
, 1},
1457 { 5, T_REINFORCE
, 1},
1458 { 15, T_SECURE_IDENTIFY
, 1},
1459 { 15, T_ENT_S_POTION
, 1},
1460 { 16, T_SPIRITUALITY_CHECK
, 1},
1461 { 27, T_LIQUID_LEAP
, 1},
1463 sat_tech
[] = { { 1, T_APPRAISAL
, 1},
1464 { 1, T_PANIC_DIGGING
, 1},
1465 { 1, T_PHASE_DOOR
, 1},
1466 { 1, T_INVOKE_DEITY
, 1},
1467 { 1, T_REINFORCE
, 1},
1468 { 1, T_ON_THE_SAME_TEAM
, 1},
1469 { 13, T_HEAL_HANDS
, 1},
1471 { 15, T_SECURE_IDENTIFY
, 1},
1472 { 20, T_CALM_STEED
, 1},
1473 { 20, T_DRAW_ENERGY
, 1},
1474 { 21, T_LIQUID_LEAP
, 1},
1475 { 22, T_SUMMON_TEAM_ANT
, 1},
1476 { 24, T_TELEKINESIS
, 1},
1477 { 30, T_SUMMON_PET
, 1},
1479 clk_tech
[] = { { 1, T_FLURRY
, 1},
1481 { 1, T_APPRAISAL
, 1},
1482 { 1, T_PANIC_DIGGING
, 1},
1483 { 1, T_PHASE_DOOR
, 1},
1484 { 1, T_INVOKE_DEITY
, 1},
1486 { 2, T_SPIRITUALITY_CHECK
, 1},
1487 { 4, T_DOUBLE_THROWNAGE
, 1},
1489 { 6, T_SHIELD_BASH
, 1},
1490 { 7, T_SIGIL_DISCHARGE
, 1},
1491 { 8, T_IRON_SKIN
, 1},
1493 { 11, T_POLYFORM
, 1},
1494 { 12, T_DRAW_ENERGY
, 1},
1495 { 13, T_CONCENTRATING
, 1},
1496 { 15, T_SIGIL_TEMPEST
, 1},
1497 { 15, T_SECURE_IDENTIFY
, 1},
1498 { 20, T_RECHARGE
, 1},
1499 { 20, T_ENT_S_POTION
, 1},
1500 { 23, T_SIGIL_CONTROL
, 1},
1501 { 25, T_EDDY_WIND
, 1},
1502 { 28, T_DECONTAMINATE
, 1},
1504 ogr_tech
[] = { { 1, T_FLURRY
, 1},
1505 { 1, T_APPRAISAL
, 1},
1506 { 1, T_PANIC_DIGGING
, 1},
1507 { 1, T_PHASE_DOOR
, 1},
1508 { 1, T_INVOKE_DEITY
, 1},
1509 { 10, T_BERSERK
, 1},
1510 { 15, T_PRIMAL_ROAR
, 1},
1511 { 15, T_SECURE_IDENTIFY
, 1},
1512 { 20, T_CRIT_STRIKE
, 1},
1514 fay_tech
[] = { { 1, T_APPRAISAL
, 1},
1515 { 1, T_PANIC_DIGGING
, 1},
1516 { 1, T_PHASE_DOOR
, 1},
1517 { 1, T_INVOKE_DEITY
, 1},
1519 { 15, T_SECURE_IDENTIFY
, 1},
1520 { 16, T_SPELL_SPAM
, 1},
1521 { 20, T_DRAW_ENERGY
, 1},
1523 alc_tech
[] = { { 1, T_RESEARCH
, 1},
1525 { 1, T_APPRAISAL
, 1},
1526 { 1, T_PANIC_DIGGING
, 1},
1527 { 1, T_PHASE_DOOR
, 1},
1528 { 1, T_INVOKE_DEITY
, 1},
1529 { 10, T_SURGERY
, 1},
1530 { 15, T_SECURE_IDENTIFY
, 1},
1531 { 20, T_SUMMON_TEAM_ANT
, 1},
1532 { 25, T_DRAW_ENERGY
, 1},
1533 { 30, T_EGG_BOMB
, 1},
1535 ung_tech
[] = { { 1, T_WORLD_FALL
, 1},
1536 { 1, T_APPRAISAL
, 1},
1537 { 1, T_PANIC_DIGGING
, 1},
1538 { 1, T_PHASE_DOOR
, 1},
1539 { 1, T_INVOKE_DEITY
, 1},
1540 { 1, T_POKE_BALL
, 1},
1541 { 1, T_RESEARCH
, 1},
1542 { 1, T_PRACTICE
, 1},
1543 { 1, T_CALM_STEED
, 1},
1544 { 1, T_TURN_UNDEAD
, 1},
1545 { 1, T_BLESSING
, 1},
1546 { 1, T_DRAW_BLOOD
, 1},
1548 { 1, T_DOUBLE_THROWNAGE
, 1},
1549 { 1, T_EDDY_WIND
, 1},
1550 { 15, T_SECURE_IDENTIFY
, 1},
1551 { 16, T_SPIRITUALITY_CHECK
, 1},
1552 { 24, T_POLYFORM
, 1},
1554 mou_tech
[] = { { 1, T_APPRAISAL
, 1},
1555 { 1, T_PANIC_DIGGING
, 1},
1556 { 1, T_PHASE_DOOR
, 1},
1557 { 1, T_INVOKE_DEITY
, 1},
1558 { 10, T_POLYFORM
, 1},
1559 { 15, T_SECURE_IDENTIFY
, 1},
1561 oct_tech
[] = { { 1, T_APPRAISAL
, 1},
1562 { 1, T_PANIC_DIGGING
, 1},
1563 { 1, T_PHASE_DOOR
, 1},
1564 { 1, T_INVOKE_DEITY
, 1},
1565 { 1, T_LIQUID_LEAP
, 1},
1567 { 15, T_SECURE_IDENTIFY
, 1},
1568 { 20, T_ENT_S_POTION
, 1},
1570 ink_tech
[] = { { 1, T_APPRAISAL
, 1},
1571 { 1, T_PANIC_DIGGING
, 1},
1572 { 1, T_PHASE_DOOR
, 1},
1573 { 1, T_INVOKE_DEITY
, 1},
1574 { 5, T_ENT_S_POTION
, 1},
1575 { 10, T_RESEARCH
, 1},
1576 { 12, T_ON_THE_SAME_TEAM
, 1},
1577 { 15, T_SECURE_IDENTIFY
, 1},
1578 { 15, T_SPIRITUALITY_CHECK
, 1},
1579 { 20, T_HEAL_HANDS
, 1},
1580 { 30, T_SUMMON_PET
, 1},
1582 hob_tech
[] = { { 1, T_BLINK
, 1},
1583 { 1, T_APPRAISAL
, 1},
1584 { 1, T_PANIC_DIGGING
, 1},
1585 { 1, T_LUCKY_GAMBLE
, 1},
1586 { 1, T_PHASE_DOOR
, 1},
1587 { 1, T_INVOKE_DEITY
, 1},
1588 { 15, T_SECURE_IDENTIFY
, 1},
1591 fen_tech
[] = { { 1, T_EVISCERATE
, 1},
1592 { 1, T_APPRAISAL
, 1},
1593 { 1, T_PANIC_DIGGING
, 1},
1595 { 1, T_PHASE_DOOR
, 1},
1596 { 1, T_INVOKE_DEITY
, 1},
1598 { 15, T_SECURE_IDENTIFY
, 1},
1599 { 20, T_SUMMON_PET
, 1},
1602 ent_tech
[] = { { 1, T_ENT_S_POTION
, 1},
1603 { 1, T_APPRAISAL
, 1},
1604 { 1, T_PANIC_DIGGING
, 1},
1605 { 1, T_PHASE_DOOR
, 1},
1606 { 1, T_INVOKE_DEITY
, 1},
1607 { 15, T_SECURE_IDENTIFY
, 1},
1610 alb_tech
[] = { { 1, T_DAZZLE
, 1},
1611 { 1, T_PRACTICE
, 1},
1612 { 1, T_APPRAISAL
, 1},
1613 { 1, T_PANIC_DIGGING
, 1},
1614 { 1, T_PHASE_DOOR
, 1},
1615 { 1, T_INVOKE_DEITY
, 1},
1616 { 1, T_BLOOD_RITUAL
, 1},
1617 { 5, T_CHARGE_SABER
, 1},
1618 { 10, T_CRIT_STRIKE
, 1},
1619 { 15, T_TELEKINESIS
, 1},
1620 { 15, T_SECURE_IDENTIFY
, 1},
1622 { 25, T_JEDI_JUMP
, 1},
1625 ret_tech
[] = { { 1, T_REINFORCE
, 1},
1626 { 1, T_APPRAISAL
, 1},
1627 { 1, T_PANIC_DIGGING
, 1},
1628 { 1, T_PHASE_DOOR
, 1},
1629 { 1, T_INVOKE_DEITY
, 1},
1630 { 5, T_RESEARCH
, 1},
1632 { 10, T_CONCENTRATING
, 1},
1633 { 15, T_SECURE_IDENTIFY
, 1},
1634 { 20, T_POWER_SURGE
, 1},
1635 { 25, T_WONDERSPELL
, 1},
1636 { 30, T_TELEKINESIS
, 1},
1639 nor_tech
[] = { { 1, T_BERSERK
, 1},
1640 { 1, T_APPRAISAL
, 1},
1641 { 1, T_PANIC_DIGGING
, 1},
1642 { 1, T_PHASE_DOOR
, 1},
1643 { 1, T_INVOKE_DEITY
, 1},
1644 { 8, T_CONCENTRATING
, 1},
1646 { 15, T_SECURE_IDENTIFY
, 1},
1649 lic_tech
[] = { { 1, T_BLOOD_RITUAL
, 1},
1650 { 1, T_APPRAISAL
, 1},
1651 { 1, T_PANIC_DIGGING
, 1},
1652 { 1, T_PHASE_DOOR
, 1},
1653 { 1, T_INVOKE_DEITY
, 1},
1654 { 15, T_SECURE_IDENTIFY
, 1},
1657 ins_tech
[] = { { 1, T_SUMMON_TEAM_ANT
, 1},
1658 { 1, T_APPRAISAL
, 1},
1659 { 1, T_PANIC_DIGGING
, 1},
1660 { 1, T_PHASE_DOOR
, 1},
1661 { 1, T_INVOKE_DEITY
, 1},
1662 { 12, T_DOUBLE_THROWNAGE
, 1},
1663 { 15, T_SECURE_IDENTIFY
, 1},
1665 kla_tech
[] = { { 1, T_SUMMON_TEAM_ANT
, 1},
1666 { 1, T_APPRAISAL
, 1},
1667 { 1, T_PANIC_DIGGING
, 1},
1668 { 1, T_PHASE_DOOR
, 1},
1669 { 1, T_INVOKE_DEITY
, 1},
1670 { 15, T_SECURE_IDENTIFY
, 1},
1671 { 15, T_CRIT_STRIKE
, 1},
1672 { 20, T_TELEKINESIS
, 1},
1673 { 25, T_SPIRIT_BOMB
, 1},
1675 kob_tech
[] = { { 1, T_APPRAISAL
, 1},
1676 { 1, T_PANIC_DIGGING
, 1},
1677 { 1, T_PHASE_DOOR
, 1},
1678 { 1, T_INVOKE_DEITY
, 1},
1679 { 3, T_DOUBLE_THROWNAGE
, 1},
1681 { 15, T_SECURE_IDENTIFY
, 1},
1683 kha_tech
[] = { { 1, T_EVISCERATE
, 1},
1684 { 1, T_APPRAISAL
, 1},
1685 { 1, T_PANIC_DIGGING
, 1},
1686 { 1, T_PHASE_DOOR
, 1},
1687 { 1, T_INVOKE_DEITY
, 1},
1688 { 15, T_SECURE_IDENTIFY
, 1},
1690 gel_tech
[] = { { 1, T_LIQUID_LEAP
, 1},
1691 { 1, T_APPRAISAL
, 1},
1692 { 1, T_PANIC_DIGGING
, 1},
1693 { 1, T_PHASE_DOOR
, 1},
1694 { 1, T_INVOKE_DEITY
, 1},
1695 { 15, T_SECURE_IDENTIFY
, 1},
1697 ton_tech
[] = { { 1, T_DASH
, 1},
1698 { 1, T_APPRAISAL
, 1},
1699 { 1, T_PANIC_DIGGING
, 1},
1700 { 1, T_PHASE_DOOR
, 1},
1701 { 1, T_INVOKE_DEITY
, 1},
1702 { 6, T_SHIELD_BASH
, 1},
1703 { 10, T_IRON_SKIN
, 1},
1704 { 10, T_ON_THE_SAME_TEAM
, 1},
1705 { 15, T_SECURE_IDENTIFY
, 1},
1706 { 20, T_POKE_BALL
, 1},
1708 hmo_tech
[] = { { 1, T_BERSERK
, 1},
1709 { 1, T_APPRAISAL
, 1},
1710 { 1, T_PANIC_DIGGING
, 1},
1711 { 1, T_PHASE_DOOR
, 1},
1712 { 1, T_INVOKE_DEITY
, 1},
1713 { 15, T_SECURE_IDENTIFY
, 1},
1715 zru_tech
[] = { { 1, T_BERSERK
, 1},
1717 { 1, T_APPRAISAL
, 1},
1718 { 1, T_PANIC_DIGGING
, 1},
1719 { 1, T_PHASE_DOOR
, 1},
1720 { 1, T_INVOKE_DEITY
, 1},
1721 { 10, T_PRIMAL_ROAR
, 1},
1722 { 15, T_SECURE_IDENTIFY
, 1},
1725 lyc_tech
[] = { { 1, T_EVISCERATE
, 1},
1726 { 1, T_APPRAISAL
, 1},
1727 { 1, T_PANIC_DIGGING
, 1},
1728 { 1, T_PHASE_DOOR
, 1},
1729 { 1, T_INVOKE_DEITY
, 1},
1730 { 10, T_BERSERK
, 1},
1731 { 15, T_SECURE_IDENTIFY
, 1},
1733 vam_tech
[] = { { 1, T_DAZZLE
, 1},
1734 { 1, T_APPRAISAL
, 1},
1735 { 1, T_PANIC_DIGGING
, 1},
1736 { 1, T_PHASE_DOOR
, 1},
1737 { 1, T_INVOKE_DEITY
, 1},
1738 { 1, T_DRAW_BLOOD
, 1},
1739 { 15, T_SECURE_IDENTIFY
, 1},
1741 lev_tech
[] = { { 1, T_DAZZLE
, 1},
1743 { 1, T_TELEKINESIS
, 1},
1744 { 1, T_APPRAISAL
, 1},
1745 { 1, T_PANIC_DIGGING
, 1},
1746 { 1, T_PHASE_DOOR
, 1},
1747 { 1, T_INVOKE_DEITY
, 1},
1748 { 4, T_SPIRITUALITY_CHECK
, 1},
1749 { 5, T_ATTIRE_CHARM
, 1},
1750 { 8, T_ENT_S_POTION
, 1},
1752 { 13, T_RECHARGE
, 1},
1753 { 15, T_BLESSING
, 1},
1754 { 15, T_SECURE_IDENTIFY
, 1},
1755 { 18, T_POLYFORM
, 1},
1756 { 20, T_LIQUID_LEAP
, 1},
1757 { 22, T_LUCKY_GAMBLE
, 1},
1758 { 25, T_DRAW_ENERGY
, 1},
1759 { 30, T_SUMMON_TEAM_ANT
, 1},
1761 ang_tech
[] = { { 1, T_DAZZLE
, 1},
1762 { 1, T_APPRAISAL
, 1},
1763 { 1, T_PANIC_DIGGING
, 1},
1764 { 1, T_PHASE_DOOR
, 1},
1765 { 1, T_TURN_UNDEAD
, 1},
1766 { 1, T_INVOKE_DEITY
, 1},
1767 { 15, T_SECURE_IDENTIFY
, 1},
1769 hrb_tech
[] = { { 1, T_SURGERY
, 1},
1770 { 1, T_APPRAISAL
, 1},
1771 { 1, T_PANIC_DIGGING
, 1},
1772 { 1, T_PHASE_DOOR
, 1},
1773 { 1, T_INVOKE_DEITY
, 1},
1774 { 15, T_SECURE_IDENTIFY
, 1},
1777 mum_tech
[] = { { 1, T_RAISE_ZOMBIES
, 1},
1778 { 1, T_APPRAISAL
, 1},
1779 { 1, T_PANIC_DIGGING
, 1},
1780 { 1, T_PHASE_DOOR
, 1},
1781 { 1, T_INVOKE_DEITY
, 1},
1782 { 15, T_SECURE_IDENTIFY
, 1},
1784 vor_tech
[] = { { 1, T_APPRAISAL
, 1},
1785 { 1, T_PANIC_DIGGING
, 1},
1786 { 1, T_PHASE_DOOR
, 1},
1787 { 1, T_INVOKE_DEITY
, 1},
1789 { 5, T_SPIRITUALITY_CHECK
, 1},
1790 { 10, T_TELEKINESIS
, 1},
1791 { 15, T_EGG_BOMB
, 1},
1792 { 15, T_SECURE_IDENTIFY
, 1},
1793 { 20, T_WORLD_FALL
, 1},
1794 { 25, T_RECHARGE
, 1},
1796 cor_tech
[] = { { 1, T_APPRAISAL
, 1},
1797 { 1, T_PANIC_DIGGING
, 1},
1798 { 1, T_PHASE_DOOR
, 1},
1799 { 1, T_INVOKE_DEITY
, 1},
1801 { 1, T_EGG_BOMB
, 1},
1802 { 5, T_SPIRITUALITY_CHECK
, 1},
1803 { 10, T_TELEKINESIS
, 1},
1804 { 15, T_SECURE_IDENTIFY
, 1},
1805 { 20, T_WORLD_FALL
, 1},
1806 { 25, T_RECHARGE
, 1},
1808 bor_tech
[] = { { 3, T_JEDI_JUMP
, 1},
1809 { 10, T_CHARGE_SABER
, 1},
1810 { 15, T_SECURE_IDENTIFY
, 1},
1811 { 20, T_TELEKINESIS
, 1},
1812 { 1, T_PHASE_DOOR
, 1},
1813 { 1, T_INVOKE_DEITY
, 1},
1814 { 1, T_APPRAISAL
, 1},
1815 { 1, T_PANIC_DIGGING
, 1},
1818 woo_tech
[] = { { 12, T_JEDI_JUMP
, 1},
1819 { 20, T_CHARGE_SABER
, 1},
1820 { 15, T_SECURE_IDENTIFY
, 1},
1821 { 1, T_PHASE_DOOR
, 1},
1822 { 1, T_INVOKE_DEITY
, 1},
1823 { 1, T_APPRAISAL
, 1},
1824 { 1, T_PANIC_DIGGING
, 1},
1827 bat_tech
[] = { { 1, T_APPRAISAL
, 1},
1828 { 1, T_PANIC_DIGGING
, 1},
1829 { 1, T_PHASE_DOOR
, 1},
1830 { 1, T_INVOKE_DEITY
, 1},
1831 { 1, T_PRACTICE
, 1},
1832 { 1, T_ON_THE_SAME_TEAM
, 1},
1833 { 1, T_DRAW_BLOOD
, 1},
1834 { 15, T_SECURE_IDENTIFY
, 1},
1835 { 20, T_POLYFORM
, 1},
1837 cen_tech
[] = { { 1, T_INVOKE_DEITY
, 1},
1838 { 1, T_APPRAISAL
, 1},
1839 { 1, T_PANIC_DIGGING
, 1},
1840 { 1, T_PHASE_DOOR
, 1},
1841 { 7, T_SHIELD_BASH
, 1},
1842 { 15, T_SECURE_IDENTIFY
, 1},
1844 rod_tech
[] = { { 1, T_APPRAISAL
, 1},
1845 { 1, T_PANIC_DIGGING
, 1},
1846 { 1, T_PHASE_DOOR
, 1},
1847 { 1, T_INVOKE_DEITY
, 1},
1848 { 5, T_CARD_TRICK
, 1},
1849 { 10, T_DOUBLE_TROUBLE
, 1},
1850 { 15, T_SECURE_IDENTIFY
, 1},
1851 { 20, T_WONDERSPELL
, 1},
1852 { 25, T_SPELL_SPAM
, 1},
1853 { 30, T_RESET_TECHNIQUE
, 1},
1856 man_tech
[] = { { 1, T_APPRAISAL
, 1},
1857 { 1, T_PANIC_DIGGING
, 1},
1858 { 1, T_PHASE_DOOR
, 1},
1859 { 1, T_INVOKE_DEITY
, 1},
1860 { 10, T_SKILLOMORPH
, 1},
1863 jel_tech
[] = { { 1, T_DRAW_ENERGY
, 1},
1864 { 1, T_LIQUID_LEAP
, 1},
1865 { 1, T_PHASE_DOOR
, 1},
1866 { 1, T_INVOKE_DEITY
, 1},
1867 { 1, T_APPRAISAL
, 1},
1868 { 1, T_PANIC_DIGGING
, 1},
1869 { 1, T_SPIRITUALITY_CHECK
, 1},
1870 { 12, T_RECHARGE
, 1},
1871 { 15, T_SECURE_IDENTIFY
, 1},
1872 { 22, T_POLYFORM
, 1},
1875 dry_tech
[] = { { 1, T_IRON_SKIN
, 1},
1876 { 1, T_INVOKE_DEITY
, 1},
1877 { 1, T_APPRAISAL
, 1},
1878 { 1, T_PANIC_DIGGING
, 1},
1879 { 1, T_PHASE_DOOR
, 1},
1880 { 15, T_SECURE_IDENTIFY
, 1},
1883 tur_tech
[] = { { 1, T_PUMMEL
, 1},
1884 { 1, T_APPRAISAL
, 1},
1885 { 1, T_PANIC_DIGGING
, 1},
1886 { 1, T_PHASE_DOOR
, 1},
1887 { 1, T_INVOKE_DEITY
, 1},
1890 { 2, T_CHI_STRIKE
, 1},
1891 { 4, T_CHI_HEALING
, 1},
1892 { 5, T_DOUBLE_THROWNAGE
, 1},
1894 { 8, T_DRAW_ENERGY
, 1},
1896 { 11, T_WARD_FIRE
, 1},
1897 { 13, T_WARD_COLD
, 1},
1898 { 15, T_WARD_ELEC
, 1},
1899 { 15, T_SECURE_IDENTIFY
, 1},
1900 { 17, T_SPIRIT_BOMB
, 1},
1901 { 20, T_POWER_SURGE
, 1},
1902 { 25, T_EDDY_WIND
, 1},
1905 gri_tech
[] = { { 1, T_APPRAISAL
, 1},
1906 { 1, T_PANIC_DIGGING
, 1},
1907 { 1, T_PHASE_DOOR
, 1},
1908 { 1, T_INVOKE_DEITY
, 1},
1909 { 10, T_RECHARGE
, 1},
1910 { 15, T_SECURE_IDENTIFY
, 1},
1913 tme_tech
[] = { { 1, T_APPRAISAL
, 1},
1914 { 1, T_PANIC_DIGGING
, 1},
1915 { 1, T_PHASE_DOOR
, 1},
1916 { 1, T_INVOKE_DEITY
, 1},
1917 { 1, T_CREATE_AMMO
, 1},
1918 { 12, T_HARDCORE_ALIENIZATION
, 1},
1919 { 15, T_SECURE_IDENTIFY
, 1},
1922 inc_tech
[] = { { 1, T_APPRAISAL
, 1},
1923 { 1, T_PANIC_DIGGING
, 1},
1924 { 1, T_PHASE_DOOR
, 1},
1925 { 1, T_INVOKE_DEITY
, 1},
1926 { 15, T_SECURE_IDENTIFY
, 1},
1927 { 20, T_RECHARGE
, 1},
1930 mim_tech
[] = { { 1, T_APPRAISAL
, 1},
1931 { 1, T_PANIC_DIGGING
, 1},
1932 { 1, T_PHASE_DOOR
, 1},
1933 { 1, T_INVOKE_DEITY
, 1},
1934 { 10, T_POLYFORM
, 1},
1935 { 15, T_SECURE_IDENTIFY
, 1},
1938 mis_tech
[] = { { 1, T_APPRAISAL
, 1},
1939 { 1, T_PANIC_DIGGING
, 1},
1940 { 1, T_PHASE_DOOR
, 1},
1941 { 1, T_INVOKE_DEITY
, 1},
1942 { 1, T_RECHARGE
, 1},
1943 { 12, T_TERRAIN_CLEANUP
, 1},
1944 { 15, T_SECURE_IDENTIFY
, 1},
1947 nav_tech
[] = { { 1, T_APPRAISAL
, 1},
1948 { 1, T_PANIC_DIGGING
, 1},
1949 { 1, T_PHASE_DOOR
, 1},
1950 { 1, T_INVOKE_DEITY
, 1},
1951 { 15, T_SECURE_IDENTIFY
, 1},
1952 { 18, T_CONCENTRATING
, 1},
1955 spi_tech
[] = { { 1, T_APPRAISAL
, 1},
1956 { 1, T_PANIC_DIGGING
, 1},
1957 { 1, T_PHASE_DOOR
, 1},
1958 { 1, T_INVOKE_DEITY
, 1},
1959 { 15, T_SECURE_IDENTIFY
, 1},
1960 { 15, T_EDDY_WIND
, 1},
1963 ven_tech
[] = { { 1, T_APPRAISAL
, 1},
1964 { 1, T_PANIC_DIGGING
, 1},
1965 { 1, T_PHASE_DOOR
, 1},
1966 { 1, T_INVOKE_DEITY
, 1},
1967 { 1, T_LUCKY_GAMBLE
, 1},
1968 { 15, T_SECURE_IDENTIFY
, 1},
1971 spr_tech
[] = { { 1, T_APPRAISAL
, 1},
1972 { 1, T_PANIC_DIGGING
, 1},
1973 { 1, T_PHASE_DOOR
, 1},
1974 { 1, T_INVOKE_DEITY
, 1},
1975 { 6, T_IRON_SKIN
, 1},
1976 { 15, T_SECURE_IDENTIFY
, 1},
1979 trf_tech
[] = { { 1, T_APPRAISAL
, 1},
1980 { 1, T_PANIC_DIGGING
, 1},
1981 { 1, T_PHASE_DOOR
, 1},
1982 { 1, T_INVOKE_DEITY
, 1},
1983 { 5, T_POLYFORM
, 1},
1984 { 15, T_SECURE_IDENTIFY
, 1},
1987 out_tech
[] = { { 1, T_APPRAISAL
, 1},
1988 { 1, T_PANIC_DIGGING
, 1},
1989 { 1, T_PHASE_DOOR
, 1},
1990 { 1, T_INVOKE_DEITY
, 1},
1991 { 6, T_EVISCERATE
, 1},
1993 { 12, T_CRIT_STRIKE
, 1},
1995 { 15, T_SECURE_IDENTIFY
, 1},
1996 { 18, T_TELEKINESIS
, 1},
1997 { 20, T_RESEARCH
, 1},
1998 { 20, T_REINFORCE
, 1},
1999 { 30, T_SKILLOMORPH
, 1},
2002 trp_tech
[] = { { 1, T_APPRAISAL
, 1},
2003 { 1, T_PANIC_DIGGING
, 1},
2004 { 1, T_PHASE_DOOR
, 1},
2005 { 1, T_INVOKE_DEITY
, 1},
2006 { 11, T_RECHARGE
, 1},
2007 { 15, T_SECURE_IDENTIFY
, 1},
2008 { 28, T_SPIRITUALITY_CHECK
, 1},
2011 ira_tech
[] = { { 1, T_APPRAISAL
, 1},
2012 { 1, T_PANIC_DIGGING
, 1},
2013 { 1, T_PHASE_DOOR
, 1},
2014 { 1, T_INVOKE_DEITY
, 1},
2015 { 4, T_HARDCORE_ALIENIZATION
, 1},
2016 { 5, T_ROCK_TO_POISON
, 1},
2017 { 12, T_CREATE_AMMO
, 1},
2018 { 15, T_SECURE_IDENTIFY
, 1},
2021 una_tech
[] = { { 1, T_APPRAISAL
, 1},
2022 { 1, T_PANIC_DIGGING
, 1},
2023 { 1, T_PHASE_DOOR
, 1},
2024 { 1, T_INVOKE_DEITY
, 1},
2025 { 3, T_SHIELD_BASH
, 1},
2026 { 6, T_IRON_SKIN
, 1},
2027 { 8, T_DOUBLE_THROWNAGE
, 1},
2028 { 10, T_CONCENTRATING
, 1},
2029 { 12, T_SPIRITUALITY_CHECK
, 1},
2030 { 15, T_SECURE_IDENTIFY
, 1},
2031 { 18, T_POLYFORM
, 1},
2032 { 21, T_EDDY_WIND
, 1},
2033 { 24, T_RECHARGE
, 1},
2034 { 27, T_SUMMON_PET
, 1},
2037 uni_tech
[] = { { 1, T_APPRAISAL
, 1},
2038 { 1, T_PANIC_DIGGING
, 1},
2039 { 1, T_PHASE_DOOR
, 1},
2040 { 1, T_INVOKE_DEITY
, 1},
2041 { 1, T_LUCKY_GAMBLE
, 1},
2042 { 10, T_SUMMON_PET
, 1},
2043 { 15, T_SECURE_IDENTIFY
, 1},
2046 unm_tech
[] = { { 1, T_APPRAISAL
, 1},
2047 { 1, T_PANIC_DIGGING
, 1},
2048 { 1, T_PHASE_DOOR
, 1},
2049 { 1, T_INVOKE_DEITY
, 1},
2050 { 10, T_RECHARGE
, 1},
2051 { 15, T_SECURE_IDENTIFY
, 1},
2054 vee_tech
[] = { { 1, T_APPRAISAL
, 1},
2055 { 1, T_PANIC_DIGGING
, 1},
2056 { 1, T_PHASE_DOOR
, 1},
2057 { 1, T_INVOKE_DEITY
, 1},
2058 { 1, T_SPIRITUALITY_CHECK
, 1},
2059 { 15, T_SECURE_IDENTIFY
, 1},
2060 { 17, T_SPELL_SPAM
, 1},
2063 wrp_tech
[] = { { 1, T_APPRAISAL
, 1},
2064 { 1, T_PANIC_DIGGING
, 1},
2065 { 1, T_PHASE_DOOR
, 1},
2066 { 1, T_INVOKE_DEITY
, 1},
2067 { 1, T_POLYFORM
, 1},
2068 { 15, T_SECURE_IDENTIFY
, 1},
2071 egy_tech
[] = { { 1, T_APPRAISAL
, 1},
2072 { 1, T_PANIC_DIGGING
, 1},
2073 { 1, T_PHASE_DOOR
, 1},
2074 { 1, T_INVOKE_DEITY
, 1},
2076 { 1, T_PREACHING
, 1},
2077 { 15, T_SECURE_IDENTIFY
, 1},
2078 { 25, T_HARDCORE_ALIENIZATION
, 1},
2081 nem_tech
[] = { { 1, T_APPRAISAL
, 1},
2082 { 1, T_PANIC_DIGGING
, 1},
2083 { 1, T_PHASE_DOOR
, 1},
2084 { 1, T_INVOKE_DEITY
, 1},
2085 { 15, T_SECURE_IDENTIFY
, 1},
2086 { 20, T_WORLD_FALL
, 1},
2089 cup_tech
[] = { { 1, T_APPRAISAL
, 1},
2090 { 1, T_PANIC_DIGGING
, 1},
2091 { 1, T_PHASE_DOOR
, 1},
2092 { 1, T_INVOKE_DEITY
, 1},
2093 { 10, T_ATTIRE_CHARM
, 1},
2094 { 15, T_SECURE_IDENTIFY
, 1},
2097 urg_tech
[] = { { 1, T_APPRAISAL
, 1},
2098 { 1, T_PANIC_DIGGING
, 1},
2099 { 1, T_PHASE_DOOR
, 1},
2100 { 1, T_INVOKE_DEITY
, 1},
2102 { 10, T_PRIMAL_ROAR
, 1},
2103 { 15, T_SECURE_IDENTIFY
, 1},
2106 thr_tech
[] = { { 1, T_APPRAISAL
, 1},
2107 { 1, T_PANIC_DIGGING
, 1},
2108 { 1, T_PHASE_DOOR
, 1},
2109 { 1, T_INVOKE_DEITY
, 1},
2110 { 15, T_SECURE_IDENTIFY
, 1},
2115 zau_tech
[] = { { 1, T_APPRAISAL
, 1},
2116 { 1, T_PANIC_DIGGING
, 1},
2117 { 1, T_PHASE_DOOR
, 1},
2118 { 1, T_INVOKE_DEITY
, 1},
2119 { 12, T_EVISCERATE
, 1},
2120 { 15, T_SECURE_IDENTIFY
, 1},
2121 { 16, T_IRON_SKIN
, 1},
2122 { 20, T_CRIT_STRIKE
, 1},
2125 wyl_tech
[] = { { 1, T_APPRAISAL
, 1},
2126 { 1, T_PANIC_DIGGING
, 1},
2127 { 1, T_PHASE_DOOR
, 1},
2128 { 1, T_INVOKE_DEITY
, 1},
2129 { 6, T_SPELL_SPAM
, 1},
2130 { 15, T_SECURE_IDENTIFY
, 1},
2131 { 25, T_REINFORCE
, 1},
2134 bac_tech
[] = { { 1, T_APPRAISAL
, 1},
2135 { 1, T_PANIC_DIGGING
, 1},
2136 { 1, T_PHASE_DOOR
, 1},
2137 { 1, T_INVOKE_DEITY
, 1},
2138 { 15, T_SECURE_IDENTIFY
, 1},
2139 { 15, T_WORLD_FALL
, 1},
2140 { 18, T_PERMAMORPH
, 1},
2141 { 20, T_POKE_BALL
, 1},
2142 { 25, T_DECONTAMINATE
, 1},
2145 cer_tech
[] = { { 1, T_APPRAISAL
, 1},
2146 { 1, T_PANIC_DIGGING
, 1},
2147 { 1, T_PHASE_DOOR
, 1},
2148 { 1, T_INVOKE_DEITY
, 1},
2149 { 5, T_PRIMAL_ROAR
, 1},
2150 { 15, T_SECURE_IDENTIFY
, 1},
2153 kst_tech
[] = { { 1, T_APPRAISAL
, 1},
2154 { 1, T_PANIC_DIGGING
, 1},
2155 { 1, T_PHASE_DOOR
, 1},
2156 { 1, T_INVOKE_DEITY
, 1},
2158 { 15, T_SECURE_IDENTIFY
, 1},
2159 { 16, T_TERRAIN_CLEANUP
, 1},
2160 { 22, T_DIAMOND_BARRIER
, 1},
2163 vie_tech
[] = { { 1, T_APPRAISAL
, 1},
2164 { 1, T_PANIC_DIGGING
, 1},
2165 { 1, T_PHASE_DOOR
, 1},
2166 { 1, T_INVOKE_DEITY
, 1},
2167 { 15, T_CREATE_AMMO
, 1},
2168 { 15, T_SECURE_IDENTIFY
, 1},
2169 { 20, T_SPIRIT_BOMB
, 1},
2172 mog_tech
[] = { { 1, T_APPRAISAL
, 1},
2173 { 1, T_PANIC_DIGGING
, 1},
2174 { 1, T_PHASE_DOOR
, 1},
2175 { 1, T_INVOKE_DEITY
, 1},
2177 { 5, T_DOUBLE_THROWNAGE
, 1},
2179 { 15, T_SECURE_IDENTIFY
, 1},
2180 { 20, T_EDDY_WIND
, 1},
2181 { 25, T_BLOOD_RITUAL
, 1},
2184 per_tech
[] = { { 1, T_APPRAISAL
, 1},
2185 { 1, T_PANIC_DIGGING
, 1},
2186 { 1, T_PHASE_DOOR
, 1},
2187 { 1, T_INVOKE_DEITY
, 1},
2188 { 1, T_CALM_STEED
, 1},
2189 { 1, T_HARDCORE_ALIENIZATION
, 1},
2190 { 5, T_WARD_FIRE
, 1},
2191 { 15, T_SECURE_IDENTIFY
, 1},
2192 { 20, T_SPIRITUALITY_CHECK
, 1},
2193 { 25, T_PREACHING
, 1},
2196 bov_tech
[] = { { 1, T_APPRAISAL
, 1},
2197 { 1, T_PANIC_DIGGING
, 1},
2198 { 1, T_PHASE_DOOR
, 1},
2199 { 1, T_INVOKE_DEITY
, 1},
2200 { 14, T_SUMMON_PET
, 1},
2201 { 15, T_SECURE_IDENTIFY
, 1},
2202 { 28, T_BLOOD_RITUAL
, 1},
2205 han_tech
[] = { { 1, T_APPRAISAL
, 1},
2206 { 1, T_PANIC_DIGGING
, 1},
2207 { 1, T_PHASE_DOOR
, 1},
2208 { 1, T_INVOKE_DEITY
, 1},
2210 { 10, T_EVISCERATE
, 1},
2211 { 15, T_SECURE_IDENTIFY
, 1},
2212 { 15, T_TELEKINESIS
, 1},
2213 { 20, T_HEAL_HANDS
, 1},
2214 { 25, T_CALM_STEED
, 1},
2217 mac_tech
[] = { { 1, T_APPRAISAL
, 1},
2218 { 1, T_PANIC_DIGGING
, 1},
2219 { 1, T_PHASE_DOOR
, 1},
2220 { 1, T_INVOKE_DEITY
, 1},
2221 { 12, T_CALM_STEED
, 1},
2222 { 15, T_SECURE_IDENTIFY
, 1},
2225 crt_tech
[] = { { 1, T_APPRAISAL
, 1},
2226 { 1, T_PANIC_DIGGING
, 1},
2227 { 1, T_PHASE_DOOR
, 1},
2228 { 1, T_INVOKE_DEITY
, 1},
2229 { 1, T_CALM_STEED
, 1},
2230 { 15, T_SECURE_IDENTIFY
, 1},
2231 { 20, T_TERRAIN_CLEANUP
, 1},
2232 { 24, T_HARDCORE_ALIENIZATION
, 1},
2235 rus_tech
[] = { { 1, T_APPRAISAL
, 1},
2236 { 1, T_PANIC_DIGGING
, 1},
2237 { 1, T_PHASE_DOOR
, 1},
2238 { 1, T_INVOKE_DEITY
, 1},
2239 { 10, T_SKILLOMORPH
, 1},
2240 { 10, T_CONCENTRATING
, 1},
2241 { 15, T_SECURE_IDENTIFY
, 1},
2245 pic_tech
[] = { { 1, T_APPRAISAL
, 1},
2246 { 1, T_PANIC_DIGGING
, 1},
2247 { 1, T_PHASE_DOOR
, 1},
2248 { 1, T_INVOKE_DEITY
, 1},
2249 { 15, T_SECURE_IDENTIFY
, 1},
2250 { 20, T_TERRAIN_CLEANUP
, 1},
2253 bab_tech
[] = { { 1, T_APPRAISAL
, 1},
2254 { 1, T_PANIC_DIGGING
, 1},
2255 { 1, T_PHASE_DOOR
, 1},
2256 { 1, T_INVOKE_DEITY
, 1},
2257 { 1, T_IRON_SKIN
, 1},
2258 { 15, T_SECURE_IDENTIFY
, 1},
2261 ger_tech
[] = { { 1, T_APPRAISAL
, 1},
2262 { 1, T_PANIC_DIGGING
, 1},
2263 { 1, T_PHASE_DOOR
, 1},
2264 { 1, T_INVOKE_DEITY
, 1},
2265 { 10, T_ROCK_TO_POISON
, 1},
2266 { 15, T_SECURE_IDENTIFY
, 1},
2269 poi_tech
[] = { { 1, T_APPRAISAL
, 1},
2270 { 1, T_PANIC_DIGGING
, 1},
2271 { 1, T_PHASE_DOOR
, 1},
2272 { 1, T_INVOKE_DEITY
, 1},
2273 { 15, T_SECURE_IDENTIFY
, 1},
2274 { 20, T_ROCK_TO_POISON
, 1},
2277 def_tech
[] = { { 1, T_APPRAISAL
, 1}, /* everyone is supposed to get this --Amy */
2278 { 1, T_PANIC_DIGGING
, 1},
2279 { 1, T_PHASE_DOOR
, 1},
2280 { 1, T_INVOKE_DEITY
, 1},
2281 { 15, T_SECURE_IDENTIFY
, 1},
2286 * these give you direct access to the player's list of techs.
2287 * Are you sure you don't want to use tech_inuse, which is the
2288 * extern function for checking whether a fcn is inuse
2291 #define techt_inuse(tech) tech_list[tech].t_inuse
2292 #define techtout(tech) tech_list[tech].t_tout
2293 #define techlev(tech) (u.ulevel - tech_list[tech].t_lev)
2294 #define techid(tech) tech_list[tech].t_id
2295 #define techname(tech) (tech_names[techid(tech)])
2296 #define techlet(tech) \
2297 ((char)((tech < 26) ? ('a' + tech) : ('A' + tech - 26)))
2299 /* A simple pseudorandom number generator
2301 * This should generate fairly random numbers that will be
2302 * mod LP_HPMOD from 2 to 9, with 0 mod LP_HPMOD
2303 * but can't use the normal RNG since can_limitbreak() must
2304 * return the same state on the same turn.
2305 * This also has to depend on things that do NOT change during
2306 * save and restore, and also should only change between turns
2308 #if 0 /* Probably overkill */
2309 #define LB_CYCLE 259993L /* number of turns before the pattern repeats */
2310 #define LB_BASE1 ((long) (monstermoves + u.uhpmax + 300L))
2311 #define LB_BASE2 ((long) (moves + u.uenmax + u.ulevel + 300L))
2312 #define LB_STRIP 6 /* Remove the last few bits as they tend to be less random */
2315 #define LB_CYCLE 101L /* number of turns before the pattern repeats */
2316 #define LB_BASE1 ((long) (monstermoves + u.uhpmax + 10L))
2317 #define LB_BASE2 ((long) (moves + u.uenmax + u.ulevel + 10L))
2318 #define LB_STRIP 3 /* Remove the last few bits as they tend to be less random */
2320 #define LB_HPMOD ((long) ((u.uhp * 10 / u.uhpmax > 2) ? \
2321 (u.uhp * 10 / u.uhpmax) : 2))
2323 #define can_limitbreak() (!Upolyd && (u.uhp*10 < u.uhpmax) && \
2324 (u.uhp == 1 || (!((((LB_BASE1 * \
2325 LB_BASE2) % LB_CYCLE) >> LB_STRIP) \
2328 /* Whether you know the tech */
2334 for (i
= 0; i
< MAXTECH
; i
++) {
2335 if (techid(i
) == tech
)
2342 undo_lockfloodP(x
, y
, roomcnt
)
2346 if (levl
[x
][y
].typ
< STONE
|| levl
[x
][y
].typ
> ROCKWALL
)
2348 if (((levl
[x
][y
].wall_info
& W_NONDIGGABLE
) != 0) && levl
[x
][y
].typ
!= ROCKWALL
)
2351 if (*in_rooms(x
,y
,SHOPBASE
)) return;
2353 (*(int *)roomcnt
)++;
2355 /* Get rid of stone at x, y */
2356 levl
[x
][y
].typ
= CORR
;
2357 blockorunblock_point(x
,y
);
2358 if (!(levl
[x
][y
].wall_info
& W_HARDGROWTH
)) levl
[x
][y
].wall_info
|= W_EASYGROWTH
;
2363 terraincleanup(x
, y
, roomcnt
)
2367 if (Is_waterlevel(&u
.uz
)) return;
2369 if (levl
[x
][y
].typ
< GRAVEWALL
)
2371 if (levl
[x
][y
].typ
>= SDOOR
&& levl
[x
][y
].typ
<= SCORR
)
2373 if ((levl
[x
][y
].wall_info
& W_NONDIGGABLE
) != 0)
2375 if (levl
[x
][y
].typ
== DRAWBRIDGE_UP
|| levl
[x
][y
].typ
== DRAWBRIDGE_DOWN
)
2377 if (levl
[x
][y
].typ
>= DOOR
&& levl
[x
][y
].typ
<= STRAWMATTRESS
)
2380 (*(int *)roomcnt
)++;
2382 /* Get rid of stone at x, y */
2383 levl
[x
][y
].typ
= CORR
;
2384 blockorunblock_point(x
,y
);
2385 if (!(levl
[x
][y
].wall_info
& W_HARDGROWTH
)) levl
[x
][y
].wall_info
|= W_EASYGROWTH
;
2389 /* Called to prematurely stop a technique */
2396 i
= get_tech_no(tech
);
2398 if (tech_list
[i
].t_inuse
) {
2399 switch (tech_list
[i
].t_id
) {
2401 u
.uhpmax
-= tech_list
[i
].t_inuse
- 1;
2404 u
.uhp
-= tech_list
[i
].t_inuse
- 1;
2409 u
.uenmax
-= tech_list
[i
].t_inuse
- 1;
2412 u
.uen
-= tech_list
[i
].t_inuse
- 1;
2417 tech_list
[i
].t_inuse
= 0;
2422 learntech_or_leveltech(tech
, mask
, tlevel
)
2428 i
= get_tech_no(tech
);
2429 if (tech_list
[i
].t_intrinsic
& mask
) {
2430 techlevelspecific(tech_list
[i
].t_id
);
2432 learntech(tech
, mask
, tlevel
);
2437 /* Called to teach a new tech. Level is starting tech level */
2439 learntech(tech
, mask
, tlevel
)
2445 const struct innate_tech
*tp
;
2447 if (istechless
&& tlevel
>= 0) return; /* tough luck... --Amy */
2449 i
= get_tech_no(tech
);
2450 /* Amy note: some techs are given only if you're the correct alignment when leveling up
2451 * diablist for alignment-specific techs goes here */
2453 if (tech
== T_PREACHING
&& mask
!= FROMOUTSIDE
&& u
.ualign
.type
!= A_LAWFUL
) return;
2454 if (tech
== T_ON_THE_SAME_TEAM
&& mask
!= FROMOUTSIDE
&& u
.ualign
.type
!= A_NEUTRAL
) return;
2455 if (tech
== T_PERMAMORPH
&& mask
!= FROMOUTSIDE
&& u
.ualign
.type
!= A_CHAOTIC
) return;
2460 i
= get_tech_no(NO_TECH
);
2462 impossible("No room for new technique?");
2466 tlevel
= u
.ulevel
? u
.ulevel
- tlevel
: 0;
2467 if (tech_list
[i
].t_id
== NO_TECH
) {
2468 tech_list
[i
].t_id
= tech
;
2469 tech_list
[i
].t_lev
= tlevel
;
2470 tech_list
[i
].t_inuse
= 0; /* not in use */
2471 tech_list
[i
].t_intrinsic
= 0;
2473 else if (tech_list
[i
].t_intrinsic
& mask
) {
2474 pline("Tech already known."); /* can happen with recursion --Amy */
2477 if (mask
== FROMOUTSIDE
) {
2478 tech_list
[i
].t_intrinsic
&= ~OUTSIDE_LEVEL
;
2479 tech_list
[i
].t_intrinsic
|= tlevel
& OUTSIDE_LEVEL
;
2481 if (tlevel
< tech_list
[i
].t_lev
)
2482 tech_list
[i
].t_lev
= tlevel
;
2483 tech_list
[i
].t_intrinsic
|= mask
;
2484 /*tech_list[i].t_tout = 0;*/ /* Can use immediately*/
2485 /* should be initialized as 0 if you newly learn it, but be saved as the earlier timeout if you level-drained
2486 * yourself and thereby lost knowledge of the tech. This is to prevent drain-for-gain exploits at XL15 - players
2487 * would certainly find out that you can use secure identify indefinitely that way... --Amy */
2489 else if (tlevel
< 0) {
2491 if (i
< 0 || !(tech_list
[i
].t_intrinsic
& mask
)) {
2492 pline("Tech not known."); /* can happen with recursion --Amy */
2495 if (techlev(i
) < 1) {
2496 tech_list
[i
].t_intrinsic
&= ~mask
;
2497 if (!(tech_list
[i
].t_intrinsic
& INTRINSIC
)) {
2498 if (tech_list
[i
].t_inuse
)
2500 tech_list
[i
].t_id
= NO_TECH
;
2503 /* Re-calculate lowest t_lev */
2504 if (tech_list
[i
].t_intrinsic
& FROMOUTSIDE
)
2505 tlevel
= tech_list
[i
].t_intrinsic
& OUTSIDE_LEVEL
;
2506 if (tech_list
[i
].t_intrinsic
& FROMEXPER
) {
2507 for(tp
= role_tech(); tp
->tech_id
; tp
++)
2508 if (tp
->tech_id
== tech
)
2511 impossible("No inate technique for role?");
2512 else if (tlevel
< 0 || tp
->ulevel
- tp
->tech_lev
< tlevel
)
2513 tlevel
= tp
->ulevel
- tp
->tech_lev
;
2515 if (tech_list
[i
].t_intrinsic
& FROMRACE
) {
2516 for(tp
= race_tech(); tp
->tech_id
; tp
++)
2517 if (tp
->tech_id
== tech
)
2520 impossible("No inate technique for race?");
2521 else if (tlevel
< 0 || tp
->ulevel
- tp
->tech_lev
< tlevel
)
2522 tlevel
= tp
->ulevel
- tp
->tech_lev
;
2524 tech_list
[i
].t_lev
= tlevel
;
2528 impossible("Invalid Tech Level!");
2532 * Return TRUE if a tech was picked, with the tech index in the return
2533 * parameter. Otherwise return FALSE.
2540 char ilet
, lets
[BUFSZ
], qbuf
[QBUFSZ
];
2542 for (ntechs
= i
= 0; i
< MAXTECH
; i
++)
2543 if (techid(i
) != NO_TECH
) ntechs
++;
2545 /* display the menu anyway, because of vibrating square stuff --Amy */
2546 /* if (ntechs == 0) {
2547 You("don't know any techniques right now.");
2550 if (flags
.menu_style
== MENU_TRADITIONAL
) {
2551 if (ntechs
== 1) strcpy(lets
, "a");
2552 else if (ntechs
< 27) sprintf(lets
, "a-%c", 'a' + ntechs
- 1);
2553 else if (ntechs
== 27) sprintf(lets
, "a-z A");
2554 else sprintf(lets
, "a-z A-%c", 'A' + ntechs
- 27);
2557 sprintf(qbuf
, "Perform which technique? [%s ?]", lets
);
2558 if ((ilet
= yn_function(qbuf
, (char *)0, '\0')) == '?')
2561 if (index(quitchars
, ilet
))
2564 if (letter(ilet
) && ilet
!= '@') {
2565 /* in a-zA-Z, convert back to an index */
2566 if (lowc(ilet
) == ilet
) /* lower case */
2569 idx
= ilet
- 'A' + 26;
2572 for(i
= 0; i
< MAXTECH
; i
++)
2573 if (techid(i
) != NO_TECH
) {
2580 You("don't know that technique.");
2583 return dotechmenu(PICK_ONE
, tech_no
);
2587 dotechmenu(how
, tech_no
)
2592 int i
, n
, len
, longest
, techs_useable
, tlevel
;
2593 char buf
[BUFSZ
], let
= 'a';
2595 menu_item
*selected
;
2598 tmpwin
= create_nhwindow(NHW_MENU
);
2600 any
.a_void
= 0; /* zero out all bits */
2604 if (!iflags
.menu_tab_sep
) {
2605 /* find the length of the longest tech */
2606 for (longest
= 0, i
= 0; i
< MAXTECH
; i
++) {
2607 if (techid(i
) == NO_TECH
) continue;
2608 if ((len
= strlen(techname(i
))) > longest
)
2611 sprintf(buf
, " %-*s Level Status", longest
, "Name");
2613 sprintf(buf
, "Name\tLevel\tStatus");
2615 add_menu(tmpwin
, NO_GLYPH
, &any
, 0, 0, ATR_NONE
, buf
, MENU_UNSELECTED
);
2617 for (i
= 0; i
< MAXTECH
; i
++) {
2618 if (techid(i
) == NO_TECH
)
2620 tlevel
= techlev(i
);
2621 if (TechLossEffect
|| u
.uprops
[TECH_LOSS_EFFECT
].extrinsic
|| have_techlossstone()) {
2625 } else if (tlevel
> 0 && (wizard
|| !techtout(i
)) ) {
2635 if (wizard
|| (RngeTechInsight
&& !(TechLossEffect
|| u
.uprops
[TECH_LOSS_EFFECT
].extrinsic
|| have_techlossstone()) ) )
2636 if (!iflags
.menu_tab_sep
)
2637 sprintf(buf
, "%s%-*s %2d%c%c%c%c %s(%i)",
2638 prefix
, longest
, techname(i
), tlevel
, ((techtout(i
) || (tlevel
<= 0)) ? '*' : ' '),
2639 tech_list
[i
].t_intrinsic
& FROMEXPER
? 'X' : ' ',
2640 tech_list
[i
].t_intrinsic
& FROMRACE
? 'R' : ' ',
2641 tech_list
[i
].t_intrinsic
& FROMOUTSIDE
? 'O' : ' ',
2642 tech_inuse(techid(i
)) ? "Active" :
2643 tlevel
<= 0 ? "Beyond recall" :
2644 can_limitbreak() ? "LIMIT" :
2645 !techtout(i
) ? "Prepared" :
2646 techtout(i
) > 10000 ? "Huge timeout" :
2647 techtout(i
) > 1000 ? "Not Ready" :
2648 techtout(i
) > 100 ? "Reloading" : "Soon",
2651 sprintf(buf
, "%s%s\t%2d%c%c%c%c\t%s(%i)",
2652 prefix
, techname(i
), tlevel
, ((techtout(i
) || (tlevel
<= 0)) ? '*' : ' '),
2653 tech_list
[i
].t_intrinsic
& FROMEXPER
? 'X' : ' ',
2654 tech_list
[i
].t_intrinsic
& FROMRACE
? 'R' : ' ',
2655 tech_list
[i
].t_intrinsic
& FROMOUTSIDE
? 'O' : ' ',
2656 tech_inuse(techid(i
)) ? "Active" :
2657 tlevel
<= 0 ? "Beyond recall" :
2658 can_limitbreak() ? "LIMIT" :
2659 !techtout(i
) ? "Prepared" :
2660 techtout(i
) > 10000 ? "Huge timeout" :
2661 techtout(i
) > 1000 ? "Not Ready" :
2662 techtout(i
) > 100 ? "Reloading" : "Soon",
2666 if (TechLossEffect
|| u
.uprops
[TECH_LOSS_EFFECT
].extrinsic
|| have_techlossstone()) {
2668 } else if (!iflags
.menu_tab_sep
) {
2669 sprintf(buf
, "%s%-*s %5d%c %s",
2670 prefix
, longest
, techname(i
), tlevel
, ((techtout(i
) || (tlevel
<= 0)) ? '*' : ' '),
2671 tech_inuse(techid(i
)) ? "Active" :
2672 tlevel
<= 0 ? "Beyond recall" :
2673 can_limitbreak() ? "LIMIT" :
2674 !techtout(i
) ? "Prepared" :
2675 techtout(i
) > 10000 ? "Huge timeout" :
2676 techtout(i
) > 1000 ? "Not Ready" :
2677 techtout(i
) > 100 ? "Reloading" : "Soon");
2679 sprintf(buf
, "%s%s\t%5d%c\t%s",
2680 prefix
, techname(i
), tlevel
, ((techtout(i
) || (tlevel
<= 0)) ? '*' : ' '),
2681 tech_inuse(techid(i
)) ? "Active" :
2682 tlevel
<= 0 ? "Beyond recall" :
2683 can_limitbreak() ? "LIMIT" :
2684 !techtout(i
) ? "Prepared" :
2685 techtout(i
) > 10000 ? "Huge timeout" :
2686 techtout(i
) > 1000 ? "Not Ready" :
2687 techtout(i
) > 100 ? "Reloading" : "Soon");
2689 add_menu(tmpwin
, NO_GLYPH
, &any
,
2690 (tlevel
<= 0) ? 0 : (techtout(i
) && !(TechLossEffect
|| u
.uprops
[TECH_LOSS_EFFECT
].extrinsic
|| have_techlossstone()) && !wizard
) ? 0 : let
, 0, ATR_NONE
, buf
, MENU_UNSELECTED
);
2691 if (let
++ == 'z') let
= 'A';
2692 if (let
== 'Z') let
= 'a';
2698 /* Amy addition: if you are on the vibrating square, print a special message. The reason for it being that
2699 * #technique is one of the commands that ALWAYS works, no matter which nasty traps you have. Yes, there is a trap
2700 * that prevents the techniques from actually working, but the menu can be accessed anyway, and therefore it's
2701 * always possible in theory (he he) to find the VS no matter which, or how many(!!!), interface screws are active */
2702 end_menu(tmpwin
, (isok(u
.ux
, u
.uy
) && invocation_pos(u
.ux
, u
.uy
)) ? "You're standing on the vibrating square." : how
== PICK_ONE
? "Choose a technique" :
2703 "Currently known techniques");
2705 n
= select_menu(tmpwin
, how
, &selected
);
2706 destroy_nhwindow(tmpwin
);
2708 int selection
= selected
[0].item
.a_int
- 1;
2709 if (selection
< 0) { /* shouldn't happen, but according to amateurhour it can... so he fixed it --Amy */
2710 free((void *)selected
);
2713 *tech_no
= selection
;
2714 free((void *)selected
);
2726 int i
, n
, len
, tlevel
;
2730 if (techid(0) == NO_TECH
) {
2731 dump("", "You didn't know any techniques.");
2735 dump("", "Techniques known in the end");
2737 sprintf(buf
, " %-17s Level Status", "Name");
2739 for (i
= 0; i
< MAXTECH
; i
++) {
2740 if (techid(i
) == NO_TECH
)
2742 tlevel
= techlev(i
);
2743 if (!techtout(i
) && tlevel
> 0) {
2749 if (!iflags
.menu_tab_sep
) {
2750 sprintf(buf
, "%s%-20s %2d%c%c%c %s(%i)",
2751 prefix
, techname(i
), tlevel
,
2752 tech_list
[i
].t_intrinsic
& FROMEXPER
? 'X' : ' ',
2753 tech_list
[i
].t_intrinsic
& FROMRACE
? 'R' : ' ',
2754 tech_list
[i
].t_intrinsic
& FROMOUTSIDE
? 'O' : ' ',
2755 tech_inuse(techid(i
)) ? "Active" :
2756 tlevel
<= 0 ? "Beyond recall" :
2757 can_limitbreak() ? "LIMIT" :
2758 !techtout(i
) ? "Prepared" :
2759 techtout(i
) > 10000 ? "Huge timeout" :
2760 techtout(i
) > 1000 ? "Not Ready" :
2761 techtout(i
) > 100 ? "Reloading" : "Soon",
2765 sprintf(buf
, "%s%s\t%2d%c%c%c\t%s(%i)",
2766 prefix
, techname(i
), tlevel
,
2767 tech_list
[i
].t_intrinsic
& FROMEXPER
? 'X' : ' ',
2768 tech_list
[i
].t_intrinsic
& FROMRACE
? 'R' : ' ',
2769 tech_list
[i
].t_intrinsic
& FROMOUTSIDE
? 'O' : ' ',
2770 tech_inuse(techid(i
)) ? "Active" :
2771 tlevel
<= 0 ? "Beyond recall" :
2772 can_limitbreak() ? "LIMIT" :
2773 !techtout(i
) ? "Prepared" :
2774 techtout(i
) > 10000 ? "Huge timeout" :
2775 techtout(i
) > 1000 ? "Not Ready" :
2776 techtout(i
) > 100 ? "Reloading" : "Soon",
2783 } /* dump_techniques */
2792 for (i
= 0; i
< MAXTECH
; i
++) {
2793 if (techid(i
) == tech
) {
2807 for (i
= 0; i
< MAXTECH
; i
++) {
2808 if (techid(i
) == NO_TECH
)
2810 if (techtout(i
)) techtout(i
) = 0;
2812 pline("The timeout on all your techniques has been set to zero.");
2823 for (i
= 0; i
< MAXTECH
; i
++) {
2824 if (techid(i
) == NO_TECH
)
2826 if (!rn2(5)) techtout(i
) += 1000000;
2836 for (i
= 0; i
< MAXTECH
; i
++) {
2837 if (techid(i
) == NO_TECH
)
2839 techtout(i
) += rnz(100000);
2849 if (flags
.tech_description
&& !(TechLossEffect
|| u
.uprops
[TECH_LOSS_EFFECT
].extrinsic
|| have_techlossstone()) ) {
2851 if (gettech(&tech_no
)) {
2853 switch (techid(tech_no
)) {
2856 pline("This technique sometimes allow you to identify some of your items. Higher intelligence and wisdom increase the chance of success, higher technique levels increase the average amount of stuff identified.");
2860 pline("You can only use this technique while bare-handed and not polymorphed. If you do, your unarmed attacks do more damage for a while; the technique's level determines the duration of this effect.");
2864 pline("This technique allows you to do stronger attacks for a while; the technique's level determines the duration of this effect.");
2868 pline("Using this technique allows you to reinforce your memory of an almost-forgotten spell, or increase the memory of a moderately memorized spell up to 110%%.");
2872 pline("A technique that can be used to get a multishot bonus with bows and certain other weapons, the duration of which depends on the technique's level.");
2875 case T_INVOKE_DEITY
:
2876 pline("Invoke your deity for healing. If successful, some or all of your hit point damage will be restored, but there may be negative outcomes depending on certain circumstances.");
2879 case T_DOUBLE_TROUBLE
:
2880 pline("Create a clone of yourself with this technique. At higher technique levels you might summon some familiars too.");
2884 pline("This technique allows you to determine the enchantment value of your currently wielded weapon. If you use it while wielding a non-weapon (e.g. a wand), the timeout of this technique will be much longer.");
2887 case T_PANIC_DIGGING
:
2888 pline("In situations where there is no other way forward, you can use this technique to transform walls on the eight squares surrounding you into open floor. Of course it only works if those squares are diggable, and it also paralyzes you for up to 20 turns, so be careful about using it when monsters are around!");
2891 case T_SECURE_IDENTIFY
:
2892 pline("Everyone learns this technique at experience level 15, and it allows the player to identify an item in open inventory without fail.");
2896 pline("If you need to get out of trouble, you can use this tech for a short-range teleport. It will teleport you over an euclidean distance of at least 3 but no more than 100. Of course it doesn't work if teleportation is prohibited on the current dungeon level.");
2900 pline("With this technique, you can practice with your currently wielded weapon, sometimes determining the enchantment value. Also, it gets you closer to increasing your skill level, but monsters may interrupt you.");
2904 pline("A technique that can be used to cure a variety of afflictions, but you should have either a scalpel or a medical kit filled with bandages for it to work.");
2908 pline("Using this technique can cure sliming or sickness, or heal a techlevel-dependant amount of hit points.");
2912 pline("If you use this technique, your melee attacks do much more damage for a period of time, the length of which depends on the technique's level.");
2916 pline("You need to be riding in order to use this technique. If you do, your steed's tameness will increase; higher technique levels increase the average amount of tameness points gained.");
2920 pline("Turn undead is the act of causing nearby undead creatures to flee; weak undead might even be killed outright by this effect.");
2924 pline("By using this technique, you will become invisible and fast for some time. Higher technique levels give a longer effect.");
2928 pline("This technique allows you to perform a powerful attack against a monster close by, the strength of which depends on the technique's level.");
2932 pline("You need a blade to use this technique. Doing so allows you to severely hurt an adjacent non-headless monster; high technique levels sometimes even allow you to instakill the monster, but only if the monster's level isn't too high relative to the technique's level.");
2936 pline("Using this technique allows you to uncurse a cursed item or bless an uncursed one.");
2940 pline("This technique enhances your melee attacks with elemental powers for a techlevel-dependant amount of turns.");
2944 pline("A technique that temporarily promotes your pets to their grown-up form, but after a techlevel-dependent time they will revert.");
2948 pline("This allows you to jump in a direction of your choice, passing through monsters, iron bars and similar stuff. The technique's level affects the damage done to monsters you jump through.");
2951 case T_SIGIL_TEMPEST
:
2952 pline("This technique costs quite some mana, but if used, your ray spells will create 3x3 explosions around you as long as the technique is in effect. The duration increases with the technique's level. Combine it with sigil of control to control the explosions.");
2955 case T_SIGIL_CONTROL
:
2956 pline("This technique costs quite some mana, but if used, you can control the direction of your ray spells' rebounds for a while. The duration increases with the technique's level.");
2959 case T_SIGIL_DISCHARGE
:
2960 pline("This technique costs quite some mana, but if used, your ray spells will create huge explosions that can hit lots of monsters in a single shot as long as it's active. The duration increases with the technique's level.");
2963 case T_RAISE_ZOMBIES
:
2964 pline("This technique searches the squares adjacent to you for corpses, trying to make tame zombies out of them.");
2968 pline("Allows you to revive a corpse from the floor or your inventory, but at the cost of health. This cost is reduced by increasing the technique's level.");
2972 pline("Using this technique makes you resistant to fire for a while (longer with higher technique levels).");
2976 pline("Using this technique makes you resistant to cold for a while (longer with higher technique levels).");
2980 pline("Using this technique makes you resistant to shock for a while (longer with higher technique levels).");
2984 pline("You must hold an item in your hand that can be upgraded if you want to use this technique effectively. Also, it takes a very long time to upgrade an object; the duration is decreased slightly if the technique's level is lower, but monsters are still likely to interrupt you. And if that happens, the technique will be on timeout anyway, so better lock yourself in a closet first.");
2988 pline("Temporarily increases your maximum hit points by a techlevel-dependant amount, but your HP will slowly bleed out until they reach their previous value, so be careful.");
2992 pline("Using this technique allows you to move super-fast for a period of time, the length of which increases with the technique's level.");
2996 pline("A technique that uses your mana in order to enhance your melee attacks.");
3000 pline("Draws energy (mana) from your surroundings for 15 turns; if altars, thrones or similar stuff are on the squares adjacent to you, the effect will be stronger. However, if a monster interrupts you, you'll get nothing at all.");
3004 pline("Your mana will be converted to health for a period of time if you use this technique.");
3008 pline("Tries to disarm a monster (read: knock their weapon away); you need to be holding a weapon you're at least skilled with, though. Also the weapon needs to be at least +1 and if it's successful, the weapon loses a point of enchantment.");
3012 pline("A technique that can stun a monster and cause it to flee; it is much more likely to succeed if the target monster's level is lower than the technique's level.");
3016 pline("Allows you to input several successive commands that will be converted into moves. You can always do at least 2 moves; 3 at techlevel 10 or higher, 4 at techlevel 20 or higher, and 5 at techlevel 30.");
3020 pline("This technique can be used to rapidly strike an adjacent monster using your fists.");
3024 pline("A technique that can be used to slam an adjacent monster into the ground, creating a pit and doing lots of damage.");
3028 pline("You can use this technique to move by several squares in a single turn, but only in a straight line.");
3032 pline("A very powerful technique that temporarily increases your maximum mana to a very high amount, but it slowly bleeds off to its original value.");
3036 pline("This technique allows you to do a 'kamehameha' attack against a monster, causing it to explode while also damaging other monsters nearby. According to Nethackwiki, you can't hit yourself or your pets with this attack either (and the page is even still there, because it's a SLASH'EM technique; certain evil people wiped all SLEX-specific info). But in-game experience says otherwise, i.e. pets can very well still be hit, sadly.");
3040 pline("A nearly useless technique that will use a medical kit to drain your experience for a single potion of blood.");
3044 pline("Uses mana to jump. Higher technique levels allow you to jump farther.");
3048 pline("This technique allows you to throw a poke ball, trying to catch any adjacent non-unique monster. Higher technique levels give a greater chance of success and sometimes allow you to catch several monsters in a single turn. Actual pokemon are more likely to be caught, and 'petty' monsters are guaranteed to be caught.");
3051 case T_SUMMON_TEAM_ANT
:
3052 pline("A technique that summons tame Team Ant members (monsters represented by the letter a). Higher technique levels are more likely to summon several of them at once.");
3055 case T_ATTIRE_CHARM
:
3056 pline("With this technique, you can attempt to tame adjacent intelligent human(oid) monsters, but you need to be wearing high heels for it to work. A higher level of this technique sometimes tames several monsters at once.");
3060 pline("A very powerful technique that will instakill all non-unique monsters on the current dungeon level whose monster level is lower than half the technique's level. Sometimes it will also kill higher-level monsters.");
3064 pline("Creates a techlevel-dependant amount of bullets.");
3068 pline("This technique creates stoning grenades at your feet. Higher techlevels create more of them at once on average.");
3072 pline("Using this technique is very similar to quaffing a potion of booze, but it will also create some potions of booze out of thin air. The technique's level determines the average amount of potions created.");
3076 pline("A technique that can be used to interact with dungeon features from far away.");
3080 pline("Using this technique will improve your armor class for a short period of time.");
3084 pline("You can use this technique for an uncontrolled random polymorph. It can turn you into monsters that are normally not a valid polymorph form, but you cannot make those polymorphs permanent via an amulet of unchanging because that would be too easy.");
3087 case T_CONCENTRATING
:
3088 pline("With this technique active, your melee attacks will almost never miss; however, it only lasts for a short time.");
3092 pline("A technique that summons a tame monster.");
3095 case T_DOUBLE_THROWNAGE
:
3096 pline("Use this technique just before you start throwing darts, daggers or similar throwing weapons, and you can throw many more projectiles per turn!");
3100 pline("If you use this technique, your one-handed melee attacks will deal more damage as long as you have a shield equipped. The damage bonus depends on the shield's enchantment value.");
3104 pline("A very useful technique that allows you to recharge wands, tools and similar items. However, blessed scrolls of charging are still better, so you should probably not use this technique on a wand of wishing.");
3107 case T_SPIRITUALITY_CHECK
:
3108 pline("If you're unsure whether you can safely pray, you can use this technique to communicate with your god. There are no negative effects - it simply tells you whether it's safe to pray now.");
3112 pline("You can invoke this technique to walk right through monsters for a short time. Remember: if you want to attack them in melee, you'll need to prefix your movements with the F command. If you are wielding two weapons at the same time and attack a monster while having the technique active, you will deal extra damage with every hit.");
3115 case T_BLOOD_RITUAL
:
3116 pline("Requires an athame in your open inventory. If you use this technique, you sacrifice up to 200 max HP and Pw, and all of your stats are reduced by up to 2, but you will be granted a wish, an acquirement, a random artifact or a random powerful item.");
3119 case T_ENT_S_POTION
:
3120 pline("Restores some of your health and also fixes blindness, stunning, confusion, hallucination, numbness, fear, freezing, dimness and burns.");
3123 case T_LUCKY_GAMBLE
:
3124 pline("Randomly increases or decreases your base luck by one, with equal probability.");
3127 case T_DECONTAMINATE
:
3128 pline("Greatly reduces your contamination when used.");
3132 pline("Allows you to set a different secondary weapon, but only if you're not currently dual-wielding. If you're a master at dual-wielding, this even lets you skip potential bad effects that wielding the weapon would give you.");
3136 pline("Teaches a random spell when used.");
3139 case T_RESET_TECHNIQUE
:
3140 pline("Allows you to select a technique that's currently on timeout, which will become usable again.");
3143 case T_SILENT_OCEAN
:
3144 pline("Using this technique will try to cancel all ; and I monsters in a rather large area around you. Also, while the technique is active, you have swimming and magical breathing, plus your items are protected from water damage and drowning attacks cannot harm you. If the technique is about to run out, you get a message so you can get out of the water. However, you also cannot cast spells or chat while it's active.");
3148 pline("If you use this technique, you will get the effect of applying a noncursed unicorn horn every turn for a period of time, even if you don't actually have a unicorn horn.");
3151 case T_INTRINSIC_ROULETTE
:
3152 pline("This technique can give or remove a random intrinsic, which can be good or bad.");
3155 case T_SPECTRAL_SWORD
:
3156 pline("Adds elemental damage to your melee weapon for a period of time.");
3159 case T_REVERSE_IDENTIFY
:
3160 pline("Allows you to identify an item based on random appearance, or input the name of an unknown item which will then be identified. It can also randomly identify some other unknown items.");
3163 case T_DETECT_TRAPS
:
3164 pline("Reveals some of the traps on the current dungeon level when used.");
3168 pline("Very useful for petmasters, this technique lets you give orders to your pets. The higher your petkeeping skill, the more things you can change about your pets' behavior.");
3171 case T_REMOVE_IMPLANT
:
3172 pline("Allows you to take off a worn implant, even if it's a cursed one.");
3175 case T_REROLL_IMPLANT
:
3176 pline("This technique targets a worn implant and will reroll its base stats.");
3179 case T_MILDEN_CURSE
:
3180 pline("Use this technique to turn a sticky/heavily/prime cursed item into a regularly cursed one. If you use it on an item that has the black breath, topi ylinen or ancient morgothian curses, there is only a 10%% chance of turning them into a regularly cursed one.");
3184 pline("Activates a temporary force field that makes monsters with ranged weapons or beam wands much less likely to hit you.");
3188 pline("This technique requires you to wield a polearm or lance. If it's a negatively enchanted one, it gains a random amount of enchantment (not past +0), otherwise it can gain an additional point of enchantment, but the chance is lower the more enchantment your weapon has. Maximum that can be reached is +25.");
3192 pline("Allows you to place a stinking cloud that deals poison damage to enemies, and also to you should you happen to walk into it.");
3196 pline("After using this technique, for a certain period of time your quarterstaff can attack several times in a single turn. The higher your quarterstaff skill, the more extra attacks you get.");
3199 case T_DELIBERATE_CURSE
:
3200 pline("This technique replicates the effect of a potion of unholy water, allowing you to curse an item. Take note that even blessed items go straight to cursed when using this technique, unlike unholy water which would only unbless them.");
3203 case T_ACQUIRE_STEED
:
3204 pline("Tries to tame an adjacent monster of a 'rideable' class. Of course this is SLEX, you can theoretically ride any monster, but this technique specifically tames the following glyphs: q, u, A, C, D, J, z. Only one monster can be tamed per use, however there's a chance for monsters to resist so if you surround yourself with several potential pets, there's a better chance that not all of them will resist.");
3208 pline("Creates a saddle out of thin air.");
3211 case T_SHOPPING_QUEEN
:
3212 pline("Every woman's wet dream, this technique lets you shop for shoes! Depending on your high heels skill, there's a certain amount of shoes that you can pick from. You can only pick one pair from the list, which will be placed on the floor. So choose wisely and become the prettiest woman in the dungeon by donning your favorite high heels! (Disclaimer: You don't need to pay money; the technique is basically the voucher that you redeem to get your shoes.)");
3215 case T_BEAUTY_CHARM
:
3216 pline("This technique requires you to be wearing high heels, and paralyzes you for 10 turns, so be careful when using it. During those turns, it repeatedly tries to pacify humanoids and animals in a 7x7 radius around you, hoping that they fall in love with your beautiful high heels and decide to stop fighting you. However, monsters may resist the attempt and attack you anyway.");
3220 pline("If you want to use this technique, you must be wearing stiletto heels. Then it lasts for 50 turns, and once you kick a male humanoid or animal, you will place a devastating kick between their legs. The enemy's nuts will be pushed out of their original position by your very tender stiletto heels, causing unbearable pain to the monster and knocking it out for possibly hundreds of turns, but this technique immediately ends once you successfully kick something with it. Take note that using this technique puts a timeout on all of the following techniques: asian kick, legscratch attack, ground stomp, athletic combat.");
3223 case T_LEGSCRATCH_ATTACK
:
3224 pline("Requires you to wear cone heels. If you use this technique, your kick attack will be able to scratch up and down the enemy's legs for a while, ripping their shins to shreds, and as a result they'll move more slowly. Do it often enough and their legs will be bleeding so badly that all your kicks deal double damage because your beautiful cone heels are so incredibly sharp-edged! Take note that using this technique puts a timeout on all of the following techniques: asian kick, legscratch attack, ground stomp, athletic combat.");
3227 case T_GROUND_STOMP
:
3228 pline("In order to use this technique, you must be wearing wedge heels. It will last for a while, and if you kick a paralyzed enemy while the technique is active, you'll not only deal double damage but also increase the time for which the enemy is paralyzed, so you can effectively chain-paralyze them. Gotta kick 'em while they're down, and stomp them with your very lovely, massive wedge heels! Take note that using this technique puts a timeout on all of the following techniques: asian kick, legscratch attack, ground stomp, athletic combat.");
3231 case T_ATHLETIC_COMBAT
:
3232 pline("Only characters in block heels can use this technique. It lasts for a generous amount of time, and while it's active, you can place a high kick with your block heels at the enemy's belly, shoulder or even their head. The elegance of your very feminine block heels will mesmerize them so much that they may spontaneously stop fighting back, allowing you to kick them again and again with your fleecy block heel. Take note that using this technique puts a timeout on all of the following techniques: asian kick, legscratch attack, ground stomp, athletic combat.");
3235 case T_PRAYING_SUCCESS
:
3236 pline("This very helpful technique allows you to pray when it would normally not be safe to pray. Please be aware of the fact that your deity is still inaccessible in Gehennom; the gods won't get angry if you use this technique in Gehennom, but they won't be able to help you anyway. Also, there's limits as to what it can do; if your alignment is extremely low or you have a huge prayer timeout, it might still fail, and it won't necessarily work when your god is extremely angry.");
3240 pline("After using this technique, your ray and beam wands and spells have a much greater range than usually. It lasts for a generous amount of time. Diagonally fired rays in particular will sometimes bounce for quite a long time!");
3243 case T_ENCHANTERANG
:
3244 pline("A technique that can only be used if you're wielding a boomerang, and which will try to enchant it so you'll be more capable of killing the little poison ivies. You can also wield an entire stack, and as long as it's 10 or less boomerangs in it, the entire stack will be enchanted. Trying to enchant greater stacks can fail, more often the bigger the stack is. Also, boomerangs that are already +25 or higher can not be further enchanted with this technique.");
3247 case T_BATMAN_ARSENAL
:
3248 pline("If you want to be able to fight Scarecrow, Clayface and the Penguin, you need a lot of batarangs. Using this technique will create one out of thin air!");
3252 pline("Yes, Batman is capable of defeating the Joker, even though he's the biggest villain in all of Gotham City and has three separate ways of instakilling Batman and is also very capable of killing Batman via normal damage. Use this technique and your batarang will be able to paralyze monsters for a while if you throw it!");
3255 case T_CALL_THE_POLICE
:
3256 pline("If you need help, use this technique and tame kops will appear to fight your enemies.");
3260 pline("Tries to tame an adjacent animal. At low technique levels you'll usually only dominate a single one, while with higher levels it may occasionally tame several animals in one use.");
3264 pline("Allows you to select an adjacent monster and try to polymorph into it. But beware, there's a one in three chance that you polymorph into something completely random instead.");
3267 case T_COMBO_STRIKE
:
3268 pline("This technique can be used with chained blitz if you have that, and if you do so, every hit deals 10 extra damage compared to the previous one. Using it 'normally' gives a different effect: for a period of time, every melee hit you land will deal one more point of damage compared to the previous one, but it instantly terminates if you try to use chained blitz while having combo strike active, and it also terminates if you spend a turn doing something other than hitting a monster in melee, so you have to keep attacking things to maximize the effect.");
3272 pline("With this technique, you will polymorph into a random F-class monster. Beware, polymorph control doesn't let you choose what you become. Since most fungi aren't capable of wearing armor or wielding weapons, this is a way to shake off cursed ones. However, most fungi also lack limbs and generally make poor fighting forms.");
3275 case T_BECOME_UNDEAD
:
3276 pline("Unlike the turn undead technique, this one actually allows you to become an undead creature! This is done by polymorphing you, but the one you turn into is random, even if you have polymorph control.");
3280 pline("A bare-handed combat technique that lasts for a very long time. While it's active, your fists will deal more damage the better a monster's armor class is, but it doesn't increase your to-hit to match, so you'd better be good enough to actually hit the monsters :D");
3284 pline("While this technique is active, throwing shuriken will additionally shoot invisible beams at the enemy that may hit several of them at once, but these beams require 10 mana each.");
3288 pline("Use this technique while standing next to a monster that used to be your pet, and if the monster was peaceful it'll become tame again. Using it on a former pet that actually became hostile only has a 1 in 3 chance of working, and using it on a former pet that became frenzied will never work.");
3292 pline("Using this technique stops time for 6-11 turns.");
3296 pline("Provides temporary resistance to sickness, stun, confusion, blindness, hallucination and fear.");
3299 case T_CHARGE_SABER
:
3300 pline("This technique will use up all of your current mana and convert it into lightsaber energy. If the techlevel is at least 10, you can also win the jackpot. However, monsters may interrupt you, preventing your lightsaber from actually being charged.");
3303 case T_UNCURSE_SABER
:
3304 pline("Use this technique while wielding a cursed lightsaber and it will be uncursed! If it's heavily cursed or worse, it gets the usual chance of resisting, of course.");
3307 case T_ENERGY_CONSERVATION
:
3308 pline("It lasts for a very long time, and reduces the rate at which your lightsaber will use up power. The higher your Makashi skill, the better the reduction.");
3311 case T_ENCHANT_ROBE
:
3312 pline("This technique requires you to wear a robe, which will receive a random enchantment. If your robe already has an enchantment, it will lose the one it has and get a new random one. And if your Soresu skill is at Grand Master or better, the technique can also occasionally increase the enchantment of your robe up to a maximum of +7; this will never vaporize the robe because SLEX adheres to the 'enhancing your skills should never have detrimental side effects' principle.");
3315 case T_WILD_SLASHING
:
3316 pline("While this technique is active, your dual-wielded lightsabers will attack more quickly but have reduced to-hit. Beware: you can't just cheat by running a to-hit-increasing technique at the same time, those won't give you any to-hit bonuses while wild slashing is active.");
3319 case T_ABSORBER_SHIELD
:
3320 pline("A technique that will last for a while, and as long as it's active, blocking a projectile with your lightsaber will add some saber power.");
3323 case T_PSYCHO_FORCE
:
3324 pline("Allows you to select a monster that you can see, which will take damage and be paralyzed for a while.");
3327 case T_INTENSIVE_TRAINING
:
3328 pline("Every time you use this technique, a random stat will be increased by 1.");
3331 case T_SURRENDER_OR_DIE
:
3332 pline("This technique lasts for a few hundred turns and allows your lightsaber attacks to occasionally pacify the opponent, or sometimes your lightsaber will gain enchantment, or the lightsaber gains additional power. But it only triggers if you manage to smash apart an enemy's held weapon.");
3335 case T_PERILOUS_WHIRL
:
3336 pline("If you use a lit double lightsaber while having this technique active, your attacks may occasionally drain the enemy's levels.");
3340 pline("Well, guess :D It summons a tame shoe that will kick monsters!");
3343 case T_KICK_IN_THE_NUTS
:
3344 pline("Requires you to wear sexy flats, and can only be used on a male monster, which will deal a lot of damage to it and also prevent the target from fighting back for a while.");
3347 case T_DISARMING_KICK
:
3348 pline("This technique can only be used if you wear sexy flats, and will disarm an adjacent monster. If successful, its weapon will land at your feet. Unlike the disarm technique, this works even if the target is holding a cursed weapon.");
3351 case T_INLAY_WARFARE
:
3352 pline("Using this technique requires sexy flats to be worn, and if you do use it, you'll create a stinking cloud at your position and may confuse and paralyze nearby monsters. You will also be confused for a while and need to wait for 2 turns before you can act again, meaning you'll probably be affected by the cloud too.");
3355 case T_DIAMOND_BARRIER
:
3356 pline("Creates grave walls on the eight squares surrounding you, as long as those squares are open floor tiles.");
3360 pline("This technique increases your to-hit by a flat 5 points for a period of time.");
3363 case T_FORCE_FILLING
:
3364 pline("If you use this technique, you restore a bit of mana.");
3367 case T_JEDI_TAILORING
:
3368 pline("Creates a random robe that you can use.");
3371 case T_INTRINSIC_SACRIFICE
:
3372 pline("If you use this technique, you may lose an intrinsic. But it will add a lot of energy to both of your lightsabers. Oh, almost forgot to mention this: it can only be used if you're wielding two lightsabers at once.");
3376 pline("When using this technique, your thrown lightsaber will be able to fire invisible beams for a while.");
3379 case T_ENERGY_TRANSFER
:
3380 pline("While this technique is active, casting spells while wielding a lit lightsaber will add energy to the saber.");
3383 case T_SOFTEN_TARGET
:
3384 pline("Allows you to target a single monster next to you, which will lose an experience level even if it resists level drain.");
3387 case T_PROTECT_WEAPON
:
3388 pline("Can only be used while wielding a two-handed weapon, which will be erosionproofed.");
3391 case T_POWERFUL_AURA
:
3392 pline("This technique temporarily grants magic resistance, reflection and free action.");
3396 pline("Using this technique requires you to wield a staff, and will try to enchant it (up to a maximum of +8, although the chance of enchanting it decreases with higher enchantment). Can also uncurse a cursed staff.");
3399 case T_CLONE_JAVELIN
:
3400 pline("Requires you to wield a javelin, which will receive an extra ammo. Yes, you can multiply artifact javelins that way; this is not a bug.");
3404 pline("While having this technique active, undead creatures that are near you will continuously take damage and may also be scared.");
3407 case T_DRAINING_PUNCH
:
3408 pline("This martial arts move can be chained, and it may drain levels from monsters if they fail to resist. It requires you to be bare-handed.");
3412 pline("A technique that lasts for a period of time and requires a robe to be worn, in which case it increases your bare-handed or lightsaber melee damage.");
3415 case T_PIRATE_BROTHERING
:
3416 pline("Requires you to dual-wield with a lightsaber in your primary hand and a scimitar in your off-hand, and the lightsaber must be lit. While the technique is active, the lightsaber will not consume energy, and every time the scimitar hits something your lightsaber is recharged a bit.");
3419 case T_NUTS_AND_BOLTS
:
3420 pline("Using this technique creates some crossbow bolts and increases your nutrition.");
3423 case T_DECAPABILITY
:
3424 pline("While this technique is active, your polearm may sometimes put monsters to sleep if you apply it at them, and if your lightsaber destroys an enemy's weapon, the enemy in question is also put to sleep.");
3427 case T_NO_HANDS_CURSE
:
3428 pline("Only works if you are wielding a two-handed weapon that is not cursed. The weapon in question will become heavily cursed and get a negative enchantment value, but you gain +1 luck, +100 alignment record, -1 divine anger and -500 prayer timeout. Also, hostile monsters that are next to you have a chance of becoming peaceful.");
3431 case T_HIGH_HEELED_SNEAKERS
:
3432 pline("If you use this technique, you can use the high heels and sexy flats skills simultaneously for a while. But this only works if you actually have a pair that qualifies, which means it has to be one that has both a high-heeled randomized appearance and a sexy flats base item type or the other way around.");
3436 pline("Requires you to be wielding a lightsaber, and will transform it into a different type of lightsaber that you can choose.");
3439 case T_STAR_DIGGING
:
3440 pline("Fires digging rays in all eight directions.");
3443 case T_WONDER_YONDER
:
3444 pline("Teaches you a random spell when used, but also causes long-lasting inertia and some random bad effects.");
3448 pline("Tries to tame adjacent evilvariant monsters (use the pokedex to look for the 'Origin: Evil variant' bit). They can try to resist via monster magic resistance though.");
3452 pline("Inspired by Splicehack, this technique lets you choose a scroll in your open inventory for a chance to duplicate it. The higher the cost of writing the scroll in question with a magic marker, the lower the chance that your duplication attempt works, but higher technique levels will increase the chance of success. Scrolls that cannot be written with a magic marker, e.g. wishing, can never be duplicated with this technique because that would be too powerful, and artifact scrolls are impossible too.");
3456 pline("Lets you pick a skill in which you're not restricted, and trains it by a few points. This lets you bypass the RNG limitations that might have made a skill impossible to train, meaning that repeatedly using this technique may allow you to reach skill levels that you can't otherwise reach, but of course you can't go over the cap displayed in the #enhance screen.");
3459 case T_SHOTTY_BLAST
:
3460 pline("Creates shotgun shells out of thin air.");
3463 case T_AMMO_UPGRADE
:
3464 pline("This technique requires you to wield firearm ammo, which may be enhanced in enchantment value and BUC. Remember that like everything that can affect a stack of items, big stacks of ammo (more than 25 ammos in one stack) have a chance to resist depending on the exact stack size. Ammo that is already highly enchanted is less likely to gain additional enchantment points, and the maximum that you can reach with this technique is +10.");
3468 pline("Creates laser gun ammo out of thin air.");
3472 pline("This powerful technique creates a rocket launcher with ammo out of thin air.");
3475 case T_SHUT_THAT_BITCH_UP
:
3476 pline("A technique that lasts for a couple of turns and allows your firearm ammos to stop time if they hit a female enemy.");
3480 pline("This technique works only if there's no trap on your current location. It also requires 500 points of nutrition. If you fulfill those requirements, you create a trap at your location that can only affect hostile monsters and deals damage relative to your squeaking skill and technique level. However, only monsters that didn't see you create the trap can trigger it and they can also only ever trigger it while they're outside of your line of sight!");
3484 pline("Shoots acid rays in all directions and may destroy iron bars.");
3487 case T_WOMAN_NOISES
:
3488 pline("If you use this technique, hostile monsters in a certain radius around you have to make a saving throw or be affected by several bad effects.");
3491 case T_EXTRA_LONG_SQUEAK
:
3492 pline("After using this technique, it will stay active for a while and protect you from farting effects, and additionally all nearby hostile male monsters will have to make a saving throw each turn or take damage.");
3496 pline("This technique tames an adjacent male monster. It has a 1 in 5 chance of taming boss monsters.");
3500 pline("Well DUH :D Using it will change your sex from male to female or the other way around!");
3503 case T_EVEN_MORE_AMMO
:
3504 pline("You must be wielding firearm ammo to use this technique, and if you do, its stack size will increase.");
3508 pline("Only player characters that are currently polymorphed into a monster can use this technique, and if you do so, you'll spawn a tame monster of the same type as your current polymorph form.");
3512 pline("Using this technique lets you select a hazy item in your open inventory, which will become un-hazy so it won't polymorph back into the original item.");
3515 case T_SQUEAKY_REPAIR
:
3516 pline("This technique creates a fart trap on your current location and triggers it, but only if there was no trap on your location. If the trap was successfully made, you then get to repair an item of your choice in your main inventory.");
3520 pline("Using this technique makes your firearm ammo reusable for a while, i.e. ammos that you shot may drop on the ground and be re-used, although most of the time they'll still be mulched.");
3524 pline("This technique lets you pick a wand in your open inventory and add a charge to it without incrementing the recharge counter and without the chance of blowing up the wand, but caution: the wand must be one that can be recharged indefinitely. Using it on one that can only be recharged once (e.g. wand of wishing) will not work.");
3527 case T_STARWARS_FRIENDS
:
3528 pline("A technique that tries to tame all adjacent monsters which are from Castle of the Winds or joke monsters, but they get a resistance roll. Also, one tame such monster is generated from thin air.");
3531 case T_USE_THE_FORCE_LUKE
:
3532 pline("This technique lasts for a period of time and increases the damage of the #force command while active.");
3535 case T_TERRAIN_CLEANUP
:
3536 pline("This powerful technique removes most annoying terrain from the eight squares surrounding you: water, trees, ice, farmland, nether mist and so on... It doesn't raze walls though, and furniture (e.g. wagons or fountains) is unaffected. The general rule of thumb is that if the terrain type can replace walls in maze levels, it will be affected.");
3540 pline("The basic symbiosis technique, using this will create a symbiote item out of thin air with which you can then perform symbiosis. It's probably a good idea to use this technique whenever you can, as it allows you to slowly but steadily build up a supply of symbiote items for later use.");
3543 case T_ADJUST_SYMBIOTE
:
3544 pline("Adjusts the aggressivity of your symbiotes, which is a global value that persists even if you switch to a different symbiote. Higher aggressivity means that your symbiote's attacks trigger more often, and damage that you would normally take is redirected to the symbiote more often.");
3547 case T_HEAL_SYMBIOTE
:
3548 pline("Damages you by half of your current HP and transfers that amount of hit points to your symbiote, but if that causes it to be overhealed, the extra points will just go to waste.");
3551 case T_BOOST_SYMBIOTE
:
3552 pline("Whenever you use this technique, your symbiote's maximum health will increase. However, there is a cap of 500 HP for the symbiote.");
3556 pline("Activating this technique temporarily allows your symbiote to deal double damage and take half damage.");
3559 case T_UNARMED_FOCUS
:
3560 pline("A technique meant to be used by those who really want to focus on bare-handed or martial arts combat. It lasts for a pretty long time, and even longer if you keep wearing a robe of focussing. While it's active, it increases the base damage multiplier of your fists by about 50%%. However, all other active techniques are stopped and while it's active, you cannot use any techniques at all. Also, trying to use a weapon with this technique active gives a hefty to-hit penalty, so you'd better make sure you really want to focus on fighting unarmed!");
3564 pline("Allows you to try to drown a monster. For that to work, either you or the monster needs to be on a water square (can be a pool, moat, watery tunnel or crystal water) and the monster may not be unbreathing of course.");
3568 pline("If you're annoyed by all the finalized items that you cannot polymorph, blank or cancel, this technique allows you to remove the finalized flag from one item.");
3571 case T_ANTI_INERTIA
:
3572 pline("Useful when you're slowed down by inertia, because it reduces the amount of time for which you're slowed.");
3575 case T_GRENADES_OF_COURSE
:
3576 pline("Creates frag grenades or gas grenades.");
3579 case T_IMPLANTED_SYMBIOSIS
:
3580 pline("This technique lasts for quite a while when you use it. While active, you benefit from the more powerful implant effects as long as you're in symbiosis, and if your implant is positively enchanted, your symbiote will take less damage based on the exact enchantment value.");
3583 case T_ASSUME_SYMBIOTE
:
3584 pline("Polymorphs you into the base monster type of your current symbiote. Doing that causes your symbiote to persist, so don't worry about it dying from this tech - it just makes it so that both you and your symbiote are of the same species. What's more, you will be able to move around as long as you still have the symbiote, even though symbiotes are characterized by the fact that they're nonmoving monsters.");
3587 case T_GENERATE_OFFSPRING
:
3588 pline("If you use this technique while having a symbiote, you will lay an egg of the symbiote's monster type that will hatch tame after a while.");
3592 pline("Using this technique breaks the atheist conduct and slightly increases your alignment record, but not above the current maximum.");
3595 case T_ON_THE_SAME_TEAM
:
3596 pline("Tries to pacify hostile neutral-aligned monsters next to you, but they get a resistance roll.");
3600 pline("A tech that lasts for a hundred turns or so, and while active, your spells don't lose spell memory over time, cost a bit less mana, and are more effective if they're of a type that scales with skill.");
3603 case T_DROP_BOULDER
:
3604 pline("Creates a boulder on your square when used.");
3608 pline("Requires you to wear stiletto heels, and makes you super fast for a couple of turns when used, but it only affects movement. Other actions still happen at your regular speed.");
3611 pline("This technique can only be used when you're wearing stiletto heels. After using it, you have a couple of turns to find a paralyzed monster that has a head and is not a boss, and then you can kick that monster to kill it instantly! For best results, have a way of paralyzing opponents ready.");
3613 case T_FEMALE_COMBO
:
3614 pline("Requires cone heels to be worn, and once activated, you have to kick a monster every turn or the technique will end. Every kick that hits an enemy while the female combo is active will deal more damage than the previous one.");
3617 pline("Creates a sexy leather pump with positive enchantment, which is a hammer-class weapon that you can wield and bash enemies with. While this technique is active, the sexy leather pump will do bonus damage against enemies who have a head and can also occasionally paralyze them.");
3619 case T_BITCH_POSING
:
3620 pline("This technique works only while you're wearing block heels. If they're negatively enchanted, they lose some negative enchantment, otherwise there's a chance for the heels to gain a point of enchantment up to a maximum of +7. Additionally, monsters who are at most 3 squares away from you have to make saving throws or be turned peaceful.");
3623 pline("Lasts for a while, but works only if you wear block heels. While active, you have intrinsic free action and if you still get paralyzed, the paralysis will time out very quickly.");
3626 pline("This technique lasts for quite a while, but doesn't do anything unless you're wearing wedge heels. If you are, your movement is faster than normal.");
3628 case T_PERFUME_STRIDE
:
3629 pline("Requires you to be wearing wedge heels, which become sticky heavily cursed upon using this technique, and a tame perfume monster is summoned. The technique then lasts for a while and as long as it's still active, you cannot take your heels off, even if you manage to uncurse them.");
3631 case T_NAUGHTY_HEELOT
:
3632 pline("This technique lasts for quite a while. When active, a pair of shoes that has a randomized appearance counting as cone heels and a base type counting as stiletto heels (or the other way around) allows you to use both of those skills at the same time. You'd have to get pretty lucky to find such a pair of shoes, though.");
3634 case T_EXTREME_STURDINESS
:
3635 pline("Works while you're wearing either block or wedge heels, lasts for a bunch of turns, and gives you a 50%% chance of not taking damage whenever something tries to damage you.");
3637 case T_BUTT_PROTECTION
:
3638 pline("If you're wearing cone heels, this technique will last for a while and as long as it's active, any male monster that hits you in melee takes some damage in return, provided it has legs that can be scratched by your heels. The more often such a monster is hit by that damage, the higher the amount of damage that it takes.");
3641 pline("Allows you to enchant a pair of block-heeled boots that you're wearing, up to a maximum of +5, but you can't just use it an infinite amount of times on the same pair. Eventually, it'll stop working for a particular pair of boots, although you can still use it on others.");
3643 case T_STAR_HEEL_SWAP
:
3644 pline("You must be wearing a pair of wedge heels and have a morning star wielded in your main hand if you want to use this technique. Then, what happens is that these two items swap their enchantment value and BUC.");
3647 pline("You can only use this technique if you're wearing a pair of stiletto heels and wielding a knife. Then, it'll last a while, and your knife will gain a +5 damage bonus, plus the enchantment value of your boots if that's higher than 0.");
3651 pline("This technique mimics the scroll of earth, dropping boulders on your square and the eight squares surrounding you, but minus the effect of boulders hitting monsters.");
3654 case T_MARTIAL_STYLE
:
3655 pline("A must have for martial arts users, this technique lets you switch to different martial arts styles. Depending on your skill levels, certain ones are available, plus brawling, which is the default. All other styles have upsides and downsides, so choose wisely, because the only way to switch is by using this tech again! Also, most of these styles work only if you're fighting bare-handed.");
3659 pline("This powerful technique lets you target an adjacent monster and tries to polymorph it, although it can resist via monster magic resistance and those that have player-style magic resistance are outright immune. If you're successful in polymorphing it, the monster's polymorph will be semi-permanent.");
3662 case T_HARDCORE_ALIENIZATION
:
3663 pline("Creates a shemagh out of thin air and forces you to wear it, unequipping any other helmet-slot item you may be wearing.");
3667 pline("Targets an adjacent humanoid monster and tries to turn it peaceful, although it can also resist. Shopkeepers, guards, temple priests and unique monsters are immune.");
3671 pline("For a few turns after using this technique, it shoots fire bolts in the direction you came from.");
3675 pline("Deals cold damage and tries to slow targets in a 5x5 area near you, although it doesn't always hit. This technique lasts for a few turns before it ends.");
3678 case T_THUNDERSTORM
:
3679 pline("Lasts for a while and periodically deals lightning damage to nearby monsters.");
3683 pline("Shoots highly damaging lightning bolts in all eight directions. This technique sets a timeout for all of the following techniques: autokill, chain thunderbolt and flashing mischief.");
3686 case T_CHAIN_THUNDERBOLT
:
3687 pline("Shoots an invisible globe in a direction of your choosing, which will travel for 8 squares or until it hits a terrain obstacle. At the target destination, it shoots highly damaging lightning bolts in all eight directions. This technique sets a timeout for all of the following techniques: autokill, chain thunderbolt and flashing mischief.");
3690 case T_FLASHING_MISCHIEF
:
3691 pline("Shoots an invisible globe in a direction of your choosing, which will travel for 8 squares or until it hits a terrain obstacle. For each square it travels, the globe shoots a highly damaging lightning bolt in a random direction. This technique sets a timeout for all of the following techniques: autokill, chain thunderbolt and flashing mischief.");
3695 pline("A single-target ranged attack that travels in the chosen direction for 8 squares, but not through terrain obstacles, and deals damage to the first monster it hits.");
3698 case T_SHADOW_MANTLE
:
3699 pline("Darkens the area and blinds nearby monsters.");
3703 pline("Creates throwing stars out of thin air.");
3706 case T_BLADE_SHIELD
:
3707 pline("This technique lasts for a while and periodically deals damage to hostile monsters adjacent to you.");
3710 case T_GREEN_WEAPON
:
3711 pline("Requires you to be wielding a claw, which will be badly poisoned, making it less likely to lose its poisoning compared to regular poisoned weapons.");
3714 case T_LIGHTER_BALLS
:
3715 pline("Lasts for quite a while, and reduces the weight of your wielded heavy iron ball by half while active.");
3719 pline("This technique only works if you're wielding a heavy iron ball, or another type of heavy ball as a weapon, and repairs a bit of damage on the ball.");
3722 case T_JAVELIN_FORGING
:
3723 pline("Creates a random javelin when used.");
3726 case T_VENOM_MIXING
:
3727 pline("An arcane technique that allows you to create venom out of thin air.");
3730 case T_ROCK_TO_POISON
:
3731 pline("Allows you to target a stack of regular rocks, which may not be an artifact, and attempts to turn them into acid venoms. The standard rules for manipulating a stack apply, so in most cases, attempting to target a stack of more than 25 rocks may fail.");
3735 pline("Targets an adjacent monster and hits it with nerve poison, damaging and paralyzing it as long as it doesn't resist.");
3738 case T_SUPER_POISON
:
3739 pline("Requires you to wield a stack of venoms, and tries to add some enchantment value to it. This works only if the venom's enchantment is less than +25.");
3742 case T_GREEN_MISSILE
:
3743 pline("Lasts for a couple of turns, and as long as it's active, throwing venoms will additionally launch poison blasts at the enemy.");
3747 pline("Activating this technique means that monsters who hit you in melee are hit with poison for a while.");
3750 case T_PLANT_TERROR
:
3751 pline("Transforms you into a meshera plant for a couple dozen turns. That's an immobile monster, so be aware that you cannot run away once transformed. In addition, a few tame little poison ivies are summoned who will help you plant new trees in Gotham Forest. You can only hope that Batsy, that old bat, won't come to try and stop you with his batarangs, though.");
3754 case T_POISON_PEN_LETTER
:
3755 pline("Doesn't last very long at all, but while it does last, you can engrave with venoms. Doing so releases a stinking cloud at your location, which is bigger the more letters you engrave at once.");
3758 case T_CORONATION_CULMINATION
:
3759 pline("Infects you with covid-19 and gives a random good effect when used.");
3762 case T_RESTORE_LIFE_LEVELS
:
3763 pline("When using this technique after you got your levels drained, they will be restored. No effect if your level wasn't drained.");
3767 pline("Using this technique requires you to guess an item. If you guess correctly, you get the item in question, otherwise you're forced to equip a bad item.");
3770 case T_TOILET_VISIT
:
3771 pline("If you want to play the antje trap 2 minigame where you visit the public toilet, you can use this technique. You will also gain maximum health and cure sickness when doing so.");
3775 pline("For a while, your polearms and lances are effective at close range after you've used this technique.");
3779 pline("In order to use this technique, you have to be wielding an axe, which will hit all adjacent monsters. Be careful, it can also hit peaceful targets!");
3783 pline("Allows you to banish an adjacent monster, sending it to a random dungeon level. Careful: if the demigod event has already been triggered, it only teleports the monster on the current level!");
3786 case T_PARTICIPATION_LOSS
:
3787 pline("This extremely powerful technique lets you delete an adjacent monster from the game, but it doesn't work against bosses, shopkeepers or temple priests. Be aware that the monster's inventory is deleted with it (macguffins will drop to the floor to prevent the game from becoming unwinnable).");
3790 case T_WEAPON_BLOCKER
:
3791 pline("A technique that lasts for a while, but requires you to be dual-wielding. While active, you have a chance of using your weapons to block melee attacks and projectiles.");
3794 case T_EXTRA_MEMORY
:
3795 pline("You can select a spell and increase its memory with this technique. It has a minuscule chance of working on a forgotten spell, allowing you to cast it again, but most of the time, using it on a forgotten spell will simply fail.");
3799 pline("Temporarily makes your grinder work like a lance and your lance will work like a grinder. Or if that sounds like Chinese to you, it means that you can joust with a grinder and grind with a lance.");
3802 case T_DIABOLIC_MINION
:
3803 pline("If you use this technique, a random tame Diablo monster is summoned.");
3806 case T_CURE_AMNESIA
:
3807 pline("A useful technique that removes the 'map amnesia' intrinsic. Be aware that if you're e.g. playing the amnesiac race, you'll still have map amnesia. It's useful especially when you triggered a lasting amnesia trap.");
3810 case T_ELEMENTAL_IMBUE
:
3811 pline("This technique transforms your currently wielded weapon into an elemental-branded artifact. It works only if the weapon in question is neither a real nor fake artifact, and only if it's actually listed under 'weapons' in your inventory. Plus, it obviously doesn't work on a stack.");
3814 case T_HIDDEN_POWER
:
3815 pline("Using this technique creates a specific item, the identity of which depends on the skill you used for unlocking the technique.");
3819 pline("Requires you to wield a weapon that uses one of the following skills: short sword, broad sword, long sword or two-handed sword. The weapon in question will gain one level of enchantment, but not beyond +7.");
3823 pline("Requires you to wield a weapon that uses one of the following skills: mace, flail, club or hammer. The weapon in question will be erosionproofed and all erosion damage is repaired.");
3828 pline("This technique doesn't have a description yet, but it might get one in future. --Amy");
3832 if (yn("Use this technique?") == 'y') return techeffects(tech_no
);
3837 } else if (gettech(&tech_no
)) {
3838 return techeffects(tech_no
);
3844 static NEARDATA
const char kits
[] = { TOOL_CLASS
, 0 };
3847 use_medical_kit(type
, feedback
, verb
)
3852 struct obj
*obj
, *otmp
;
3853 makeknown(MEDICAL_KIT
);
3854 if (!(obj
= carrying(MEDICAL_KIT
))) {
3855 if (feedback
) You("need a medical kit to do that.");
3856 return (struct obj
*)0;
3858 for (otmp
= invent
; otmp
; otmp
= otmp
->nobj
)
3859 if (otmp
->otyp
== MEDICAL_KIT
&& otmp
!= obj
)
3861 if (otmp
) { /* More than one medical kit */
3862 obj
= getobj(kits
, verb
);
3864 return (struct obj
*)0;
3866 for (otmp
= obj
->cobj
; otmp
; otmp
= otmp
->nobj
)
3867 if (otmp
->otyp
== type
)
3871 You_cant("find any more %s in %s.",
3872 makeplural(simple_typename(type
)), yname(obj
));
3873 return (struct obj
*)0;
3878 /* gettech is reworked getspell */
3879 /* reworked class special effects code */
3880 /* adapted from specialpower in cmd.c */
3882 techeffects(tech_no
)
3885 /* These variables are used in various techs */
3886 struct obj
*obj
, *otmp
;
3890 char Your_buf
[BUFSZ
];
3892 int i
, j
, t_timeout
= 0;
3894 boolean maybeleveltech
= FALSE
;
3897 if (tech_inuse(techid(tech_no
))) {
3898 pline("This technique is already active!");
3901 if (techtout(tech_no
) /*&& !can_limitbreak()*/) {
3902 You("have to wait %s before using your technique again.",
3903 (techtout(tech_no
) > 100) ?
3904 "for a while" : "a little longer");
3906 if (!wizard
|| (yn("Use technique anyways?") == 'n'))
3911 if ((TechTrapEffect
|| u
.uprops
[TECHBUG
].extrinsic
|| have_techniquestone()) && (rn2(10) || TechBugXtra
) ) {
3913 pline("Unfortunately, nothing happens.");
3914 techtout(tech_no
) = rnz(5000);
3915 if (ishaxor
&& techtout(tech_no
) > 1) techtout(tech_no
) /= 2;
3916 /*By default, action should take a turn*/
3921 if (uarmc
&& uarmc
->oartifact
== ART_ARTIFICIAL_FAKE_DIFFICULTY
&& !rn2(6)) {
3923 pline("Unfortunately, nothing happens.");
3924 techtout(tech_no
) = rnz(1000);
3925 if (ishaxor
&& techtout(tech_no
) > 1) techtout(tech_no
) /= 2;
3926 /*By default, action should take a turn*/
3931 if (Role_if(PM_FAILED_EXISTENCE
) && rn2(2)) {
3933 pline("Unfortunately, nothing happens.");
3934 techtout(tech_no
) = rnz(1000);
3935 if (ishaxor
&& techtout(tech_no
) > 1) techtout(tech_no
) /= 2;
3936 /*By default, action should take a turn*/
3941 if (tech_inuse(T_UNARMED_FOCUS
)) {
3943 pline("While you're focussing on unarmed combat, you cannot use any techniques. Sorry!");
3948 /* switch to the tech and do stuff */
3949 switch (techid(tech_no
)) {
3951 /* WAC stolen from the spellcasters...'A' can identify from
3952 historical research*/
3953 if(Hallucination
|| (Stunned
&& !Stun_resist
) || (Confusion
&& !Conf_resist
) ) {
3954 You("can't concentrate right now!");
3956 } else if((ACURR(A_INT
) + ACURR(A_WIS
)) < rnd(60)) {
3957 pline("Nothing in your pack looks familiar.");
3958 t_timeout
= rnz(2000);
3961 You("examine your possessions.");
3962 identify_pack((int) ((techlevX(tech_no
) / 10) + 1), 0, 0);
3964 /* KMH -- fixed non-compliant string */
3965 You("are already quite familiar with the contents of your pack.");
3968 t_timeout
= rnz(5000);
3971 /* only when empty handed, in human form */
3972 if (Upolyd
|| uwep
|| uarmg
) {
3973 You_cant("do this while %s!", Upolyd
? "polymorphed" :
3974 uwep
? "holding a weapon" : "wearing gloves");
3977 Your("fingernails extend into claws!");
3979 techt_inuse(tech_no
) = d(2,4) + techlevX(tech_no
)/2 + 2;
3980 t_timeout
= rnz(2000);
3983 You("fly into a berserk rage!");
3984 techt_inuse(tech_no
) = d(2,8) +
3985 (techlevX(tech_no
)/2) + 2;
3986 incr_itimeout(&HFast
, techt_inuse(tech_no
));
3987 t_timeout
= rnz(1500);
3990 /* WAC spell-users can study their known spells*/
3991 if(Hallucination
|| (Stunned
&& !Stun_resist
) || (Confusion
&& !Conf_resist
) ) {
3992 You("can't concentrate right now!");
3995 You("concentrate...");
3996 if (studyspell()) t_timeout
= rnz(1500); /*in spell.c*/
4000 Your("%s %s become blurs as they reach for your quiver!",
4001 uarmg
? "gloved" : "bare", /* Del Lamb */
4002 makeplural(body_part(HAND
)));
4003 techt_inuse(tech_no
) = rnd((int) (techlevX(tech_no
)/6 + 1)) + 2;
4004 t_timeout
= rnz(1500);
4006 case T_INVOKE_DEITY
: /* ask for healing if your alignment record is positive --Amy */
4008 if (Race_if(PM_MACTHEIST
)) {
4009 pline("As an atheist, you cannot use such a technique.");
4013 if (u
.ualign
.record
< 0) {
4015 if ( (Inhell
&& !Race_if(PM_HERETIC
) ) || flags
.gehenna
) {
4016 pline("%s is inaccessible, and %s decides to smite you!",u_gname(), Role_if(PM_GANG_SCHOLAR
) ? "Anna" : Role_if(PM_WALSCHOLAR
) ? "Anna" : "Moloch" );
4017 u
.ublesscnt
+= rnz(-u
.ualign
.record
);
4018 if (Role_if(PM_GANG_SCHOLAR
)) losehp(rnz(-u
.ualign
.record
), "annoying Anna", KILLED_BY
);
4019 else if (Role_if(PM_WALSCHOLAR
)) losehp(rnz(-u
.ualign
.record
), "annoying Anna", KILLED_BY
);
4020 else losehp(rnz(-u
.ualign
.record
), "annoying Moloch", KILLED_BY
);
4022 pline("%s smites you for your sins!",u_gname() );
4023 u
.ublesscnt
+= rnz(-u
.ualign
.record
);
4024 losehp(rnz(-u
.ualign
.record
), "disturbing their deity", KILLED_BY
);
4026 /* If your deity feels annoyed, they will damage you and increase your prayer timeout. They won't get angry though. */
4029 else if (Race_if(PM_IMPERIAL
)) {
4030 pline("%s hates you and decides you need to be punished!",u_gname() );
4031 u
.ublesscnt
+= rnz(monster_difficulty() + 1 );
4032 losehp(rnz(monster_difficulty() + 1 ), "being a pesky heretic", KILLED_BY
);
4033 /* Imperials cannot use this technique successfully. */
4036 else if ( (Inhell
&& !Race_if(PM_HERETIC
) ) || flags
.gehenna
) {
4037 pline("%s is inaccessible, and %s decides to smite you!",u_gname(), Role_if(PM_GANG_SCHOLAR
) ? "Anna" : Role_if(PM_WALSCHOLAR
) ? "Anna" : "Moloch" );
4038 u
.ublesscnt
+= rnz(monster_difficulty() + 1 );
4039 losehp(rnz(monster_difficulty() + 1 ), "trying to contact their deity in Gehennom", KILLED_BY
);
4040 /* Trying to invoke a deity in Gehennom is never a good idea... */
4043 else if (u
.ualign
.record
> 0) {
4044 pline("%s commends your efforts and grants you a boon.",u_gname() );
4045 u
.ublesscnt
-= rnz(u
.ualign
.record
+ techlevX(tech_no
) );
4046 if(u
.ublesscnt
< 0) u
.ublesscnt
= 0;
4047 healup( rnz(u
.ualign
.record
+ techlevX(tech_no
)) , 0, FALSE
, FALSE
);
4048 /* If your deity is pleased with you, heal some damage and decrease your prayer timeout. */
4051 else { /* alignment record exactly 0, do nothing */
4052 pline("%s ignores your pleadings.",u_gname() );
4055 u
.uconduct
.gnostic
++; /* you just tried to access your god */
4056 if (Race_if(PM_MAGYAR
)) {
4057 You_feel("bad about breaking the atheist conduct.");
4060 use_skill(P_SPIRITUALITY
, Role_if(PM_PRIEST
) ? 10 : 2);
4061 t_timeout
= rnz(3000);
4065 You("are not wielding anything!");
4067 } else if (weapon_type(uwep
) == P_NONE
) {
4068 You("examine %s.", doname(uwep
));
4070 You("discover it is %s",doname(uwep
));
4071 if (u
.enchantrecskill
< 100 || !rn2(u
.enchantrecskill
)) {
4072 u
.enchantrecskill
++;
4073 if (u
.enchantrecskill
> 250) u
.enchantrecskill
= 250;
4075 if (uwep
&& uwep
->oartifact
== ART_KAMAHEWA
&& uwep
->spe
< 7) {
4077 Your("gauntlets seem more effective.");
4079 t_timeout
= rnz(2000);
4081 You("examine %s.", doname(uwep
));
4083 You("discover it is %s",doname(uwep
));
4084 if (u
.weapchantrecskill
< 100 || !rn2(u
.weapchantrecskill
)) {
4085 u
.weapchantrecskill
++;
4086 if (u
.weapchantrecskill
> 250) u
.weapchantrecskill
= 250;
4089 if (Race_if(PM_GERTEUT
) && is_poisonable(uwep
) && !stack_too_big(uwep
)) {
4090 Your("%s is poisoned.", doname(uwep
));
4091 uwep
->opoisoned
= TRUE
;
4093 if (uwep
&& uwep
->oartifact
== ART_KAMAHEWA
&& uwep
->spe
< 7) {
4095 Your("gauntlets seem more effective.");
4097 if (!(uarmc
&& uarmc
->oartifact
== ART_PINEAPPLE_TYCOON_S_FINISH
) || !rn2(4)) {
4098 t_timeout
= rnz(200);
4105 if (!Role_if(PM_CAMPERSTRIKER
) || !rn2(4)) t_timeout
= rnz(1000);
4108 case T_PANIC_DIGGING
:
4109 pline("You perform the panic digging ritual and are paralyzed for a while.");
4112 do_clear_areaX(u
.ux
, u
.uy
, 1, undo_lockfloodP
, (void *)&maderoom
);
4114 if (maderoom
) pline("Some solid rock is pulverized!");
4115 else pline("There was nothing to dig out...");
4117 if (isstunfish
) nomul(-rnz(20), "panic digging", TRUE
);
4118 else nomul(-rn1(10, 10), "panic digging", TRUE
);
4119 if (!PlayerCannotUseSkills
&& P_SKILL(P_PICK_AXE
) >= P_SUPREME_MASTER
) t_timeout
= rnz(500);
4120 else if (!PlayerCannotUseSkills
&& P_SKILL(P_PICK_AXE
) >= P_GRAND_MASTER
) t_timeout
= rnz(1500);
4121 else if (!PlayerCannotUseSkills
&& P_SKILL(P_PICK_AXE
) >= P_MASTER
) t_timeout
= rnz(2500);
4122 else t_timeout
= rnz(5000);
4125 case T_SECURE_IDENTIFY
:
4127 if (CannotSelectItemsInPrompts
) break;
4128 pline("Choose an item for secure identification.");
4132 otmp
= getobj(allnoncount
, "secure identify");
4135 if (yn("Really exit with no object selected?") == 'y')
4136 pline("You just wasted the opportunity to secure identify your objects.");
4137 else goto secureidchoice
;
4138 pline("A feeling of loss comes over you.");
4142 makeknown(otmp
->otyp
);
4143 if (otmp
->oartifact
) discover_artifact((int)otmp
->oartifact
);
4144 otmp
->known
= otmp
->dknown
= otmp
->bknown
= otmp
->rknown
= 1;
4145 if (otmp
->otyp
== EGG
&& otmp
->corpsenm
!= NON_PM
)
4146 learn_egg_type(otmp
->corpsenm
);
4147 prinv((char *)0, otmp
, 0L);
4152 if (u
.glassgolemdown
) t_timeout
= rnz(10000);
4153 else t_timeout
= rnz(20000);
4157 if(!uwep
|| (weapon_type(uwep
) == P_NONE
)) {
4158 You("are not wielding a weapon!");
4160 } else if(uwep
->known
== TRUE
) {
4163 if (not_fully_identified(uwep
)) {
4164 You("examine %s.", doname(uwep
));
4165 if (rnd(15) <= ACURR(A_INT
)) {
4166 makeknown(uwep
->otyp
);
4168 if (u
.weapchantrecskill
< 100 || !rn2(u
.weapchantrecskill
)) {
4169 u
.weapchantrecskill
++;
4170 if (u
.weapchantrecskill
> 250) u
.weapchantrecskill
= 250;
4172 You("discover it is %s",doname(uwep
));
4174 pline("Unfortunately, you didn't learn anything new.");
4176 /*WAC Added practicing code - in weapon.c*/
4179 t_timeout
= rnz(1000);
4182 if (Hallucination
|| (Stunned
&& !Stun_resist
) || (Confusion
&& !Conf_resist
) ) {
4183 You("are in no condition to perform surgery!");
4186 if (Sick
|| Slimed
) {
4187 if (carrying(SCALPEL
)) {
4188 pline("Using your scalpel (ow!), you cure your infection!");
4189 make_sick(0L, (char *)0, TRUE
, SICK_ALL
);
4195 } else if (u
.uhp
> 6)
4199 t_timeout
= rnz(1000);
4202 } else pline("If only you had a scalpel...");
4204 if (Upolyd
? u
.mh
< u
.mhmax
: u
.uhp
< u
.uhpmax
) {
4205 otmp
= use_medical_kit(BANDAGE
, FALSE
,
4206 "dress your wounds with");
4209 if (otmp
->quan
> 1L) {
4211 otmp
->ocontainer
->owt
= weight(otmp
->ocontainer
);
4213 obj_extract_self(otmp
);
4214 obfree(otmp
, (struct obj
*)0);
4217 use_skill(P_DEVICES
,1);
4218 if (Race_if(PM_FAWN
)) {
4219 use_skill(P_DEVICES
,1);
4221 if (Race_if(PM_SATRE
)) {
4222 use_skill(P_DEVICES
,1);
4223 use_skill(P_DEVICES
,1);
4226 pline("Using a bandage, you dress your wounds."); /* read after free fix by Demo */
4227 healup(techlevX(tech_no
) * (rnd(2)+1) + (rn1(5,5) * techlevX(tech_no
)),
4230 You("strap your wounds as best you can.");
4231 healup(techlevX(tech_no
) + rn1(5,5), 0, FALSE
, FALSE
);
4233 t_timeout
= rnz(1500);
4235 } else You("don't need your healing powers!");
4239 Your("body is on fire!");
4241 t_timeout
= rnz(3000);
4243 You("lay your hands on the foul sickness...");
4244 make_sick(0L, (char*)0, TRUE
, SICK_ALL
);
4245 t_timeout
= rnz(3000);
4246 } else if (Upolyd
? u
.mh
< u
.mhmax
: u
.uhp
< u
.uhpmax
) {
4247 pline("A warm glow spreads through your body!");
4248 healup(techlevX(tech_no
) * 4, 0, FALSE
, FALSE
);
4249 t_timeout
= rnz(3000);
4251 pline("%s", nothing_happens
);
4252 if (FailureEffects
|| u
.uprops
[FAILURE_EFFECTS
].extrinsic
|| have_failurestone()) {
4253 pline("Oh wait, actually something bad happens...");
4259 You("scream \"KIIILLL!\"");
4261 techt_inuse(tech_no
) = rnd((int) (techlevX(tech_no
)/2 + 1)) + 2;
4262 t_timeout
= rnz(1500);
4266 if (u
.usteed
) pline("You calm your steed.");
4273 pline("%s gets tamer.", Monnam(u
.usteed
));
4274 tamedog(u
.usteed
, (struct obj
*) 0, FALSE
); /* caveat: you might be riding a non-tame monster */
4276 while (calmedX
== 0) { /* remove the stupid bug that caused this tech to do nothing --Amy */
4278 if (u
.usteed
&& u
.usteed
->mtame
< 20) u
.usteed
->mtame
++;
4280 if (techlevX(tech_no
) < rnd(50)) calmedX
++; /* high level tech has high chance of extra tameness */
4284 t_timeout
= rnz(1500);
4286 Your("technique is only effective when riding a monster.");
4289 if (!turn_undead()) t_timeout
= rnz(10);
4290 else t_timeout
= rnz(50);
4293 if (Invisible
&& Fast
) {
4294 You("are already quite nimble and undetectable.");
4296 techt_inuse(tech_no
) = rn1(10,10) + (techlevX(tech_no
) * 2);
4297 if (!Invisible
) pline("In a puff of smoke, you disappear!");
4298 if (!Fast
) You_feel("more nimble!");
4299 incr_itimeout(&HInvis
, techt_inuse(tech_no
));
4300 incr_itimeout(&HFast
, techt_inuse(tech_no
));
4301 newsym(u
.ux
,u
.uy
); /* update position */
4302 t_timeout
= rnz(1500);
4305 if (!getdir((char *)0)) return(0);
4306 if (!u
.dx
&& !u
.dy
) {
4307 /* Hopefully a mistake ;B */
4308 You("decide against that idea.");
4311 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
4312 pline("Invalid target location.");
4315 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
4317 You("perform a flashy twirl!");
4318 t_timeout
= rnz(1500);
4320 int oldhp
= mtmp
->mhp
;
4323 if (!attack(mtmp
)) return(0);
4324 if (!DEADMONSTER(mtmp
) && mtmp
->mhp
< oldhp
&&
4325 !noncorporeal(mtmp
->data
) && !unsolid(mtmp
->data
)) {
4326 You("strike %s vital organs!", s_suffix(mon_nam(mtmp
)));
4327 /* Base damage is always something, though it may be
4328 * reduced to zero if the hero is hampered. However,
4329 * since techlev will never be zero, stiking vital
4330 * organs will always do _some_ damage.
4332 tmp
= mtmp
->mhp
> 1 ? mtmp
->mhp
/ 2 : 1;
4333 if (!humanoid(mtmp
->data
) || is_golem(mtmp
->data
) ||
4334 mtmp
->data
->mlet
== S_CENTAUR
) {
4335 You("are hampered by the differences in anatomy.");
4338 tmp
+= techlevX(tech_no
);
4339 t_timeout
= rnz(1500);
4346 You("obviously can't perform that without a weapon.");
4349 if (!is_blade(uwep
)) {
4350 You("need a blade to perform cutthroat!");
4353 if (!getdir((char *)0)) return 0;
4354 if (!u
.dx
&& !u
.dy
) {
4355 /* Hopefully a mistake ;B */
4356 pline("Things may be going badly, but that's extreme.");
4359 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
4360 pline("Invalid target location.");
4363 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
4365 You("attack...nothing!");
4366 t_timeout
= rnz(6000);
4368 int oldhp
= mtmp
->mhp
;
4370 if (!attack(mtmp
)) return 0;
4371 if (!DEADMONSTER(mtmp
) && mtmp
->mhp
< oldhp
) {
4372 if (!has_head(mtmp
->data
) || u
.uswallow
)
4373 You_cant("perform cutthroat on %s!", mon_nam(mtmp
));
4376 int severlevel
= techlevX(tech_no
) * 2;
4377 if (severlevel
< 1) severlevel
= 1; /* fail safe */
4379 if ((rn2(8) < (techlevX(tech_no
)/10 + 1)) && (mtmp
->m_lev
<= rnd(severlevel
)) ) {
4380 You("sever %s head!", s_suffix(mon_nam(mtmp
)));
4383 You("hurt %s badly!", s_suffix(mon_nam(mtmp
)));
4384 tmp
= mtmp
->mhp
/ 2;
4386 tmp
+= techlevX(tech_no
);
4387 t_timeout
= rnz(6000);
4394 allowall
[0] = ALL_CLASSES
; allowall
[1] = '\0';
4396 if (CannotSelectItemsInPrompts
) break;
4397 if ( !(obj
= getobj(allowall
, "bless"))) return(0);
4398 pline("An aura of holiness surrounds your hands!");
4399 if (!Blind
) (void) Shk_Your(Your_buf
, obj
);
4402 pline("%s %s %s.",Your_buf
,
4403 aobjnam(obj
, "softly glow"),
4405 if (!stack_too_big(obj
)) uncurse(obj
, FALSE
);
4406 else pline("But it failed! The stack was too big...");
4408 } else if(!obj
->blessed
) {
4410 str
= hcolor(NH_LIGHT_BLUE
);
4411 pline("%s %s with a%s %s aura.",
4413 aobjnam(obj
, "softly glow"),
4414 index(vowels
, *str
) ? "n" : "", str
);
4416 if (!stack_too_big(obj
)) bless(obj
);
4417 else pline("But it failed! The stack was too big...");
4421 pline ("That object is already blessed!");
4425 pline("The aura fades.");
4427 t_timeout
= rnz(7500);
4428 if (uarmc
&& uarmc
->oartifact
== ART_PRIESTEST_BLESS
) t_timeout
= rnz(6000);
4433 str
= makeplural(body_part(HAND
));
4434 You("focus the powers of the elements into your %s", str
);
4435 techt_inuse(tech_no
) = rnd((int) (techlevX(tech_no
)/3 + 1)) + d(1,4) + 2;
4437 t_timeout
= rnz(1500);
4440 You("let out a bloodcurdling roar!");
4443 techt_inuse(tech_no
) = d(2,6) + (techlevX(tech_no
) * rnd(4)) + 2;
4445 incr_itimeout(&HFast
, techt_inuse(tech_no
));
4447 for(i
= -5; i
<= 5; i
++) for(j
= -5; j
<= 5; j
++)
4448 if(isok(u
.ux
+i
, u
.uy
+j
) && (mtmp
= m_at(u
.ux
+i
, u
.uy
+j
))) {
4449 if (mtmp
->mtame
!= 0 && !mtmp
->isspell
) {
4450 struct permonst
*ptr
= mtmp
->data
;
4451 struct monst
*mtmp2
;
4452 int ttime
= techt_inuse(tech_no
);
4453 int type
= little_to_big(monsndx(ptr
));
4455 mtmp2
= tamedog(mtmp
, (struct obj
*) 0, TRUE
);
4459 if (type
&& type
!= monsndx(ptr
)) {
4461 mon_spec_poly(mtmp
, ptr
, ttime
, FALSE
,
4462 canseemon(mtmp
), FALSE
, TRUE
);
4466 t_timeout
= rnz(1500);
4468 case T_LIQUID_LEAP
: {
4470 int dx
, dy
, sx
, sy
, range
;
4472 pline("Where do you want to leap to?");
4476 getpos(&cc
, TRUE
, "the desired position");
4477 if (cc
.x
== -10) return 0; /* user pressed esc */
4481 /* allow diagonals */
4482 if (dx
&& dy
&& dx
!= dy
&& dx
!= -dy
) {
4483 You("can only leap in straight lines!");
4485 } else if (distu(cc
.x
, cc
.y
) > 19 + techlevX(tech_no
)) {
4488 } else if (m_at(cc
.x
, cc
.y
) || !isok(cc
.x
, cc
.y
) ||
4489 IS_ROCK(levl
[cc
.x
][cc
.y
].typ
) ||
4490 sobj_at(BOULDER
, cc
.x
, cc
.y
) ||
4491 closed_door(cc
.x
, cc
.y
)) {
4492 You_cant("flow there!"); /* MAR */
4496 if (Stoned
) fix_petrification(); /* basically, you become an acid beam, and while I have absolutely no idea why acid would fix petrification in the first place, at least I'll make it consistent throughout the game. --Amy */
4497 if (Punished
&& !u
.repunishcounter
) {
4498 You("slip out of the iron chain.");
4502 switch(u
.utraptype
) {
4504 You("slide out of the bear trap.");
4507 You("leap from the pit!");
4510 You("flow through the web!");
4513 You("get rid of the sticky glue!");
4516 You("separate from the lava!");
4521 You("ooze out of the floor!");
4525 /* Fry the things in the path ;B */
4528 if (range
< 0) range
= -range
;
4533 while (range
-- > 0) {
4536 if (!Invulnerable
) Invulnerable
= tmp_invul
= 1;
4538 tmp_at(DISP_BEAM
, zapdir_to_glyph(dx
, dy
, AD_ACID
-1));
4540 delay_output(); /* wait a little */
4541 if ((mtmp
= m_at(sx
, sy
)) != 0) {
4545 if (!chance
|| (3 - chance
) > AC_VALUE(find_mac(mtmp
)))
4548 You("catch %s in your acid trail!", mon_nam(mtmp
));
4549 if (!resists_acid(mtmp
) || player_will_pierce_resistance()) {
4551 /* Need to add a to-hit */
4553 tmp
+= rn2((int) (techlevX(tech_no
) + 1));
4554 if (!Blind
) pline_The("acid burns %s!", mon_nam(mtmp
));
4556 } else if (!Blind
) pline_The("acid doesn't affect %s!", mon_nam(mtmp
));
4560 if (tmp_invul
) Invulnerable
= 0;
4563 /* A little Sokoban guilt... */
4564 if (In_sokoban(&u
.uz
) && !playercancheatinsoko()) {
4566 pline("You cheater!");
4567 if (evilfriday
) u
.ugangr
++;
4570 teleds(cc
.x
, cc
.y
, FALSE
);
4571 nomul(-1, "liquid leaping", TRUE
);
4574 t_timeout
= rnz(1500);
4577 case T_SIGIL_TEMPEST
:
4578 /* Have enough power? */
4579 num
= 50 - techlevX(tech_no
);
4580 if (num
< 10) num
= 10;
4582 You("don't have enough power to invoke the sigil! You need at least %d!",num
);
4588 You("invoke the sigil of tempest!");
4589 techt_inuse(tech_no
) = d(1,6) + rnd(techlevX(tech_no
)/2 + 1) + 2;
4591 t_timeout
= rnz(50);
4594 case T_SIGIL_CONTROL
:
4595 /* Have enough power? */
4596 num
= 30 - techlevX(tech_no
)/2;
4597 if (num
< 10) num
= 10;
4599 You("don't have enough power to invoke the sigil! You need at least %d!",num
);
4605 You("invoke the sigil of control!");
4606 techt_inuse(tech_no
) = d(1,4) + rnd(techlevX(tech_no
)/2 + 1) + 2;
4608 t_timeout
= rnz(50);
4611 case T_SIGIL_DISCHARGE
:
4612 /* Have enough power? */
4613 num
= 100 - techlevX(tech_no
)*2;
4614 if (num
< 10) num
= 10;
4616 You("don't have enough power to invoke the sigil! You need at least %d!",num
);
4622 You("invoke the sigil of discharge!");
4623 techt_inuse(tech_no
) = d(1,4) + rnd(techlevX(tech_no
)/2 + 1) + 2;
4625 t_timeout
= rnz(50);
4628 case T_RAISE_ZOMBIES
:
4629 You("chant the ancient curse...");
4630 for(i
= -1; i
<= 1; i
++) for(j
= -1; j
<= 1; j
++) {
4633 if (!isok(u
.ux
+i
, u
.uy
+j
)) continue;
4634 for (obj
= level
.objects
[u
.ux
+i
][u
.uy
+j
]; obj
; obj
= otmp
) {
4635 otmp
= obj
->nexthere
;
4637 if (obj
->otyp
!= CORPSE
) continue;
4638 /* Only generate undead */
4639 corpsenm
= mon_to_zombie(obj
->corpsenm
);
4640 if (corpsenm
!= -1 && !cant_create(&corpsenm
, TRUE
) &&
4641 (!obj
->oxlth
|| obj
->oattached
!= OATTACHED_MONST
)) {
4642 /* Maintain approx. proportion of oeaten to cnutrit
4643 * so that the zombie's HP relate roughly to how
4644 * much of the original corpse was left.
4648 eaten_stat(mons
[corpsenm
].cnutrit
, obj
);
4649 obj
->corpsenm
= corpsenm
;
4652 if (!resist(mtmp
, SPBOOK_CLASS
, 0, TELL
) || ((rnd(30 - ACURR(A_CHA
))) < 4) ) {
4653 mtmp
= tamedog(mtmp
, (struct obj
*) 0, FALSE
);
4654 You("dominate %s!", mon_nam(mtmp
));
4655 } else setmangry(mtmp
);
4660 nomul(-2, "recovering from an attempt to raise zombies", TRUE
); /* You need to recover */
4662 t_timeout
= rnz(1500);
4666 if (CannotSelectItemsInPrompts
) break;
4668 You("%s", no_elbow_room
);
4671 num
= 100 - techlevX(tech_no
); /* WAC make this depend on mon? */
4672 if (num
< 25) num
= 25;
4673 if ((Upolyd
&& u
.mh
<= num
) || (!Upolyd
&& u
.uhp
<= num
)){
4674 You("don't have the strength to perform revivification!");
4678 obj
= getobj((const char *)revivables
, "revive");
4679 if (!obj
) return (0);
4682 if (Is_blackmarket(&u
.uz
))
4686 make_happy_shk(mtmp
, FALSE
);
4687 else if (!resist(mtmp
, SPBOOK_CLASS
, 0, NOTELL
) || (((rnd(30 - ACURR(A_CHA
))) < 4) && !resist(mtmp
, SPBOOK_CLASS
, 0, TELL
) ) || (((rnd(30 - ACURR(A_CHA
))) < 4) && !resist(mtmp
, SPBOOK_CLASS
, 0, TELL
) ) )
4688 (void) tamedog(mtmp
, (struct obj
*) 0, FALSE
);
4690 if (Upolyd
) u
.mh
-= num
;
4692 t_timeout
= rnz(5000);
4695 /* Already have it intrinsically? */
4696 if (HFire_resistance
& FROMOUTSIDE
) {
4697 You("are already fire resistant.");
4701 You("invoke the ward against flame!");
4702 HFire_resistance
+= rn1(100,50);
4703 HFire_resistance
+= techlevX(tech_no
);
4704 t_timeout
= rnz(1500);
4708 /* Already have it intrinsically? */
4709 if (HCold_resistance
& FROMOUTSIDE
) {
4710 You("are already cold resistant.");
4714 You("invoke the ward against ice!");
4715 HCold_resistance
+= rn1(100,50);
4716 HCold_resistance
+= techlevX(tech_no
);
4717 t_timeout
= rnz(1500);
4721 /* Already have it intrinsically? */
4722 if (HShock_resistance
& FROMOUTSIDE
) {
4723 You("are already shock resistant.");
4727 You("invoke the ward against lightning!");
4728 HShock_resistance
+= rn1(100,50);
4729 HShock_resistance
+= techlevX(tech_no
);
4730 t_timeout
= rnz(1500);
4735 You("can't do any tinkering if you can't see!");
4739 You("aren't holding an object to work on!");
4742 You("are holding %s.", doname(uwep
));
4743 if (yn("Start tinkering on this?") != 'y') return(0);
4744 You("start working on %s",doname(uwep
));
4745 delay
= -150 + techlevX(tech_no
);
4746 if (delay
> -100) delay
= -100;
4747 set_occupation(tinker
, "tinkering", 0);
4748 t_timeout
= rnz(200);
4752 You("cannot focus your anger!");
4755 You_feel("the anger inside you erupt!");
4756 num
= 50 + (4 * techlevX(tech_no
));
4757 techt_inuse(tech_no
) = num
+ 1;
4764 t_timeout
= rnz(5000);
4767 You_feel("the flow of time slow down.");
4768 techt_inuse(tech_no
) = rnd(techlevX(tech_no
) + 1) + 2;
4769 t_timeout
= rnz(1500);
4772 if (!blitz_chi_strike()) return(0);
4773 t_timeout
= rnz(1500);
4776 if (u
.uen
== u
.uenmax
) {
4777 if (Hallucination
) You("are fully charged!");
4778 else You("cannot hold any more energy!");
4781 You("begin drawing energy from your surroundings!");
4783 set_occupation(draw_energy
, "drawing energy", 0);
4784 t_timeout
= rnz(1500);
4788 You("are too weak to attempt this! You need at least one point of mana!");
4791 You("direct your internal energy to restoring your body!");
4792 techt_inuse(tech_no
) = techlevX(tech_no
)*10 + 4;
4793 t_timeout
= rnz(1500);
4797 You("aren't wielding a weapon!");
4801 if (P_SKILL(weapon_type(uwep
)) == P_NONE
) {
4802 You("aren't wielding a proper weapon!");
4805 if ((P_SKILL(weapon_type(uwep
)) < P_SKILLED
) || PlayerCannotUseSkills
|| (Blind
)) {
4806 You("aren't capable of doing this!");
4810 if (uwep
&& uwep
->spe
< 1) {
4811 Your("weapon isn't strong enough for that!");
4812 /* could be unidentified, in which case we give a timeout --Amy */
4813 if (!(uwep
->known
)) t_timeout
= rnz(500);
4818 pline("What do you think %s is? A sword swallower?",
4823 if (!getdir((char *)0)) return(0);
4824 if (!u
.dx
&& !u
.dy
) {
4825 /* Hopefully a mistake ;B */
4826 pline("Why don't you try wielding something else instead.");
4829 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
4830 pline("Invalid target location.");
4833 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
4834 if (!mtmp
|| !canspotmon(mtmp
)) {
4835 if (memory_is_invisible(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
))
4836 You("don't know where to aim for!");
4838 You("don't see anything there!");
4841 obj
= MON_WEP(mtmp
); /* can be null */
4843 You_cant("disarm an unarmed foe!");
4846 /* Blindness dealt with above */
4847 if (!mon_visible(mtmp
)
4848 || (obj
->oinvis
&& !See_invisible
) || obj
->oinvisreal
4850 You_cant("see %s weapon!", s_suffix(mon_nam(mtmp
)));
4853 num
= ((rn2(techlevX(tech_no
) + 15))
4854 * (P_SKILL(weapon_type(uwep
)) - P_SKILLED
+ 1)) / 10;
4856 if (uarmf
&& uarmf
->oartifact
== ART_CORINA_S_SNOWY_TREAD
) {
4857 if (num
< 0) num
= 0;
4861 You("attempt to disarm %s...",mon_nam(mtmp
));
4862 /* WAC can't yank out cursed items */
4863 if (num
> 0 && (!Fumbling
|| !rn2(10)) && !obj
->cursed
) {
4865 obj_extract_self(obj
);
4866 possibly_unwield(mtmp
, FALSE
);
4867 setmnotwielded(mtmp
, obj
);
4868 roll
= rn2(num
+ 1);
4869 if (roll
> 3) roll
= 3;
4871 if (obj
&& obj
->mstartinventB
&& !(obj
->oartifact
) && !(obj
->fakeartifact
&& timebasedlowerchance()) && (!rn2(4) || (rn2(100) < u
.equipmentremovechance
) || !timebasedlowerchance() ) ) {
4873 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
4875 t_timeout
= rnz(5000);
4878 if (obj
&& obj
->mstartinventC
&& !(obj
->oartifact
) && !(obj
->fakeartifact
&& !rn2(10)) && rn2(10) ) {
4880 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
4882 t_timeout
= rnz(5000);
4886 if (obj
&& obj
->mstartinventE
&& !(obj
->oartifact
) && !(obj
->fakeartifact
&& !rn2(20)) && rn2(20) ) {
4888 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
4890 t_timeout
= rnz(5000);
4894 if (obj
&& obj
->mstartinventD
&& !(obj
->oartifact
) && !(obj
->fakeartifact
&& !rn2(4)) && rn2(4) ) {
4896 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
4898 t_timeout
= rnz(5000);
4902 if (obj
&& obj
->mstartinventX
) {
4904 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
4906 t_timeout
= rnz(5000);
4913 /* to floor near you */
4914 You("knock %s %s to the %s!",
4915 s_suffix(mon_nam(mtmp
)), xname(obj
), surface(u
.ux
, u
.uy
));
4916 if (obj
->otyp
== CRYSKNIFE
&&
4917 (!obj
->oerodeproof
|| !rn2(10))) {
4918 obj
->otyp
= WORM_TOOTH
;
4919 obj
->oerodeproof
= 0;
4922 place_object(obj
, u
.ux
, u
.uy
);
4926 /* right into your inventory */
4928 You("snatch %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
4929 if (obj
->otyp
== CORPSE
&&
4930 touch_petrifies(&mons
[obj
->corpsenm
]) &&
4931 (!uarmg
|| FingerlessGloves
) && (!Stone_resistance
|| (!IntStone_resistance
&& !rn2(20)) ) &&
4932 !(poly_when_stoned(youmonst
.data
) &&
4933 polymon(PM_STONE_GOLEM
))) {
4934 static char kbuf
[BUFSZ
];
4936 sprintf(kbuf
, "snatching a petrifying corpse");
4937 pline("Snatching this type of corpse is a fatal mistake.");
4940 obj
= hold_another_object(obj
, "You drop %s!",
4941 doname(obj
), (const char *)0);
4944 } else if (mtmp
->mcanmove
&& !mtmp
->msleeping
)
4945 pline("%s evades your attack.", Monnam(mtmp
));
4947 You("fail to dislodge %s %s.", s_suffix(mon_nam(mtmp
)), xname(obj
));
4949 if (!mtmp
->mcanmove
&& !rn2(10)) {
4954 t_timeout
= rnz(5000);
4957 /* Short range stun attack */
4959 You("can't see anything!");
4962 if (!getdir((char *)0)) return(0);
4963 if (!u
.dx
&& !u
.dy
) {
4964 /* Hopefully a mistake ;B */
4965 You("can't see yourself!");
4968 for(i
= 0; (i
<= ((techlevX(tech_no
) / 8) + 1)
4969 && isok(u
.ux
+ (i
*u
.dx
), u
.uy
+ (i
*u
.dy
))); i
++) {
4970 mtmp
= m_at(u
.ux
+ (i
*u
.dx
), u
.uy
+ (i
*u
.dy
));
4971 if (mtmp
&& canseemon(mtmp
)) break;
4973 if (!mtmp
|| !canseemon(mtmp
)) {
4974 You("fail to make eye contact with anything!");
4975 /* regular SLASH'EM would allow you to scan for the presence of monsters until there is one...
4976 * But this isn't regular SLASH'EM. If you use the technique, you get a timeout, period. --Amy */
4977 t_timeout
= rnz(75);
4980 You("stare at %s.", mon_nam(mtmp
));
4981 if (!haseyes(mtmp
->data
))
4982 pline("..but %s has no eyes!", mon_nam(mtmp
));
4983 else if (!mtmp
->mcansee
)
4984 pline("..but %s cannot see you!", mon_nam(mtmp
));
4985 else if ((rn2(6) + rn2(6) + (techlevX(tech_no
) - mtmp
->m_lev
)) > rnd(10)) {
4987 if (!rn2(10)) goto breakstare
;
4988 if (mtmp
->mfrenzied
&& !rn2(5)) goto breakstare
;
4990 You("dazzle %s!", mon_nam(mtmp
));
4992 mtmp
->mfrozen
= rnd(10);
4995 pline("%s breaks the stare!", Monnam(mtmp
));
4996 if (!mtmp
->mtame
&& !mtmp
->mpeaceful
&& !mtmp
->mfrenzied
&& !rn2(5)) {
4997 mtmp
->mfrenzied
= 1;
4998 pline("Now %s is really angry at you.", mon_nam(mtmp
));
5001 t_timeout
= rnz(750);
5004 if (!canuseunarmedtechs()) {
5005 You("can't do this while wielding a weapon!");
5006 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5009 You("can't do this while holding a shield!");
5010 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5013 if (!doblitz()) return (0);
5015 u
.comboactive
= FALSE
;
5016 t_timeout
= rnz(5000);
5019 if (!canuseunarmedtechs()) {
5020 You("can't do this while wielding a weapon!");
5021 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5024 You("can't do this while holding a shield!");
5025 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5028 if (!getdir((char *)0)) return(0);
5029 if (!u
.dx
&& !u
.dy
) {
5030 You("flex your muscles.");
5033 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
5034 pline("Invalid target location.");
5037 if (!blitz_pummel()) return(0);
5038 t_timeout
= rnz(2000);
5041 if (!canuseunarmedtechs()) {
5042 You("can't do this while wielding a weapon!");
5043 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5046 You("can't do this while holding a shield!");
5047 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5050 if (!getdir((char *)0)) return(0);
5051 if (!u
.dx
&& !u
.dy
) {
5052 You("flex your muscles.");
5055 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
5056 pline("Invalid target location.");
5059 if (!blitz_g_slam()) return(0);
5060 t_timeout
= rnz(1500);
5063 if (!getdir((char *)0)) return(0);
5064 if (!u
.dx
&& !u
.dy
) {
5068 if (!blitz_dash()) return(0);
5069 t_timeout
= rnz(500);
5072 if (!blitz_power_surge()) return(0);
5073 t_timeout
= rnz(issoviet
? 1500 : 5000);
5074 if (issoviet
) pline("Sovetskaya nichego ne znayet o balansirovaniya ne ponimayet i poetomu khochet etu tekhniku, kotoraya uzhe slishkom sil'na, chtoby byt' yeshche sil'neye.");
5077 if (!canuseunarmedtechs()) {
5078 You("can't do this while wielding a weapon!");
5079 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5082 You("can't do this while holding a shield!");
5083 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5086 if (!getdir((char *)0)) return(0);
5087 if (!blitz_spirit_bomb()) return(0);
5088 t_timeout
= rnz(1500);
5091 /*if (!maybe_polyd(is_vampire(youmonst.data),
5092 Race_if(PM_VAMPIRE)) && !Race_if(PM_UNGENOMOLD) ) {*/
5094 * Otherwise we get problems with what we create:
5095 * potions of vampire blood would no longer be
5097 * Note by Amy: Ungenomolds will be able to use this anyway. They may polymorph into a vampire,
5098 * which would make the potions useful for them. Even if they don't, they can still dilute them.
5099 * another note by Amy: who cares? If they can't use it in their current form, too bad. It's still
5100 * better than simply disabling the tech altogether.
5102 /*You("must be in your natural form to draw blood.");
5105 obj
= use_medical_kit(PHIAL
, TRUE
, "draw blood with");
5108 if (u
.ulevel
<= 1) {
5109 You_cant("seem to find a vein.");
5116 obj_extract_self(obj
);
5117 obfree(obj
, (struct obj
*)0);
5120 use_skill(P_DEVICES
,1);
5121 if (Race_if(PM_FAWN
)) {
5122 use_skill(P_DEVICES
,1);
5124 if (Race_if(PM_SATRE
)) {
5125 use_skill(P_DEVICES
,1);
5126 use_skill(P_DEVICES
,1);
5129 pline("Using your medical kit, you draw off a phial of your blood.");
5130 /* Amy edit: let's make this much more useful by having the level drain only occur 1 out of 3 times. */
5131 if (!rn2(3)) {losexp("drawing blood", TRUE
, FALSE
);
5133 u
.uexp
= newuexp(u
.ulevel
- 1);
5135 otmp
= mksobj(POT_VAMPIRE_BLOOD
, FALSE
, FALSE
, FALSE
);
5137 otmp
->cursed
= obj
->cursed
;
5138 otmp
->blessed
= obj
->blessed
;
5139 (void) hold_another_object(otmp
,
5140 "You fill, but have to drop, %s!", doname(otmp
),
5143 t_timeout
= rnz(1500);
5147 You("can't channel the force around you. Jedi jumps require 25 points of mana!");
5148 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
5151 if (!jump((techlevX(tech_no
)/5)+1)) return 0;
5153 t_timeout
= rnz(500);
5158 You("don't have enough free space to throw the ball!");
5162 int i
, j
, caught
, catchrate
;
5164 register struct monst
*mtmp2
;
5166 pline("%s used Poke Ball!", playeraliasname
);
5168 for (i
= -1; i
<= 1; i
++) for(j
= -1; j
<= 1; j
++) {
5169 if (!isok(u
.ux
+ i
, u
.uy
+ j
)) continue;
5170 if ( ((mtmp
= m_at(u
.ux
+ i
, u
.uy
+ j
)) != 0) && mtmp
->mtame
== 0
5171 && mtmp
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp
->data
->geno
& G_UNIQ
) && caught
== 0)
5173 /* using the M3_PETTY attribute now --Amy */
5177 if (is_petty(mtmp
->data
) || mtmp
->egotype_petty
)
5180 /*maybe_tameX(mtmp);*/
5181 pline("Gotcha! %s was caught!", mon_nam(mtmp
));
5182 (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
5184 t_timeout
= rnz(3000);
5187 else if ( (mtmp
->m_lev
> (2 * techlevX(tech_no
)) || rn2(4) ) && mtmp
->m_lev
> techlevX(tech_no
) && caught
== 0 && ( (!is_pokemon(mtmp
->data
) && (!mtmp
->egotype_pokemon
) ) || rn2(2) ) )
5189 pline("You missed the Pokemon!");
5192 else if (caught
== 0) /* other monster that can be caught */
5195 /* If catchrate is a higher numeric value, the chance of catching the monster is lower. */
5197 catchrate
= (60 + mtmp
->m_lev
- techlevX(tech_no
));
5198 if (!rn2(4)) catchrate
-= ACURR(A_CHA
);
5199 if (!rn2(4)) catchrate
-= techlevX(tech_no
);
5200 if (is_pokemon(mtmp
->data
) || mtmp
->egotype_pokemon
) catchrate
= (catchrate
/ 2);
5201 if (catchrate
< 3) catchrate
= 3;
5202 if (rnd(100) < catchrate
) pline("Oh, no! The Pokemon broke free!");
5203 else if (rnd(100) < catchrate
) pline("Aww! It appeared to be caught!");
5204 else if (rnd(100) < catchrate
) pline("Arrgh! Almost had it!");
5205 else if (rnd(100) < catchrate
) pline("Shit! It was so close too!");
5207 /*maybe_tameX(mtmp);*/
5208 pline("Gotcha! %s was caught!", mon_nam(mtmp
));
5209 (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
5211 t_timeout
= rnz(3000);
5216 } /* monster is catchable loop */
5219 if (caught
== 0) pline("The ball expodes in midair!");
5220 /* This is an intentional typo, derived from another roguelike. Do you know which one it is? --Amy*/
5222 t_timeout
= rnz(3000);
5224 case T_SUMMON_TEAM_ANT
:
5227 int maxchance
= techlevX(tech_no
);
5228 if (maxchance
> 50) maxchance
= 50;
5229 pline("Go Team Ant!");
5234 while (caughtY
== 0) {
5235 /*mtmp = make_helper(S_ANT, u.ux, u.uy); */
5236 mtmp
= makemon(mkclass(S_ANT
,0), u
.ux
, u
.uy
, NO_MM_FLAGS
);
5238 /*mtmp->mtame = 10;*/
5239 /*maybe_tameX(mtmp);*/
5240 (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
5241 if (maxchance
< rnd(75)) caughtY
++;
5244 /* A high level Insectoid character can create quite the army of insects sometimes. --Amy */
5248 t_timeout
= rnz(5000);
5251 case T_DOUBLE_TROUBLE
: /* inspired by Khor */
5254 int maxchance
= techlevX(tech_no
);
5255 if (maxchance
> 45) maxchance
= 45;
5257 pline("Double Trouble...");
5262 if (!rn2(5)) mtmp
= makemon(&mons
[urace
.malenum
], u
.ux
, u
.uy
, NO_MM_FLAGS
);
5263 else if (Upolyd
) mtmp
= makemon(&mons
[u
.umonnum
], u
.ux
, u
.uy
, NO_MM_FLAGS
);
5264 else mtmp
= makemon(&mons
[urole
.malenum
], u
.ux
, u
.uy
, NO_MM_FLAGS
);
5265 if (mtmp
) (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
5267 if ((techlevX(tech_no
)) < rnd(50)) familiardone
= 1;
5268 else pline("Sent in some familiars too.");
5270 while (familiardone
== 0) {
5272 mtmp
= makemon((struct permonst
*)0, u
.ux
, u
.uy
, NO_MM_FLAGS
);
5273 if (mtmp
) (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
5275 if (maxchance
< rnd(50)) familiardone
= 1;
5280 t_timeout
= rnz(10000);
5283 case T_ATTIRE_CHARM
:
5286 pline("The monster can't see its inside anyway!");
5290 if (!PlayerInHighHeels
) {
5291 pline("You must be wearing high heels for that.");
5296 struct monst
*mtmp3
;
5298 pline("You strike a sexy pose with your heels!");
5299 if (uarmf
&& uarmf
->oartifact
== ART_PRECURSOR_TO_THE___
) adjattrib(A_CHA
, 1, -1, TRUE
);
5301 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
5302 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
5303 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !is_infrastructure_monster(mtmp3
) && mtmp3
->mtame
== 0 && mtmp3
->isminion
== 0 && mtmp3
->isgyp
== 0
5304 && mtmp3
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp3
->data
->geno
& G_UNIQ
) && caughtX
== 0)
5306 /* gotta write a huge function for this now --Amy */
5310 if ( humanoid(mtmp3
->data
) || mtmp3
->data
->mlet
== S_HUMAN
) {
5311 /*maybe_tameX(mtmp3);*/
5312 pline("%s is charmed, and wants to be your friend!", mon_nam(mtmp3
));
5313 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
5314 if (techlevX(tech_no
) < rnd(100)) caughtX
++;
5315 t_timeout
= rnz(5000);
5318 else pline("%s is too stupid to fully appreciate you!", mon_nam(mtmp3
));
5320 } /* monster is catchable loop */
5323 /* signature technique of some roles, but too OP for others --Amy */
5324 if (Role_if(PM_TRANSVESTITE
) || Role_if(PM_TOPMODEL
) || Role_if(PM_TRANSSYLVANIAN
) || Role_if(PM_FAILED_EXISTENCE
)) t_timeout
= rnz(5000);
5325 else t_timeout
= rnz(25000);
5330 You("scream \"EYGOORTS-TOGAAL, JEZEHH!\"");
5331 /* Actually, it's "To win the game you must kill me, John Romero" recorded backwards.
5332 * When I was little, I always thought it said "Eygoorts-togaal, jezehh". --Amy */
5334 int wflvl
= ((techlevX(tech_no
)) / 2);
5335 if (wflvl
< 1) wflvl
= 1;
5337 register struct monst
*mtmp
, *mtmp2
;
5341 for (mtmp
= fmon
; mtmp
; mtmp
= mtmp2
) {
5343 if ( ((mtmp
->m_lev
< wflvl
) || (!rn2(4) && mtmp
->m_lev
< (2 * wflvl
))) && mtmp
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp
->data
->geno
& G_UNIQ
) ) {
5348 pline("Eliminated %d monster%s.", num
, plur(num
));
5351 t_timeout
= rnz(100000);
5357 boolean canbfg
= FALSE
;
5358 boolean canrocket
= FALSE
;
5359 boolean canshotty
= FALSE
;
5360 boolean canblaster
= FALSE
;
5363 ammotype
= 1; /* bullets */
5364 if (Role_if(PM_DOOM_MARINE
)) {
5366 if (techlevX(tech_no
) >= 25) {
5375 else if (techlevX(tech_no
) >= 20) {
5382 else if (techlevX(tech_no
) >= 15) {
5388 else if (techlevX(tech_no
) >= 10) {
5395 if (Role_if(PM_SPACE_MARINE
)) {
5399 if (Race_if(PM_TURMENE
)) {
5403 if (!Role_if(PM_GRENADONIN
)) {
5404 boolean haschosen
= FALSE
;
5405 pline("Pick an ammo type that you want to create. The prompt will loop until you actually make a choice.");
5406 while (!haschosen
) {
5407 if (yn("Do you want to create pistol bullets?") == 'y') {
5411 else if (yn("Do you want to create five-seven bullets?") == 'y') {
5415 else if (yn("Do you want to create SMG bullets?") == 'y') {
5419 else if (yn("Do you want to create rifle bullets?") == 'y') {
5423 else if (yn("Do you want to create sniper bullets?") == 'y') {
5427 else if (yn("Do you want to create MG bullets?") == 'y') {
5431 else if (yn("Do you want to create assault rifle bullets?") == 'y') {
5435 else if (canshotty
&& yn("Do you want to create shotgun shells?") == 'y') {
5439 else if (canshotty
&& yn("Do you want to create auto shotgun shells?") == 'y') {
5443 else if (canrocket
&& yn("Do you want to create rockets?") == 'y') {
5447 else if (canbfg
&& yn("Do you want to create BFG ammo?") == 'y') {
5451 else if (canblaster
&& yn("Do you want to create blaster bolts?") == 'y') {
5455 else if (canblaster
&& yn("Do you want to create heavy blaster bolts?") == 'y') {
5459 else if (canblaster
&& yn("Do you want to create raygun bolts?") == 'y') {
5463 else if (canblaster
&& yn("Do you want to create laser beams?") == 'y') {
5467 else if (canblaster
&& yn("Do you want to create radios?") == 'y') {
5471 else if (canblaster
&& yn("Do you want to create carcosan bolts?") == 'y') {
5479 if (Role_if(PM_GRENADONIN
)) ammotype
= 666; /* grenades */
5481 You("make some ammo for your gun.");
5485 if (ammotype
== 666) uammo
= mksobj(rn2(2) ? GAS_GRENADE
: FRAG_GRENADE
, TRUE
, FALSE
, FALSE
);
5486 else if (ammotype
== 5) uammo
= mksobj(BFG_AMMO
, TRUE
, FALSE
, FALSE
);
5487 else if (ammotype
== 4) uammo
= mksobj(ROCKET
, TRUE
, FALSE
, FALSE
);
5488 else if (ammotype
== 3) uammo
= mksobj(SHOTGUN_SHELL
, TRUE
, FALSE
, FALSE
);
5489 else if (ammotype
== 2) uammo
= mksobj(BLASTER_BOLT
, TRUE
, FALSE
, FALSE
);
5490 else if (ammotype
== 6) uammo
= mksobj(SMG_BULLET
, TRUE
, FALSE
, FALSE
);
5491 else if (ammotype
== 7) uammo
= mksobj(RIFLE_BULLET
, TRUE
, FALSE
, FALSE
);
5492 else if (ammotype
== 8) uammo
= mksobj(SNIPER_BULLET
, TRUE
, FALSE
, FALSE
);
5493 else if (ammotype
== 9) uammo
= mksobj(MG_BULLET
, TRUE
, FALSE
, FALSE
);
5494 else if (ammotype
== 10) uammo
= mksobj(ASSAULT_RIFLE_BULLET
, TRUE
, FALSE
, FALSE
);
5495 else if (ammotype
== 11) uammo
= mksobj(AUTO_SHOTGUN_SHELL
, TRUE
, FALSE
, FALSE
);
5496 else if (ammotype
== 12) uammo
= mksobj(HEAVY_BLASTER_BOLT
, TRUE
, FALSE
, FALSE
);
5497 else if (ammotype
== 13) uammo
= mksobj(RAYGUN_BOLT
, TRUE
, FALSE
, FALSE
);
5498 else if (ammotype
== 14) uammo
= mksobj(LASER_BEAM
, TRUE
, FALSE
, FALSE
);
5499 else if (ammotype
== 15) uammo
= mksobj(RADIO
, TRUE
, FALSE
, FALSE
);
5500 else if (ammotype
== 16) uammo
= mksobj(FIVE_SEVEN_BULLET
, TRUE
, FALSE
, FALSE
);
5501 else if (ammotype
== 17) uammo
= mksobj(CARCOSAN_BOLT
, TRUE
, FALSE
, FALSE
);
5502 else uammo
= mksobj(PISTOL_BULLET
, TRUE
, FALSE
, FALSE
);
5504 uammo
->quan
= techlevX(tech_no
);
5505 /* gunner really specializes in ranged weapons, so needs a big bonus --Amy */
5506 if (Role_if(PM_GUNNER
)) uammo
->quan
*= 1 + rnd(2);
5507 if (uarmf
&& uarmf
->oartifact
== ART_ZERDROY_GUNNING
) {
5509 if (uarmf
) curse(uarmf
);
5511 if (uammo
&& ammotype
== 1 && uarmh
&& uarmh
->oartifact
== ART_TURKISH_EMPIRE
) uammo
->quan
*= 2;
5512 if (uammo
&& ammotype
== 6 && uarmh
&& uarmh
->oartifact
== ART_TURKISH_EMPIRE
) uammo
->quan
*= 2;
5513 if (uammo
&& ammotype
== 7 && uarmh
&& uarmh
->oartifact
== ART_TURKISH_EMPIRE
) uammo
->quan
*= 2;
5514 if (uammo
&& ammotype
== 8 && uarmh
&& uarmh
->oartifact
== ART_TURKISH_EMPIRE
) uammo
->quan
*= 2;
5515 if (uammo
&& ammotype
== 9 && uarmh
&& uarmh
->oartifact
== ART_TURKISH_EMPIRE
) uammo
->quan
*= 2;
5516 if (uammo
&& ammotype
== 10 && uarmh
&& uarmh
->oartifact
== ART_TURKISH_EMPIRE
) uammo
->quan
*= 2;
5517 if (uammo
&& ammotype
== 16 && uarmh
&& uarmh
->oartifact
== ART_TURKISH_EMPIRE
) uammo
->quan
*= 2;
5518 if (uarmc
&& uarmc
->oartifact
== ART_ARABELLA_S_WEAPON_STORAGE
) uammo
->quan
*= 2;
5519 if (ammotype
== 5) uammo
->quan
*= 4;
5520 if (ammotype
== 4) uammo
->quan
/= 10;
5521 if (uammo
->quan
< 0) uammo
->quan
= 1; /* fail safe */
5522 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
5523 uammo
->owt
= weight(uammo
);
5528 if (Role_if(PM_GRENADONIN
) && u
.ulevel
>= 10) {
5530 if (!u
.grenadoninlauncher
&& !rn2(5)) {
5531 u
.grenadoninlauncher
= TRUE
;
5532 uammo
= mksobj(GRENADE_LAUNCHER
, TRUE
, FALSE
, FALSE
);
5534 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
5537 pline("There's your grenade launcher!");
5542 uammo
= mksobj(STICK_OF_DYNAMITE
, TRUE
, FALSE
, FALSE
);
5544 uammo
->quan
= techlevX(tech_no
) - 9;
5545 if (uammo
->quan
< 1) uammo
->quan
= 1;
5546 if (uarmc
&& uarmc
->oartifact
== ART_ARABELLA_S_WEAPON_STORAGE
) uammo
->quan
*= 2;
5548 if (uammo
->quan
< 1) uammo
->quan
= 1; /* fail safe */
5549 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
5550 uammo
->owt
= weight(uammo
);
5559 if (uarmh
&& uarmh
->oartifact
== ART_TURKISH_EMPIRE
) {
5560 uammo
= mksobj(ROCKET
, TRUE
, FALSE
, FALSE
);
5562 uammo
->quan
= techlevX(tech_no
);
5563 if (uarmc
&& uarmc
->oartifact
== ART_ARABELLA_S_WEAPON_STORAGE
) uammo
->quan
*= 2;
5565 if (uammo
->quan
< 1) uammo
->quan
= 1; /* fail safe */
5566 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
5567 uammo
->owt
= weight(uammo
);
5574 if (Role_if(PM_DOOM_MARINE
) || Role_if(PM_GUNNER
)) t_timeout
= rnz(500);
5575 else t_timeout
= rnz(2500);
5582 You("create some stoning grenades.");
5588 while (caughtZ
== 0) {
5590 uegg
= mksobj(EGG
, FALSE
, FALSE
, FALSE
);
5594 uegg
->owt
= weight(uegg
);
5595 uegg
->corpsenm
= egg_type_from_parent(PM_COCKATRICE
, FALSE
);
5596 uegg
->known
= uegg
->dknown
= 1;
5597 attach_egg_hatch_timeout(uegg
);
5598 kill_egg(uegg
); /* make sure they're stale --Amy */
5602 if (techlevX(tech_no
) < rnd(500)) caughtZ
++;
5606 t_timeout
= rnz(10000);
5612 int maxchance
= techlevX(tech_no
);
5613 if (maxchance
> 50) maxchance
= 50;
5615 You("procure some refreshing drinks.");
5617 make_confused(HConfusion
+ d(3,8), FALSE
);
5618 healup(Role_if(PM_DRUNK
) ? rnz(20 + u
.ulevel
) : 1, 0, FALSE
, FALSE
);
5620 if (Race_if(PM_CLOCKWORK_AUTOMATON
)) u
.uhunger
+= 200;
5621 if (Race_if(PM_RUSMOT
)) u
.uhunger
+= 100;
5622 if (Role_if(PM_DRUNK
)) u
.uhunger
+= 100;
5624 exercise(A_WIS
, FALSE
);
5630 while (caughtW
== 0) {
5632 udrink
= mksobj(POT_BOOZE
, TRUE
, FALSE
, FALSE
);
5634 udrink
->known
= udrink
->dknown
= 1;
5635 udrink
->finalcancel
= 1; /* goddamn it, these aren't supposed to be free holy water... */
5639 if (maxchance
< rnd(75)) caughtW
++;
5640 if (!rn2(10) && caughtW
> 0) caughtW
= 0;
5646 t_timeout
= rnz(2000);
5650 num
= 9 + techlevX(tech_no
);
5651 techt_inuse(tech_no
) = num
+ 1;
5652 pline("Your skin becomes harder.");
5654 t_timeout
= rnz(2000);
5659 pline("You feel polyform.");
5660 techt_inuse(tech_no
) = 1;
5662 techt_inuse(tech_no
) = 0;
5663 t_timeout
= rnz(10000);
5666 case T_CONCENTRATING
:
5667 num
= 1 + (techlevX(tech_no
) / 2);
5668 techt_inuse(tech_no
) = num
+ 1;
5670 pline("You start concentrating.");
5671 t_timeout
= rnz(2500);
5675 pline("You summon a pet.");
5677 if (Role_if(PM_BUTT_LOVER
)) {
5678 register struct monst
*buttpet
;
5680 struct permonst
*pm
= 0;
5687 if (attempts
&& (attempts
% 10000 == 0)) u
.mondiffhack
++;
5688 if (!rn2(2000)) reset_rndmonst(NON_PM
);
5690 } while ( (!pm
|| (pm
&& !(pm
->msound
== MS_FART_NORMAL
) && !(pm
->msound
== MS_FART_LOUD
) && !(pm
->msound
== MS_FART_QUIET
))) && attempts
< 50000);
5692 if (!pm
&& rn2(50) ) {
5696 if (pm
&& !(pm
->msound
== MS_FART_NORMAL
) && !(pm
->msound
== MS_FART_LOUD
) && !(pm
->msound
== MS_FART_QUIET
) && rn2(50) ) {
5701 if (pm
) (buttpet
= makemon(pm
, u
.ux
, u
.uy
, NO_MM_FLAGS
));
5704 tamedog(buttpet
, (struct obj
*) 0, TRUE
);
5705 pline("Suddenly, you gain a new sexy pet!");
5711 (void) make_familiar((struct obj
*)0, u
.ux
, u
.uy
, FALSE
, FALSE
);
5714 t_timeout
= rnz(10000);
5717 case T_DOUBLE_THROWNAGE
:
5719 Your("%s %s become blurs as they reach for your throwing weapons!", uarmg
? "gloved" : "bare", makeplural(body_part(HAND
)));
5720 techt_inuse(tech_no
) = rnd((int) (techlevX(tech_no
)/6 + 1)) + 2;
5721 t_timeout
= rnz(1500);
5727 pline("You aren't wearing a shield!");
5730 num
= 1 + techlevX(tech_no
);
5731 techt_inuse(tech_no
) = num
+ 1;
5732 pline("You ready your shield as an additional weapon.");
5734 t_timeout
= rnz(2000);
5740 if (CannotSelectItemsInPrompts
) break;
5743 struct obj
*otmpC
= getobj(recharge_type
, "charge");
5745 if (yn("Really exit with no object selected?") == 'y')
5746 pline("You just wasted the opportunity to charge your items.");
5747 else goto chargingchoice
;
5752 t_timeout
= rnz(15000);
5756 case T_SPIRITUALITY_CHECK
:
5758 if (Race_if(PM_MACTHEIST
)) {
5759 pline("As an atheist, you cannot use such a technique.");
5763 if (can_pray(FALSE
) && !u
.ugangr
) pline("You can safely pray!");
5765 pline("You can not safely pray.");
5766 if (u
.ugangr
) pline("The gods are angry with you.");
5767 if (u
.ublesscnt
> 0) pline("Your prayer timeout isn't zero.");
5768 if ((int)Luck
< 0) pline("Your luck is negative.");
5769 if (u
.ualign
.record
< 0) pline("Your alignment record is negative.");
5771 u
.uconduct
.gnostic
++; /* you just communicated with your god */
5772 if (Race_if(PM_MAGYAR
)) {
5773 You_feel("bad about breaking the atheist conduct.");
5776 use_skill(P_SPIRITUALITY
, Role_if(PM_PRIEST
) ? 25 : 5);
5778 t_timeout
= rnz(2000);
5781 case T_BLOOD_RITUAL
:
5783 if (!(carrying(ATHAME
) || carrying(MERCURIAL_ATHAME
)) ) {
5784 pline("You need an athame to conduct the ritual!");
5787 if (u
.uhpmax
< 201) {
5788 pline("You don't have enough health to conduct the ritual!");
5791 if (Upolyd
&& u
.mhmax
< 201) {
5792 pline("You don't have enough health to conduct the ritual!");
5795 if (u
.uenmax
< 201) {
5796 pline("You don't have enough mana to conduct the ritual!");
5799 pline("Using your athame, you mutilate your own body. Don't ask me, I know nothing about those heretical rituals, apart from the fact they exist...");
5801 u
.uhpmax
-= rno(200);
5802 if (u
.uhp
> u
.uhpmax
) u
.uhp
= u
.uhpmax
;
5804 u
.mhmax
-= rno(200);
5805 if (u
.mh
> u
.mhmax
) u
.mh
= u
.mhmax
;
5807 u
.uenmax
-= rno(200);
5808 if (u
.uen
> u
.uenmax
) u
.uen
= u
.uenmax
;
5810 ABASE(A_STR
) -= rno(2);
5811 if (ABASE(A_STR
) < ATTRABSMIN(A_STR
)) ABASE(A_STR
) = ATTRABSMIN(A_STR
);
5812 AMAX(A_STR
) = ABASE(A_STR
);
5814 ABASE(A_DEX
) -= rno(2);
5815 if (ABASE(A_DEX
) < ATTRABSMIN(A_DEX
)) ABASE(A_DEX
) = ATTRABSMIN(A_DEX
);
5816 AMAX(A_DEX
) = ABASE(A_DEX
);
5818 ABASE(A_INT
) -= rno(2);
5819 if (ABASE(A_INT
) < ATTRABSMIN(A_INT
)) ABASE(A_INT
) = ATTRABSMIN(A_INT
);
5820 AMAX(A_INT
) = ABASE(A_INT
);
5822 ABASE(A_WIS
) -= rno(2);
5823 if (ABASE(A_WIS
) < ATTRABSMIN(A_WIS
)) ABASE(A_WIS
) = ATTRABSMIN(A_WIS
);
5824 AMAX(A_WIS
) = ABASE(A_WIS
);
5826 ABASE(A_CON
) -= rno(2);
5827 if (ABASE(A_CON
) < ATTRABSMIN(A_CON
)) ABASE(A_CON
) = ATTRABSMIN(A_CON
);
5828 AMAX(A_CON
) = ABASE(A_CON
);
5830 ABASE(A_CHA
) -= rno(2);
5831 if (ABASE(A_CHA
) < ATTRABSMIN(A_CHA
)) ABASE(A_CHA
) = ATTRABSMIN(A_CHA
);
5832 AMAX(A_CHA
) = ABASE(A_CHA
);
5834 if (!rn2(4)) makewish(TRUE
);
5835 else othergreateffect();
5837 t_timeout
= rnz(25000);
5840 case T_ENT_S_POTION
:
5841 pline("You feel very good.");
5842 healup(techlevX(tech_no
) * 10, 0, FALSE
, FALSE
);
5843 make_blinded(0L,FALSE
);
5844 make_stunned(0L,TRUE
);
5845 make_confused(0L,TRUE
);
5846 (void) make_hallucinated(0L,FALSE
,0L);
5847 make_numbed(0L,TRUE
);
5848 make_feared(0L,TRUE
);
5849 make_frozen(0L,TRUE
);
5850 make_burned(0L,TRUE
);
5851 make_dimmed(0L,TRUE
);
5852 u
.uhunger
+= techlevX(tech_no
) * 10;
5854 t_timeout
= rnz(10000);
5857 case T_LUCKY_GAMBLE
:
5864 You_feel("unlucky.");
5867 t_timeout
= rnz(2000);
5870 case T_DECONTAMINATE
:
5871 /* divide player's contamination by half, but don't reduce it by more than 1000 --Amy */
5873 if (!u
.contamination
) {
5874 t_timeout
= rnz(200);
5875 You("were not contaminated to begin with.");
5876 pline("Nothing happens.");
5877 if (FailureEffects
|| u
.uprops
[FAILURE_EFFECTS
].extrinsic
|| have_failurestone()) {
5878 pline("Oh wait, actually something bad happens...");
5884 pline("Your contamination is cured greatly.");
5886 if (u
.contamination
< 2000) decontaminate(u
.contamination
/ 2);
5887 else decontaminate(1000);
5888 t_timeout
= rnz(4000);
5894 t_timeout
= rnz(10000);
5899 pline("Sorry, you can only swap your secondary weapon while not dual-wielding.");
5903 t_timeout
= rnz(500);
5906 case T_RESET_TECHNIQUE
:
5909 pline("Choose a technique to reset. The prompt will loop until you actually make a choice. You can also opt to reset no technique at all, in which case there will be no timeout.");
5911 for (numtechs
= 0; numtechs
< MAXTECH
&& techid(numtechs
) != NO_TECH
; numtechs
++) {
5912 if (techid(numtechs
) == T_RESET_TECHNIQUE
) continue;
5913 if (techtout(numtechs
) > 0) {
5914 pline("Your %s technique is currently on timeout.", techname(numtechs
));
5915 if (yn("Make this technique usable again?") == 'y') {
5916 techtout(numtechs
) = 0;
5917 pline("The timeout on your %s technique has been set to zero.", techname(numtechs
));
5918 t_timeout
= rnz(Race_if(PM_DEVELOPER
) ? 50000 : 200000);
5923 pline("If you don't feel like resetting a technique right now, you can choose to reset none at all.");
5924 if (yn("Do you want to reset no technique at all?") == 'y') {
5933 case T_SILENT_OCEAN
:
5937 pline("The ocean becomes silent. You can freely swim in the water without your equipment becoming wet, and are protected from wrap attacks, but you're also silenced.");
5939 register struct monst
*nexusmon
, *nextmon
;
5940 register int silentoceandist
= 60 + (techlevX(tech_no
) * 3);
5942 for(nexusmon
= fmon
; nexusmon
; nexusmon
= nextmon
) {
5943 nextmon
= nexusmon
->nmon
;
5944 if (DEADMONSTER(nexusmon
)) continue;
5945 if (resist(nexusmon
, SPBOOK_CLASS
, 0, NOTELL
)) continue;
5946 if ((distu(nexusmon
->mx
, nexusmon
->my
)) > silentoceandist
) continue;
5947 nexusmon
->mcan
= 1; /* don't cancel egotypes */
5950 num
= 10 + (techlevX(tech_no
) * 5);
5951 techt_inuse(tech_no
) = num
+ 1;
5952 t_timeout
= rnz(5000);
5959 pline("Suddenly, a glowing unicorn horn appears above your %s!", body_part(HEAD
));
5960 num
= 10 + (techlevX(tech_no
) / 2);
5961 techt_inuse(tech_no
) = num
+ 1;
5962 t_timeout
= rnz(2000);
5965 case T_MILDEN_CURSE
:
5967 if (CannotSelectItemsInPrompts
) break;
5969 allowall
[0] = ALL_CLASSES
; allowall
[1] = '\0';
5971 if ( !(obj
= getobj(allowall
, "milden"))) return(0);
5974 pline("That object wasn't cursed to begin with.");
5978 pline("It seems that object wasn't cursed to begin with.");
5980 } else if (obj
->cursed
&& !obj
->hvycurse
&& !obj
->prmcurse
&& !obj
->morgcurse
&& !obj
->evilcurse
&& !obj
->bbrcurse
&& !obj
->stckcurse
) {
5982 pline("That object didn't have any kind of curse that could be mildened. It is still cursed.");
5986 pline("It seems that object didn't have any kind of curse that could be mildened. It is still cursed.");
5988 } else if (obj
->cursed
&& !obj
->morgcurse
&& !obj
->evilcurse
&& !obj
->bbrcurse
) {
5991 if (stack_too_big(obj
)) {
5992 pline("The stack was too big! Nothing happens.");
5993 t_timeout
= rnz(7500);
5997 if (obj
->stckcurse
) {
5998 obj
->stckcurse
= FALSE
;
5999 pline("The sticky curse is broken!");
6001 if (obj
->prmcurse
) {
6002 obj
->prmcurse
= obj
->hvycurse
= FALSE
;
6003 pline("The prime curse is broken!");
6005 if (obj
->hvycurse
) {
6006 obj
->hvycurse
= FALSE
;
6007 pline("The heavy curse is broken!");
6009 } else if (obj
->cursed
&& (obj
->morgcurse
|| obj
->evilcurse
|| obj
->bbrcurse
)) {
6012 if (stack_too_big(obj
)) {
6013 pline("The stack was too big! Nothing happens.");
6014 t_timeout
= rnz(7500);
6019 pline("Unfortunately, you failed to break the curse.");
6020 t_timeout
= rnz(7500);
6023 if (obj
->stckcurse
) {
6024 obj
->stckcurse
= FALSE
;
6025 pline("The sticky curse is broken!");
6027 if (obj
->morgcurse
) {
6028 obj
->morgcurse
= obj
->prmcurse
= obj
->hvycurse
= FALSE
;
6029 pline("The ancient morgothian curse is broken!");
6031 if (obj
->evilcurse
) {
6032 obj
->evilcurse
= obj
->prmcurse
= obj
->hvycurse
= FALSE
;
6033 pline("The topi ylinen curse is broken!");
6035 if (obj
->bbrcurse
) {
6036 obj
->bbrcurse
= obj
->prmcurse
= obj
->hvycurse
= FALSE
;
6037 pline("The black breath curse is broken!");
6040 t_timeout
= rnz(7500);
6045 pline("Force field activated!");
6046 num
= 50 + (techlevX(tech_no
) * 3);
6047 if (Race_if(PM_PLAYER_ATLANTEAN
)) num
*= 2;
6048 techt_inuse(tech_no
) = num
+ 1;
6049 t_timeout
= rnz(4000);
6055 pline("That doesn't work without a weapon!");
6058 if (uwep
&& weapon_type(uwep
) != P_POLEARMS
&& weapon_type(uwep
) != P_LANCE
) {
6059 pline("That only works if your wielded weapon is a polearm or lance, and currently it's not!");
6063 if (uwep
&& uwep
->spe
< 0) {
6064 uwep
->spe
+= rnd(abs(uwep
->spe
));
6065 if (uwep
->spe
> 0) uwep
->spe
= 0; /* fail safe */
6066 pline("Your stick seems slightly sharp now.");
6067 } else if (uwep
&& uwep
->spe
< 2) {
6069 pline("Your stick seems sharper now.");
6070 } else if (uwep
&& uwep
->spe
< 25 && !rn2(uwep
->spe
) ) {
6072 pline("Your stick seems very sharp now.");
6073 } else pline("Your stick seems as sharp as it was before.");
6075 t_timeout
= rnz(7500);
6082 pline("You may place a stinking cloud on the map.");
6083 pline("Where do you want to center the cloud?");
6086 if (getpos(&cc
, TRUE
, "the desired position") < 0) {
6087 pline("%s", Never_mind
);
6088 if (FailureEffects
|| u
.uprops
[FAILURE_EFFECTS
].extrinsic
|| have_failurestone()) {
6089 pline("Oh wait, actually I do mind...");
6094 if (!cansee(cc
.x
, cc
.y
) || distu(cc
.x
, cc
.y
) >= 32) {
6095 You("smell rotten eggs.");
6098 if (!PlayerCannotUseSkills
&& P_SKILL(P_PADDLE
) >= P_GRAND_MASTER
)
6099 (void) create_gas_cloud(cc
.x
, cc
.y
, 4, 12);
6101 (void) create_gas_cloud(cc
.x
, cc
.y
, 3, 8);
6105 t_timeout
= rnz(2000);
6111 pline("That doesn't work without a weapon!");
6114 if (uwep
&& weapon_type(uwep
) != P_QUARTERSTAFF
) {
6115 pline("That only works if your wielded weapon is a quarterstaff, and currently it's not!");
6119 You("start whirling like mad with your quarterstaff!");
6120 num
= 20 + techlevX(tech_no
);
6121 techt_inuse(tech_no
) = num
+ 1;
6122 t_timeout
= rnz(2500);
6125 case T_DELIBERATE_CURSE
:
6127 if (CannotSelectItemsInPrompts
) break;
6128 allowall
[0] = ALL_CLASSES
; allowall
[1] = '\0';
6129 if ( !(obj
= getobj(allowall
, "curse"))) return(0);
6132 if (stack_too_big(obj
)) {
6133 pline("The stack was too big! Nothing happens.");
6134 t_timeout
= rnz(5000);
6139 pline("Okay, that object is cursed now.");
6141 t_timeout
= rnz(5000);
6144 case T_ACQUIRE_STEED
:
6149 pline("Engulfing steeds can't see you, and therefore the taming attempt fails.");
6154 struct monst
*mtmp3
;
6156 pline("You try to acquire a steed!");
6158 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
6159 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
6160 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !is_infrastructure_monster(mtmp3
) && mtmp3
->mtame
== 0 && mtmp3
->isminion
== 0 && mtmp3
->isgyp
== 0
6161 && mtmp3
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp3
->data
->geno
& G_UNIQ
) && caughtX
== 0)
6165 if (mtmp3
->data
->mlet
== S_QUADRUPED
|| mtmp3
->data
->mlet
== S_UNICORN
|| mtmp3
->data
->mlet
== S_ANGEL
|| mtmp3
->data
->mlet
== S_CENTAUR
|| mtmp3
->data
->mlet
== S_DRAGON
|| mtmp3
->data
->mlet
== S_JABBERWOCK
|| mtmp3
->data
->mlet
== S_ZOUTHERN
) {
6166 if (!(resist(mtmp3
, RING_CLASS
, 0, NOTELL
) && resist(mtmp3
, RING_CLASS
, 0, NOTELL
) && resist(mtmp3
, RING_CLASS
, 0, NOTELL
))) {
6167 pline("%s is successfully tamed!", mon_nam(mtmp3
));
6168 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
6169 if (techlevX(tech_no
) < rnd(100)) caughtX
++;
6170 t_timeout
= rnz(5000);
6171 } else if ( ((rnd(30 - ACURR(A_CHA
))) < 4) && (!resist(mtmp3
, RING_CLASS
, 0, NOTELL
) || !resist(mtmp3
, RING_CLASS
, 0, NOTELL
) || !resist(mtmp3
, RING_CLASS
, 0, NOTELL
)) ) {
6172 pline("%s is successfully tamed!", mon_nam(mtmp3
));
6173 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
6174 if (techlevX(tech_no
) < rnd(100)) caughtX
++;
6175 t_timeout
= rnz(5000);
6177 pline("%s resists the taming attempt!", mon_nam(mtmp3
));
6179 } else pline("%s cannot be tamed by this method!", mon_nam(mtmp3
));
6181 } /* monster is catchable loop */
6185 t_timeout
= rnz(5000);
6192 struct obj
*usaddling
;
6194 pline("A saddle is created!");
6195 usaddling
= mksobj(rnd_class(LEATHER_SADDLE
, INKA_SADDLE
), TRUE
, FALSE
, FALSE
);
6197 usaddling
->quan
= 1;
6198 usaddling
->known
= usaddling
->dknown
= usaddling
->bknown
= usaddling
->rknown
= 1;
6199 usaddling
->owt
= weight(usaddling
);
6201 stackobj(usaddling
);
6206 t_timeout
= rnz(10000);
6209 case T_SHOPPING_QUEEN
:
6211 register struct obj
*heelses1
, *heelses2
, *heelses3
, *heelses4
, *heelses5
, *heelses6
, *heelses7
, *heelses8
, *heelses9
, *heelses10
;
6212 register int heelsamount
;
6215 if (PlayerCannotUseSkills
|| (P_SKILL(P_HIGH_HEELS
) <= P_EXPERT
)) heelsamount
= 1;
6216 else if (P_SKILL(P_HIGH_HEELS
) <= P_MASTER
) heelsamount
= 3;
6217 else if (P_SKILL(P_HIGH_HEELS
) <= P_GRAND_MASTER
) heelsamount
= 5;
6218 else if (P_SKILL(P_HIGH_HEELS
) <= P_SUPREME_MASTER
) heelsamount
= 10;
6219 else heelsamount
= 1; /* should never happen; fail safe */
6221 pline("Wow! You can get a pair of shoes from a list!");
6223 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6226 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6227 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6230 heelses1
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6233 heelses1
->known
= heelses1
->dknown
= heelses1
->bknown
= heelses1
->rknown
= 1;
6234 heelses1
->owt
= weight(heelses1
);
6237 if (heelsamount
>= 3) {
6239 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6242 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6243 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6246 heelses2
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6249 heelses2
->known
= heelses2
->dknown
= heelses2
->bknown
= heelses2
->rknown
= 1;
6250 heelses2
->owt
= weight(heelses2
);
6253 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6256 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6257 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6260 heelses3
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6263 heelses3
->known
= heelses3
->dknown
= heelses3
->bknown
= heelses3
->rknown
= 1;
6264 heelses3
->owt
= weight(heelses3
);
6269 if (heelsamount
>= 5) {
6271 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6274 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6275 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6278 heelses4
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6281 heelses4
->known
= heelses4
->dknown
= heelses4
->bknown
= heelses4
->rknown
= 1;
6282 heelses4
->owt
= weight(heelses4
);
6285 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6288 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6289 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6292 heelses5
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6295 heelses5
->known
= heelses5
->dknown
= heelses5
->bknown
= heelses5
->rknown
= 1;
6296 heelses5
->owt
= weight(heelses5
);
6301 if (heelsamount
>= 10) {
6303 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6306 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6307 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6310 heelses6
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6313 heelses6
->known
= heelses6
->dknown
= heelses6
->bknown
= heelses6
->rknown
= 1;
6314 heelses6
->owt
= weight(heelses6
);
6317 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6320 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6321 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6324 heelses7
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6327 heelses7
->known
= heelses7
->dknown
= heelses7
->bknown
= heelses7
->rknown
= 1;
6328 heelses7
->owt
= weight(heelses7
);
6331 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6334 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6335 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6338 heelses8
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6341 heelses8
->known
= heelses8
->dknown
= heelses8
->bknown
= heelses8
->rknown
= 1;
6342 heelses8
->owt
= weight(heelses8
);
6345 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6348 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6349 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6352 heelses9
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6355 heelses9
->known
= heelses9
->dknown
= heelses9
->bknown
= heelses9
->rknown
= 1;
6356 heelses9
->owt
= weight(heelses9
);
6359 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6362 while (trycnt
< 5000 && !ishighheeledb(heelidentity
) ) {
6363 heelidentity
= (PLASTEEL_BOOTS
+ rn2(LEVITATION_BOOTS
- PLASTEEL_BOOTS
+ 1) );
6366 heelses10
= mksobj(heelidentity
, TRUE
, FALSE
, FALSE
);
6368 heelses10
->quan
= 1;
6369 heelses10
->known
= heelses10
->dknown
= heelses10
->bknown
= heelses10
->rknown
= 1;
6370 heelses10
->owt
= weight(heelses10
);
6375 pline("Pick a pair of heels to acquire. The prompt will loop until you actually make a choice.");
6378 pline("You can get %s.", doname(heelses1
));
6379 if (yn("Do you want them?") == 'y') {
6382 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6383 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6384 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6385 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6386 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6387 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6388 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6389 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6390 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6395 if (heelses2
&& heelsamount
>= 3) {
6396 pline("You can get %s.", doname(heelses2
));
6397 if (yn("Do you want them?") == 'y') {
6400 if (heelses1
) dealloc_obj(heelses1
);
6401 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6402 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6403 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6404 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6405 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6406 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6407 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6408 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6413 if (heelses3
&& heelsamount
>= 3) {
6414 pline("You can get %s.", doname(heelses3
));
6415 if (yn("Do you want them?") == 'y') {
6418 if (heelses1
) dealloc_obj(heelses1
);
6419 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6420 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6421 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6422 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6423 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6424 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6425 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6426 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6431 if (heelses4
&& heelsamount
>= 5) {
6432 pline("You can get %s.", doname(heelses4
));
6433 if (yn("Do you want them?") == 'y') {
6436 if (heelses1
) dealloc_obj(heelses1
);
6437 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6438 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6439 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6440 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6441 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6442 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6443 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6444 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6449 if (heelses5
&& heelsamount
>= 5) {
6450 pline("You can get %s.", doname(heelses5
));
6451 if (yn("Do you want them?") == 'y') {
6454 if (heelses1
) dealloc_obj(heelses1
);
6455 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6456 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6457 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6458 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6459 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6460 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6461 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6462 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6467 if (heelses6
&& heelsamount
>= 10) {
6468 pline("You can get %s.", doname(heelses6
));
6469 if (yn("Do you want them?") == 'y') {
6472 if (heelses1
) dealloc_obj(heelses1
);
6473 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6474 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6475 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6476 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6477 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6478 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6479 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6480 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6485 if (heelses7
&& heelsamount
>= 10) {
6486 pline("You can get %s.", doname(heelses7
));
6487 if (yn("Do you want them?") == 'y') {
6490 if (heelses1
) dealloc_obj(heelses1
);
6491 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6492 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6493 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6494 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6495 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6496 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6497 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6498 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6503 if (heelses8
&& heelsamount
>= 10) {
6504 pline("You can get %s.", doname(heelses8
));
6505 if (yn("Do you want them?") == 'y') {
6508 if (heelses1
) dealloc_obj(heelses1
);
6509 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6510 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6511 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6512 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6513 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6514 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6515 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6516 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6521 if (heelses9
&& heelsamount
>= 10) {
6522 pline("You can get %s.", doname(heelses9
));
6523 if (yn("Do you want them?") == 'y') {
6526 if (heelses1
) dealloc_obj(heelses1
);
6527 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6528 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6529 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6530 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6531 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6532 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6533 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6534 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6539 if (heelses10
&& heelsamount
>= 10) {
6540 pline("You can get %s.", doname(heelses10
));
6541 if (yn("Do you want them?") == 'y') {
6543 stackobj(heelses10
);
6544 if (heelses1
) dealloc_obj(heelses1
);
6545 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6546 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6547 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6548 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6549 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6550 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6551 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6552 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6557 pline("There's nothing else left on the list.");
6558 if (yn("Do you choose to get no heels at all?") == 'y') {
6560 if (heelses1
) dealloc_obj(heelses1
);
6561 if (heelses2
&& heelsamount
>= 3) dealloc_obj(heelses2
);
6562 if (heelses3
&& heelsamount
>= 3) dealloc_obj(heelses3
);
6563 if (heelses4
&& heelsamount
>= 5) dealloc_obj(heelses4
);
6564 if (heelses5
&& heelsamount
>= 5) dealloc_obj(heelses5
);
6565 if (heelses6
&& heelsamount
>= 10) dealloc_obj(heelses6
);
6566 if (heelses7
&& heelsamount
>= 10) dealloc_obj(heelses7
);
6567 if (heelses8
&& heelsamount
>= 10) dealloc_obj(heelses8
);
6568 if (heelses9
&& heelsamount
>= 10) dealloc_obj(heelses9
);
6569 if (heelses10
&& heelsamount
>= 10) dealloc_obj(heelses10
);
6577 pline("There might be something waiting for you on the %s...", surface(u
.ux
, u
.uy
));
6578 t_timeout
= rnz(7500);
6581 case T_BEAUTY_CHARM
:
6583 if (!PlayerInHighHeels
) {
6584 pline("You must be wearing high heels for that.");
6588 techt_inuse(tech_no
) = 11;
6589 nomul(-11, "posing sexily", FALSE
);
6590 pline("You start posing sexily with your high heels, hoping to charm the bystanders.");
6591 if (uarmf
&& uarmf
->oartifact
== ART_PRECURSOR_TO_THE___
) adjattrib(A_CHA
, 1, -1, TRUE
);
6593 t_timeout
= rnz(2000);
6598 if (!PlayerInStilettoHeels
) {
6599 pline("Only heroes wearing stiletto heels can use this technique!");
6603 techt_inuse(tech_no
) = 51;
6604 pline("Your stiletto heels are ready. Quick! Find someone with nuts and kick him for a devastating effect!");
6605 t_timeout
= rnz(2500);
6608 case T_LEGSCRATCH_ATTACK
:
6610 if (!PlayerInConeHeels
) {
6611 pline("Only heroes wearing cone heels can use this technique!");
6615 num
= 50 + (techlevX(tech_no
) * 2);
6616 techt_inuse(tech_no
) = num
+ 1;
6617 pline("Your cone heels are eager to scratch up and down hostile legs. Make sure you kick everyone that crosses your path!");
6619 t_timeout
= rnz(3000);
6622 case T_GROUND_STOMP
:
6624 if (!PlayerInWedgeHeels
) {
6625 pline("Only heroes wearing wedge heels can use this technique!");
6629 num
= 25 + (techlevX(tech_no
) * 2);
6630 techt_inuse(tech_no
) = num
+ 1;
6631 pline("Your wedge heels absolutely want to stomp enemies, so you should try to kick monsters with them now!");
6633 t_timeout
= rnz(4000);
6636 case T_ATHLETIC_COMBAT
:
6638 if (!PlayerInBlockHeels
) {
6639 pline("Only heroes wearing block heels can use this technique!");
6643 num
= 50 + (techlevX(tech_no
) * 3);
6644 techt_inuse(tech_no
) = num
+ 1;
6645 pline("Your block heels expect you to repeatedly kick enemies now, hoping to bludgeon them.");
6647 t_timeout
= rnz(2500);
6650 case T_PRAYING_SUCCESS
:
6652 techt_inuse(tech_no
) = 1;
6654 t_timeout
= rnz(30000);
6659 num
= 100 + (techlevX(tech_no
) * 5);
6660 techt_inuse(tech_no
) = num
+ 1;
6661 pline("For a while, all your rays have extended range!");
6663 t_timeout
= rnz(5000);
6666 case T_ENCHANTERANG
:
6669 pline("That doesn't work without a weapon!");
6672 if (uwep
&& weapon_type(uwep
) != P_BOOMERANG
&& weapon_type(uwep
) != -P_BOOMERANG
) {
6673 pline("That only works if your wielded weapon is a boomerang, and currently it's not!");
6677 if (uwep
&& stack_too_big(uwep
)) {
6678 pline("You were trying to enchant too many boomerangs at once and therefore they barely received any enchantment bonus.");
6679 } else if (uwep
&& uwep
->spe
< 0) {
6680 uwep
->spe
+= rnd(abs(uwep
->spe
));
6681 if (uwep
->spe
> 0) uwep
->spe
= 0; /* fail safe */
6682 } else if (uwep
&& uwep
->spe
< 2) {
6684 } else if (uwep
&& uwep
->spe
< 25 && !rn2(uwep
->spe
) ) {
6688 if (uwep
&& stack_too_big(uwep
)) {
6689 pline("You were trying to enchant too many boomerangs at once and therefore they barely received any enchantment bonus.");
6690 } else if (uwep
&& uwep
->spe
< 2) {
6692 } else if (uwep
&& uwep
->spe
< 25 && !rn2(uwep
->spe
) ) {
6696 if (uwep
&& stack_too_big(uwep
)) {
6697 pline("You were trying to enchant too many boomerangs at once and therefore they barely received any enchantment bonus.");
6698 } else if (uwep
&& uwep
->spe
< 2) {
6700 pline("Your boomerang is barely enchanted.");
6701 } else if (uwep
&& uwep
->spe
< 25 && !rn2(uwep
->spe
) ) {
6703 pline("Your boomerang is well-enchanted.");
6704 } else pline("Your boomerang is moderately enchanted.");
6706 t_timeout
= rnz(10000);
6709 case T_BATMAN_ARSENAL
:
6712 struct obj
*uboomerang
;
6714 pline("A boomerang is created!");
6715 uboomerang
= mksobj(rn2(3) ? BOOMERANG
: !rn2(4) ? ALU_BOOMERANG
: !rn2(3) ? BATARANG
: rn2(2) ? DARK_BATARANG
: SILVER_CHAKRAM
, TRUE
, FALSE
, FALSE
);
6717 uboomerang
->quan
= 1;
6718 uboomerang
->known
= uboomerang
->dknown
= uboomerang
->bknown
= uboomerang
->rknown
= 1;
6719 uboomerang
->owt
= weight(uboomerang
);
6721 stackobj(uboomerang
);
6726 t_timeout
= rnz(5000);
6731 num
= 100 + (techlevX(tech_no
) * 5);
6732 techt_inuse(tech_no
) = num
+ 1;
6733 pline("Your batarang is capable of paralyzing monsters for a while.");
6734 t_timeout
= rnz(8000);
6738 case T_CALL_THE_POLICE
:
6740 pline("You call the kops!");
6747 while (caughtY
== 0) {
6748 mtmp
= makemon(mkclass(S_KOP
,0), u
.ux
, u
.uy
, NO_MM_FLAGS
);
6750 (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
6751 if (techlevX(tech_no
) < rnd(80)) caughtY
++;
6756 t_timeout
= rnz(10000);
6762 pline("Domination doesn't work while you're engulfed!");
6769 struct monst
*mtmp3
;
6771 pline("You try to dominate monsters!");
6773 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
6774 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
6775 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !is_infrastructure_monster(mtmp3
) && mtmp3
->mtame
== 0 && mtmp3
->isminion
== 0 && mtmp3
->isgyp
== 0
6776 && mtmp3
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp3
->data
->geno
& G_UNIQ
) && caughtX
== 0)
6780 if ( is_animal(mtmp3
->data
)) {
6781 pline("%s is dominated!", mon_nam(mtmp3
));
6782 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
6783 if (techlevX(tech_no
) < rnd(100)) caughtX
++;
6784 t_timeout
= rnz(10000);
6787 else pline("%s can't be dominated with this method!", mon_nam(mtmp3
));
6789 } /* monster is catchable loop */
6792 t_timeout
= rnz(10000);
6802 int k
, l
, polymorphnumber
;
6803 struct monst
*mtmp3
;
6805 pline("Pick a monster to incarnate into. The prompt will loop until you actually make a choice.");
6808 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
6809 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
6810 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0)) {
6811 polymorphnumber
= mtmp3
->mnum
;
6812 pline("You can incarnate into %s.", mtmp3
->data
->mname
);
6813 if (yn("Do it?") == 'y') {
6814 u
.wormpolymorph
= polymorphnumber
;
6815 goto incarnationfinish
;
6820 pline("You can also choose to not incarnate at all, although that would be a waste.");
6821 if (yn("Do it?") == 'y') {
6822 pline("Well, if you really want to waste such a powerful technique...");
6823 t_timeout
= rnz(25000);
6826 goto incarnationselect
;
6830 u
.wormpolymorph
= rn2(NUMMONS
);
6831 pline("Your incarnation attempt goes out of control!");
6837 t_timeout
= rnz(25000);
6841 case T_COMBO_STRIKE
:
6843 if (!canuseunarmedtechs()) {
6844 You("can't do that while wielding a weapon!");
6848 num
= 30 + (techlevX(tech_no
) * 2);
6849 techt_inuse(tech_no
) = num
+ 1;
6850 pline("You're starting your combo!");
6852 u
.comboactive
= TRUE
;
6853 t_timeout
= rnz(5000);
6859 pline("You feel fungal.");
6860 techt_inuse(tech_no
) = 1;
6862 techt_inuse(tech_no
) = 0;
6863 t_timeout
= rnz(8000);
6866 case T_BECOME_UNDEAD
:
6868 pline("You feel dead.");
6869 techt_inuse(tech_no
) = 1;
6871 techt_inuse(tech_no
) = 0;
6872 t_timeout
= rnz(8000);
6877 num
= 1000 + (techlevX(tech_no
) * 10);
6878 techt_inuse(tech_no
) = num
+ 1;
6879 pline("You start doing jiu-jitsu!");
6880 t_timeout
= rnz(10000);
6885 num
= 100 + (techlevX(tech_no
) * 3);
6886 techt_inuse(tech_no
) = num
+ 1;
6887 pline("Your shuriken can fire beams now!");
6889 t_timeout
= rnz(7500);
6894 pline("You try to tame your former pet...");
6898 struct monst
*mtmp3
;
6900 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
6901 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
6902 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !mtmp3
->mfrenzied
&& (mtmp3
->mpeaceful
|| !rn2(3) || ((rnd(30 - ACURR(A_CHA
))) < 4) ) && mtmp3
->mtame
== 0 && mtmp3
->wastame
) {
6904 pline("%s wants to be your pet again!", mon_nam(mtmp3
));
6905 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
6906 t_timeout
= rnz(1500);
6914 t_timeout
= rnz(1500);
6918 case T_INTRINSIC_ROULETTE
:
6919 You("spin the roulette wheel...");
6920 intrinsicgainorloss(0);
6921 t_timeout
= rnz(10000);
6924 case T_SPECTRAL_SWORD
:
6925 You("focus the powers of the elements into your weapon.");
6926 techt_inuse(tech_no
) = rnd((int) (techlevX(tech_no
)/3 + 1)) + d(1,4) + 2;
6927 t_timeout
= rnz(1500);
6930 case T_REVERSE_IDENTIFY
:
6936 for (j
= 0; j
<= 5; j
++) {
6938 pline("%s", thats_enough_tries
);
6941 getlin("What do you want to identify?", buf
);
6942 if (buf
[0] == 0) continue;
6944 otmp
= readobjnam(buf
, (struct obj
*)0, TRUE
, FALSE
);
6945 if (u
.ugold
!= oldgold
) {
6946 pline("Don't you date cheat me again! -- Your fault!");
6948 u
.ugold
= oldgold
/ 2;
6951 if (otmp
== &zeroobj
|| otmp
== (struct obj
*) 0) {
6952 pline("That doesn't exist.");
6957 strcpy(buf
,xname(otmp
));
6958 makeknown(otmp
->otyp
);
6959 pline("The %s is a %s.",buf
,xname(otmp
));
6960 if (Has_contents(otmp
))
6961 delete_contents(otmp
);
6962 obfree(otmp
,(struct obj
*) 0);
6965 pline("You also learn the identity of some other objects:");
6966 for (i
= 0; i
< 5; i
++) {
6967 j
= rn2(NUM_OBJECTS
);
6968 while (objects
[j
].oc_prob
< 1) j
= rn2(NUM_OBJECTS
);
6970 pline("%s (%s).", obj_descr
[j
].oc_name
, obj_descr
[j
].oc_descr
);
6972 t_timeout
= rnz(20000);
6976 case T_DETECT_TRAPS
:
6977 trap_detect((struct obj
*)0);
6978 t_timeout
= rnz(20000);
6982 if (PlayerCannotUseSkills
) {
6983 pline("Unfortunately, no one seems to follow any directives you're giving.");
6984 t_timeout
= rnz(200);
6987 if (P_SKILL(P_PETKEEPING
) < P_SKILLED
&& P_SKILL(P_RIDING
) < P_SKILLED
) {
6988 pline("Unfortunately, no one seems to follow any directives you're giving.");
6989 t_timeout
= rnz(200);
6993 if (P_SKILL(P_RIDING
) >= P_SKILLED
) {
6995 pline("Currently your steed has %d%% chance of being targetted by monsters.", u
.steedhitchance
);
6996 if (yn("Change it?") == 'y') {
6998 int lowerbound
, higherbound
;
7002 switch (P_SKILL(P_RIDING
)) {
7015 case P_GRAND_MASTER
:
7019 case P_SUPREME_MASTER
:
7029 pline("You can set the chance to values between %d%% and %d%% (inclusive).", lowerbound
, higherbound
);
7030 if (lowerbound
<= 1 && yn("Set the chance to 1%%?") == 'y') {
7031 u
.steedhitchance
= 1;
7032 pline("The chance that attacks target your steed is 1%% now.");
7033 } else if (lowerbound
<= 3 && yn("Set the chance to 3%%?") == 'y') {
7034 u
.steedhitchance
= 3;
7035 pline("The chance that attacks target your steed is 3%% now.");
7036 } else if (lowerbound
<= 5 && yn("Set the chance to 5%%?") == 'y') {
7037 u
.steedhitchance
= 5;
7038 pline("The chance that attacks target your steed is 5%% now.");
7039 } else if (lowerbound
<= 10 && yn("Set the chance to 10%%?") == 'y') {
7040 u
.steedhitchance
= 10;
7041 pline("The chance that attacks target your steed is 10%% now.");
7042 } else if (lowerbound
<= 20 && yn("Set the chance to 20%%?") == 'y') {
7043 u
.steedhitchance
= 20;
7044 pline("The chance that attacks target your steed is 20%% now.");
7045 } else if (yn("Set the chance to 25%%?") == 'y') {
7046 u
.steedhitchance
= 25;
7047 pline("The chance that attacks target your steed is 25%% now.");
7048 } else if (higherbound
>= 33 && yn("Set the chance to 33%%?") == 'y') {
7049 u
.steedhitchance
= 33;
7050 pline("The chance that attacks target your steed is 33%% now.");
7051 } else if (higherbound
>= 50 && yn("Set the chance to 50%%?") == 'y') {
7052 u
.steedhitchance
= 50;
7053 pline("The chance that attacks target your steed is 50%% now.");
7054 } else if (higherbound
>= 75 && yn("Set the chance to 75%%?") == 'y') {
7055 u
.steedhitchance
= 75;
7056 pline("The chance that attacks target your steed is 75%% now.");
7057 } else if (higherbound
>= 90 && yn("Set the chance to 90%%?") == 'y') {
7058 u
.steedhitchance
= 90;
7059 pline("The chance that attacks target your steed is 90%% now.");
7060 } else if (higherbound
>= 100 && yn("Set the chance to 100%%?") == 'y') {
7061 u
.steedhitchance
= 100;
7062 pline("The chance that attacks target your steed is 100%% now.");
7063 } else pline("The chance that attacks target your steed remains %d%%.", u
.steedhitchance
);
7069 if (P_SKILL(P_PETKEEPING
) >= P_SKILLED
) {
7070 pline("Currently your pets can%s pick up items.", u
.petcollectitems
? "" : "'t");
7071 if (yn("Change it?") == 'y') {
7072 if (u
.petcollectitems
) u
.petcollectitems
= 0;
7073 else u
.petcollectitems
= 1;
7074 pline("Your pets can%s pick up items now.", u
.petcollectitems
? "" : "'t");
7078 if (P_SKILL(P_PETKEEPING
) >= P_EXPERT
) {
7079 pline("Currently your pets can%s attack%s monsters.", (u
.petattackenemies
> 0) ? "" : "'t", u
.petattackenemies
== 2 ? " both hostile and peaceful" : u
.petattackenemies
== 1 ? " only hostile" : u
.petattackenemies
== -1 ? " or be attacked by" : "");
7080 if (yn("Change it?") == 'y') {
7081 pline("You got the following options: make the pet attack everything, make it attack only hostile monsters, or prevent it from attacking anything (with the choice that it may or may not still be attacked by hostiles).");
7082 if (yn("Do you want your pets to attack everything?") == 'y') {
7083 u
.petattackenemies
= 2;
7084 pline("Your pets can attack all monsters now.");
7085 } else if (yn("Do you want your pets to only attack hostile creatures?") == 'y') {
7086 u
.petattackenemies
= 1;
7087 pline("Your pets can attack hostile monsters now, but will leave peaceful ones alone.");
7088 } else if (yn("Do you want your pets to not attack any monsters?") == 'y') {
7089 u
.petattackenemies
= 0;
7090 pline("Your pets can't attack monsters now.");
7091 } else if (yn("Do you want your pets to not attack any monsters, and also not be attacked by them anymore?") == 'y') {
7092 u
.petattackenemies
= -1;
7093 pline("Your pets can't attack monsters now and also won't be attacked by monsters.");
7098 if (P_SKILL(P_PETKEEPING
) >= P_MASTER
) {
7099 pline("Currently your pets can%s eat food off the floor.", u
.petcaneat
? "" : "'t");
7100 if (yn("Change it?") == 'y') {
7101 if (u
.petcaneat
) u
.petcaneat
= 0;
7102 else u
.petcaneat
= 1;
7103 pline("Your pets can%s eat food off the floor now.", u
.petcaneat
? "" : "'t");
7107 if (P_SKILL(P_PETKEEPING
) >= P_GRAND_MASTER
) {
7108 pline("Currently your pets can%s try to follow you.", u
.petcanfollow
? "" : "'t");
7109 if (yn("Change it?") == 'y') {
7110 if (u
.petcanfollow
) u
.petcanfollow
= 0;
7111 else u
.petcanfollow
= 1;
7112 pline("Your pets can%s try to follow you now.", u
.petcanfollow
? "" : "'t");
7116 t_timeout
= rnz(P_SKILL(P_PETKEEPING
) >= P_SUPREME_MASTER
? 50 : 200);
7119 case T_REMOVE_IMPLANT
:
7122 pline("There is no implant that could be removed!");
7125 pline("Your implant is removed.");
7128 t_timeout
= rnz(20000);
7131 case T_REROLL_IMPLANT
:
7134 pline("You're not wearing any implant!");
7139 register struct obj
*wearimplant
;
7142 wearimplant
= uimplant
;
7144 pline("Somehow the implant went missing...");
7148 savewornmask
= wearimplant
->owornmask
;
7149 setworn((struct obj
*)0, wearimplant
->owornmask
);
7151 if (wearimplant
->otyp
>= IMPLANT_OF_ABSORPTION
&& wearimplant
->otyp
<= IMPLANT_OF_PROSPERITY
) {
7152 objects
[wearimplant
->otyp
].a_ac
= rnd(10);
7154 if (wearimplant
->otyp
>= IMPLANT_OF_QUEEB_BUTT
&& wearimplant
->otyp
<= IMPLANT_OF_FINGER_POINTING
) {
7155 objects
[wearimplant
->otyp
].a_ac
= rnd(10);
7158 if (wearimplant
->otyp
>= IMPLANT_OF_QUICKENING
&& wearimplant
->otyp
<= IMPLANT_OF_BLITZEN
) {
7159 objects
[wearimplant
->otyp
].a_ac
= rnd(8);
7160 objects
[wearimplant
->otyp
].oc_oprop
= randnastyenchantment();
7162 if (wearimplant
->otyp
>= IMPLANT_OF_TOTAL_NONSENSE
&& wearimplant
->otyp
<= IMPLANT_OF_GALVANIZATION
) {
7163 objects
[wearimplant
->otyp
].a_ac
= rnd(8);
7164 objects
[wearimplant
->otyp
].oc_oprop
= randnastyenchantment();
7167 if (wearimplant
->otyp
>= IMPLANT_OF_SERENITY
&& wearimplant
->otyp
<= IMPLANT_OF_CARNAGE
) {
7168 objects
[wearimplant
->otyp
].a_ac
= rnd(9);
7169 objects
[wearimplant
->otyp
].oc_oprop
= randfemienchantment();
7171 if (wearimplant
->otyp
>= IMPLANT_OF_LEGEND
&& wearimplant
->otyp
<= IMPLANT_OF_VIRTUE
) {
7172 objects
[wearimplant
->otyp
].a_ac
= rnd(9);
7173 objects
[wearimplant
->otyp
].oc_oprop
= randfemienchantment();
7176 if (wearimplant
->otyp
>= IMPLANT_OF_IRE
&& wearimplant
->otyp
<= IMPLANT_OF_FREEDOM
) {
7177 objects
[wearimplant
->otyp
].a_ac
= rnd(5);
7178 objects
[wearimplant
->otyp
].oc_oprop
= !rn2(10) ? randnastyenchantment() : randenchantment();
7180 if (wearimplant
->otyp
>= IMPLANT_OF_TEN_THOUSAND_THINGS
&& wearimplant
->otyp
<= IMPLANT_OF_VIRTUE
) {
7181 objects
[wearimplant
->otyp
].a_ac
= rnd(5);
7182 objects
[wearimplant
->otyp
].oc_oprop
= !rn2(10) ? randnastyenchantment() : randenchantment();
7184 wearimplant
->shirtmessage
= rnd(1000000);
7186 setworn(wearimplant
, savewornmask
);
7187 pline("All done - your implant got re-initialized! Its base AC value got rerolled, and if it was a type that had a random enchantment, that was re-randomized as well. The bonus you'll get from wearing it while in a form without hands has also been changed.");
7190 t_timeout
= rnz(10000);
7195 pline((Role_if(PM_SAMURAI
) || Role_if(PM_NINJA
)) ? "Jikan ga teishi shimashita." : "Time has stopped.");
7196 TimeStopped
+= (5 + rnd(6));
7197 t_timeout
= rnz(25000);
7201 num
= 50 + (techlevX(tech_no
) * 10);
7202 techt_inuse(tech_no
) = num
+ 1;
7203 t_timeout
= rnz(3000);
7206 case T_UNCURSE_SABER
:
7208 pline("That doesn't work without a weapon!");
7211 if (uwep
&& !(is_lightsaber(uwep
))) {
7212 pline("Trying to cheat, huh? Nope. This technique can only uncurse lightsabers.");
7215 if (uwep
&& !(uwep
->cursed
)) {
7216 uwep
->bknown
= TRUE
;
7217 pline("Your lightsaber wasn't cursed to begin with, and therefore nothing happens.");
7218 t_timeout
= rnz(5000);
7221 t_timeout
= rnz(5000);
7223 pline("Your lightsaber is surrounded by a holy aura.");
7224 uncurse(uwep
, TRUE
);
7228 case T_ENERGY_CONSERVATION
:
7229 if (!uwep
|| (uwep
&& !is_lightsaber(uwep
))) {
7230 pline("You're not holding a lightsaber!");
7233 num
= 1000 + (techlevX(tech_no
) * 10);
7234 techt_inuse(tech_no
) = num
+ 1;
7235 pline("The energy consumption rate of your lightsaber slows down!");
7236 t_timeout
= rnz(6000);
7239 case T_UNARMED_FOCUS
:
7241 if (!canuseunarmedtechs()) {
7242 pline("That requires you to be fighting without a weapon!");
7245 docalm(); /* stop all other techs that might be active --Amy */
7247 num
= 1000 + (techlevX(tech_no
) * 10);
7248 techt_inuse(tech_no
) = num
+ 1;
7249 pline("You're focussing on fighting unarmed!");
7250 t_timeout
= rnz(6000);
7253 case T_ENCHANT_ROBE
:
7255 register struct obj
*wearrobe
;
7259 pline("Without armor, that technique won't do anything.");
7262 if (uarm
&& !(uarm
->otyp
>= ROBE
&& uarm
->otyp
<= ROBE_OF_WEAKNESS
)) {
7263 pline("Nope, that won't work. Wear a robe!");
7268 pline("Somehow the robe is missing...");
7271 savewornmask
= wearrobe
->owornmask
;
7272 setworn((struct obj
*)0, wearrobe
->owornmask
);
7273 t_timeout
= rnz(10000);
7275 wearrobe
->enchantment
= randenchantment();
7276 pline("Your robe's special enchantment was randomized.");
7277 if (!PlayerCannotUseSkills
&& P_SKILL(P_SORESU
) >= P_GRAND_MASTER
) {
7278 if (wearrobe
&& wearrobe
->spe
< 0) {
7279 wearrobe
->spe
+= rnd(abs(wearrobe
->spe
));
7280 if (wearrobe
->spe
> 0) wearrobe
->spe
= 0; /* fail safe */
7281 pline("Your robe's negative enchantment value is remedied.");
7282 } else if (wearrobe
&& wearrobe
->spe
< 2) {
7284 pline("Your robe gained a positive enchantment value.");
7285 } else if (wearrobe
&& wearrobe
->spe
< 7 && !rn2(wearrobe
->spe
) ) {
7287 pline("Your robe has a high positive enchantment value now.");
7288 } else pline("Your robe's enchantment value unfortunately didn't increase.");
7291 setworn(wearrobe
, savewornmask
);
7295 case T_WILD_SLASHING
:
7296 if (!(uwep
&& is_lightsaber(uwep
) && uwep
->lamplit
&& u
.twoweap
&& uswapwep
&& is_lightsaber(uswapwep
) && uswapwep
->lamplit
)) {
7297 pline("You must be dual-wielding lit lightsabers for that!");
7300 num
= 20 + (techlevX(tech_no
) * 3);
7301 techt_inuse(tech_no
) = num
+ 1;
7302 t_timeout
= rnz(3000);
7303 pline("Your lightsabers start attacking rapidly at the cost of accuracy.");
7306 case T_ABSORBER_SHIELD
:
7307 if (!uwep
|| (uwep
&& !is_lightsaber(uwep
))) {
7308 pline("You're not holding a lightsaber!");
7311 num
= 200 + (techlevX(tech_no
) * 7);
7312 techt_inuse(tech_no
) = num
+ 1;
7313 t_timeout
= rnz(2500);
7314 pline("Your lightsaber becomes capable of absorbing enemy projectiles to gain energy.");
7317 case T_PSYCHO_FORCE
:
7321 struct monst
*psychmonst
;
7322 pline("Select a monster to use psycho force");
7325 getpos(&cc
, TRUE
, "the spot to attack");
7326 if (cc
.x
== -10) return (0); /* user pressed esc */
7327 psychmonst
= m_at(cc
.x
, cc
.y
);
7329 if (!psychmonst
|| (!canseemon(psychmonst
) && !canspotmon(psychmonst
))) {
7330 You("don't see a monster there!");
7336 forcedamage
= u
.ulevel
+ techlevX(tech_no
);
7337 if (!PlayerCannotUseSkills
) {
7339 switch (P_SKILL(P_DJEM_SO
)) {
7340 case P_MASTER
: forcedamage
*= 3; forcedamage
/= 2; break;
7341 case P_GRAND_MASTER
: forcedamage
*= 2; break;
7342 case P_SUPREME_MASTER
: forcedamage
*= 5; forcedamage
/= 2; break;
7346 psychmonst
->mcanmove
= 0;
7347 psychmonst
->mstrategy
&= ~STRAT_WAITFORU
;
7349 if (forcedamage
< 31) psychmonst
->mfrozen
= 3;
7350 else psychmonst
->mfrozen
= (forcedamage
/ 10);
7352 pline("%s sputters at the forced hold!", Monnam(psychmonst
));
7353 psychmonst
->mhp
-= forcedamage
;
7354 if (psychmonst
->mhp
< 1) {
7355 pline("%s dies!", Monnam(psychmonst
));
7356 xkilled(psychmonst
,0);
7357 } else wakeup(psychmonst
); /* monster becomes hostile */
7362 t_timeout
= rnz(2000);
7365 case T_INTENSIVE_TRAINING
:
7367 pline("You train your attributes...");
7368 adjattrib(rn2(A_MAX
), 1, -1, TRUE
);
7369 t_timeout
= rnz(7500);
7372 case T_SURRENDER_OR_DIE
:
7373 if (!uwep
|| (uwep
&& !is_lightsaber(uwep
))) {
7374 pline("You're not holding a lightsaber!");
7377 num
= 200 + (techlevX(tech_no
) * 20);
7378 techt_inuse(tech_no
) = num
+ 1;
7379 t_timeout
= rnz(5000);
7380 pline("Your lightsaber gains the ability to pacify monsters when breaking their weapon!");
7383 case T_PERILOUS_WHIRL
:
7384 if (!uwep
|| (uwep
&& !is_lightsaber(uwep
)) || (uwep
&& !bimanual(uwep
)) ) {
7385 pline("You're not holding a double lightsaber!");
7388 num
= 100 + (techlevX(tech_no
) * 6);
7389 techt_inuse(tech_no
) = num
+ 1;
7390 t_timeout
= rnz(2500);
7391 pline("Your lightsaber can drain the life of opponents for a while!");
7395 t_timeout
= rnz(10000);
7398 struct permonst
*shoe
= 0;
7400 struct monst
*shoemonst
;
7405 if (attempts
&& (attempts
% 10000 == 0)) u
.mondiffhack
++;
7406 if (!rn2(2000)) reset_rndmonst(NON_PM
);
7408 } while ( (!shoe
|| (shoe
&& !(shoe
->msound
== MS_SHOE
))) && attempts
< 50000);
7410 if (shoe
&& (shoe
->msound
== MS_SHOE
) ) {
7411 pline("A shoe appears from nowhere!");
7412 shoemonst
= makemon(shoe
, u
.ux
, u
.uy
, NO_MM_FLAGS
);
7413 if (shoemonst
) (void) tamedog(shoemonst
, (struct obj
*) 0, TRUE
);
7415 pline("Hmm... you expected a shoe, but some other monster appeared instead!");
7416 shoemonst
= makemon(shoe
, u
.ux
, u
.uy
, NO_MM_FLAGS
);
7417 if (shoemonst
) (void) tamedog(shoemonst
, (struct obj
*) 0, TRUE
);
7418 } else pline("Somehow, it failed... :(");
7427 num
= 1 + techlevX(tech_no
);
7428 techt_inuse(tech_no
) = num
+ 1;
7429 pline("You prepare a powerful axe-and-sword-mill!");
7431 t_timeout
= rnz(3500);
7434 case T_KICK_IN_THE_NUTS
:
7436 if (!PlayerInSexyFlats
) {
7437 pline("You must be wearing sexy flats for that!");
7441 if (!getdir((char *)0)) return 0;
7442 if (!u
.dx
&& !u
.dy
) {
7443 /* Hopefully a mistake ;B */
7444 pline(flags
.female
? "Since you don't have nuts, you cannot try to smash them with your feet either." : "For a moment, you feel the itch to ram your footwear into your own nuts, but then remember that you have a task to complete, and therefore decide against the idea.");
7447 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
7448 pline("Invalid target location.");
7451 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
7453 You("perform a powerful kick, and listen to very sexy air current noises as your %s whirls through thin air.", body_part(FOOT
));
7454 } else if (mtmp
->female
|| is_neuter(mtmp
->data
)) {
7455 pline("%s has no nuts to kick and is therefore unaffected!", Monnam(mtmp
));
7457 pline("%s moans in agony as his nuts are squashed by your sexy footwear!", Monnam(mtmp
));
7459 mtmp
->mfrozen
= 10 + rnd(techlevX(tech_no
));
7460 mtmp
->mstrategy
&= ~STRAT_WAITFORU
;
7461 int tmp
= 50 + rnd(techlevX(tech_no
) * 4);
7464 if (mtmp
&& !DEADMONSTER(mtmp
) && mtmp
->mpeaceful
&& !mtmp
->mtame
) mtmp
->mpeaceful
= 0; /* monster becomes hostile */
7466 t_timeout
= rnz(2500);
7470 case T_DISARMING_KICK
:
7472 if (!PlayerInSexyFlats
) {
7473 pline("You must be wearing sexy flats for that!");
7478 pline("Kicking an engulfer's weapon from the inside would be quite the feat.");
7482 if (!getdir((char *)0)) return(0);
7483 if (!u
.dx
&& !u
.dy
) {
7484 /* Hopefully a mistake ;B */
7485 pline("Why don't you try wielding something else instead.");
7488 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
7489 pline("Invalid target location.");
7492 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
7493 if (!mtmp
|| !canspotmon(mtmp
)) {
7494 if (memory_is_invisible(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
))
7495 You("don't know where to aim for!");
7497 You("don't see anything there!");
7500 obj
= MON_WEP(mtmp
); /* can be null */
7502 You_cant("disarm an unarmed foe!");
7506 You("kick %s in the %s with your sexy footwear...", mon_nam(mtmp
), mbodypart(mtmp
, HAND
));
7508 obj_extract_self(obj
);
7509 possibly_unwield(mtmp
, FALSE
);
7510 setmnotwielded(mtmp
, obj
);
7512 if (obj
&& obj
->mstartinventB
&& !(obj
->oartifact
) && !(obj
->fakeartifact
&& timebasedlowerchance()) && (!rn2(4) || (rn2(100) < u
.equipmentremovechance
) || !timebasedlowerchance() ) ) {
7513 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
7515 t_timeout
= rnz(1000);
7517 } else if (obj
&& obj
->mstartinventC
&& !(obj
->oartifact
) && !(obj
->fakeartifact
&& !rn2(10)) && rn2(10) ) {
7518 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
7520 t_timeout
= rnz(1000);
7522 } else if (obj
&& obj
->mstartinventE
&& !(obj
->oartifact
) && !(obj
->fakeartifact
&& !rn2(20)) && rn2(20) ) {
7523 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
7525 t_timeout
= rnz(1000);
7527 } else if (obj
&& obj
->mstartinventD
&& !(obj
->oartifact
) && !(obj
->fakeartifact
&& !rn2(4)) && rn2(4) ) {
7528 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
7530 t_timeout
= rnz(1000);
7532 } else if (obj
&& obj
->mstartinventX
) {
7533 You("vaporize %s %s!", s_suffix(mon_nam(mtmp
)), xname(obj
));
7535 t_timeout
= rnz(1000);
7539 You("knock %s %s to the %s!", s_suffix(mon_nam(mtmp
)), xname(obj
), surface(u
.ux
, u
.uy
));
7540 if (obj
->otyp
== CRYSKNIFE
&& (!obj
->oerodeproof
|| !rn2(10))) {
7541 obj
->otyp
= WORM_TOOTH
;
7542 obj
->oerodeproof
= 0;
7544 place_object(obj
, u
.ux
, u
.uy
);
7547 t_timeout
= rnz(1000);
7551 case T_INLAY_WARFARE
:
7553 if (!PlayerInSexyFlats
) {
7554 pline("You must be wearing sexy flats for that!");
7558 nomul(-2, "inhaling their own smelly inlay", FALSE
);
7559 make_confused(HConfusion
+ rnz(10), FALSE
);
7560 set_itimeout(&HeavyConfusion
, HConfusion
);
7564 int inlayradius
= rnd(5);
7565 int mondistance
= 0;
7566 struct monst
*mtmp3
;
7569 for (k
= -inlayradius
; k
<= inlayradius
; k
++) for(l
= -inlayradius
; l
<= inlayradius
; l
++) {
7570 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
7573 if (k
> 1) mondistance
= k
;
7574 if (k
< -1) mondistance
= -k
;
7576 if (l
> 1 && l
> mondistance
) mondistance
= l
;
7577 if (l
< -1 && (-l
> mondistance
)) mondistance
= -l
;
7579 if ( (mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) {
7580 mtmp3
->mcanmove
= 0;
7581 mtmp3
->mfrozen
= (16 - (mondistance
* 2));
7582 mtmp3
->mstrategy
&= ~STRAT_WAITFORU
;
7583 mtmp3
->mconf
= TRUE
;
7584 pline("%s becomes dizzy from the smell!", Monnam(mtmp3
));
7585 if (mtmp3
->mpeaceful
&& !mtmp3
->mtame
) mtmp3
->mpeaceful
= 0; /* monster becomes hostile */
7589 if (!PlayerCannotUseSkills
&& P_SKILL(P_SEXY_FLATS
) >= P_SUPREME_MASTER
)
7590 (void) create_gas_cloud(u
.ux
, u
.uy
, 4, 12);
7592 (void) create_gas_cloud(u
.ux
, u
.uy
, 3, 8);
7595 t_timeout
= rnz(4000);
7599 case T_DIAMOND_BARRIER
:
7601 pline("You try to erect barriers!");
7603 if (Role_if(PM_WALSCHOLAR
)) {
7604 register struct obj
*waldiamond
;
7606 waldiamond
= carrying(DIAMOND
);
7609 pline("But you don't have a diamond to create them...");
7614 if (waldiamond
->quan
> 1) {
7616 waldiamond
->owt
= weight(waldiamond
);
7618 else useup(waldiamond
);
7619 You("use a diamond to create the barriers.");
7626 int diamondradius
= 1;
7628 if (Role_if(PM_WALSCHOLAR
)) diamondradius
= 3; /* can't reduce, unlike mason */
7630 if (Role_if(PM_MASON
)) {
7632 diamondradius
= rounddiv(techlevX(tech_no
), 5);
7633 if ((techlevX(tech_no
), 5) > 4) diamondradius
++; /* fix off-by-one error --Amy */
7634 if (diamondradius
< 1) diamondradius
= 1;
7636 if (diamondradius
> 1) pline("The maximum possible radius for the diamond barrier is %d, but you may opt to choose a smaller radius if you want.", diamondradius
);
7638 while (diamondradius
> 1) {
7639 pline("Current diamond barrier radius is %d.", diamondradius
);
7641 if (yn("Reduce the radius by one?") == 'y') diamondradius
--;
7645 pline("Using radius %d for the diamond barrier.", diamondradius
);
7651 for (k
= -diamondradius
; k
<= diamondradius
; k
++) for(l
= -diamondradius
; l
<= diamondradius
; l
++) {
7652 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
7653 if (k
== 0 && l
== 0) continue; /* don't place wall on your own position --Amy */
7655 if (isok(u
.ux
+ k
, u
.uy
+ l
) && (levl
[u
.ux
+ k
][u
.uy
+ l
].typ
== ROOM
|| levl
[u
.ux
+ k
][u
.uy
+ l
].typ
== CORR
|| (levl
[u
.ux
+ k
][u
.uy
+ l
].typ
== DOOR
&& levl
[u
.ux
+ k
][u
.uy
+ l
].doormask
== D_NODOOR
) ) ) {
7657 if (levl
[u
.ux
+ k
][u
.uy
+ l
].typ
!= DOOR
) levl
[u
.ux
+ k
][u
.uy
+ l
].typ
= GRAVEWALL
;
7658 else doorlockX(u
.ux
+ k
, u
.uy
+ l
, TRUE
);
7659 blockorunblock_point(u
.ux
+ k
, u
.uy
+ l
);
7660 newsym(u
.ux
+ k
, u
.uy
+ l
);
7669 if (Role_if(PM_WALSCHOLAR
)) {
7670 u
.walscholarpass
+= (rnd(50) + rnd(techlevX(tech_no
) * 5) );
7671 pline("For a while, you can freely pass through grave walls!");
7674 t_timeout
= Role_if(PM_MASON
) ? rnz(1000) : rnz(5000);
7679 num
= 100 + (techlevX(tech_no
) * 5);
7680 techt_inuse(tech_no
) = num
+ 1;
7681 pline("Your %s become steady.", makeplural(body_part(HAND
)));
7683 t_timeout
= rnz(2000);
7686 case T_FORCE_FILLING
:
7688 You_feel("full of mystic power!");
7690 if (!rn2(20)) u
.uen
+= (400 + rnz(techlevX(tech_no
)));
7691 else if (!rn2(5)) u
.uen
+= (d(6,8) + rnz(techlevX(tech_no
)));
7692 else u
.uen
+= (d(5,6) + rnz(techlevX(tech_no
)));
7693 if (u
.uen
> u
.uenmax
) u
.uen
= u
.uenmax
;
7695 t_timeout
= rnz(1000);
7698 case T_JEDI_TAILORING
:
7704 uroub
= mksobj(rnd_class(ROBE
, ROBE_OF_WEAKNESS
), TRUE
, FALSE
, FALSE
);
7709 pline("A robe appeared at your %s!", makeplural(body_part(FOOT
)));
7710 } else pline("For some unknown reason, the tailoring attempt failed.");
7714 t_timeout
= rnz(15000);
7717 case T_INTRINSIC_SACRIFICE
:
7719 if (!(uwep
&& is_lightsaber(uwep
) && u
.twoweap
&& uswapwep
&& is_lightsaber(uswapwep
))) {
7720 pline("That only works if you are dual-wielding lightsabers!");
7726 if (uwep
&& is_lightsaber(uwep
)) {
7728 if (uwep
->otyp
== ORANGE_LIGHTSABER
) uwep
->age
+= (1000 * rnd(2));
7729 if (uwep
->oartifact
== ART_DESANN_S_WRATH
) uwep
->age
+= (1000 * rnd(2));
7731 if (uswapwep
&& is_lightsaber(uswapwep
)) {
7732 uswapwep
->age
+= 1000;
7733 if (uswapwep
->otyp
== ORANGE_LIGHTSABER
) uswapwep
->age
+= (1000 * rnd(2));
7734 if (uswapwep
->oartifact
== ART_DESANN_S_WRATH
) uswapwep
->age
+= (1000 * rnd(2));
7737 pline("Lightsaber energy replenished. Did it cost you an important intrinsic?");
7739 t_timeout
= rnz(10000);
7743 num
= 100 + (techlevX(tech_no
) * 3);
7744 techt_inuse(tech_no
) = num
+ 1;
7745 pline("Your lightsaber can fire beams now!");
7747 t_timeout
= rnz(2500);
7750 case T_ENERGY_TRANSFER
:
7751 num
= 200 + (techlevX(tech_no
) * 5);
7752 techt_inuse(tech_no
) = num
+ 1;
7753 pline("For a while, casting spells will recharge your lightsaber (but it must be lit).");
7755 t_timeout
= rnz(5000);
7758 case T_SOFTEN_TARGET
:
7761 pline("Softening an engulfer unfortunately doesn't work.");
7765 if (!getdir((char *)0)) return(0);
7766 if (!u
.dx
&& !u
.dy
) {
7767 /* Hopefully a mistake ;B */
7768 pline("You can't soften yourself!");
7771 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
7772 pline("Invalid target location.");
7775 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
7776 if (!mtmp
|| !canspotmon(mtmp
)) {
7777 if (memory_is_invisible(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
))
7778 pline("Can't soften what you can't see!");
7780 You("don't see anything there!");
7786 pline("%s suddenly seems weaker!", Monnam(mtmp
));
7787 mtmp
->mhpmax
-= xtmp
;
7789 if (xtmp
< mtmp
->mhp
) showdmg(xtmp
);
7791 if ((mtmp
->mhp
-= xtmp
) <= 0 || !mtmp
->m_lev
) {
7792 pline("%s dies!", Monnam(mtmp
));
7796 wakeup(mtmp
); /* monster becomes hostile */
7800 t_timeout
= rnz(10000);
7803 case T_PROTECT_WEAPON
:
7804 if (!uwep
|| !bimanual(uwep
)) {
7805 pline("This requires you to wield a bimanual weapon, which you currently don't.");
7808 uwep
->oerodeproof
= 1;
7810 pline("Alright - your weapon is erosionproof now.");
7812 t_timeout
= rnz(10000);
7815 case T_POWERFUL_AURA
:
7816 num
= 40 + (techlevX(tech_no
) * 3);
7817 techt_inuse(tech_no
) = num
+ 1;
7818 pline("A powerful aura surrounds you!");
7820 t_timeout
= rnz(3000);
7824 if (!uwep
|| weapon_type(uwep
) != P_QUARTERSTAFF
) {
7825 pline("How are you going to boost your staff if you don't wield it?");
7828 pline("Your staff is surrounded by a shimmering aura.");
7829 uncurse(uwep
, TRUE
);
7831 if (uwep
&& uwep
->spe
< 2) {
7833 } else if (uwep
&& uwep
->spe
< 8 && !rn2(uwep
->spe
) ) {
7837 t_timeout
= rnz(6000);
7840 case T_CLONE_JAVELIN
:
7841 if (!uwep
|| weapon_type(uwep
) != P_JAVELIN
) {
7842 pline("This requires you to actually wield the javelin that you want to clone.");
7846 uwep
->owt
= weight(uwep
);
7847 pline("A new javelin is created out of thin air!");
7848 t_timeout
= rnz(7000);
7852 num
= 20 + techlevX(tech_no
);
7853 techt_inuse(tech_no
) = num
+ 1;
7854 pline("Refuge activated!");
7856 t_timeout
= rnz(2400);
7859 case T_DRAINING_PUNCH
:
7861 if (!canuseunarmedtechs()) {
7862 You("can't do this while wielding a weapon!");
7863 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
7866 /* used to be impossible with a shield but that was dumb --Amy */
7867 if (!getdir((char *)0)) return(0);
7868 if (!u
.dx
&& !u
.dy
) {
7869 You("flex your muscles.");
7872 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
7873 pline("Invalid target location.");
7877 if (!blitz_draining_punch()) return(0);
7879 t_timeout
= rnz(2000);
7885 pline("Without armor, that technique won't do anything.");
7888 if (uarm
&& !(uarm
->otyp
>= ROBE
&& uarm
->otyp
<= ROBE_OF_WEAKNESS
)) {
7889 pline("That technique won't work if your worn armor isn't a robe!");
7893 num
= 50 + (techlevX(tech_no
) * 3);
7894 techt_inuse(tech_no
) = num
+ 1;
7895 pline("Escrobism started - your bare hands or lightsaber will temporarily deal extra damage while you are wearing a robe.");
7897 t_timeout
= rnz(4000);
7900 case T_PIRATE_BROTHERING
:
7903 pline("This won't work if you don't dual-wield!");
7906 if (uwep
&& !is_lightsaber(uwep
)) {
7907 pline("Your primary weapon isn't a lightsaber, and therefore this technique won't work!");
7910 if (uswapwep
&& weapon_type(uswapwep
) != P_SCIMITAR
) {
7911 pline("Your secondary weapon isn't a scimitar, and therefore this technique won't work!");
7914 if (!uwep
|| !uswapwep
) {
7915 pline("At least one of your hands isn't wielding any weapon, and therefore this technique won't work!");
7919 num
= 250 + (techlevX(tech_no
) * 10);
7920 techt_inuse(tech_no
) = num
+ 1;
7921 pline("Alright, your lightsaber loses no energy and can be recharged by hitting things with the scimitar.");
7923 t_timeout
= rnz(5000);
7926 case T_NUTS_AND_BOLTS
:
7928 You("make crossbow ammo and increase your satiation.");
7932 uammo
= mksobj(CROSSBOW_BOLT
, TRUE
, FALSE
, FALSE
);
7934 uammo
->quan
= rnd(20 + (2 * techlevX(tech_no
)));
7935 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
7936 uammo
->owt
= weight(uammo
);
7943 t_timeout
= rnz(4000);
7946 case T_WONDER_YONDER
:
7949 int inerduration
= rnz(1000);
7950 int nastyfects
= rnd(5);
7951 if (!inertiaprotection()) {
7952 u
.uprops
[DEAC_FAST
].intrinsic
+= inerduration
;
7953 u
.inertia
+= inerduration
;
7954 You_feel("lethargic...");
7956 while (nastyfects
> 0) {
7963 t_timeout
= rnz(15000);
7968 if (CannotSelectItemsInPrompts
) break;
7970 otmp
= getobj(allnoncount
, "duplicate");
7972 if (yn("Really exit with no object selected?") == 'y')
7973 pline("You just wasted the opportunity to duplicate a scroll.");
7974 else goto cardtrickchoice
;
7975 pline("A feeling of loss comes over you.");
7980 if (otmp
->oclass
!= SCROLL_CLASS
) {
7981 pline("That isn't a scroll, and therefore the card trick was wasted.");
7982 t_timeout
= rnz(10000);
7985 if (otmp
->oartifact
) {
7986 pline("Artifact scrolls cannot be duplicated, and therefore the card trick was wasted.");
7987 t_timeout
= rnz(10000);
7991 int cardpotency
= 50 + techlevX(tech_no
);
7992 if (rnd(cardpotency
) > writecost(otmp
)) {
7993 pline("Success! You managed to duplicate the scroll.");
7995 otmp
->owt
= weight(otmp
);
7997 pline("Unfortunately your attempt to duplicate the scroll failed.");
8001 t_timeout
= rnz(10000);
8006 additionalskilltraining(rnd(10));
8007 t_timeout
= rnz(10000);
8010 case T_SHOTTY_BLAST
:
8015 pline("You can choose from these kinds of ammo: shotgun shells or auto shotgun shells.");
8017 boolean haschosen
= FALSE
;
8018 pline("Pick an ammo type that you want to create. The prompt will loop until you actually make a choice.");
8019 while (!haschosen
) {
8020 if (yn("Do you want to create shotgun shells?") == 'y') {
8024 else if (yn("Do you want to create auto shotgun shells?") == 'y') {
8030 You("make some shotgun shells.");
8036 if (ammotype
== 1) uammo
= mksobj(AUTO_SHOTGUN_SHELL
, TRUE
, FALSE
, FALSE
);
8037 else uammo
= mksobj(SHOTGUN_SHELL
, TRUE
, FALSE
, FALSE
);
8039 uammo
->quan
= 5 + (techlevX(tech_no
) / 3);
8040 if (uammo
->quan
< 1) uammo
->quan
= 1;
8041 if (uarmc
&& uarmc
->oartifact
== ART_ARABELLA_S_WEAPON_STORAGE
) uammo
->quan
*= 2;
8042 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
8043 uammo
->owt
= weight(uammo
);
8050 t_timeout
= rnz(5000);
8054 case T_AMMO_UPGRADE
:
8057 pline("You're not wielding anything!");
8060 if (uwep
&& !is_bullet(uwep
)) {
8061 pline("You're not wielding firearm ammo!");
8064 if (uwep
&& is_bullet(uwep
)) {
8065 You("try to upgrade your ammo.");
8066 if (stack_too_big(uwep
)) {
8067 t_timeout
= rnz(4000);
8068 pline("But the stack size was too big, and therefore it failed.");
8072 if (uwep
->cursed
) uncurse(uwep
, TRUE
);
8073 else if (!uwep
->cursed
&& !uwep
->blessed
) bless(uwep
);
8074 if (uwep
->spe
< 2) uwep
->spe
++;
8075 else if (uwep
->spe
< 10 && uwep
->spe
> 1 && !rn2(uwep
->spe
)) uwep
->spe
++;
8079 t_timeout
= rnz(10000);
8086 pline("You can choose from these kinds of ammo: blaster bolts, heavy blaster bolts, laser beams, raygun bolts or radios.");
8088 boolean haschosen
= FALSE
;
8089 pline("Pick an ammo type that you want to create. The prompt will loop until you actually make a choice.");
8090 while (!haschosen
) {
8091 if (yn("Do you want to create blaster bolts?") == 'y') {
8095 else if (yn("Do you want to create heavy blaster bolts?") == 'y') {
8099 else if (yn("Do you want to create laser beams?") == 'y') {
8103 else if (yn("Do you want to create raygun bolts?") == 'y') {
8107 else if (yn("Do you want to create radios?") == 'y') {
8111 else if (yn("Do you want to create carcosan bolts?") == 'y') {
8117 You("make some laser ammo.");
8123 if (ammotype
== 5) uammo
= mksobj(BLASTER_BOLT
, TRUE
, FALSE
, FALSE
);
8124 else if (ammotype
== 4) uammo
= mksobj(HEAVY_BLASTER_BOLT
, TRUE
, FALSE
, FALSE
);
8125 else if (ammotype
== 3) uammo
= mksobj(LASER_BEAM
, TRUE
, FALSE
, FALSE
);
8126 else if (ammotype
== 2) uammo
= mksobj(RAYGUN_BOLT
, TRUE
, FALSE
, FALSE
);
8127 else if (ammotype
== 6) uammo
= mksobj(CARCOSAN_BOLT
, TRUE
, FALSE
, FALSE
);
8128 else uammo
= mksobj(RADIO
, TRUE
, FALSE
, FALSE
);
8131 uammo
->quan
= 10 + techlevX(tech_no
);
8132 if (uammo
->quan
< 1) uammo
->quan
= 1;
8133 if (uarmc
&& uarmc
->oartifact
== ART_ARABELLA_S_WEAPON_STORAGE
) uammo
->quan
*= 2;
8134 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
8135 uammo
->owt
= weight(uammo
);
8142 t_timeout
= rnz(7500);
8148 You("make a rocket launcher.");
8154 uammo
= mksobj(ROCKET_LAUNCHER
, TRUE
, FALSE
, FALSE
);
8156 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
8161 uammo
= mksobj(ROCKET
, TRUE
, FALSE
, FALSE
);
8163 uammo
->quan
= 5 + (techlevX(tech_no
) / 3);
8164 if (uammo
->quan
< 1) uammo
->quan
= 1;
8165 if (uarmc
&& uarmc
->oartifact
== ART_ARABELLA_S_WEAPON_STORAGE
) uammo
->quan
*= 2;
8166 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
8167 uammo
->owt
= weight(uammo
);
8174 t_timeout
= rnz(25000);
8177 case T_SHUT_THAT_BITCH_UP
:
8179 num
= 20 + (techlevX(tech_no
) * 3);
8180 techt_inuse(tech_no
) = num
+ 1;
8181 pline("Your firearms can temporarily shut up bitches upon hitting them.");
8183 t_timeout
= rnz(15000);
8188 if (t_at(u
.ux
, u
.uy
)) {
8189 pline("There is a trap at your location, and therefore the attempt fails!");
8190 t_timeout
= rnz(2000);
8193 if (u
.uhunger
< 500) {
8194 You("don't have enough nutrition, and therefore the attempt fails!");
8195 t_timeout
= rnz(2000);
8200 ttrap
= maketrap(u
.ux
, u
.uy
, S_PRESSING_TRAP
, 0, FALSE
);
8201 if (ttrap
&& !ttrap
->hiddentrap
) {
8203 ttrap
->madeby_u
= 1;
8206 /* launch_otyp is set in trap.c and controls the trap's strength --Amy */
8207 You("laid a trap.");
8208 u
.uhunger
-= 500; /* not "morehungry", not affected by full nutrients */
8210 if (practicantterror
) {
8211 pline("%s thunders: 'You shitty practicant lass! Your act of shitting up my laboratory will not be tolerated! Now you pay 5000 zorkmids and clean away your shit, got it?'", noroelaname());
8212 fineforpracticant(5000, 0, 0);
8217 register struct monst
*nexusmon
, *nextmon
;
8219 for(nexusmon
= fmon
; nexusmon
; nexusmon
= nextmon
) {
8220 nextmon
= nexusmon
->nmon
;
8221 if (DEADMONSTER(nexusmon
)) continue;
8222 if (canseemon(nexusmon
)) nexusmon
->spressingseen
= TRUE
;
8226 use_skill(P_SQUEAKING
, rnd(20));
8228 t_timeout
= rnz(2000);
8234 int melteestrength
= 1;
8235 if (techlevX(tech_no
) > 9) melteestrength
+= (techlevX(tech_no
) / 10);
8237 if (practicantterror
) {
8238 pline("%s thunders: 'What do you think you're doing here, peeing in my laboratory? That makes 10000 zorkmids, and your mirror is confiscated too to make you hopefully repent your deeds!'", noroelaname());
8239 fineforpracticant(10000, 0, 0);
8240 u
.uprops
[DEAC_REFLECTING
].intrinsic
+= 10000;
8243 techt_inuse(tech_no
) = 1;
8244 buzz(17, melteestrength
, u
.ux
, u
.uy
, -1, 0);
8245 buzz(17, melteestrength
, u
.ux
, u
.uy
, 1, 0);
8246 buzz(17, melteestrength
, u
.ux
, u
.uy
, -1, 1);
8247 buzz(17, melteestrength
, u
.ux
, u
.uy
, 1, 1);
8248 buzz(17, melteestrength
, u
.ux
, u
.uy
, 0, 1);
8249 buzz(17, melteestrength
, u
.ux
, u
.uy
, -1, -1);
8250 buzz(17, melteestrength
, u
.ux
, u
.uy
, 1, -1);
8251 buzz(17, melteestrength
, u
.ux
, u
.uy
, 0, -1);
8252 techt_inuse(tech_no
) = 0;
8256 use_skill(P_SQUEAKING
, rnd(50));
8257 t_timeout
= rnz(5000);
8260 case T_WOMAN_NOISES
:
8262 You("make very female noises!");
8264 register struct monst
*nexusmon
, *nextmon
;
8266 for(nexusmon
= fmon
; nexusmon
; nexusmon
= nextmon
) {
8267 nextmon
= nexusmon
->nmon
; /* trap might kill mon */
8268 if (DEADMONSTER(nexusmon
)) continue;
8269 if (nexusmon
->mpeaceful
|| nexusmon
->mtame
) continue;
8270 if (resist(nexusmon
, SPBOOK_CLASS
, 0, NOTELL
)) continue;
8271 if (resist(nexusmon
, SPBOOK_CLASS
, 0, NOTELL
)) continue;
8273 if (distu(nexusmon
->mx
, nexusmon
->my
) > rnd(50)) continue;
8275 /* doesn't anger peaceful ones - not a bug --Amy */
8276 pline("%s cannot resist!", Monnam(nexusmon
));
8277 monflee(nexusmon
, rnd(20), FALSE
, TRUE
);
8278 if (nexusmon
->mblinded
< 100) nexusmon
->mblinded
+= 20;
8279 nexusmon
->mcansee
= 0;
8280 nexusmon
->mstun
= TRUE
;
8281 nexusmon
->mconf
= TRUE
;
8283 if (!resists_drain(nexusmon
) && !resist(nexusmon
, SPBOOK_CLASS
, 0, NOTELL
)) {
8284 pline("%s shudders in dread!", Monnam(nexusmon
));
8285 nexusmon
->mhpmax
-= rnd(10);
8286 if (nexusmon
->mhpmax
< 1) nexusmon
->mhpmax
= 1;
8287 if (nexusmon
->mhp
> nexusmon
->mhpmax
) nexusmon
->mhp
= nexusmon
->mhpmax
;
8288 nexusmon
->m_enmax
-= rnd(10);
8289 if (nexusmon
->m_enmax
< 0) nexusmon
->m_enmax
= 0;
8290 if (nexusmon
->m_en
> nexusmon
->m_enmax
) nexusmon
->m_en
= nexusmon
->m_enmax
;
8291 if (nexusmon
->m_lev
> 0) nexusmon
->m_lev
--;
8292 if (nexusmon
->m_lev
> 0 && !rn2(4)) nexusmon
->m_lev
--;
8298 if (practicantterror
) {
8299 pline("%s rings out: 'Your irritating noises are disturbing the other practicants, so here's a warning for you to not do that again and I also receive 50 zorkmids from you.'", noroelaname());
8300 fineforpracticant(50, 0, 0);
8303 use_skill(P_SQUEAKING
, rnd(50));
8304 t_timeout
= rnz(5000);
8307 case T_EXTRA_LONG_SQUEAK
:
8309 num
= 20 + techlevX(tech_no
);
8310 techt_inuse(tech_no
) = num
+ 1;
8311 pline("Your butt starts squeaking.");
8312 use_skill(P_SQUEAKING
, rnd(50));
8313 t_timeout
= rnz(5000);
8319 pline("Did you seriously expect to be able to hug a monster that has engulfed you?");
8326 struct monst
*mtmp3
;
8328 pline("You try to hug the monsters next to you!");
8330 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
8331 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
8332 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !is_infrastructure_monster(mtmp3
) && mtmp3
->mtame
== 0 && mtmp3
->isminion
== 0 && mtmp3
->isgyp
== 0 && !is_rider(mtmp3
->data
) && !is_deadlysin(mtmp3
->data
)
8333 && mtmp3
->mnum
!= quest_info(MS_NEMESIS
) && !(rn2(5) && mtmp3
->data
->geno
& G_UNIQ
) && caughtX
== 0)
8337 if (humanoid(mtmp3
->data
) && !mtmp3
->female
) {
8338 pline("%s is infatuated with you and asks to become your slave!", mon_nam(mtmp3
));
8339 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
8340 if (techlevX(tech_no
) < rnd(100)) caughtX
++;
8341 t_timeout
= rnz(20000);
8344 else pline("%s brushes you away.", mon_nam(mtmp3
));
8346 } /* monster is catchable loop */
8351 if (practicantterror
) {
8352 pline("%s thunders: 'You've molested the male practicants! That's 5000 zorkmids on the spot and I told all of them that you're a mean sexual predator. Do that again and you'll receive hall exclusion.'", noroelaname());
8353 fineforpracticant(5000, 0, 0);
8354 HateTrapEffect
+= 10000;
8357 t_timeout
= rnz(20000);
8362 Your("gender is changed!");
8365 if (practicantterror
) {
8366 pline("%s thunders: 'That type of surgery is dangerous! You've practiced it without adhering to standard safety precautions, meaning there's now a fine of 20000 zorkmids and I'll also collect any money you gain from now on to teach you a lesson!'", noroelaname());
8367 fineforpracticant(20000, 0, 0);
8368 BankTrapEffect
|= FROMOUTSIDE
;
8371 t_timeout
= rnz(10000);
8374 case T_EVEN_MORE_AMMO
:
8377 pline("You're not wielding anything!");
8380 if (uwep
&& !is_bullet(uwep
)) {
8381 pline("You're not wielding firearm ammo!");
8384 if (uwep
&& is_bullet(uwep
)) {
8385 if (uwep
->otyp
== SMG_BULLET
|| uwep
->otyp
== ANTIMATTER_SMG_BULLET
|| uwep
->otyp
== MG_BULLET
|| uwep
->otyp
== ANTIMATTER_MG_BULLET
|| uwep
->otyp
== RIFLE_BULLET
|| uwep
->otyp
== ANTIMATTER_RIFLE_BULLET
|| uwep
->otyp
== SNIPER_BULLET
|| uwep
->otyp
== ANTIMATTER_SNIPER_BULLET
|| uwep
->otyp
== ASSAULT_RIFLE_BULLET
|| uwep
->otyp
== LOWRATE_ASSAULT_RIFLE_BULLET
|| uwep
->otyp
== ANTIMATTER_ASSAULT_RIFLE_BULLE
|| uwep
->otyp
== PISTOL_BULLET
|| uwep
->otyp
== SILVER_PISTOL_BULLET
|| uwep
->otyp
== LEAD_PISTOL_BULLET
|| uwep
->otyp
== FIVE_SEVEN_BULLET
|| uwep
->otyp
== SHADOW_FIVE_SEVEN_BULLET
|| uwep
->otyp
== LEAD_FIVE_SEVEN_BULLET
|| uwep
->otyp
== LEAD_SMG_BULLET
|| uwep
->otyp
== BRONZE_SMG_BULLET
|| uwep
->otyp
== LEAD_RIFLE_BULLET
|| uwep
->otyp
== COPPER_RIFLE_BULLET
|| uwep
->otyp
== LEAD_MG_BULLET
|| uwep
->otyp
== HOLLOW_POINT_MG_BULLET
|| uwep
->otyp
== LEAD_SNIPER_BULLET
|| uwep
->otyp
== PLATINUM_SNIPER_BULLET
|| uwep
->otyp
== LEAD_ASSAULT_RIFLE_BULLET
|| uwep
->otyp
== ANTIMATTER_PISTOL_BULLET
|| uwep
->otyp
== ANTIMATTER_FIVE_SEVEN_BULLET
|| uwep
->otyp
== BLASTER_BOLT
|| uwep
->otyp
== RAYGUN_BOLT
|| uwep
->otyp
== RADIO
|| uwep
->otyp
== HEAVY_BLASTER_BOLT
|| uwep
->otyp
== LASER_BEAM
) {
8386 uwep
->quan
+= (20 + techlevX(tech_no
));
8387 pline("The amount of ammo was increased!");
8388 } else if (uwep
->otyp
== BFG_AMMO
|| uwep
->otyp
== CARCOSAN_BOLT
) {
8389 uwep
->quan
+= (80 + (techlevX(tech_no
) * 5));
8390 pline("The amount of ammo was increased!");
8391 } else if (uwep
->otyp
== SHOTGUN_SHELL
|| uwep
->otyp
== CHROME_PELLET
|| uwep
->otyp
== AUTO_SHOTGUN_SHELL
|| uwep
->otyp
== LEAD_SHOT
|| uwep
->otyp
== AUTO_LEAD_SHOT
|| uwep
->otyp
== COATED_AUTO_SHELL
) {
8392 uwep
->quan
+= (10 + (techlevX(tech_no
) / 2));
8393 pline("The amount of ammo was increased!");
8394 } else if (uwep
->otyp
== ROCKET
) {
8395 uwep
->quan
+= (1 + (techlevX(tech_no
) / 5));
8396 pline("The amount of ammo was increased!");
8398 pline("The ammo you're wielding cannot be duplicated. Sorry. Please try some other type of ammo.");
8402 t_timeout
= rnz(8000);
8408 pline("That doesn't work if you're not polymorphed.");
8411 You("try to clone yourself!");
8413 t_timeout
= rnz(20000);
8418 if (CannotSelectItemsInPrompts
) break;
8420 otmp
= getobj(allnoncount
, "polyfix");
8422 if (yn("Really exit with no object selected?") == 'y')
8423 pline("You just wasted the opportunity to polyfix an item.");
8424 else goto polyfixchoice
;
8425 pline("A feeling of loss comes over you.");
8430 if (!is_hazy(otmp
)) {
8431 pline("That item wasn't hazy, and therefore nothing happens.");
8432 } else if (!stack_too_big(otmp
)) {
8433 stop_timer(UNPOLY_OBJ
, (void *) otmp
);
8434 otmp
->oldtyp
= STRANGE_OBJECT
;
8435 pline("%s is no longer hazy.", Yname2(otmp
));
8436 if (otmp
&& objects
[(otmp
)->otyp
].oc_material
== MT_CELESTIUM
&& !stack_too_big(otmp
)) {
8437 if (!otmp
->cursed
) bless(otmp
);
8438 else uncurse(otmp
, FALSE
);
8440 } else pline("The stack was too big, and therefore nothing happens.");
8444 t_timeout
= rnz(5000);
8447 case T_SQUEAKY_REPAIR
:
8449 if (CannotSelectItemsInPrompts
) break;
8450 if (t_at(u
.ux
, u
.uy
)) {
8451 pline("There is a trap at your location, and therefore the attempt fails!");
8452 t_timeout
= rnz(8000);
8457 ttrap
= maketrap(u
.ux
, u
.uy
, FART_TRAP
, 0, TRUE
);
8461 pline("You may repair a damaged item.");
8463 otmp
= getobj(allnoncount
, "magically repair");
8465 if (yn("Really exit with no object selected?") == 'y')
8466 pline("You just wasted the opportunity to repair your items.");
8467 else goto repairitemchoice
;
8468 pline("A feeling of loss comes over you.");
8469 t_timeout
= rnz(8000);
8471 } else if (stack_too_big(otmp
)) {
8472 pline("The stack was too big, and therefore the attempt failed.");
8473 } else if (otmp
&& greatest_erosion(otmp
) > 0) {
8474 pline("Your %s is in perfect condition again!", xname(otmp
));
8475 if (otmp
->oeroded
> 0) { otmp
->oeroded
= 0; }
8476 if (otmp
->oeroded2
> 0) { otmp
->oeroded2
= 0; }
8477 if (otmp
&& objects
[(otmp
)->otyp
].oc_material
== MT_CELESTIUM
&& !stack_too_big(otmp
)) {
8478 if (!otmp
->cursed
) bless(otmp
);
8479 else uncurse(otmp
, FALSE
);
8482 } else pline("Your %s is still as undamaged as ever.", xname(otmp
));
8484 } else pline("For some unknown reason, the attempt failed.");
8486 use_skill(P_SQUEAKING
, rnd(80));
8487 t_timeout
= rnz(8000);
8492 num
= 100 + (techlevX(tech_no
) * 5);
8493 techt_inuse(tech_no
) = num
+ 1;
8494 pline("Your ammo can temporarily be reused.");
8495 t_timeout
= rnz(10000);
8498 case T_TERRAIN_CLEANUP
:
8500 pline("You try to clean up annoying terrain.");
8503 do_clear_areaX(u
.ux
, u
.uy
, 1, terraincleanup
, (void *)&maderoomX
);
8505 if (maderoomX
) pline("Some annoying terrain was cleaned up!");
8506 else pline("There was nothing to clean up...");
8508 t_timeout
= rnz(8000);
8516 /* symbiant and goauld can use it more often... but they're too different, and therefore
8517 * being a goauld symbiant doesn't reduce the timeout by more :P --Amy */
8519 int symbiotimer
= 20000;
8521 if (!PlayerCannotUseSkills
) {
8522 switch (P_SKILL(P_SYMBIOSIS
)) {
8525 symbiotimer
= 18000;
8528 symbiotimer
= 16000;
8531 symbiotimer
= 14000;
8534 symbiotimer
= 12000;
8536 case P_GRAND_MASTER
:
8537 symbiotimer
= 10000;
8539 case P_SUPREME_MASTER
:
8546 if (Role_if(PM_SYMBIANT
) || Race_if(PM_GOAULD
)) symbiotimer
/= 2;
8548 struct obj
*usymbioteitem
;
8550 pline("A symbiote is created!");
8551 usymbioteitem
= mksobj(SYMBIOTE
, TRUE
, FALSE
, FALSE
);
8552 if (usymbioteitem
) {
8553 usymbioteitem
->quan
= 1;
8554 usymbioteitem
->known
= usymbioteitem
->dknown
= usymbioteitem
->bknown
= usymbioteitem
->rknown
= 1;
8555 usymbioteitem
->owt
= weight(usymbioteitem
);
8556 usymbioteitem
->finalcancel
= TRUE
; /* no polymorphing exploits, sorry --Amy */
8557 dropy(usymbioteitem
);
8558 stackobj(usymbioteitem
);
8561 t_timeout
= rnz(symbiotimer
);
8567 case T_ADJUST_SYMBIOTE
:
8569 /* intentional that you can use this even while not having a symbiote --Amy */
8570 if (!PlayerCannotUseSkills
&& (P_SKILL(P_SYMBIOSIS
) >= P_SKILLED
)) {
8572 pline("Currently your symbiote's aggressiveness is %d%%.", u
.symbioteaggressivity
);
8574 int lowerbound
, higherbound
;
8578 switch (P_SKILL(P_SYMBIOSIS
)) {
8591 case P_GRAND_MASTER
:
8595 case P_SUPREME_MASTER
:
8605 pline("You can set the aggressivity to values between %d%% and %d%% (inclusive).", lowerbound
, higherbound
);
8606 if (lowerbound
<= 5 && yn("Set the aggressivity to 5%%?") == 'y') {
8607 u
.symbioteaggressivity
= 5;
8608 pline("Your symbiote's aggressivity is 5%% now.");
8609 } else if (lowerbound
<= 10 && yn("Set the aggressivity to 10%%?") == 'y') {
8610 u
.symbioteaggressivity
= 10;
8611 pline("Your symbiote's aggressivity is 10%% now.");
8612 } else if (lowerbound
<= 12 && yn("Set the aggressivity to 12%%?") == 'y') {
8613 u
.symbioteaggressivity
= 12;
8614 pline("Your symbiote's aggressivity is 12%% now.");
8615 } else if (lowerbound
<= 15 && yn("Set the aggressivity to 15%%?") == 'y') {
8616 u
.symbioteaggressivity
= 15;
8617 pline("Your symbiote's aggressivity is 15%% now.");
8618 } else if (lowerbound
<= 20 && yn("Set the aggressivity to 20%%?") == 'y') {
8619 u
.symbioteaggressivity
= 20;
8620 pline("Your symbiote's aggressivity is 20%% now.");
8621 } else if (yn("Set the aggressivity to 25%%?") == 'y') {
8622 u
.symbioteaggressivity
= 25;
8623 pline("Your symbiote's aggressivity is 25%% now.");
8624 } else if (higherbound
>= 33 && yn("Set the aggressivity to 33%%?") == 'y') {
8625 u
.symbioteaggressivity
= 33;
8626 pline("Your symbiote's aggressivity is 33%% now.");
8627 } else if (higherbound
>= 40 && yn("Set the aggressivity to 40%%?") == 'y') {
8628 u
.symbioteaggressivity
= 40;
8629 pline("Your symbiote's aggressivity is 40%% now.");
8630 } else if (higherbound
>= 50 && yn("Set the aggressivity to 50%%?") == 'y') {
8631 u
.symbioteaggressivity
= 50;
8632 pline("Your symbiote's aggressivity is 50%% now.");
8633 } else if (higherbound
>= 60 && yn("Set the aggressivity to 60%%?") == 'y') {
8634 u
.symbioteaggressivity
= 60;
8635 pline("Your symbiote's aggressivity is 60%% now.");
8636 } else if (higherbound
>= 75 && yn("Set the aggressivity to 75%%?") == 'y') {
8637 u
.symbioteaggressivity
= 75;
8638 pline("Your symbiote's aggressivity is 75%% now.");
8639 } else pline("Your symbiote's aggressivity remains %d%%.", u
.symbioteaggressivity
);
8641 } else pline("Unfortunately your symbiosis skill is too low to use this ability.");
8643 t_timeout
= rnz(500);
8647 case T_HEAL_SYMBIOTE
:
8649 if (!uinsymbiosis
) {
8650 pline("You don't have a symbiote, so you can't heal it either!");
8653 if (u
.uhp
< ((u
.uhpmax
/ 2) + 1)) {
8654 pline("Your health is too low!");
8657 if (u
.uhpmax
< 5) { /* arbitrary */
8658 pline("Your health is too low!");
8661 u
.uhp
-= (u
.uhpmax
/ 2);
8662 u
.usymbiote
.mhp
+= (u
.uhpmax
/ 2);
8663 if (u
.usymbiote
.mhp
> u
.usymbiote
.mhpmax
) u
.usymbiote
.mhp
= u
.usymbiote
.mhpmax
;
8665 You("sap some of your health, and transfer it to your symbiote!");
8667 t_timeout
= rnz(2000);
8670 case T_BOOST_SYMBIOTE
:
8672 if (!uinsymbiosis
) {
8673 pline("You can't boost a nonexistant symbiote!");
8677 u
.usymbiote
.mhpmax
+= rnd(8);
8678 maybe_evolve_symbiote();
8679 if (u
.usymbiote
.mhpmax
> 500) u
.usymbiote
.mhpmax
= 500;
8680 if (flags
.showsymbiotehp
) flags
.botl
= TRUE
;
8681 Your("symbiote's health is improved!");
8683 t_timeout
= rnz(4000);
8686 case T_GRENADES_OF_COURSE
:
8688 You("make some grenades.");
8694 if (!rn2(2)) uammo
= mksobj(FRAG_GRENADE
, TRUE
, FALSE
, FALSE
);
8695 else uammo
= mksobj(GAS_GRENADE
, TRUE
, FALSE
, FALSE
);
8697 uammo
->quan
= 5 + (techlevX(tech_no
) / 5);
8698 if (Role_if(PM_GRENADONIN
)) uammo
->quan
*= 5;
8699 if (uammo
->quan
< 1) uammo
->quan
= 1;
8700 if (uarmc
&& uarmc
->oartifact
== ART_ARABELLA_S_WEAPON_STORAGE
) uammo
->quan
*= 2;
8701 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
8702 uammo
->owt
= weight(uammo
);
8709 t_timeout
= rnz(20000);
8713 if (Race_if(PM_MACTHEIST
)) {
8714 pline("As an atheist, you cannot use such a technique.");
8718 u
.uconduct
.gnostic
++; /* you just communicated with your god */
8719 if (Race_if(PM_MAGYAR
)) {
8720 You_feel("bad about breaking the atheist conduct.");
8723 use_skill(P_SPIRITUALITY
, Role_if(PM_PRIEST
) ? 5 : 1);
8724 adjalign(5 + techlevX(tech_no
) / 3);
8726 t_timeout
= rnz(4000);
8729 case T_ON_THE_SAME_TEAM
:
8732 pline("That doesn't work while you're engulfed!");
8739 struct monst
*mtmp3
;
8740 pline("You try to pacify monsters!");
8742 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
8743 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
8744 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !is_infrastructure_monster(mtmp3
) && mtmp3
->mtame
== 0 && mtmp3
->mpeaceful
== 0 && mtmp3
->mfrenzied
== 0 && mtmp3
->isminion
== 0 && mtmp3
->isgyp
== 0
8745 && mtmp3
->mnum
!= quest_info(MS_NEMESIS
) && !resist(mtmp3
, RING_CLASS
, 0, NOTELL
) && !(mtmp3
->data
->geno
& G_UNIQ
) )
8749 if (mtmp3
->data
->maligntyp
== 0) {
8750 pline("%s looks calmer.", mon_nam(mtmp3
));
8751 mtmp3
->mpeaceful
= 1;
8754 else pline("%s can't be pacified with this method!", mon_nam(mtmp3
));
8756 } /* monster is catchable loop */
8759 } /* variable definition bracket */
8761 t_timeout
= rnz(6000);
8764 case T_CURE_AMNESIA
:
8766 You("decide to cure your amnesia.");
8768 if (HMap_amnesia
& INTRINSIC
) {
8769 HMap_amnesia
&= ~INTRINSIC
;
8770 You_feel("less forgetful!");
8772 if (HMap_amnesia
& TIMEOUT
) {
8773 HMap_amnesia
&= ~TIMEOUT
;
8774 You_feel("less forgetful!");
8777 t_timeout
= rnz(50000);
8780 case T_ELEMENTAL_IMBUE
:
8782 int randomelement
= rnd(3);
8785 pline("Without a weapon, this technique won't work!");
8789 if (uwep
&& (uwep
->quan
> 1)) {
8790 pline("You're wielding a stack of weapons! Drop all but one!");
8794 if (uwep
&& (uwep
->oartifact
|| uwep
->fakeartifact
)) {
8795 pline("Transforming a weapon into an artifact doesn't work on weapons that are already artifacts.");
8799 if (uwep
&& (uwep
->oclass
!= WEAPON_CLASS
)) {
8800 pline("That's not a proper weapon, and therefore cannot be transformed into an artifact!");
8805 switch (randomelement
) {
8807 elemental_imbue(1); /* see artifact.c */
8808 uwep
= onameX(uwep
, artiname(ART_FIRE_SWING
));
8812 uwep
= onameX(uwep
, artiname(ART_FROST_SWING
));
8816 uwep
= onameX(uwep
, artiname(ART_SHOCK_SWING
));
8821 Your("weapon transforms, and is now imbued with elemental power!");
8824 t_timeout
= rnz(20000);
8832 num
= 100 + (techlevX(tech_no
) * 2);
8833 techt_inuse(tech_no
) = num
+ 1;
8834 pline("Your spells are more powerful for a while.");
8835 t_timeout
= rnz(12000);
8839 case T_DROP_BOULDER
:
8841 if (Is_rogue_level(&u
.uz
) || (In_endgame(&u
.uz
) && !Is_earthlevel(&u
.uz
))) {
8842 pline("That doesn't work in this area.");
8846 if (In_sokoban(&u
.uz
) && !playercancheatinsoko()) {
8848 pline("You cheater!");
8849 if (evilfriday
) u
.ugangr
++;
8854 if (isok(u
.ux
, u
.uy
)) {
8855 otmp2
= mksobj(BOULDER
, FALSE
, FALSE
, FALSE
);
8857 if (!flooreffects(otmp2
, u
.ux
, u
.uy
, "fall")) {
8858 place_object(otmp2
, u
.ux
, u
.uy
);
8860 newsym(u
.ux
, u
.uy
); /* map the rock */
8867 t_timeout
= rnz(20000);
8871 case T_MARTIAL_STYLE
:
8874 boolean madechoice
= 0;
8876 if (Race_if(PM_SAMEDI
)) {
8877 u
.martialstyle
= MARTIALSTYLE_CAPOEIRA
;
8878 pline("The Sons of Samedi are permanently locked into the capoeira martial arts style!");
8882 if (PlayerCannotUseSkills
) {
8883 t_timeout
= rnz(8000);
8884 pline("Somehow, nothing happens.");
8888 pline("Your current martial arts style is %s.", currentmartialstyle());
8890 pline("Choose a martial arts style. The prompt will loop until you actually make a choice.");
8892 while (madechoice
== 0) {
8894 if (yn("Switch to the 'brawling' style (default martial arts style, no special effects)?")=='y') {
8895 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_BRAWLING
;
8896 } else if (P_SKILL(P_MARTIAL_ARTS
) >= P_BASIC
&& yn("Switch to the 'judo' style (break holding attacks, boosts dexterity, more frequency for special martial arts strikes, reduces your damage output)?")=='y') {
8897 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_JUDO
;
8898 } else if (P_SKILL(P_MARTIAL_ARTS
) >= P_SKILLED
&& yn("Switch to the 'taekwondo' style (powers up your kick attack, can block projectiles if both of your hands are free, can also be used while wielding a weapon, your melee attacks have reduced to-hit)?")=='y') {
8899 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_TAEKWONDO
;
8900 } else if (P_SKILL(P_MARTIAL_ARTS
) >= P_EXPERT
&& yn("Switch to the 'muay thai' style (speeds you up, boosts unarmed damage, makes your AC worse, your spells fail more often and are more expensive, your ranged weapons have reduced to-hit)?")=='y') {
8901 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_MUAYTHAI
;
8902 } else if (P_SKILL(P_MARTIAL_ARTS
) >= P_MASTER
&& yn("Switch to the 'silat' style (boosts unarmed to-hit, unarmed attacks can sometimes stun opponents, improves your AC, makes your inventory weigh more and slows you down slightly)?")=='y') {
8903 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_SILAT
;
8904 } else if (P_SKILL(P_MARTIAL_ARTS
) >= P_GRAND_MASTER
&& yn("Switch to the 'krav maga' style (greatly boosts unarmed damage, causes aggravate monster, reduces your regeneration rate and can send enemies into a frenzy)?")=='y') {
8905 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_KRAVMAGA
;
8906 } else if (P_SKILL(P_QUARTERSTAFF
) >= P_MASTER
&& yn("Switch to the 'bojutsu' style (requires quarterstaff, allows you to block projectiles with the staff, boosts your AC and allows you to sometimes evade rays, reduces your melee damage output)?")=='y') {
8907 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_BOJUTSU
;
8908 } else if (P_SKILL(P_MARTIAL_ARTS
) >= P_EXPERT
&& P_SKILL(P_BARE_HANDED_COMBAT
) >= P_EXPERT
&& yn("Switch to the 'kung fu' style (slightly improves your unarmed and kick damage and boosts unarmed to-hit, kick hits enemies more often, your weapons are less effective)?")=='y') {
8909 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_KUNGFU
;
8910 } else if (uwep
&& uwep
->otyp
== JEONTU_GEOM
&& yn("Switch to the 'haidong gumdo' style (requires jeontu geom, boosts melee damage and to-hit and allows you to use martial arts techniques while wielding a jeontu geom, reduces your melee to-hit whenever you're not wielding a jeontu geom)?")=='y') {
8911 madechoice
= 1; u
.martialstyle
= MARTIALSTYLE_HAIDONGGUMDO
;
8912 } else if (yn("Do you choose to not switch your style after all?")=='y') {
8915 /* capoeira cannot be selected, this is on purpose --Amy */
8919 pline("Your new martial arts style is %s.", currentmartialstyle());
8922 t_timeout
= rnz(8000);
8927 if (!PlayerInStilettoHeels
) {
8928 pline("That doesn't work without stiletto heels!");
8932 num
= 50 + (techlevX(tech_no
) * 2);
8933 techt_inuse(tech_no
) = num
+ 1;
8934 pline("You start sprinting with your heels.");
8936 t_timeout
= rnz(10000);
8939 if (!PlayerInStilettoHeels
) {
8940 pline("That doesn't work without stiletto heels!");
8945 techt_inuse(tech_no
) = num
+ 1;
8946 pline("Quick! Paralyze an opponent and then kick him to death! You have 20 turns to do so!");
8948 t_timeout
= rnz(50000);
8950 case T_FEMALE_COMBO
:
8951 if (!PlayerInConeHeels
) {
8952 pline("That doesn't work without cone heels!");
8956 num
= 50 + (techlevX(tech_no
));
8957 techt_inuse(tech_no
) = num
+ 1;
8958 pline("You start your female combo. Now make sure you kick an enemy every turn to keep the combo going!");
8960 u
.femcombostrike
= 2;
8961 u
.femcomboactive
= TRUE
;
8963 t_timeout
= rnz(5000);
8969 num
= 100 + (techlevX(tech_no
) * 3);
8970 techt_inuse(tech_no
) = num
+ 1;
8971 pline("Yay, now you can bash enemies with a sexy leather pump! (Be sure to pick it up from the floor.)");
8973 uammo
= mksobj(SEXY_LEATHER_PUMP
, TRUE
, FALSE
, FALSE
);
8976 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
8977 uammo
->spe
= rnd(7);
8978 uammo
->cursed
= uammo
->hvycurse
= uammo
->stckcurse
= uammo
->prmcurse
= uammo
->bbrcurse
= uammo
->morgcurse
= uammo
->evilcurse
= FALSE
;
8979 uammo
->owt
= weight(uammo
);
8984 t_timeout
= rnz(20000);
8987 case T_BITCH_POSING
:
8988 if (!PlayerInBlockHeels
) {
8989 pline("That doesn't work without block heels!");
8993 if (uarmf
->spe
< 0) {
8994 int sperepair
= abs(uarmf
->spe
);
8995 sperepair
= rnd(sperepair
);
8996 uarmf
->spe
+= sperepair
;
8997 Your("heels got repaired!");
8999 if (uarmf
&& uarmf
->spe
< 2) {
9001 } else if (uarmf
&& uarmf
->spe
< 8 && !rn2(uarmf
->spe
) ) {
9004 Your("heels shine for a moment.");
9009 struct monst
*rainedmon
;
9011 for (i
= -3; i
<= 3; i
++) for(j
= -3; j
<= 3; j
++) {
9012 if (!isok(u
.ux
+ i
, u
.uy
+ j
)) continue;
9014 if ( (rainedmon
= m_at(u
.ux
+ i
, u
.uy
+ j
)) != 0) {
9015 if (rainedmon
->mpeaceful
|| rainedmon
->mtame
|| rainedmon
->mfrenzied
) continue;
9016 if (resist(rainedmon
, WEAPON_CLASS
, 0, NOTELL
) && resist(rainedmon
, WEAPON_CLASS
, 0, NOTELL
) && resist(rainedmon
, WEAPON_CLASS
, 0, NOTELL
) ) continue;
9017 rainedmon
->mpeaceful
= TRUE
;
9018 pline("%s cannot resist your sexy pose and is charmed!", Monnam(rainedmon
));
9025 t_timeout
= rnz(8000);
9028 if (!PlayerInBlockHeels
) {
9029 pline("That doesn't work without block heels!");
9033 num
= 200 + (techlevX(tech_no
) * 10);
9034 techt_inuse(tech_no
) = num
+ 1;
9035 pline("You perform a sexy stand.");
9037 t_timeout
= rnz(20000);
9040 if (!PlayerInWedgeHeels
) {
9041 pline("That doesn't work without wedge heels!");
9045 num
= 1000 + (techlevX(tech_no
) * 10);
9046 techt_inuse(tech_no
) = num
+ 1;
9047 pline("You're starting to run a marathon.");
9049 t_timeout
= rnz(30000);
9051 case T_PERFUME_STRIDE
:
9052 if (!PlayerInWedgeHeels
) {
9053 pline("That doesn't work without wedge heels!");
9057 pline("Where the hell are your shoes???"); /* shouldn't happen, but just making sure --Amy */
9061 num
= 500 - (techlevX(tech_no
) * 5);
9062 if (num
< 50) num
= 50;
9063 techt_inuse(tech_no
) = num
+ 1;
9064 pline("A perfume companion starts to follow you, but now you're obligated to wear your heels for a while.");
9067 uarmf
->hvycurse
= uarmf
->stckcurse
= TRUE
;
9071 register struct permonst
*ptrZ
;
9072 register struct monst
*bossmon
;
9080 if (attempts
&& (attempts
% 10000 == 0)) u
.mondiffhack
++;
9081 if (!rn2(2000)) reset_rndmonst(NON_PM
);
9083 } while ( (!ptrZ
|| (ptrZ
&& !(ptrZ
->msound
== MS_STENCH
))) && attempts
< 50000);
9085 if (ptrZ
&& ptrZ
->msound
== MS_STENCH
) {
9086 bossmon
= makemon(ptrZ
, u
.ux
, u
.uy
, NO_MM_FLAGS
);
9090 goto perfumestriding
;
9094 tamedog(bossmon
, (struct obj
*) 0, TRUE
);
9100 t_timeout
= rnz(16000);
9102 case T_NAUGHTY_HEELOT
:
9104 num
= 1000 + (techlevX(tech_no
) * 10);
9105 techt_inuse(tech_no
) = num
+ 1;
9106 pline("You become the naughty heelot.");
9108 if (!PlayerInConeHeels
&& !PlayerInStilettoHeels
) pline("But without the proper shoes, that won't do jack squat.");
9109 else if (!PlayerInConeHeels
|| !PlayerInStilettoHeels
) pline("Seems like your current footwear isn't eligible for that, though, so you'd better find the right pair, fast.");
9110 /* still allows the player to use the tech, this is not a mistake --Amy */
9112 t_timeout
= rnz(10000);
9114 case T_EXTREME_STURDINESS
:
9115 if (!PlayerInWedgeHeels
&& !PlayerInBlockHeels
) {
9116 pline("You need to either wear wedge or block heels for that!");
9120 num
= 50 + (techlevX(tech_no
));
9121 techt_inuse(tech_no
) = num
+ 1;
9122 pline("You become extremely sturdy!");
9124 t_timeout
= rnz(20000);
9126 case T_BUTT_PROTECTION
:
9127 if (!PlayerInConeHeels
) {
9128 pline("That doesn't work without cone heels!");
9132 num
= 50 + (techlevX(tech_no
) * 2);
9133 techt_inuse(tech_no
) = num
+ 1;
9134 pline("Your butt is protected now.");
9136 t_timeout
= rnz(10000);
9139 if (!PlayerInBlockHeels
) {
9140 pline("That doesn't work without block heels!");
9144 pline("Where the hell are your shoes???"); /* shouldn't happen, but just making sure --Amy */
9148 if (uarmf
->obrittle
>= 3 || uarmf
->obrittle2
>= 3) {
9149 pline("Your pair of heels is maximally profiled already! Any more and you'd risk breaking them!");
9152 if (uarmf
->spe
>= 5) {
9153 pline("It wouldn't make sense to add more profiling to this pair of boots.");
9157 if (rn2(2)) uarmf
->obrittle
++;
9158 else uarmf
->obrittle2
++;
9159 pline("You added some profiling to your boots.");
9161 t_timeout
= rnz(8000);
9163 case T_STAR_HEEL_SWAP
:
9164 if (!PlayerInWedgeHeels
) {
9165 pline("That doesn't work without wedge heels!");
9169 pline("Where the hell are your shoes???"); /* shouldn't happen, but just making sure --Amy */
9173 pline("That doesn't work without a weapon!");
9176 if (uwep
&& weapon_type(uwep
) != P_MORNING_STAR
) {
9177 pline("That only works if your wielded weapon is a morning star, and currently it's not!");
9182 int knifeenchant
= uwep
->spe
;
9183 int heelsenchant
= uarmf
->spe
;
9187 /* now for a system that will make every C programmer's skin crawl... :-P --Amy */
9188 if (uwep
->blessed
) knifebuc
= 1;
9189 if (uwep
->cursed
) knifebuc
= 2;
9190 if (uwep
->hvycurse
) knifebuc
= 3;
9191 if (uwep
->prmcurse
) knifebuc
= 4;
9192 if (uwep
->stckcurse
) knifebuc
+= 10;
9193 if (uwep
->bbrcurse
) knifebuc
+= 100;
9194 if (uwep
->morgcurse
) knifebuc
+= 1000;
9195 if (uwep
->evilcurse
) knifebuc
+= 10000;
9197 if (uarmf
->blessed
) heelsbuc
= 1;
9198 if (uarmf
->cursed
) heelsbuc
= 2;
9199 if (uarmf
->hvycurse
) heelsbuc
= 3;
9200 if (uarmf
->prmcurse
) heelsbuc
= 4;
9201 if (uarmf
->stckcurse
) heelsbuc
+= 10;
9202 if (uarmf
->bbrcurse
) heelsbuc
+= 100;
9203 if (uarmf
->morgcurse
) heelsbuc
+= 1000;
9204 if (uarmf
->evilcurse
) heelsbuc
+= 10000;
9206 uwep
->spe
= heelsenchant
;
9207 uarmf
->spe
= knifeenchant
;
9209 uwep
->blessed
= uwep
->cursed
= uwep
->hvycurse
= uwep
->prmcurse
= uwep
->stckcurse
= uwep
->morgcurse
= uwep
->bbrcurse
= uwep
->evilcurse
= 0;
9210 uarmf
->blessed
= uarmf
->cursed
= uarmf
->hvycurse
= uarmf
->prmcurse
= uarmf
->stckcurse
= uarmf
->morgcurse
= uarmf
->bbrcurse
= uarmf
->evilcurse
= 0;
9212 if (knifebuc
== 1) uarmf
->blessed
= TRUE
;
9214 if (knifebuc
>= 10000) {
9216 uarmf
->cursed
= uarmf
->hvycurse
= uarmf
->prmcurse
= uarmf
->evilcurse
= TRUE
;
9218 if (knifebuc
>= 1000) {
9220 uarmf
->cursed
= uarmf
->hvycurse
= uarmf
->prmcurse
= uarmf
->morgcurse
= TRUE
;
9222 if (knifebuc
>= 100) {
9224 uarmf
->cursed
= uarmf
->hvycurse
= uarmf
->prmcurse
= uarmf
->bbrcurse
= TRUE
;
9226 if (knifebuc
>= 10) {
9228 uarmf
->cursed
= uarmf
->stckcurse
= TRUE
;
9230 if (knifebuc
>= 2) {
9231 uarmf
->cursed
= TRUE
;
9232 if (knifebuc
>= 3) uarmf
->hvycurse
= TRUE
;
9233 if (knifebuc
>= 4) uarmf
->prmcurse
= TRUE
;
9237 if (heelsbuc
== 1) uwep
->blessed
= TRUE
;
9239 if (heelsbuc
>= 10000) {
9241 uwep
->cursed
= uwep
->hvycurse
= uwep
->prmcurse
= uwep
->evilcurse
= TRUE
;
9243 if (heelsbuc
>= 1000) {
9245 uwep
->cursed
= uwep
->hvycurse
= uwep
->prmcurse
= uwep
->morgcurse
= TRUE
;
9247 if (heelsbuc
>= 100) {
9249 uwep
->cursed
= uwep
->hvycurse
= uwep
->prmcurse
= uwep
->bbrcurse
= TRUE
;
9251 if (heelsbuc
>= 10) {
9253 uwep
->cursed
= uwep
->stckcurse
= TRUE
;
9255 if (heelsbuc
>= 2) {
9256 uwep
->cursed
= TRUE
;
9257 if (heelsbuc
>= 3) uwep
->hvycurse
= TRUE
;
9258 if (heelsbuc
>= 4) uwep
->prmcurse
= TRUE
;
9262 pline("Enchantments and BUC of your knife and heels have been swapped.");
9266 t_timeout
= rnz(9000);
9269 if (!PlayerInStilettoHeels
) {
9270 pline("That doesn't work without stiletto heels!");
9274 pline("That doesn't work without a weapon!");
9277 if (uwep
&& weapon_type(uwep
) != P_KNIFE
) {
9278 pline("That only works if your wielded weapon is a knife, and currently it's not!");
9282 num
= 100 + (techlevX(tech_no
) * 2);
9283 techt_inuse(tech_no
) = num
+ 1;
9284 pline("Your heel-shaped knife can stab enemies much more effectively now.");
9286 t_timeout
= rnz(6000);
9291 if (Is_rogue_level(&u
.uz
) || (In_endgame(&u
.uz
) && !Is_earthlevel(&u
.uz
))) {
9292 pline("That doesn't work in this area.");
9296 if (In_sokoban(&u
.uz
) && !playercancheatinsoko()) {
9298 pline("You cheater!");
9299 if (evilfriday
) u
.ugangr
++;
9306 int earthradius
= 1;
9308 for (x
= u
.ux
-earthradius
; x
<= u
.ux
+earthradius
; x
++) {
9309 for (y
= u
.uy
-earthradius
; y
<= u
.uy
+earthradius
; y
++) {
9310 if (isok(x
, y
) && !IS_ROCK(levl
[x
][y
].typ
)) {
9311 otmp2
= mksobj(BOULDER
, FALSE
, FALSE
, FALSE
);
9313 if (!flooreffects(otmp2
, x
, y
, "fall")) {
9314 place_object(otmp2
, x
, y
);
9316 newsym(x
, y
); /* map the rock */
9323 pline("Several boulders fall.");
9326 t_timeout
= rnz(40000);
9330 case T_HARDCORE_ALIENIZATION
:
9332 register struct obj
*shemagh
;
9334 if ((find_shemagh()) != -1) {
9335 shemagh
= mksobj(find_shemagh(), TRUE
, FALSE
, FALSE
);
9339 (void) pickup_object(shemagh
, shemagh
->quan
, TRUE
, TRUE
);
9343 if (is_helmet(shemagh
)) {
9344 if (uarmh
) remove_worn_item(uarmh
, TRUE
);
9345 setworn(shemagh
, W_ARMH
);
9347 if (shemagh
) curse(shemagh
);
9348 You("are wearing a shemagh now.");
9350 pline("Somehow, no shemagh was created!");
9353 } else pline("Somehow, it failed.");
9354 } else pline("Something has gone wrong...");
9359 t_timeout
= rnz(20000);
9365 if (!getdir((char *)0)) return 0;
9366 if (!u
.dx
&& !u
.dy
) {
9367 pline("This technique is for polymorphing monsters, not yourself.");
9370 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
9371 pline("Invalid target location.");
9374 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
9376 You("were such a noob and wasted this powerful technique by aiming it at thin air! Why didn't you target a monster instead?");
9377 } else if (!is_infrastructure_monster(mtmp
) && mtmp
->isminion
== 0 && mtmp
->isgyp
== 0
9378 && mtmp
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp
->data
->geno
& G_UNIQ
) ) {
9379 if (!resist(mtmp
, WAND_CLASS
, 0, NOTELL
)) {
9380 (void) mon_spec_polyX(mtmp
, (struct permonst
*)0, 0L, FALSE
, TRUE
, FALSE
, FALSE
);
9382 pline("%s resists! Hahahahahahaha! Now you can wait for an eternity before the technique becomes available again.", Monnam(mtmp
));
9385 pline("What a shame - you apparently targetted a monster that is immune, and therefore nothing happens.");
9388 t_timeout
= rnz(75000);
9393 if (!getdir((char *)0)) return 0;
9394 if (!u
.dx
&& !u
.dy
) {
9395 pline("You cannot pacify yourself.");
9398 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
9399 pline("Invalid target location.");
9402 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
9404 pline("There is no monster in that direction. Nothing happens.");
9405 } else if (mtmp
->mtame
== 0 && !is_infrastructure_monster(mtmp
) && mtmp
->mpeaceful
== 0 && mtmp
->mfrenzied
== 0 && mtmp
->isminion
== 0 && mtmp
->isgyp
== 0
9406 && mtmp
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp
->data
->geno
& G_UNIQ
) ) {
9407 if (!resist(mtmp
, WAND_CLASS
, 0, NOTELL
)) {
9408 int pacifychance
= 10;
9409 if (!PlayerCannotUseSkills
) {
9410 switch (P_SKILL(P_ORB
)) {
9424 case P_GRAND_MASTER
:
9427 case P_SUPREME_MASTER
:
9432 if (u
.ualign
.record
< -20) pacifychance
-= 50;
9433 else if (u
.ualign
.record
< -10) pacifychance
-= 20;
9434 else if (u
.ualign
.record
< 0) pacifychance
-= 10;
9435 else if (u
.ualign
.record
> 4 && u
.ualign
.record
< 10) pacifychance
+= 5;
9436 else if (u
.ualign
.record
> 9 && u
.ualign
.record
< 14) pacifychance
+= 10;
9437 else if (u
.ualign
.record
> 14 && u
.ualign
.record
< 20) pacifychance
+= 15;
9438 else if (u
.ualign
.record
> 19 && u
.ualign
.record
< 40) pacifychance
+= 20;
9439 else if (u
.ualign
.record
> 39 && u
.ualign
.record
< 60) pacifychance
+= 30;
9440 else if (u
.ualign
.record
> 59 && u
.ualign
.record
< 80) pacifychance
+= 40;
9441 else if (u
.ualign
.record
> 79 && u
.ualign
.record
< 100) pacifychance
+= 50;
9442 else if (u
.ualign
.record
> 99 && u
.ualign
.record
< 120) pacifychance
+= 60;
9443 else if (u
.ualign
.record
> 119 && u
.ualign
.record
< 140) pacifychance
+= 70;
9444 else if (u
.ualign
.record
> 139) pacifychance
+= 80;
9446 if (rn2(100) < pacifychance
) {
9447 mtmp
->mpeaceful
= 1;
9448 pline("%s looks calmer.", mon_nam(mtmp
));
9450 pline("%s resists the attempt.", Monnam(mtmp
));
9454 pline("%s is as angry as before.", Monnam(mtmp
));
9457 pline("That monster is immune.");
9460 t_timeout
= rnz(5000);
9464 num
= 5 + (techlevX(tech_no
) / 5);
9465 techt_inuse(tech_no
) = num
+ 1;
9466 pline("You've activated your afterburner.");
9467 t_timeout
= rnz(6000);
9471 num
= 20 + techlevX(tech_no
);
9472 techt_inuse(tech_no
) = num
+ 1;
9473 pline("You've summoned a blizzard!");
9474 t_timeout
= rnz(8000);
9477 case T_THUNDERSTORM
:
9478 num
= 60 + (techlevX(tech_no
) * 20);
9479 techt_inuse(tech_no
) = num
+ 1;
9480 pline("You've conjured a thunderstorm!");
9481 t_timeout
= rnz(12000);
9487 int melteestrength
= 5 + (techlevX(tech_no
) / 4);
9489 buzz(15, melteestrength
, u
.ux
, u
.uy
, -1, 0);
9490 buzz(15, melteestrength
, u
.ux
, u
.uy
, 1, 0);
9491 buzz(15, melteestrength
, u
.ux
, u
.uy
, -1, 1);
9492 buzz(15, melteestrength
, u
.ux
, u
.uy
, 1, 1);
9493 buzz(15, melteestrength
, u
.ux
, u
.uy
, 0, 1);
9494 buzz(15, melteestrength
, u
.ux
, u
.uy
, -1, -1);
9495 buzz(15, melteestrength
, u
.ux
, u
.uy
, 1, -1);
9496 buzz(15, melteestrength
, u
.ux
, u
.uy
, 0, -1);
9499 t_timeout
= rnz(10000);
9503 case T_CHAIN_THUNDERBOLT
:
9506 int melteestrength
= 5 + (techlevX(tech_no
) / 4);
9508 ctx
= u
.ux
, cty
= u
.uy
;
9510 if (!getdir((char *)0)) return(0);
9511 if (!u
.dx
&& !u
.dy
) {
9512 You("really shouldn't be aiming that at yourself.");
9515 for(i
= 0; i
< 8; i
++) {
9516 if (!isok(ctx
+ u
.dx
, cty
+ u
.dy
)) break;
9517 if (levl
[ctx
+ u
.dx
][cty
+ u
.dy
].typ
< POOL
) break;
9523 if (ctx
== u
.ux
&& cty
== u
.uy
) {
9524 pline("The effect dissipated because you didn't aim properly!");
9527 if (!isok(ctx
, cty
)) { /* shouldn't happen */
9528 pline("The effect dissipated because it travelled off the map.");
9532 buzz(15, melteestrength
, ctx
, cty
, -1, 0);
9533 buzz(15, melteestrength
, ctx
, cty
, 1, 0);
9534 buzz(15, melteestrength
, ctx
, cty
, -1, 1);
9535 buzz(15, melteestrength
, ctx
, cty
, 1, 1);
9536 buzz(15, melteestrength
, ctx
, cty
, 0, 1);
9537 buzz(15, melteestrength
, ctx
, cty
, -1, -1);
9538 buzz(15, melteestrength
, ctx
, cty
, 1, -1);
9539 buzz(15, melteestrength
, ctx
, cty
, 0, -1);
9542 t_timeout
= rnz(10000);
9545 case T_FLASHING_MISCHIEF
:
9548 int melteestrength
= 5 + (techlevX(tech_no
) / 4);
9550 ctx
= u
.ux
, cty
= u
.uy
;
9552 if (!getdir((char *)0)) return(0);
9553 if (!u
.dx
&& !u
.dy
) {
9554 You("really shouldn't be aiming that at yourself.");
9557 for(i
= 0; i
< 8; i
++) {
9558 if (!isok(ctx
+ u
.dx
, cty
+ u
.dy
)) break;
9559 if (levl
[ctx
+ u
.dx
][cty
+ u
.dy
].typ
< POOL
) break;
9564 if (isok(ctx
, cty
)) {
9567 buzz(15, melteestrength
, ctx
, cty
, -1, 0);
9570 buzz(15, melteestrength
, ctx
, cty
, 1, 0);
9573 buzz(15, melteestrength
, ctx
, cty
, -1, 1);
9576 buzz(15, melteestrength
, ctx
, cty
, 1, 1);
9579 buzz(15, melteestrength
, ctx
, cty
, 0, 1);
9582 buzz(15, melteestrength
, ctx
, cty
, -1, -1);
9585 buzz(15, melteestrength
, ctx
, cty
, 1, -1);
9588 buzz(15, melteestrength
, ctx
, cty
, 0, -1);
9597 t_timeout
= rnz(10000);
9602 pline("That requires you to wield a weapon!");
9607 if (uwep
&& weapon_type(uwep
) != P_SHORT_SWORD
&& weapon_type(uwep
) != P_BROAD_SWORD
&& weapon_type(uwep
) != P_LONG_SWORD
&& weapon_type(uwep
) != P_TWO_HANDED_SWORD
) {
9608 pline("That only works if your wielded weapon is a short, broad, long or two-handed sword, and currently it's not!");
9612 if (uwep
&& uwep
->spe
< 7) {
9614 pline("Your weapon glows %s.", hcolor(NH_LIGHT_BLUE
));
9615 } else pline("Your currently wielded weapon can't be enchanted any further with this technique, and therefore nothing happens.");
9617 t_timeout
= rnz(20000);
9623 pline("That requires you to wield a weapon!");
9628 if (uwep
&& weapon_type(uwep
) != P_MACE
&& weapon_type(uwep
) != P_FLAIL
&& weapon_type(uwep
) != P_CLUB
&& weapon_type(uwep
) != P_HAMMER
) {
9629 pline("That only works if your wielded weapon is a mace, flail, club or hammer, and currently it's not!");
9634 uwep
->oerodeproof
= uwep
->rknown
= TRUE
;
9635 uwep
->oeroded
= uwep
->oeroded2
= 0;
9636 Your("weapon is surrounded by a shimmering shield!");
9639 t_timeout
= rnz(30000);
9645 int melteestrength
= rnd(20 + techlevX(tech_no
));
9646 if (uwep
&& uwep
->oartifact
== ART_CAMOHAMEHA
) melteestrength
*= 2;
9648 ctx
= u
.ux
, cty
= u
.uy
;
9650 if (!getdir((char *)0)) return(0);
9651 if (!u
.dx
&& !u
.dy
) {
9652 You("can't direct that at yourself.");
9655 verbalize("Kamehameha!");
9657 for(i
= 0; i
< ((uwep
&& uwep
->oartifact
== ART_CAMOHAMEHA
) ? 13 : 8); i
++) {
9658 if (!isok(ctx
+ u
.dx
, cty
+ u
.dy
)) break;
9659 if (levl
[ctx
+ u
.dx
][cty
+ u
.dy
].typ
< POOL
) break;
9664 mtmp
= m_at(ctx
, cty
);
9667 pline("The projectile hits %s!", mon_nam(mtmp
));
9668 wakeup(mtmp
); /* turn the monster hostile */
9669 hurtmon(mtmp
, melteestrength
);
9677 t_timeout
= rnz(2000);
9680 case T_SHADOW_MANTLE
:
9689 for(i
= -bd
; i
<= bd
; i
++) for(j
= -bd
; j
<= bd
; j
++) {
9690 if (!isok(u
.ux
+ i
, u
.uy
+ j
)) continue;
9691 if ((mtmp
= m_at(u
.ux
+ i
, u
.uy
+ j
)) != 0) {
9692 wakeup(mtmp
); /* monster becomes hostile */
9694 mtmp
->mblinded
= rnd(20 + techlevX(tech_no
));
9695 pline("%s is blinded!", Monnam(mtmp
));
9702 t_timeout
= rnz(5000);
9708 You("create throwing stars.");
9712 uammo
= mksobj(SHURIKEN
, TRUE
, FALSE
, FALSE
);
9714 uammo
->quan
= rnd(40 + (3 * techlevX(tech_no
)));
9715 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
9716 uammo
->owt
= weight(uammo
);
9723 t_timeout
= rnz(12000);
9727 case T_BLADE_SHIELD
:
9728 num
= 20 + techlevX(tech_no
);
9729 techt_inuse(tech_no
) = num
+ 1;
9730 pline("Blade shield activated.");
9731 t_timeout
= rnz(3000);
9734 case T_GREEN_WEAPON
:
9737 You("can't use this technique without a weapon!");
9741 if (uwep
&& weapon_type(uwep
) != P_CLAW
) {
9742 pline("That only works if your wielded weapon is a claw, and currently it's not!");
9746 uwep
->opoisoned
= TRUE
;
9747 uwep
->superpoison
= TRUE
;
9748 Your("claw became green.");
9750 t_timeout
= rnz(10000);
9753 case T_HIDDEN_POWER
:
9756 struct obj
*hiddenpwitem
;
9757 int hiddenpowertype
;
9759 hiddenpowertype
= POT_HEALING
; /* fail safe */
9761 switch (u
.hiddenpowerskill
) {
9763 hiddenpowertype
= WAN_INERTIA
; break;
9765 hiddenpowertype
= WAN_STONING
; break;
9767 hiddenpowertype
= SCR_TAMING
; break;
9769 hiddenpowertype
= WAN_DISINTEGRATION
; break;
9771 hiddenpowertype
= POT_BENEFICIAL_EFFECT
; break;
9773 hiddenpowertype
= POT_GAIN_LEVEL
; break;
9775 hiddenpowertype
= WAN_THUNDER
; break;
9776 case P_TWO_HANDED_SWORD
:
9777 hiddenpowertype
= MAGIC_HARP
; break;
9779 hiddenpowertype
= WAN_INCREASE_MAX_HITPOINTS
; break;
9781 hiddenpowertype
= WAN_REMOVE_CURSE
; break;
9783 hiddenpowertype
= POT_HEROISM
; break;
9785 hiddenpowertype
= WAN_TIME
; break;
9787 hiddenpowertype
= WAN_NETHER_BEAM
; break;
9788 case P_MORNING_STAR
:
9789 hiddenpowertype
= POT_RESTORE_ABILITY
; break;
9791 hiddenpowertype
= WAN_INFERNO
; break;
9793 hiddenpowertype
= WAN_GRAVITY_BEAM
; break;
9794 case P_QUARTERSTAFF
:
9795 hiddenpowertype
= SCR_POWER_CHARGING
; break;
9797 hiddenpowertype
= POT_RECOVERY
; break;
9799 hiddenpowertype
= WAN_TRAP_DISARMING
; break;
9801 hiddenpowertype
= SCR_REPAIR_ITEM
; break;
9803 hiddenpowertype
= WAN_PARALYSIS
; break;
9805 hiddenpowertype
= WAN_ICE_BEAM
; break;
9807 hiddenpowertype
= POT_WATER
; break;
9809 hiddenpowertype
= WAN_DISINTEGRATION_BEAM
; break;
9811 hiddenpowertype
= POT_GAIN_HEALTH
; break;
9813 hiddenpowertype
= SCR_RANDOM_ENCHANTMENT
; break;
9815 hiddenpowertype
= SCR_REGULAR_MATERIAL
; break;
9817 hiddenpowertype
= SCR_TRAP_DISARMING
; break;
9819 hiddenpowertype
= SCR_GREATER_ENCHANT_WEAPON
; break;
9821 hiddenpowertype
= EXPENSIVE_CAMERA
; break;
9823 hiddenpowertype
= WAN_CHROMATIC_BEAM
; break;
9825 hiddenpowertype
= SCR_CREATE_FAMILIAR
; break;
9827 hiddenpowertype
= SCR_CURE
; break;
9828 case P_UNICORN_HORN
:
9829 hiddenpowertype
= SCR_TERRAFORMING
; break;
9831 hiddenpowertype
= SCR_SECURE_CURSE_REMOVAL
; break;
9832 case P_ATTACK_SPELL
:
9833 hiddenpowertype
= SCR_SKILL_GROWTH
; break;
9834 case P_HEALING_SPELL
:
9835 hiddenpowertype
= POT_FULL_HEALING
; break;
9836 case P_DIVINATION_SPELL
:
9837 hiddenpowertype
= SCR_SECURE_IDENTIFY
; break;
9838 case P_ENCHANTMENT_SPELL
:
9839 hiddenpowertype
= WAN_HYPER_BEAM
; break;
9840 case P_PROTECTION_SPELL
:
9841 hiddenpowertype
= SCR_EBB_TIDE
; break;
9843 hiddenpowertype
= WAN_TOXIC
; break;
9844 case P_OCCULT_SPELL
:
9845 hiddenpowertype
= WAN_IDENTIFY
; break;
9846 case P_ELEMENTAL_SPELL
:
9847 hiddenpowertype
= SCR_SUPERIOR_MATERIAL
; break;
9849 hiddenpowertype
= TINNING_KIT
; break;
9850 case P_MATTER_SPELL
:
9851 hiddenpowertype
= WAN_SLUDGE
; break;
9852 case P_BARE_HANDED_COMBAT
:
9853 hiddenpowertype
= SCR_SKILL_UP
; break;
9855 hiddenpowertype
= TWELVE_COURSE_DINNER
; break;
9856 case P_GENERAL_COMBAT
:
9857 hiddenpowertype
= CRYSTAL_BALL
; break;
9859 hiddenpowertype
= SCR_REVERSE_IDENTIFY
; break;
9861 hiddenpowertype
= SCR_GREATER_ENCHANT_ARMOR
; break;
9862 case P_TWO_HANDED_WEAPON
:
9863 hiddenpowertype
= CAN_OF_GREASE
; break;
9864 case P_POLYMORPHING
:
9865 hiddenpowertype
= SCR_HYBRIDIZATION
; break;
9867 hiddenpowertype
= SCR_INVENTORY_ID
; break;
9869 hiddenpowertype
= STETHOSCOPE
; break;
9870 case P_SPIRITUALITY
:
9871 hiddenpowertype
= SCR_CONSECRATION
; break;
9873 hiddenpowertype
= DARK_MAGIC_WHISTLE
; break;
9874 case P_MISSILE_WEAPONS
:
9875 hiddenpowertype
= WAN_ENTRAPPING
; break;
9877 hiddenpowertype
= HUGE_CHUNK_OF_MEAT
; break;
9879 hiddenpowertype
= SCR_ARMOR_SPECIALIZATION
; break;
9881 hiddenpowertype
= POT_TRAINING
; break;
9882 case P_MEMORIZATION
:
9883 hiddenpowertype
= SCR_GAIN_MANA
; break;
9885 hiddenpowertype
= WAN_DEATH
; break;
9887 hiddenpowertype
= SHADOW_HORN
; break;
9889 hiddenpowertype
= SCR_SYMBIOSIS
; break;
9891 hiddenpowertype
= POT_RANDOM_INTRINSIC
; break;
9893 hiddenpowertype
= CHOCOLATE
; break;
9895 hiddenpowertype
= WAN_AURORA_BEAM
; break;
9897 hiddenpowertype
= WAN_BANISHMENT
; break;
9899 hiddenpowertype
= WAN_TIME_STOP
; break;
9901 hiddenpowertype
= POT_CURE_INSANITY
; break;
9903 hiddenpowertype
= POT_DOWN_LEVEL
; break;
9905 hiddenpowertype
= SCR_ERASURE
; break;
9907 hiddenpowertype
= SCR_ARTIFACT_CREATION
; break;
9909 hiddenpowertype
= WAN_CLONE_MONSTER
; break;
9910 case P_STILETTO_HEELS
:
9911 hiddenpowertype
= WAN_STERILIZE
; break;
9913 hiddenpowertype
= POT_INVULNERABILITY
; break;
9915 hiddenpowertype
= SCR_WONDER
; break;
9917 hiddenpowertype
= SCR_RETURN
; break;
9918 case P_BOULDER_THROWING
:
9919 hiddenpowertype
= SCR_BOSS_COMPANION
; break;
9920 case P_MARTIAL_ARTS
:
9921 hiddenpowertype
= WAN_CHARGING
; break;
9922 case P_TWO_WEAPON_COMBAT
:
9923 hiddenpowertype
= POT_TECH_LEVEL_UP
; break;
9925 hiddenpowertype
= WAN_FULL_HEALING
; break;
9927 hiddenpowertype
= WAN_VENOM_SCATTERING
; break;
9930 pline("A hidden item is created!");
9931 hiddenpwitem
= mksobj(hiddenpowertype
, TRUE
, FALSE
, FALSE
);
9933 hiddenpwitem
->quan
= 1;
9934 hiddenpwitem
->known
= hiddenpwitem
->dknown
= hiddenpwitem
->bknown
= hiddenpwitem
->rknown
= 1;
9935 hiddenpwitem
->owt
= weight(hiddenpwitem
);
9936 dropy(hiddenpwitem
);
9937 stackobj(hiddenpwitem
);
9943 t_timeout
= rnz(50000);
9946 case T_LIGHTER_BALLS
:
9949 You("can't use this technique without a weapon!");
9953 if (uwep
&& uwep
->oclass
!= BALL_CLASS
) {
9954 You("aren't wielding a ball!");
9958 num
= 1000 + (techlevX(tech_no
) * 10);
9959 techt_inuse(tech_no
) = num
+ 1;
9960 Your("balls get lighter.");
9961 if (FunnyHallu
) pline("Shame, now no girl will want to kick them because it wouldn't hurt you anymore.");
9963 t_timeout
= rnz(50000);
9966 case T_ROCK_TO_POISON
:
9968 if (CannotSelectItemsInPrompts
) break;
9970 otmp
= getobj(allnoncount
, "turn into poison");
9972 if (yn("Really exit with no object selected?") == 'y')
9973 pline("You just wasted the opportunity to definalize an item.");
9974 else goto rockpoisonchoice
;
9975 pline("A feeling of loss comes over you.");
9980 if (otmp
->otyp
!= ROCK
) {
9981 pline("That's not a rock, and therefore nothing happens.");
9982 } else if (otmp
->oartifact
) {
9983 pline("You knew that this wasn't gonna work on an artifact, so why do you try anyway?");
9984 } else if (!stack_too_big(otmp
)) {
9985 otmp
->otyp
= ACID_VENOM
;
9986 otmp
->oclass
= VENOM_CLASS
;
9987 pline("Success! You've concocted some venom.");
9988 } else pline("The stack was too big, and therefore nothing happens.");
9991 t_timeout
= rnz(25000);
9998 pline("Not enough room. Get out of the swallowing monster first.");
10002 if (!getdir((char *)0)) return(0);
10003 if (!u
.dx
&& !u
.dy
) {
10004 /* Hopefully a mistake ;B */
10005 pline("Nah, you're not gonna do that, it'd be too painful.");
10008 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
10009 pline("Invalid target location.");
10012 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
10014 pline("There was no monster at that location, and therefore your poisoned injection goes to waste!");
10015 t_timeout
= rnz(2500);
10019 You("inject the poison into %s's %s...", mon_nam(mtmp
), mbodypart(mtmp
, BLOOD
));
10021 int injectiondmg
= rn1(10, 6);
10022 injectiondmg
+= techlevX(tech_no
);
10023 if (!resist(mtmp
, VENOM_CLASS
, 0, NOTELL
)) {
10024 pline("%s's nerves are poisoned!", Monnam(mtmp
));
10025 if (!dmgtype(mtmp
->data
, AD_PLYS
)) {
10026 mtmp
->mcanmove
= 0;
10027 mtmp
->mfrozen
= rnd(4);
10028 mtmp
->mstrategy
&= ~STRAT_WAITFORU
;
10031 if (!resists_poison(mtmp
) || player_will_pierce_resistance()) {
10032 if (!rn2(500) && !resists_poison(mtmp
) ) {
10033 Your("poison was deadly...");
10034 injectiondmg
= (mtmp
->mhp
* 10);
10036 if (injectiondmg
> 0) {
10037 pline("%s is green now!", Monnam(mtmp
));
10038 (void) resist(mtmp
, VENOM_CLASS
, injectiondmg
, NOTELL
);
10040 } else pline("%s resisted the poison.", Monnam(mtmp
));
10043 t_timeout
= rnz(2500);
10046 case T_SUPER_POISON
:
10049 pline("That doesn't work without a weapon!");
10052 if (uwep
&& uwep
->oclass
!= VENOM_CLASS
) {
10053 pline("That only works if your wielded weapon is a venom, and currently it's not!");
10057 if (uwep
&& stack_too_big(uwep
)) {
10058 pline("You were trying to enchant too many venoms at once and therefore it failed.");
10059 } else if (uwep
&& uwep
->spe
< 25) {
10060 uwep
->spe
+= rnd(4);
10061 pline("The venoms have been enchanted.");
10063 pline("Unfortunately the venoms cannot be enchanted beyond the current enchantment level.");
10066 t_timeout
= rnz(10000);
10069 case T_GREEN_MISSILE
:
10071 num
= 10 + (techlevX(tech_no
) / 3);
10072 techt_inuse(tech_no
) = num
+ 1;
10073 pline("You've readied your special wood that you can make into poisoned missiles. Launch them by throwing venoms.");
10075 t_timeout
= rnz(5000);
10078 case T_BIG_N_VEINY
:
10080 num
= 100 + (techlevX(tech_no
));
10081 techt_inuse(tech_no
) = num
+ 1;
10082 pline("Now your body is particularly poisonous!");
10084 t_timeout
= rnz(8000);
10087 case T_PLANT_TERROR
:
10089 u
.wormpolymorph
= PM_ORIGINAL_MESHERA_PLANT
;
10091 if (u
.mtimedone
&& (u
.umonnum
== PM_ORIGINAL_MESHERA_PLANT
) ) {
10092 u
.mtimedone
= 100 + (techlevX(tech_no
));
10093 pline("The Human World does not care about the Plant World. So you'll teach them.");
10095 mtmp
= makemon(&mons
[rn2(5) ? PM_LITTLE_POISON_IVY
: PM_SWEET_ASIAN_POISON_IVY
], u
.ux
, u
.uy
, MM_ADJACENTOK
);
10096 if (mtmp
) (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
10097 mtmp
= makemon(&mons
[rn2(5) ? PM_LITTLE_POISON_IVY
: PM_SWEET_ASIAN_POISON_IVY
], u
.ux
, u
.uy
, MM_ADJACENTOK
);
10098 if (mtmp
) (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
10100 mtmp
= makemon(&mons
[rn2(5) ? PM_LITTLE_POISON_IVY
: PM_SWEET_ASIAN_POISON_IVY
], u
.ux
, u
.uy
, MM_ADJACENTOK
);
10101 if (mtmp
) (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
10103 mtmp
= makemon(&mons
[rn2(5) ? PM_LITTLE_POISON_IVY
: PM_SWEET_ASIAN_POISON_IVY
], u
.ux
, u
.uy
, MM_ADJACENTOK
);
10104 if (mtmp
) (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
10108 } else pline("Somehow, you failed to transform into a plant. Maybe you can't polymorph?");
10110 t_timeout
= rnz(50000);
10113 case T_POISON_PEN_LETTER
:
10115 num
= 20 + (techlevX(tech_no
) / 2);
10116 techt_inuse(tech_no
) = num
+ 1;
10117 pline("You're planning to write poison pen letters.");
10119 t_timeout
= rnz(8000);
10122 case T_CORONATION_CULMINATION
:
10125 t_timeout
= rnz(15000);
10128 case T_RESTORE_LIFE_LEVELS
:
10130 if (u
.ulevel
< u
.ulevelmax
) {
10132 while ((u
.ulevel
< u
.ulevelmax
) && (attempts
++ < 10000)) {
10135 Your("level has been restored.");
10137 pline("Whoops! Apparently your experience level hasn't been drained, and therefore it can't be restored to its previous value either. Too bad.");
10140 t_timeout
= rnz(20000);
10143 case T_TOILET_VISIT
:
10147 if (Upolyd
) u
.mhmax
++;
10148 Your("health is increased by one.");
10149 make_sick(0L, (char *) 0, TRUE
, SICK_ALL
);
10152 t_timeout
= rnz(5000);
10155 case T_MAKE_A_WISH
:
10159 struct obj
*yourobj
;
10160 uammo
= mkobj(RANDOM_CLASS
, TRUE
, FALSE
);
10166 pline("Something must have gone wrong. Sorry!");
10167 t_timeout
= rnz(100000);
10171 You("have to take a guess! What's the item that was generated?");
10173 for (attempts
= 0; attempts
<= 5; attempts
++) {
10175 if (attempts
>= 5) {
10176 pline("%s", thats_enough_tries
);
10180 getlin("Your guess:", buf
);
10182 if (buf
[0] == 0) continue;
10184 yourobj
= readobjnam(buf
, (struct obj
*)0, TRUE
, FALSE
);
10185 if (u
.ugold
!= oldgold
) {
10186 pline("Don't you date cheat me again! -- Your fault!");
10187 /* Make them pay */
10188 u
.ugold
= oldgold
/ 2;
10191 if (yourobj
== &zeroobj
|| yourobj
== (struct obj
*) 0) {
10192 pline("That doesn't exist.");
10196 if (yourobj
&& (yourobj
->otyp
== uammo
->otyp
)) {
10197 uammo
->owt
= weight(uammo
);
10200 pline("Yes!!! You successfully guessed the object! It can now be found on the ground.");
10202 } else if (yourobj
&& (yourobj
->oclass
== uammo
->oclass
)) {
10204 pline("Sorry, you had the right item class but not the right type. The item we were looking for was %s.", xname(uammo
));
10210 pline("Sorry, your guess was completely wrong. The item we were looking for was %s.", xname(uammo
));
10219 t_timeout
= rnz(100000);
10222 case T_VENOM_MIXING
:
10227 uammo
= mksobj(rn2(2) ? BLINDING_VENOM
: ACID_VENOM
, TRUE
, FALSE
, FALSE
);
10229 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
10230 uammo
->quan
= 30 + techlevX(tech_no
);
10231 uammo
->owt
= weight(uammo
);
10234 pline("A stack of venoms has been dropped on the ground.");
10239 t_timeout
= rnz(15000);
10242 case T_JAVELIN_FORGING
:
10247 uammo
= mksobj(rnd_class(JAVELIN
, STACK_JAVELIN
), TRUE
, FALSE
, FALSE
);
10249 uammo
->known
= uammo
->dknown
= uammo
->bknown
= uammo
->rknown
= 1;
10252 pline("A javelin was forged!");
10257 t_timeout
= rnz(10000);
10263 You("can't use this technique without a weapon!");
10267 if (uwep
&& uwep
->oclass
!= BALL_CLASS
) {
10268 You("aren't wielding a ball!");
10272 You("try to repair your ball...");
10273 if (!uwep
->oeroded
&& !uwep
->oeroded2
) pline("But it wasn't damaged to begin with.");
10275 if (uwep
->oeroded
> 0) {
10278 if (uwep
->oeroded2
> 0) {
10282 t_timeout
= rnz(20000);
10287 num
= 100 + (techlevX(tech_no
) * 5);
10288 if (Race_if(PM_HUMANOID_CENTAUR
)) num
*= 10;
10289 techt_inuse(tech_no
) = num
+ 1;
10290 pline("For a while, your polearms and lances are effective in melee range.");
10291 t_timeout
= rnz(5000);
10297 You("can't use this technique without a weapon!");
10301 if (uwep
&& weapon_type(uwep
) != P_AXE
) {
10302 pline("That only works if your wielded weapon is an axe, and currently it's not!");
10307 register struct monst
*nexusmon
, *nextmon
;
10309 for(nexusmon
= fmon
; nexusmon
; nexusmon
= nextmon
) {
10310 nextmon
= nexusmon
->nmon
; /* trap might kill mon */
10311 if (DEADMONSTER(nexusmon
)) continue;
10313 if (!monnear(nexusmon
, u
.ux
, u
.uy
)) continue;
10314 You("chop %s!", mon_nam(nexusmon
));
10315 wakeup(nexusmon
); /* monster becomes hostile */
10316 if (bigmonst(nexusmon
->data
)) hurtmon(nexusmon
, (objects
[uwep
->otyp
].oc_wldam
) + ((uwep
->spe
> 0) ? uwep
->spe
: 0));
10317 else hurtmon(nexusmon
, (objects
[uwep
->otyp
].oc_wsdam
) + ((uwep
->spe
> 0) ? uwep
->spe
: 0));
10321 t_timeout
= rnz(7500);
10325 if (!getdir((char *)0)) return 0;
10326 if (!u
.dx
&& !u
.dy
) {
10327 pline("Nah. You can't use that on yourself. You'll have to target a monster instead.");
10330 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
10331 pline("Invalid target location.");
10334 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
10336 pline("That was a waste, man. The target square didn't contain a monster!");
10338 u_teleport_monB(mtmp
, TRUE
);
10341 t_timeout
= rnz(50000);
10345 case T_PARTICIPATION_LOSS
:
10347 if (!getdir((char *)0)) return 0;
10348 if (!u
.dx
&& !u
.dy
) {
10350 pline("Do you REALLY want to do that???");
10351 getlin ("If you answer yes now, you lose the game! [yes/no]",buf
);
10352 (void) lcase (buf
);
10353 if (!(strcmp (buf
, "yes"))) {
10355 u
.youarereallydead
= 1;
10356 killer
= "being wiped from existence";
10357 killer_format
= KILLED_BY
;
10359 pline("Unfortunately, you still don't exist anymore.");
10361 done(ESCAPED
); /* you don't get to escape from this death! --Amy */
10366 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
10367 pline("Invalid target location.");
10370 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
10372 pline("That was a waste, man. The target square didn't contain a monster!");
10373 } else if (mtmp
->isminion
== 0 && !is_infrastructure_monster(mtmp
) && mtmp
->isgyp
== 0
10374 && mtmp
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp
->data
->geno
& G_UNIQ
) ) {
10378 pline("Dude you're such a noob who apparently doesn't read descriptions or you'd have known that this particular monster is immune.");
10381 t_timeout
= rnz(250000);
10385 case T_WEAPON_BLOCKER
:
10386 if (!u
.twoweap
|| !uwep
|| !uswapwep
) {
10387 pline("You need to be wielding two weapons at the same time for that!");
10391 num
= 100 + (techlevX(tech_no
) * 5);
10392 techt_inuse(tech_no
) = num
+ 1;
10393 pline("Your weapons become capable of blocking attacks.");
10394 t_timeout
= rnz(3000);
10397 case T_EXTRA_MEMORY
:
10399 extramemory(); /* spell.c */
10400 t_timeout
= rnz(20000);
10404 num
= 1000 + (techlevX(tech_no
) * 50);
10405 techt_inuse(tech_no
) = num
+ 1;
10406 pline("For a while, your grinders will work like lances while your lances will work like grinders.");
10407 t_timeout
= rnz(7000);
10410 case T_DIABOLIC_MINION
:
10411 t_timeout
= rnz(10000);
10414 struct permonst
*shoe
= 0;
10416 struct monst
*shoemonst
;
10421 if (attempts
&& (attempts
% 10000 == 0)) u
.mondiffhack
++;
10422 if (!rn2(2000)) reset_rndmonst(NON_PM
);
10424 } while ( (!shoe
|| (shoe
&& !is_diablomonster(shoe
))) && attempts
< 50000);
10426 if (shoe
&& is_diablomonster(shoe
) ) {
10427 pline("You summoned some diabolic monster!");
10428 shoemonst
= makemon(shoe
, u
.ux
, u
.uy
, NO_MM_FLAGS
);
10429 if (shoemonst
) (void) tamedog(shoemonst
, (struct obj
*) 0, TRUE
);
10431 pline("Some weirdness caused a different monster to appear. It's not what you expected.");
10432 shoemonst
= makemon(shoe
, u
.ux
, u
.uy
, NO_MM_FLAGS
);
10433 if (shoemonst
) (void) tamedog(shoemonst
, (struct obj
*) 0, TRUE
);
10434 } else pline("It seems that the world of Sanctuary has run out of monsters.");
10441 if (!getdir((char *)0)) return 0;
10443 pline("You're way too busy right now!");
10446 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
10447 pline("It seems that you're in a location where you're not allowed to be...");
10450 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
10451 pline("You try to drown an invisible barrier, which fails (predictably).");
10452 /* make the player pay for the attempt --Amy */
10453 t_timeout
= rnz(8000);
10456 if (levl
[u
.ux
][u
.uy
].typ
!= POOL
&& levl
[u
.ux
][u
.uy
].typ
!= MOAT
&& levl
[u
.ux
][u
.uy
].typ
!= WATER
&& levl
[u
.ux
][u
.uy
].typ
!= WATERTUNNEL
&& levl
[u
.ux
][u
.uy
].typ
!= CRYSTALWATER
&& levl
[u
.ux
+ u
.dx
][u
.uy
+ u
.dy
].typ
!= POOL
&& levl
[u
.ux
+ u
.dx
][u
.uy
+ u
.dy
].typ
!= MOAT
&& levl
[u
.ux
+ u
.dx
][u
.uy
+ u
.dy
].typ
!= WATER
&& levl
[u
.ux
+ u
.dx
][u
.uy
+ u
.dy
].typ
!= WATERTUNNEL
&& levl
[u
.ux
+ u
.dx
][u
.uy
+ u
.dy
].typ
!= CRYSTALWATER
) {
10457 pline("You can't drown someone here!");
10461 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
10463 You("grasp at nothing.");
10464 /* splicehack would return 0 here, but I won't let you use the tech to
10465 * scan the area for monsters --Amy */
10466 t_timeout
= rnz(8000);
10469 if (!sticks(mtmp
->data
)) {
10471 pline("You wrap up %s with your tail and pull him/her/them/it into the depths with you!", Monnam(mtmp
));
10472 if (!is_swimmer(mtmp
->data
) && !amphibious(mtmp
->data
)) {
10473 You("attempt to drown %s...", mon_nam(mtmp
));
10474 hurtmon(mtmp
, (!rn2(5) && (techlevX(tech_no
) > mtmp
->m_lev
) && (techlevX(tech_no
) >= 10)) ? mtmp
->mhp
: (rnd(techlevX(tech_no
)) * 5) );
10476 pline("%s does not drown!", Monnam(mtmp
));
10478 if (mtmp
&& !DEADMONSTER(mtmp
)) wakeup(mtmp
); /* monster becomes hostile */
10480 You("cannot get a grip on %s!", mon_nam(mtmp
));
10483 t_timeout
= rnz(8000);
10488 if (CannotSelectItemsInPrompts
) break;
10490 otmp
= getobj(allnoncount
, "definalize");
10492 if (yn("Really exit with no object selected?") == 'y')
10493 pline("You just wasted the opportunity to definalize an item.");
10494 else goto definalizechoice
;
10495 pline("A feeling of loss comes over you.");
10500 if (!otmp
->finalcancel
) {
10501 pline("That item wasn't finalized, and therefore nothing happens.");
10502 } else if (!stack_too_big(otmp
)) {
10503 otmp
->finalcancel
= FALSE
;
10504 pline("%s is no longer finalized.", Yname2(otmp
));
10505 if (otmp
&& objects
[(otmp
)->otyp
].oc_material
== MT_CELESTIUM
&& !stack_too_big(otmp
)) {
10506 if (!otmp
->cursed
) bless(otmp
);
10507 else uncurse(otmp
, FALSE
);
10509 } else pline("The stack was too big, and therefore nothing happens.");
10513 t_timeout
= rnz(50000);
10516 case T_ANTI_INERTIA
:
10517 if (!u
.inertia
) You("weren't slowed by inertia and therefore nothing happens.");
10519 if (u
.inertia
< 200) {
10521 if (u
.inertia
< 0) u
.inertia
= 0;
10522 Your("inertia counter was reduced by 100.");
10523 if (!u
.inertia
) pline("You've been cured of inertia.");
10524 } else if (u
.inertia
< 1000) {
10526 Your("inertia counter was reduced, and amounts to %d turns now.", u
.inertia
);
10529 Your("inertia counter was reduced by 500.");
10532 if (u
.inertia
< 0) u
.inertia
= 0; /* fail safe */
10534 t_timeout
= rnz(5000);
10537 case T_POWERBIOSIS
:
10539 if (!uactivesymbiosis
) {
10540 pline("Without a symbiote, this technique won't do anything.");
10544 num
= 50 + (techlevX(tech_no
) * 2);
10545 techt_inuse(tech_no
) = num
+ 1;
10546 pline("Your symbiote becomes super-powerful for a while!");
10548 t_timeout
= rnz(6000);
10551 case T_IMPLANTED_SYMBIOSIS
:
10553 if (!uactivesymbiosis
&& !uimplant
) {
10554 pline("You know that this technique requires both an implant and a symbiote. You currently have neither, and therefore very obviously nothing happens!");
10557 if (!uactivesymbiosis
) {
10558 pline("While you do have an implant, you lack a symbiote! Get one first if you want to use this technique!");
10562 pline("No implant found! You must equip one if you want to use this technique!");
10566 num
= 1000 + (techlevX(tech_no
) * 50);
10567 techt_inuse(tech_no
) = num
+ 1;
10568 pline("Your implant boosts your symbiote!");
10570 t_timeout
= rnz(7500);
10573 case T_ASSUME_SYMBIOTE
:
10575 if (!uactivesymbiosis
) {
10576 pline("What are you trying to do, polymorph into your symbiote while not actually having one?");
10577 if (FunnyHallu
) pline("If you thought this would turn you into a missingno, bad luck - the dev team thinks of everything.");
10581 You_feel("one with your symbiote.");
10582 u
.wormpolymorph
= u
.usymbiote
.mnum
;
10586 t_timeout
= rnz(10000);
10589 case T_GENERATE_OFFSPRING
:
10591 if (!uactivesymbiosis
) {
10592 pline("This requires a symbiote.");
10599 You("lay a symbiote egg.");
10600 uegg
= mksobj(EGG
, FALSE
, FALSE
, FALSE
);
10602 uegg
->spe
= 1; /* "laid by you" */
10604 uegg
->owt
= weight(uegg
);
10605 uegg
->corpsenm
= egg_type_from_parent(u
.usymbiote
.mnum
, FALSE
);
10606 uegg
->known
= uegg
->dknown
= 1;
10607 attach_egg_hatch_timeout(uegg
);
10613 t_timeout
= rnz(10000);
10617 case T_EXTRACHARGE
:
10619 if (CannotSelectItemsInPrompts
) break;
10621 otmp
= getobj(allnoncount
, "extracharge");
10623 if (yn("Really exit with no object selected?") == 'y')
10624 pline("You just wasted the opportunity to extracharge a wand.");
10625 else goto extrachargechoice
;
10626 pline("A feeling of loss comes over you.");
10627 t_timeout
= rnz(20000);
10631 if (otmp
->oclass
!= WAND_CLASS
) {
10632 pline("You selected something that isn't a wand, and therefore the charge dissipates.");
10633 t_timeout
= rnz(20000);
10636 switch (otmp
->otyp
) {
10640 case WAN_ACQUIREMENT
:
10641 case WAN_GAIN_LEVEL
:
10642 case WAN_INCREASE_MAX_HITPOINTS
:
10643 pline("That wand is too powerful, and therefore the charge dissipates.");
10644 t_timeout
= rnz(20000);
10647 if (otmp
->spe
> 125) { /* very unlikely to ever happen --Amy */
10648 pline("That wand already has the maximum amount of charges stored.");
10651 pline("Success! Your wand gained an additional charge.");
10652 if (otmp
&& objects
[(otmp
)->otyp
].oc_material
== MT_CELESTIUM
&& !stack_too_big(otmp
)) {
10653 if (!otmp
->cursed
) bless(otmp
);
10654 else uncurse(otmp
, FALSE
);
10661 t_timeout
= rnz(20000);
10669 pline("You can't tame an engulfer with this technique.");
10674 struct monst
*mtmp3
;
10676 pline("You try to tame evil monsters!");
10678 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
10679 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
10680 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !is_infrastructure_monster(mtmp3
) && mtmp3
->mtame
== 0 && mtmp3
->isminion
== 0 && mtmp3
->isgyp
== 0
10681 && mtmp3
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp3
->data
->geno
& G_UNIQ
) && caughtX
== 0)
10685 if (is_evilpatchmonster(mtmp3
->data
)) {
10686 if (!(resist(mtmp3
, RING_CLASS
, 0, NOTELL
) && resist(mtmp3
, RING_CLASS
, 0, NOTELL
))) {
10687 pline("%s is successfully tamed!", mon_nam(mtmp3
));
10688 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
10689 if (techlevX(tech_no
) < rnd(100)) caughtX
++;
10690 t_timeout
= rnz(4000);
10692 } else if ( ((rnd(30 - ACURR(A_CHA
))) < 4) && (!resist(mtmp3
, RING_CLASS
, 0, NOTELL
) || !resist(mtmp3
, RING_CLASS
, 0, NOTELL
)) ) {
10693 pline("%s is successfully tamed!", mon_nam(mtmp3
));
10694 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
10695 if (techlevX(tech_no
) < rnd(100)) caughtX
++;
10696 t_timeout
= rnz(4000);
10698 pline("%s resists the taming attempt!", mon_nam(mtmp3
));
10700 } else pline("%s cannot be tamed by this method!", mon_nam(mtmp3
));
10702 } /* monster is catchable loop */
10707 t_timeout
= rnz(4000);
10710 case T_DECAPABILITY
:
10711 num
= 50 + (techlevX(tech_no
) * 3);
10712 techt_inuse(tech_no
) = num
+ 1;
10713 pline("Polearms and lightsabers can temporarily put monsters to sleep.");
10715 t_timeout
= rnz(2500);
10718 case T_NO_HANDS_CURSE
:
10720 if (!uwep
|| !bimanual(uwep
)) {
10721 pline("That requires you to wield a two-handed weapon.");
10725 if (uwep
&& uwep
->cursed
) {
10726 pline("Your weapon is already cursed, and therefore nothing happens!");
10727 uwep
->bknown
= TRUE
;
10728 t_timeout
= rnz(600);
10732 if (uwep
&& uwep
->spe
< -20) {
10733 pline("Your weapon is in such a bad condition that this technique doesn't work!");
10734 t_timeout
= rnz(600);
10740 uwep
->hvycurse
= TRUE
;
10741 if (uwep
->spe
> 0) uwep
->spe
= 0;
10742 uwep
->spe
-= rne(2);
10743 if (uwep
->spe
< -120) uwep
->spe
= -120;
10744 uwep
->bknown
= TRUE
;
10746 pline("Your weapon is heavily cursed, but you receive some benefits.");
10749 if (u
.ugangr
> 0) u
.ugangr
--;
10750 u
.ublesscnt
-= 500;
10751 if (u
.ublesscnt
< 0) u
.ublesscnt
= 0;
10755 struct monst
*mtmp3
;
10758 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
10759 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
10760 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !is_infrastructure_monster(mtmp3
) && mtmp3
->mtame
== 0 && mtmp3
->isminion
== 0 && mtmp3
->isgyp
== 0
10761 && mtmp3
->mnum
!= quest_info(MS_NEMESIS
) && !(rn2(5) && (mtmp3
->data
->geno
& G_UNIQ
))) {
10763 if (mtmp3
->mfrenzied
) continue;
10764 if (mtmp3
->mpeaceful
) continue;
10765 if (resist(mtmp3
, RING_CLASS
, 0, NOTELL
) && !(((rnd(30 - ACURR(A_CHA
))) < 4) && !resist(mtmp3
, RING_CLASS
, 0, NOTELL
)) ) continue;
10767 pline("%s is pacified!", mon_nam(mtmp3
));
10768 mtmp3
->mpeaceful
= TRUE
;
10770 } /* monster is catchable loop */
10775 t_timeout
= rnz(6000);
10778 case T_HIGH_HEELED_SNEAKERS
:
10779 num
= 1000 + (techlevX(tech_no
) * 20);
10780 techt_inuse(tech_no
) = num
+ 1;
10781 pline("For a while, you can use high heels and sexy flats at the same time.");
10783 t_timeout
= rnz(5000);
10786 case T_FORM_CHOICE
:
10788 if (!uwep
|| !is_lightsaber(uwep
)) {
10789 pline("You can only change the form of a wielded lightsaber.");
10794 boolean madechoice
= 0;
10795 int sabertype
= -1;
10797 pline("Pick the desired lightsaber form. The prompt will loop until you actually make a choice.");
10799 while (madechoice
== 0 || sabertype
< 0) {
10801 if (yn("Do you want to switch to a one-handed lightsaber?")=='y') {
10802 madechoice
= 1; sabertype
= 1; }
10803 else if (yn("Do you want to switch to a two-handed lightsaber?")=='y') {
10804 madechoice
= 1; sabertype
= 2; }
10805 else if (yn("Do you want to switch to a laser swatter?")=='y') {
10806 madechoice
= 1; sabertype
= 3; }
10807 else if (yn("Do you want to switch to a nano hammer?")=='y') {
10808 madechoice
= 1; sabertype
= 4; }
10809 else if (yn("Do you want to switch to a lightwhip?")=='y') {
10810 madechoice
= 1; sabertype
= 5; }
10811 else if (yn("Do you want to switch to an electric cigarette?")=='y') {
10812 madechoice
= 1; sabertype
= 6; }
10813 else if (yn("Do you want to switch to a laserdent?")=='y') {
10814 madechoice
= 1; sabertype
= 7; }
10815 else if (yn("Do you want to switch to a laser sword?")=='y') {
10816 madechoice
= 1; sabertype
= 8; }
10817 else if (yn("Do you want to switch to a sith staff?")=='y') {
10818 madechoice
= 1; sabertype
= 9; }
10819 else if (yn("Do you want to switch to a laser pole?")=='y') {
10820 madechoice
= 1; sabertype
= 10; }
10821 else if (yn("Do you want to switch to a starwars mace?")=='y') {
10822 madechoice
= 1; sabertype
= 11; }
10823 else if (yn("Do you want to switch to a beamsword?")=='y') {
10824 madechoice
= 1; sabertype
= 12; }
10825 else if (yn("Do you want to switch to a laserxbow?")=='y') {
10826 madechoice
= 1; sabertype
= 13; }
10827 else if (yn("Do you want to switch to a heavy laser ball?")=='y') {
10828 madechoice
= 1; sabertype
= 14; }
10829 else if (yn("Do you want to switch to a laser chain?")=='y') {
10830 madechoice
= 1; sabertype
= 15; }
10831 else if (yn("Do you want to switch to a laserfist?")=='y') {
10832 madechoice
= 1; sabertype
= 16; }
10833 else if (yn("Do you want to switch to a laser tin opener?")=='y') {
10834 madechoice
= 1; sabertype
= 17; }
10835 else if (yn("Do you want to switch to a kliusling?")=='y') {
10836 madechoice
= 1; sabertype
= 18; }
10837 else if (yn("Do you want to switch to a lighttorch?")=='y') {
10838 madechoice
= 1; sabertype
= 19; }
10839 else if (yn("Do you want to switch to a pink lightsword?")=='y') {
10840 madechoice
= 1; sabertype
= 20; }
10841 else if (yn("Do you want to switch to a laser flyaxe?")=='y') {
10842 madechoice
= 1; sabertype
= 21; }
10843 else if (yn("Do you want to switch to a pink double lightsword?")=='y') {
10844 madechoice
= 1; sabertype
= 22; }
10848 if (sabertype
== 2 && (uarms
|| u
.twoweap
)) {
10849 pline("Something is blocking your second %s!", body_part(HAND
));
10852 if (sabertype
== 7 && (uarms
|| u
.twoweap
)) {
10853 pline("Something is blocking your second %s!", body_part(HAND
));
10856 if (sabertype
== 9 && (uarms
|| u
.twoweap
)) {
10857 pline("Something is blocking your second %s!", body_part(HAND
));
10860 if (sabertype
== 10 && (uarms
|| u
.twoweap
)) {
10861 pline("Something is blocking your second %s!", body_part(HAND
));
10864 if (sabertype
== 13 && (uarms
|| u
.twoweap
)) {
10865 pline("Something is blocking your second %s!", body_part(HAND
));
10868 if (sabertype
== 21 && (uarms
|| u
.twoweap
)) {
10869 pline("Something is blocking your second %s!", body_part(HAND
));
10872 if (sabertype
== 22 && (uarms
|| u
.twoweap
)) {
10873 pline("Something is blocking your second %s!", body_part(HAND
));
10877 if (sabertype
== 1) {
10879 case 1: uwep
->otyp
= GREEN_LIGHTSABER
; break;
10880 case 2: uwep
->otyp
= BLUE_LIGHTSABER
; break;
10881 case 3: uwep
->otyp
= RED_LIGHTSABER
; break;
10882 case 4: uwep
->otyp
= YELLOW_LIGHTSABER
; break;
10883 case 5: uwep
->otyp
= VIOLET_LIGHTSABER
; break;
10884 case 6: uwep
->otyp
= WHITE_LIGHTSABER
; break;
10885 case 7: uwep
->otyp
= MYSTERY_LIGHTSABER
; break;
10886 case 8: uwep
->otyp
= ORANGE_LIGHTSABER
; break;
10887 case 9: uwep
->otyp
= BLACK_LIGHTSABER
; break;
10888 case 10: uwep
->otyp
= RAINBOW_LIGHTSABER
; break;
10889 case 11: uwep
->otyp
= DARK_LIGHTSABER
; break;
10891 } else if (sabertype
== 2) {
10892 uwep
->otyp
= !rn2(3) ? CYAN_DOUBLE_LIGHTSABER
: rn2(2) ? RED_DOUBLE_LIGHTSABER
: WHITE_DOUBLE_LIGHTSABER
;
10893 } else if (sabertype
== 3) {
10894 uwep
->otyp
= LASER_SWATTER
;
10895 } else if (sabertype
== 4) {
10896 uwep
->otyp
= NANO_HAMMER
;
10897 } else if (sabertype
== 5) {
10898 uwep
->otyp
= LIGHTWHIP
;
10899 } else if (sabertype
== 6) {
10900 uwep
->otyp
= ELECTRIC_CIGARETTE
;
10901 } else if (sabertype
== 7) {
10902 uwep
->otyp
= LASERDENT
;
10903 } else if (sabertype
== 8) {
10904 uwep
->otyp
= LASER_SWORD
;
10905 } else if (sabertype
== 9) {
10906 uwep
->otyp
= SITH_STAFF
;
10907 } else if (sabertype
== 10) {
10908 uwep
->otyp
= LASER_POLE
;
10909 } else if (sabertype
== 11) {
10910 uwep
->otyp
= STARWARS_MACE
;
10911 } else if (sabertype
== 12) {
10912 uwep
->otyp
= BEAMSWORD
;
10913 } else if (sabertype
== 13) {
10914 uwep
->otyp
= LASERXBOW
;
10915 } else if (sabertype
== 14) {
10916 uwep
->otyp
= HEAVY_LASER_BALL
;
10917 } else if (sabertype
== 15) {
10918 uwep
->otyp
= LASER_CHAIN
;
10919 } else if (sabertype
== 16) {
10920 uwep
->otyp
= LASERFIST
;
10921 } else if (sabertype
== 17) {
10922 uwep
->otyp
= LASER_TIN_OPENER
;
10923 } else if (sabertype
== 18) {
10924 uwep
->otyp
= KLIUSLING
;
10925 } else if (sabertype
== 19) {
10926 uwep
->otyp
= LIGHTTORCH
;
10927 } else if (sabertype
== 20) {
10928 uwep
->otyp
= PINK_LIGHTSWORD
;
10929 } else if (sabertype
== 21) {
10930 uwep
->otyp
= LASER_FLYAXE
;
10931 } else /* sabertype == 22 */
10932 uwep
->otyp
= PINK_DOUBLE_LIGHTSWORD
;
10934 pline("Your lightsaber warps, and changes into a different one!");
10935 /* known problem: you can pick the form that your lightsaber already has */
10938 t_timeout
= rnz(2000);
10941 case T_STAR_DIGGING
:
10943 pline("Digging complete!");
10945 t_timeout
= rnz(10000);
10948 case T_STARWARS_FRIENDS
:
10953 pline("That won't work while engulfed.");
10958 struct monst
*mtmp3
;
10959 pline("You try to tame monsters!");
10961 for (k
= -1; k
<= 1; k
++) for(l
= -1; l
<= 1; l
++) {
10962 if (!isok(u
.ux
+ k
, u
.uy
+ l
)) continue;
10963 if ( ((mtmp3
= m_at(u
.ux
+ k
, u
.uy
+ l
)) != 0) && !is_infrastructure_monster(mtmp3
) && mtmp3
->mtame
== 0 && mtmp3
->isminion
== 0 && mtmp3
->isgyp
== 0
10964 && mtmp3
->mnum
!= quest_info(MS_NEMESIS
) && !(mtmp3
->data
->geno
& G_UNIQ
) )
10968 if (mtmp3
->data
->mflags5
& M5_SPACEWARS
|| mtmp3
->data
->mflags5
& M5_JOKE
) {
10969 if (!(resist(mtmp3
, RING_CLASS
, 0, NOTELL
) && !(((rnd(30 - ACURR(A_CHA
))) < 4) ) )) {
10970 pline("%s is successfully tamed!", mon_nam(mtmp3
));
10971 (void) tamedog(mtmp3
, (struct obj
*) 0, TRUE
);
10973 pline("%s resists the taming attempt!", mon_nam(mtmp3
));
10975 } else pline("%s cannot be tamed by this method!", mon_nam(mtmp3
));
10977 } /* monster is catchable loop */
10983 struct permonst
*shoe
= 0;
10985 struct monst
*shoemonst
;
10990 if (attempts
&& (attempts
% 10000 == 0)) u
.mondiffhack
++;
10991 if (!rn2(2000)) reset_rndmonst(NON_PM
);
10993 } while ( (!shoe
|| (shoe
&& !(shoe
->mflags5
& M5_SPACEWARS
) && !(shoe
->mflags5
& M5_JOKE
))) && attempts
< 50000);
10996 shoemonst
= makemon(shoe
, u
.ux
, u
.uy
, NO_MM_FLAGS
);
10997 if (shoemonst
) (void) tamedog(shoemonst
, (struct obj
*) 0, TRUE
);
11002 t_timeout
= rnz(5000);
11005 case T_USE_THE_FORCE_LUKE
:
11006 num
= 200 + (techlevX(tech_no
) * 5);
11007 techt_inuse(tech_no
) = num
+ 1;
11008 pline("Alright Luke, you can use the force powerfully for a while now!");
11010 t_timeout
= rnz(2500);
11013 case T_TELEKINESIS
:
11016 struct trap
*ttrap
;
11019 pline("Where do you want to apply telekinesis?");
11020 if (getpos(&cc
, TRUE
, "apply telekinesis where") < 0)
11022 if (!cansee(cc
.x
, cc
.y
)){
11023 You("can't see what's there!");
11026 if ((ttrap
=t_at(cc
.x
, cc
.y
)) && ttrap
->tseen
&&
11027 yn("Handle the trap here?") == 'y'){
11028 if (yn("Disarm the trap?") == 'y'){
11029 techt_inuse(tech_no
) = 1;
11030 /* copied from trap.c */
11031 switch(ttrap
->ttyp
) {
11034 t_timeout
= rnz(250);
11035 return disarm_holdingtrap(ttrap
);
11037 t_timeout
= rnz(250);
11038 return disarm_landmine(ttrap
);
11040 t_timeout
= rnz(250);
11041 return disarm_squeaky_board(ttrap
);
11043 t_timeout
= rnz(250);
11044 return disarm_shooting_trap(ttrap
, DART
);
11046 t_timeout
= rnz(250);
11047 return disarm_shooting_trap(ttrap
, ARROW
);
11049 t_timeout
= rnz(250);
11050 return disarm_rust_trap(ttrap
);
11052 t_timeout
= rnz(250);
11053 return disarm_fire_trap(ttrap
);
11055 You("cannot disable %s trap.", (u
.dx
|| u
.dy
) ? "that" : "this");
11058 } else if(yn("Spring this trap?")=='y') {
11059 switch(ttrap
->ttyp
) {
11061 You("trigger the landmine.");
11062 pline("KABLAAAM!");
11063 blow_up_landmine(ttrap
);
11064 fill_pit(cc
.x
, cc
.y
);
11065 newsym(cc
.x
, cc
.y
);
11066 t_timeout
= rnz(250);
11068 case ROLLING_BOULDER_TRAP
:
11070 int style
= ROLL
| (ttrap
->tseen
? LAUNCH_KNOWN
: 0);
11071 You("trigger the trap!");
11072 if(!launch_obj(BOULDER
, ttrap
->launch
.x
, ttrap
->launch
.y
, ttrap
->launch2
.x
, ttrap
->launch2
.y
, style
)){
11074 newsym(cc
.x
, cc
.y
);
11075 pline("But no boulder was released.");
11077 t_timeout
= rnz(250);
11080 You("can't spring this trap.");
11084 } else if ((otmp
= level
.objects
[cc
.x
][cc
.y
]) != 0) {
11086 sprintf(buf
, "Pick up %s?", the(xname(otmp
)));
11087 if (yn(buf
) == 'n')
11090 /* Shop items will interact incorrectly and maybe even segfault. Since I'm way too lazy to make it work
11091 * correctly, I'm simply 'sealing' this error by making such items off-limits for telekinesis --Amy */
11092 if (costly_spot(cc
.x
, cc
.y
)) {
11093 pline("This item is inside a telekinesis-proof shop. Your attempt to pick it up fails.");
11094 t_timeout
= rnz(250);
11098 You("pick up an object from the %s.", surface(cc
.x
,cc
.y
));
11099 (void) pickup_object(otmp
, Race_if(PM_LEVITATOR
) ? otmp
->quan
: 1L, TRUE
, FALSE
);
11100 newsym(cc
.x
, cc
.y
);
11101 t_timeout
= rnz(250);
11103 You("can't do anything there");
11108 case T_CHARGE_SABER
:
11109 if (!uwep
|| !is_lightsaber(uwep
)){
11110 You("are not holding a lightsaber!");
11113 if (uwep
&& uwep
->otyp
== LIGHTTORCH
) {
11114 pline("The lighttorch cannot be recharged that way!");
11118 You("lack the concentration to charge %s. You need at least 5 points of mana!", the(xname(uwep
)));
11121 You("start charging %s.", the(xname(uwep
)));
11123 set_occupation(charge_saber
, "charging", 0);
11124 t_timeout
= rnz(2500);
11127 pline ("Error! No such effect (%i)", tech_no
);
11130 if (t_timeout
>= 1) {
11131 register int timeoutamount
= t_timeout
;
11132 while (timeoutamount
>= 1000) {
11133 timeoutamount
-= 1000;
11134 use_skill(P_TECHNIQUES
, 1);
11136 if (timeoutamount
>= 1 && (timeoutamount
> rn2(1000))) use_skill(P_TECHNIQUES
, 1);
11139 if (rn2(4) && (t_timeout
> rnd(StrongExtra_wpn_practice
? 15000 : Extra_wpn_practice
? 25000 : 50000)) ) {
11140 maybeleveltech
= TRUE
;
11145 if (!PlayerCannotUseSkills
) {
11147 switch (P_SKILL(P_TECHNIQUES
)) {
11165 case P_GRAND_MASTER
:
11169 case P_SUPREME_MASTER
:
11176 if (!can_limitbreak())
11177 techtout(tech_no
) = (t_timeout
* (100 - min(techlevX(tech_no
), 50)) / 100);
11179 techtout(tech_no
) = (t_timeout
* (100 - min(techlevX(tech_no
), 50)) / 300);
11181 techtout(tech_no
) = (t_timeout
* (100 - min(techlevX(tech_no
), 50)) / 1000);
11182 /* limit break can be used for endless exploits, so this fix was urgently necessary... --Amy */
11184 if (ishaxor
&& techtout(tech_no
) > 1) techtout(tech_no
) /= 2;
11186 if (RngeTechReuse
&& techtout(tech_no
) > 1) { /* 10% reduction --Amy */
11187 techtout(tech_no
) *= 9;
11188 techtout(tech_no
) /= 10;
11191 if (u
.emynluincomplete
&& techtout(tech_no
) > 99) { /* 2% reduction --Amy */
11192 techtout(tech_no
) *= 49;
11193 techtout(tech_no
) /= 50;
11196 if (irisartiboost()) {
11197 techtout(tech_no
) *= (100 - (irisartiboost() * 5));
11198 techtout(tech_no
) /= 100;
11201 if (uamul
&& uamul
->oartifact
== ART_TYRANITAR_S_QUEST
&& !rn2(2)) techtout(tech_no
) = 0;
11203 if (powerfulimplants() && uimplant
&& uimplant
->oartifact
== ART_NO_ABNORMAL_FUTURE
) techtout(tech_no
) /= 4;
11205 if (techid(tech_no
) == T_ASIAN_KICK
) {
11207 for (i
= 0; i
< MAXTECH
; i
++) {
11208 if (techid(i
) == T_LEGSCRATCH_ATTACK
|| techid(i
) == T_GROUND_STOMP
|| techid(i
) == T_ATHLETIC_COMBAT
)
11209 if (techtout(tech_no
) > 10) techtout(i
) += rn2(3) ? rnz(techtout(tech_no
)) : rnd(techtout(tech_no
));
11214 if (techid(tech_no
) == T_LEGSCRATCH_ATTACK
) {
11216 for (i
= 0; i
< MAXTECH
; i
++) {
11217 if (techid(i
) == T_ASIAN_KICK
|| techid(i
) == T_GROUND_STOMP
|| techid(i
) == T_ATHLETIC_COMBAT
)
11218 if (techtout(tech_no
) > 10) techtout(i
) += rn2(3) ? rnz(techtout(tech_no
)) : rnd(techtout(tech_no
));
11223 if (techid(tech_no
) == T_GROUND_STOMP
) {
11225 for (i
= 0; i
< MAXTECH
; i
++) {
11226 if (techid(i
) == T_LEGSCRATCH_ATTACK
|| techid(i
) == T_ASIAN_KICK
|| techid(i
) == T_ATHLETIC_COMBAT
)
11227 if (techtout(tech_no
) > 10) techtout(i
) += rn2(3) ? rnz(techtout(tech_no
)) : rnd(techtout(tech_no
));
11232 if (techid(tech_no
) == T_ATHLETIC_COMBAT
) {
11234 for (i
= 0; i
< MAXTECH
; i
++) {
11235 if (techid(i
) == T_LEGSCRATCH_ATTACK
|| techid(i
) == T_GROUND_STOMP
|| techid(i
) == T_ASIAN_KICK
)
11236 if (techtout(tech_no
) > 10) techtout(i
) += rn2(3) ? rnz(techtout(tech_no
)) : rnd(techtout(tech_no
));
11241 if (techid(tech_no
) == T_AUTOKILL
) {
11243 for (i
= 0; i
< MAXTECH
; i
++) {
11244 if (techid(i
) == T_CHAIN_THUNDERBOLT
|| techid(i
) == T_FLASHING_MISCHIEF
)
11245 if (techtout(tech_no
) > 10) techtout(i
) += rn2(3) ? rnz(techtout(tech_no
)) : rnd(techtout(tech_no
));
11250 if (techid(tech_no
) == T_CHAIN_THUNDERBOLT
) {
11252 for (i
= 0; i
< MAXTECH
; i
++) {
11253 if (techid(i
) == T_AUTOKILL
|| techid(i
) == T_FLASHING_MISCHIEF
)
11254 if (techtout(tech_no
) > 10) techtout(i
) += rn2(3) ? rnz(techtout(tech_no
)) : rnd(techtout(tech_no
));
11259 if (techid(tech_no
) == T_FLASHING_MISCHIEF
) {
11261 for (i
= 0; i
< MAXTECH
; i
++) {
11262 if (techid(i
) == T_CHAIN_THUNDERBOLT
|| techid(i
) == T_AUTOKILL
)
11263 if (techtout(tech_no
) > 10) techtout(i
) += rn2(3) ? rnz(techtout(tech_no
)) : rnd(techtout(tech_no
));
11268 if (maybeleveltech
) {
11269 if (tech_list
[tech_no
].t_lev
> 0) {
11270 tech_list
[tech_no
].t_lev
-= 1;
11271 pline("Your %s technique leveled up to level %d!", techname(tech_no
), techlev(tech_no
));
11275 /*By default, action should take a turn*/
11276 if (techid(tech_no
) == T_DIRECTIVE
) return 0;
11280 /* Whether or not a tech is in use.
11281 * 0 if not in use, turns left if in use. Tech is done when techinuse == 1
11284 tech_inuse(tech_id
)
11289 if (tech_id
< 1 || tech_id
> MAXTECH
) {
11290 impossible ("invalid tech: %d", tech_id
);
11293 for (i
= 0; i
< MAXTECH
; i
++) {
11294 if (techid(i
) == tech_id
) {
11295 return (techt_inuse(i
));
11303 struct monst
*mtmp
;
11305 (void) tamedog(mtmp
, (struct obj
*) 0, TRUE
);
11314 for (i
= 0; i
< MAXTECH
; i
++) {
11315 if (techid(i
) == NO_TECH
)
11318 if (techid(i
) == T_SILENT_OCEAN
) {
11319 if (techt_inuse(i
) == 10) pline("Attention: The effect of Silent Ocean will only last for 10 more turns. If you can't exist in water without it, consider heading to the nearest shore.");
11320 if (techt_inuse(i
) == 2) pline("Caution! Silent Ocean will end in 2 turns! If you're currently in the water and can't exist in water without the effect of Silent Ocean, you should get back on dry land quickly in order to prevent drowning!");
11323 if (techt_inuse(i
) && !(techid(i
) == T_UNARMED_FOCUS
&& !rn2(4) && !uwep
&& !(u
.twoweap
&& uswapwep
) && uarm
&& uarm
->otyp
== ROBE_OF_FOCUSSING
) ) {
11324 /* Check if technique is done */
11325 if (!(--techt_inuse(i
)))
11326 switch (techid(i
)) {
11328 You("retract your claws.");
11329 /* You're using bare hands now, so new msg for next attack */
11331 /* Lose berserk status */
11335 The("red haze in your mind clears.");
11343 case T_DOUBLE_THROWNAGE
:
11347 You_feel("the power dissipate.");
11349 case T_SPECTRAL_SWORD
:
11350 You_feel("your weapon losing its elemental power.");
11352 case T_SIGIL_TEMPEST
:
11353 pline_The("sigil of tempest fades.");
11355 case T_SIGIL_CONTROL
:
11356 pline_The("sigil of control fades.");
11358 case T_SIGIL_DISCHARGE
:
11359 pline_The("sigil of discharge fades.");
11362 Your("anger cools.");
11364 case T_SHUT_THAT_BITCH_UP
:
11365 You("can no longer shut up bitches.");
11367 case T_EXTRA_LONG_SQUEAK
:
11368 pline("Your butt has stopped squeaking.");
11370 case T_BULLETREUSE
:
11371 pline("Your ammo can no longer be reused.");
11373 case T_CONCENTRATING
:
11374 You("stop concentrating.");
11376 case T_SHIELD_BASH
:
11377 You("pull back your shield.");
11380 You("stop whirling.");
11383 Your("skin is no longer hard as iron.");
11385 case T_POWER_SURGE
:
11386 pline_The("awesome power within you fades.");
11389 You("sense the flow of time returning to normal.");
11392 You_feel("the power in your hands dissipate.");
11395 You_feel("that the spell spam power has timed out.");
11397 case T_CHI_HEALING
:
11398 You_feel("the healing power dissipate.");
11400 case T_SILENT_OCEAN
:
11401 pline("The effect of Silent Ocean ends.");
11404 pline("The glowing unicorn horn disappears.");
11406 case T_ENERGY_CONSERVATION
:
11407 pline("Your lightsaber consumes energy at the normal rate again.");
11409 case T_UNARMED_FOCUS
:
11410 pline("You're no longer focussing on unarmed combat.");
11412 case T_WILD_SLASHING
:
11413 pline("You stop your wild slashing.");
11415 case T_ABSORBER_SHIELD
:
11416 pline("The absorber shield dissipates.");
11418 case T_STEADY_HAND
:
11419 pline("Your %s are less steady.", makeplural(body_part(HAND
)));
11422 pline("Your lightsaber can no longer fire beams.");
11424 case T_ENERGY_TRANSFER
:
11425 pline("The energy transfer has stopped.");
11427 case T_POWERFUL_AURA
:
11428 pline("You're no longer surrounded by the powerful aura.");
11431 pline("The refuge effect has ended.");
11434 pline("Escrobism is no longer active.");
11436 case T_GREEN_MISSILE
:
11437 pline("You ran out of wood for your poisonous missiles.");
11439 case T_BIG_N_VEINY
:
11440 pline("Your body is no longer poisonous.");
11442 case T_POISON_PEN_LETTER
:
11443 pline("You're done writing your poison pen letters, gotta conserve the ink after all.");
11445 case T_AFTERBURNER
:
11446 pline("Your afterburner is depleted.");
11449 pline("Damn, the buggard effect has ended already! Curse those developers that made its duration so short relative to its long timer!");
11451 case T_THUNDERSTORM
:
11452 pline("Your thunderstorm flashes for one last time and ceases.");
11454 case T_BLADE_SHIELD
:
11455 pline("Blade shield effect has ended. At least now it no longer disrupts your attacks.");
11458 pline("Your polearms and lances are no longer effective at close range.");
11460 case T_WEAPON_BLOCKER
:
11461 pline("Thankfully, weapon blocker is temporary here and has just ended. You got very annoyed by the block lock effect anyway.");
11464 pline("The effects of your grinders and lances are no longer swapped.");
11466 case T_LIGHTER_BALLS
:
11467 Your("balls are heavy again.");
11468 if (FunnyHallu
) pline("Now's the time to present them to a sweet girl, who can kick them to test your pain threshold.");
11470 case T_POWERBIOSIS
:
11471 pline("Your symbiote's awesome power fades.");
11473 case T_IMPLANTED_SYMBIOSIS
:
11474 pline("The boost granted to your symbiote by your implant has been used up.");
11476 case T_PIRATE_BROTHERING
:
11477 pline("Your pirate brothering ability deactivates.");
11479 case T_DECAPABILITY
:
11480 pline("Your weapons are no longer capable of decapability.");
11482 case T_HIGH_HEELED_SNEAKERS
:
11483 pline("You can no longer use the sexy flats skill while wearing high heels.");
11486 pline("Your sprint ends.");
11488 case T_SKULL_CRUSH
:
11489 pline("You waited too long, and can no longer crush an opponent's skull!");
11491 case T_FEMALE_COMBO
:
11492 pline("Your female combo has ended.");
11495 pline("You're done bashing enemies' heads with your heels.");
11498 pline("You've finished your sexy stand.");
11501 pline("You've been running for far too long, and decide that you need a rest.");
11503 case T_PERFUME_STRIDE
:
11504 pline("Finally, you can take your heels off again. Beware that unless you uncursed them, you probably still can't.");
11506 case T_NAUGHTY_HEELOT
:
11507 pline("You're done playing the naughty heelot.");
11509 case T_EXTREME_STURDINESS
:
11510 pline("Your GOI has expired. Or, in human-readable terms, your extreme sturdiness ends and you need to be more careful again.");
11512 case T_BUTT_PROTECTION
:
11513 pline("Your butt is no longer protected.");
11516 pline("You can no longer stab enemies with your heel.");
11518 case T_USE_THE_FORCE_LUKE
:
11519 pline("Sorry Luke, but you can no longer use the force with extra effectivity.");
11521 case T_SURRENDER_OR_DIE
:
11522 pline("Cutting an opponent's weapon no longer has special effects.");
11524 case T_PERILOUS_WHIRL
:
11525 pline("Your double lightsaber no longer drains life.");
11527 case T_STAT_RESIST
:
11528 pline("You no longer resist status effects.");
11530 case T_FORCE_FIELD
:
11531 pline("The force field dissipates.");
11534 pline("Your staff no longer attacks as quickly as before.");
11536 case T_BEAUTY_CHARM
:
11537 pline("You're done posing with your heels.");
11540 pline("You waited too long and now the opportunity to smash an enemy's nuts with your stilettos is no longer there... :(");
11542 case T_LEGSCRATCH_ATTACK
:
11543 pline("Your sexy cone heels are done scratching hostile shins. They sure drew a lot of blood, and you feel that they're very pleased!");
11545 case T_GROUND_STOMP
:
11546 pline("Your wedge heels are done stomping defenseless enemies. It was a lot of fun, and your heels love you for using them as deadly weapons!");
11548 case T_ATHLETIC_COMBAT
:
11549 pline("Wow, you're so athletic, it's amazing watching you aim high kicks at your enemies' heads with your block heels. But now it's time to relax. I'm fairly sure your fleecy block heels like you even more now!");
11552 pline("Your rays have the normal range again.");
11555 pline("Your boomerangs are no longer capable of paralyzing enemies.");
11557 case T_COMBO_STRIKE
:
11558 pline("Your combo has ended.");
11561 pline("You stop using jiu-jitsu.");
11563 case T_BLADE_ANGER
:
11564 pline("Your shuriken are no longer capable of piercing.");
11568 } else switch (techid(i
)) {
11569 /* During the technique */
11571 /* Bleed but don't kill */
11572 if (u
.uhpmax
> 1) u
.uhpmax
--;
11573 if (u
.uhp
> 1) u
.uhp
--;
11575 if (u
.mhmax
> 1) u
.uhpmax
--;
11576 if (u
.mh
> 1) u
.uhp
--;
11579 case T_POWER_SURGE
:
11580 /* Bleed off power. Can go to zero as 0 power is not fatal */
11581 if (u
.uenmax
> 1) u
.uenmax
--;
11582 if (u
.uen
> 0) u
.uen
--;
11587 } /* technique active check */
11589 if (techtout(i
) == 1) pline("Your %s technique is ready to be used!", techname(i
));
11590 if (techtout(i
) > 0) {
11591 if (!(uarmf
&& uarmf
->oartifact
== ART_THICKER_THAN_THE_HEAD
&& rn2(2) && (techtout(i
) > 1) ) )
11594 if (uarmc
&& uarmc
->oartifact
== ART_ARTIFICIAL_FAKE_DIFFICULTY
&& techtout(i
) > 0) {
11595 if (techtout(i
) == 1) pline("Your %s technique is ready to be used!", techname(i
));
11599 if (techtout(i
) < 0) techtout(i
) = 0; /* fail safe */
11606 int i
, tech
, n
= 0;
11608 for (i
= 0; i
< MAXTECH
; i
++) {
11610 if (tech
!= NO_TECH
&& techt_inuse(i
)) {
11619 /* occasionally things will cause certain techs to end prematurely --Amy */
11621 stopsingletechnique(whichtech
)
11626 for (i
= 0; i
< MAXTECH
; i
++) {
11628 if (tech
!= NO_TECH
&& techt_inuse(i
) && tech
== whichtech
) {
11637 struct monst
*mtmp
;
11641 if (mtmp
->mhp
< 1) killed (mtmp
);
11647 static const struct innate_tech
*
11650 if (Race_if(PM_YUGGER
)) return ((struct innate_tech
*) 0); /* none */
11652 switch (Role_switch
) {
11653 case PM_ARCHEOLOGIST
: return (arc_tech
);
11654 case PM_GOFF
: return (gof_tech
);
11655 case PM_DRUID
: return (drd_tech
);
11656 case PM_SOFTWARE_ENGINEER
: return (sof_tech
);
11657 case PM_CRACKER
: return (cra_tech
);
11658 case PM_STORMBOY
: return (sto_tech
);
11659 case PM_SPACE_MARINE
: return (sma_tech
);
11660 case PM_JANITOR
: return (jan_tech
);
11661 case PM_FIREFIGHTER
: return (fir_tech
);
11662 case PM_YAUTJA
: return (yau_tech
);
11663 case PM_JOCKEY
: return (joc_tech
);
11664 case PM_GAMER
: return (gam_tech
);
11665 case PM_GLADIATOR
: return (gla_tech
);
11666 case PM_AMAZON
: return (ama_tech
);
11667 case PM_ARTIST
: return (art_tech
);
11668 case PM_ALTMER
: return (alt_tech
);
11669 case PM_BOSMER
: return (bos_tech
);
11670 case PM_BULLY
: return (bul_tech
);
11671 case PM_DUNMER
: return (dun_tech
);
11672 case PM_STAND_USER
: return (sta_tech
);
11673 case PM_ORDINATOR
: return (ord_tech
);
11674 case PM_THALMOR
: return (tha_tech
);
11675 case PM_DRUNK
: return (dru_tech
);
11676 case PM_BARBARIAN
: return (bar_tech
);
11677 case PM_NOOB_MODE_BARB
: return (noo_tech
);
11678 case PM_BLOODSEEKER
: return (blo_tech
);
11679 case PM_BLEEDER
: return (ble_tech
);
11680 case PM_CAVEMAN
: return (cav_tech
);
11681 case PM_DEMAGOGUE
: return (dem_tech
);
11682 case PM_DQ_SLIME
: return (sli_tech
);
11683 case PM_ERDRICK
: return (erd_tech
);
11684 case PM_BARD
: return (brd_tech
);
11685 case PM_FLAME_MAGE
: return (fla_tech
);
11686 case PM_ACID_MAGE
: return (aci_tech
);
11687 case PM_HUSSY
: return (hus_tech
);
11688 case PM_TRANSVESTITE
: return (tra_tech
);
11689 case PM_PROSTITUTE
: return (kur_tech
);
11690 case PM_KURWA
: return (kur_tech
);
11691 case PM_DISSIDENT
: return (dis_tech
);
11692 case PM_MASON
: return (mas_tech
);
11693 case PM_XELNAGA
: return (xel_tech
);
11694 case PM_MASTERMIND
: return (mam_tech
);
11695 case PM_SAGE
: return (sag_tech
);
11696 case PM_TRANSSYLVANIAN
: return (trs_tech
);
11697 case PM_TOPMODEL
: return (top_tech
);
11698 case PM_FAILED_EXISTENCE
: return (fai_tech
);
11699 case PM_LUNATIC
: return (lun_tech
);
11700 case PM_ACTIVISTOR
: return (act_tech
);
11701 case PM_ELECTRIC_MAGE
: return (ele_tech
);
11702 case PM_POISON_MAGE
: return (psn_tech
);
11703 case PM_HEALER
: return (hea_tech
);
11704 case PM_ICE_MAGE
: return (ice_tech
);
11705 case PM_JEDI
: return (jed_tech
);
11706 case PM_HEDDERJEDI
: return (jed_tech
);
11707 case PM_KNIGHT
: return (kni_tech
);
11708 case PM_KORSAIR
: return (kor_tech
);
11709 case PM_SECRET_ADVICE_MEMBER
: return (sec_tech
);
11710 case PM_PREVERSIONER
: return (pre_tech
);
11711 case PM_DANCER
: return (dan_tech
);
11712 case PM_DIABLIST
: return (dia_tech
);
11713 case PM_BUTT_LOVER
: return (but_tech
);
11714 case PM_JUSTICE_KEEPER
: return (jus_tech
);
11715 case PM_MONK
: return (mon_tech
);
11716 case PM_OCCULT_MASTER
: return (occ_tech
);
11717 case PM_ELEMENTALIST
: return (emn_tech
);
11718 case PM_CHAOS_SORCEROR
: return (cha_tech
);
11719 case PM_JESTER
: return (jes_tech
);
11720 case PM_LADIESMAN
: return (lad_tech
);
11721 case PM_GEEK
: return (gee_tech
);
11722 case PM_GRADUATE
: return (gee_tech
);
11723 case PM_SEXYMATE
: return (sex_tech
);
11724 case PM_ZOOKEEPER
: return (zoo_tech
);
11725 case PM_MEDIUM
: return (med_tech
);
11726 case PM_FENCER
: return (fnc_tech
);
11727 case PM_FIGHTER
: return (fig_tech
);
11728 case PM_SUPERMARKET_CASHIER
: return (sup_tech
);
11729 case PM_WANDKEEPER
: return (wan_tech
);
11730 case PM_WARRIOR
: return (war_tech
);
11731 case PM_PALADIN
: return (pal_tech
);
11732 case PM_FEAT_MASTER
: return (stu_tech
);
11733 case PM_DOLL_MISTRESS
: return (dol_tech
);
11734 case PM_MIDGET
: return (mid_tech
);
11735 case PM_PSYKER
: return (psy_tech
);
11736 case PM_QUARTERBACK
: return (qua_tech
);
11737 case PM_GUNNER
: return (gun_tech
);
11738 case PM_CLIMACTERIAL
: return (cli_tech
);
11739 case PM_WOMANIZER
: return (wom_tech
);
11740 case PM_DOOM_MARINE
: return (mar_tech
);
11741 case PM_ANACHRONIST
: return (ana_tech
);
11742 case PM_LIBRARIAN
: return (lib_tech
);
11743 case PM_AUGURER
: return (aug_tech
);
11744 case PM_SAIYAN
: return (sai_tech
);
11745 case PM_PSION
: return (psi_tech
);
11746 case PM_SCIENTIST
: return (sci_tech
);
11747 case PM_ASTRONAUT
: return (ast_tech
);
11748 case PM_CELLAR_CHILD
: return (cel_tech
);
11749 case PM_DEATH_EATER
: return (dea_tech
);
11750 case PM_DIVER
: return (div_tech
);
11751 case PM_POKEMON
: return (pok_tech
);
11752 case PM_NUCLEAR_PHYSICIST
: return (nuc_tech
);
11753 case PM_FORM_CHANGER
: return (for_tech
);
11754 case PM_GENDERSTARIST
: return (gen_tech
);
11755 case PM_EMPATH
: return (emp_tech
);
11756 case PM_GANGSTER
: return (gan_tech
);
11757 case PM_ROCKER
: return (roc_tech
);
11758 case PM_NECROMANCER
: return (nec_tech
);
11759 case PM_CRUEL_ABUSER
: return (abu_tech
);
11760 case PM_PRIEST
: return (pri_tech
);
11761 case PM_GOLDMINER
: return (gol_tech
);
11762 case PM_CHEVALIER
: return (che_tech
);
11763 case PM_ASSASSIN
: return (ass_tech
);
11764 case PM_RANGER
: return (ran_tech
);
11766 case PM_ELPH
: return (elp_tech
);
11767 case PM_SPACEWARS_FIGHTER
: return (spa_tech
);
11768 case PM_CAMPERSTRIKER
: return (cam_tech
);
11769 case PM_LOCKSMITH
: return (loc_tech
);
11770 case PM_WEIRDBOY
: return (wei_tech
);
11771 case PM_GANG_SCHOLAR
: return (sco_tech
);
11772 case PM_WALSCHOLAR
: return (wal_tech
);
11773 case PM_OFFICER
: return (off_tech
);
11774 case PM_ROGUE
: return (rog_tech
);
11775 case PM_SAMURAI
: return (sam_tech
);
11776 case PM_CYBERNINJA
: return (cyb_tech
);
11777 case PM_GRENADONIN
: return (gro_tech
);
11778 case PM_NINJA
: return (nin_tech
);
11779 case PM_TOURIST
: return (tou_tech
);
11780 case PM_UNDEAD_SLAYER
: return (und_tech
);
11781 case PM_UNBELIEVER
: return (unb_tech
);
11782 case PM_SHAPESHIFTER
: return (sha_tech
);
11783 case PM_SLAVE_MASTER
: return (sla_tech
);
11784 case PM_RINGSEEKER
: return (rin_tech
);
11785 case PM_UNDERTAKER
: return (unt_tech
);
11786 case PM_VALKYRIE
: return (val_tech
);
11787 case PM_WIZARD
: return (wiz_tech
);
11788 case PM_YEOMAN
: return (yeo_tech
);
11789 case PM_CARTOMANCER
: return (car_tech
);
11790 case PM_DRAGONMASTER
: return (dra_tech
);
11791 case PM_COMBATANT
: return (com_tech
);
11792 case PM_FJORDE
: return (fjo_tech
);
11793 case PM_PRACTICANT
: return (pra_tech
);
11794 case PM_EMERA
: return (eme_tech
);
11795 case PM_SYMBIANT
: return (sym_tech
);
11796 default: return ((struct innate_tech
*) 0);
11800 static const struct innate_tech
*
11803 switch (Race_switch
) {
11804 case PM_DOPPELGANGER
: return (dop_tech
);
11805 case PM_AZTPOK
: return (azt_tech
);
11806 case PM_HC_ALIEN
: return (hca_tech
);
11807 case PM_SLYER_ALIEN
: return (sly_tech
);
11808 case PM_DWARF
: return (dwa_tech
);
11810 case PM_PLAYER_MYRKALFR
:
11811 case PM_DROW
: return (elf_tech
);
11812 case PM_CURSER
: return (cur_tech
);
11813 case PM_IMPERIAL
: return (imp_tech
);
11814 case PM_SWIKNI
: return (swi_tech
);
11815 case PM_TAYIIN
: return (tay_tech
);
11816 case PM_CLOCKWORK_AUTOMATON
: return (clk_tech
);
11818 case PM_FENEK
: return (fen_tech
);
11819 case PM_LOWER_ENT
: return (ent_tech
);
11820 case PM_NORD
: return (nor_tech
);
11821 case PM_RETICULAN
: return (ret_tech
);
11822 case PM_OUTSIDER
: return (out_tech
);
11823 case PM_LICH_WARRIOR
: return (lic_tech
);
11824 case PM_ALBAE
: return (alb_tech
);
11825 case PM_BABYLONIAN
: return (bab_tech
);
11826 case PM_GERTEUT
: return (ger_tech
);
11827 case PM_POISONER
: return (poi_tech
);
11828 case PM_PLAYABLE_NEANDERTHAL
: return (nea_tech
);
11829 case PM_VORTEX
: return (vor_tech
);
11830 case PM_CORTEX
: return (cor_tech
);
11831 case PM_GNOME
: return (gno_tech
);
11832 case PM_KOP
: return (kop_tech
);
11833 case PM_ANCIPITAL
: return (anc_tech
);
11834 case PM_DEEP_ELF
: return (dee_tech
);
11835 case PM_DEVELOPER
: return (dvp_tech
);
11836 case PM_SHOE
: return (sho_tech
);
11837 case PM_BULDOZGAR
: return (bga_tech
);
11838 case PM_PLAYER_ANDROID
: return (and_tech
);
11839 case PM_FAWN
: return (faw_tech
);
11840 case PM_PLAYER_GREMLIN
: return (gre_tech
);
11841 case PM_STICKER
: return (sti_tech
);
11842 case PM_THUNDERLORD
: return (thu_tech
);
11843 case PM_JAVA
: return (jav_tech
);
11844 case PM_WISP
: return (wis_tech
);
11845 case PM_ROHIRRIM
: return (roh_tech
);
11846 case PM_PLAYER_SALAMANDER
: return (sal_tech
);
11847 case PM_SATRE
: return (sat_tech
);
11848 case PM_KORONST
: return (kst_tech
);
11849 case PM_RUSMOT
: return (rus_tech
);
11850 case PM_PIECE
: return (pic_tech
);
11851 case PM_CARTHAGE
: return (crt_tech
);
11852 case PM_MACTHEIST
: return (mac_tech
);
11853 case PM_BOVER
: return (bov_tech
);
11854 case PM_HAND
: return (han_tech
);
11855 case PM_PERVERT
: return (per_tech
);
11856 case PM_MONGUNG
: return (mog_tech
);
11857 case PM_VIETIS
: return (vie_tech
);
11858 case PM_SPARD
: return (spd_tech
);
11859 case PM_WEAPONIZED_DINOSAUR
: return (din_tech
);
11860 case PM_BURNINATOR
: return (bur_tech
);
11861 case PM_KOBOLT
: return (kob_tech
);
11862 case PM_OGRO
: return (ogr_tech
);
11863 case PM_PLAYER_FAIRY
: return (fay_tech
);
11864 case PM_BATMAN
: return (bat_tech
);
11865 case PM_HUMANOID_CENTAUR
: return (cen_tech
);
11866 case PM_BORG
: return (bor_tech
);
11867 case PM_WOOKIE
: return (woo_tech
);
11868 case PM_RODNEYAN
: return (rod_tech
);
11869 case PM_TURTLE
: return (tur_tech
);
11870 case PM_TURMENE
: return (tme_tech
);
11871 case PM_JELLY
: return (jel_tech
);
11872 case PM_HUMANOID_DRYAD
: return (dry_tech
);
11873 case PM_UNGENOMOLD
: return (ung_tech
);
11874 case PM_PLAYER_UNICORN
: return (uni_tech
);
11875 case PM_UNMAGIC_FISH
: return (unm_tech
);
11876 case PM_MOULD
: return (mou_tech
);
11877 case PM_MANSTER
: return (man_tech
);
11878 case PM_OCTOPODE
: return (oct_tech
);
11879 case PM_INKA
: return (ink_tech
);
11880 case PM_ARGONIAN
: return (arg_tech
);
11881 case PM_BRETON
: return (bre_tech
);
11882 case PM_MAZIN
: return (mzi_tech
);
11883 case PM_PLAYER_SHEEP
: return (she_tech
);
11884 case PM_SAMEDI
: return (sdi_tech
);
11885 case PM_REDGUARD
: return (red_tech
);
11886 case PM_ARMED_COCKATRICE
: return (coc_tech
);
11887 case PM_INSECTOID
: return (ins_tech
);
11888 case PM_KLACKON
: return (kla_tech
);
11889 case PM_MUMMY
: return (mum_tech
);
11890 case PM_KHAJIIT
: return (kha_tech
);
11891 case PM_WEAPON_CUBE
: return (gel_tech
);
11892 case PM_TONBERRY
: return (ton_tech
);
11893 case PM_HOBBIT
: return (hob_tech
);
11894 case PM_HUMAN_WEREWOLF
: return (lyc_tech
);
11895 case PM_HUMAN_MONKEY
: return (hmo_tech
);
11896 case PM_PLAYER_ZRUTY
: return (zru_tech
);
11897 case PM_VAMPIRE
: return (vam_tech
);
11898 case PM_SUCKING_FIEND
: return (vam_tech
);
11899 case PM_VAMGOYLE
: return (vam_tech
);
11900 case PM_LEVITATOR
: return (lev_tech
);
11901 case PM_HERBALIST
: return (hrb_tech
);
11902 case PM_ALCHEMIST
: return (alc_tech
);
11903 case PM_WEAPON_BUG
: return (gri_tech
);
11904 case PM_HUMANOID_ANGEL
: return (ang_tech
);
11905 case PM_INCANTIFIER
: return (inc_tech
);
11906 case PM_PLAYER_MIMIC
: return (mim_tech
);
11907 case PM_MISSINGNO
: return (mis_tech
);
11908 case PM_NAVI
: return (nav_tech
);
11909 case PM_SPIDERMAN
: return (spi_tech
);
11910 case PM_VENTURE_CAPITALIST
: return (ven_tech
);
11911 case PM_TRANSFORMER
: return (trf_tech
);
11912 case PM_WEAPON_TRAPPER
: return (trp_tech
);
11913 case PM_IRAHA
: return (ira_tech
);
11914 case PM_SPRIGGAN
: return (spr_tech
);
11915 case PM_VEELA
: return (vee_tech
);
11916 case PM_WARPER
: return (wrp_tech
);
11917 case PM_EGYMID
: return (egy_tech
);
11918 case PM_NEMESIS
: return (nem_tech
);
11919 case PM_CUPID
: return (cup_tech
);
11920 case PM_URGOTH
: return (urg_tech
);
11921 case PM_WYLVAN
: return (wyl_tech
);
11922 case PM_ZAUR
: return (zau_tech
);
11923 case PM_THRALL
: return (thr_tech
);
11924 case PM_PLAYER_CERBERUS
: return (cer_tech
);
11925 case PM_BACTERIA
: return (bac_tech
);
11926 case PM_UNALIGNMENT_THING
: return (una_tech
);
11927 default: /*return ((struct innate_tech *) 0)*/return (def_tech
);
11932 adjtech(oldlevel
,newlevel
)
11933 int oldlevel
, newlevel
;
11935 const struct innate_tech
11936 *tech
= role_tech(), *rtech
= race_tech();
11937 long mask
= FROMEXPER
;
11939 while (tech
|| rtech
) {
11940 /* Have we finished with the tech lists? */
11941 if (!tech
|| !tech
->tech_id
) {
11942 /* Try the race intrinsics */
11943 if (!rtech
|| !rtech
->tech_id
) break;
11945 rtech
= (struct innate_tech
*) 0;
11949 for(; tech
->tech_id
; tech
++)
11950 if(oldlevel
< tech
->ulevel
&& newlevel
>= tech
->ulevel
) {
11951 if (tech
->ulevel
!= 1 && !tech_known(tech
->tech_id
))
11952 You("learn how to perform %s!",
11953 tech_names
[tech
->tech_id
]);
11954 learntech(tech
->tech_id
, mask
, tech
->tech_lev
);
11955 } else if (oldlevel
>= tech
->ulevel
&& newlevel
< tech
->ulevel
11956 && tech
->ulevel
!= 1) {
11957 learntech(tech
->tech_id
, mask
, -1);
11958 if (!tech_known(tech
->tech_id
))
11959 You("lose the ability to perform %s!",
11960 tech_names
[tech
->tech_id
]);
11966 mon_to_zombie(monnum
)
11969 if ((&mons
[monnum
])->mlet
== S_ZOMBIE
) return monnum
; /* is already zombie */
11970 if ((&mons
[monnum
])->mlet
== S_KOBOLD
) return PM_KOBOLD_ZOMBIE
;
11971 if ((&mons
[monnum
])->mlet
== S_GNOME
) return PM_GNOME_ZOMBIE
;
11972 if (is_orc(&mons
[monnum
])) return PM_ORC_ZOMBIE
;
11973 if (is_dwarf(&mons
[monnum
])) return PM_DWARF_ZOMBIE
;
11974 if (is_elf(&mons
[monnum
])) return PM_ELF_ZOMBIE
;
11975 if (is_human(&mons
[monnum
])) return PM_HUMAN_ZOMBIE
;
11976 if (monnum
== PM_ETTIN
) return PM_ETTIN_ZOMBIE
;
11977 if (is_giant(&mons
[monnum
])) return PM_GIANT_ZOMBIE
;
11978 /* Is it humanoid? */
11979 /* Amy edit - what the heck??? No wonder the effing tech never worked! Because NO ONE tells you that! :( */
11980 /* if (!humanoid(&mons[monnum])) return (-1); */
11981 /* Otherwise, return a ghoul or ghast */
11982 /* or a random Z because, well, we have so many monster species, let's give the necro some better undead. --Amy */
11983 if (!rn2(3)) return (pm_mkclass(S_ZOMBIE
, 0) );
11984 else if (!rn2(4)) return PM_GHAST
;
11985 else return PM_GHOUL
;
11991 int i
, tlevel
, yourmana
, manamultiply
, calchelpvar
, effectlevel
;
11996 for (i
= 0; i
< MAXTECH
; i
++) {
11997 if (techid(i
) == NO_TECH
)
11999 if (techid(i
) != T_CHARGE_SABER
)
12001 tlevel
= techlevX(i
);
12003 if (tlevel
>= 10) {
12005 int jackpotchance
= 20; /* 1 in 5 was way too common --Amy */
12008 default: jackpotchance
= 20; if (tlevel
>= 50) jackpotchance
= 5; break;
12013 jackpotchance
= 20; break;
12017 jackpotchance
= 19; break;
12021 jackpotchance
= 18; break;
12025 jackpotchance
= 17; break;
12028 jackpotchance
= 16; break;
12032 jackpotchance
= 15; break;
12035 jackpotchance
= 14; break;
12039 jackpotchance
= 13; break;
12042 jackpotchance
= 12; break;
12045 jackpotchance
= 11; break;
12048 jackpotchance
= 10; break;
12052 jackpotchance
= 9; break;
12056 jackpotchance
= 8; break;
12060 jackpotchance
= 7; break;
12063 jackpotchance
= 6; break;
12065 jackpotchance
= 5; break;
12068 if (!rn2(jackpotchance
)) {
12069 You("manage to channel the force perfectly!");
12070 uwep
->age
+= 1500; // Jackpot!
12071 if (uwep
->oartifact
== ART_KYLE_S_JACKPOT
) uwep
->age
+= (1500 * rnd(2));
12075 You("channel the force into %s.", the(xname(uwep
)));
12077 /* it was simply too strong... arbitrarily lower the amount you'll get --Amy */
12080 while (yourmana
> 99) {
12085 while (manamultiply
> 0) {
12086 calchelpvar
= (yourmana
- (manamultiply
* 100));
12087 if (calchelpvar
< 1) goto manacalccomplete
;
12088 yourmana
-= rnd(calchelpvar
);
12093 if (yourmana
< 1) yourmana
= 1; /* fail safe, shouldn't happen */
12095 if (techlevX(T_CHARGE_SABER
) < 1) {
12096 pline("Your ability to charge the saber is beyond recall, and therefore nothing happens.");
12099 effectlevel
= rno(techlevX(T_CHARGE_SABER
));
12101 /* yes no return above, it's a bonus :) */
12102 uwep
->age
+= (yourmana
* (( (effectlevel
+ rnd(5 + effectlevel
) ) / rnd(10)) + rno(3)));
12103 if (uwep
->oartifact
== ART_KYLE_S_JACKPOT
) {
12104 uwep
->age
+= (yourmana
* (( (effectlevel
+ rnd(5 + effectlevel
) ) / rnd(10)) + rno(3)));
12105 if (!rn2(2)) uwep
->age
+= (yourmana
* (( (effectlevel
+ rnd(5 + effectlevel
) ) / rnd(10)) + rno(3)));
12107 /* improved results by Amy */
12118 int finaltechlevel
= (u
.ulevel
- tech_list
[tech
].t_lev
);
12119 if (StrongTechnicality
) {
12120 finaltechlevel
*= 4;
12121 finaltechlevel
/= 3;
12122 finaltechlevel
+= 10;
12123 } else if (Technicality
) {
12124 finaltechlevel
*= 4;
12125 finaltechlevel
/= 3;
12126 finaltechlevel
+= 3;
12128 if (uarmh
&& itemhasappearance(uarmh
, APP_TECHNICAL_HELMET
)) finaltechlevel
++;
12130 finaltechlevel
+= (boost_power_value() * 2);
12132 if (finaltechlevel
> 50) finaltechlevel
= 50; /* fail safe */
12133 return finaltechlevel
;
12136 /*WAC tinker code*/
12141 struct obj
*otmp
= uwep
;
12144 if (delay
) { /* not if (delay++), so at end delay == 0 */
12147 use_skill(P_TINKER
, 1); /* Tinker skill */
12149 /*WAC a bit of practice so even if you're interrupted
12150 you won't be wasting your time ;B*/
12151 return(1); /* still busy */
12157 You("finish your tinkering.");
12159 /* chance += PSKILL(P_TINKER); */
12160 if (rnl(10) < chance
) {
12161 upgrade_obj(otmp
, FALSE
);
12163 /* object downgrade - But for now, nothing :) */
12166 setuwep(otmp
, FALSE
, TRUE
);
12167 You("now hold %s!", doname(otmp
));
12171 /*WAC draw energy from surrounding objects */
12176 if (delay
) { /* not if (delay++), so at end delay == 0 */
12179 if(isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
12180 switch((&levl
[u
.ux
+ u
.dx
][u
.uy
+ u
.dy
])->typ
) {
12181 case ALTAR
: /* Divine power */
12182 powbonus
= (u
.uenmax
> 28 ? u
.uenmax
/ 4 : 7);
12184 case THRONE
: /* Regal == pseudo divine */
12185 powbonus
= (u
.uenmax
> 36 ? u
.uenmax
/ 6 : 6);
12188 powbonus
= (u
.uenmax
> 10 ? u
.uenmax
/ 2 : 4);
12190 case CLOUD
: /* Air */
12191 case TREE
: /* Earth */
12192 case LAVAPOOL
: /* Fire */
12193 case ICE
: /* Water - most ordered form */
12197 powbonus
= (u
.uenmax
> 40 ? u
.uenmax
/ 8 : 5);
12200 case MOAT
: /* Doesn't freeze */
12205 powbonus
= (u
.uenmax
> 40 ? u
.uenmax
/ 10 : 4);
12210 powbonus
= (u
.uenmax
> 20 ? u
.uenmax
/ 5 : 4);
12212 case POOL
: /* Can dry up */
12217 powbonus
= (u
.uenmax
> 36 ? u
.uenmax
/ 12 : 3);
12219 case STRAWMATTRESS
:
12222 powbonus
= (u
.uenmax
> 50 ? u
.uenmax
/ 20 : 2);
12228 powbonus
= (u
.uenmax
> 30 ? u
.uenmax
/ 15 : 2);
12233 powbonus
= (u
.uenmax
> 20 ? u
.uenmax
/ 10 : 2);
12235 case SINK
: /* Cleansing water */
12236 if (!rn2(3)) powbonus
= 2;
12238 case TOILET
: /* Water Power...but also waste! */
12243 else powbonus
= -2;
12257 if (u
.uen
> u
.uenmax
) {
12261 if (u
.uen
< 1) u
.uen
= 0;
12263 return(1); /* still busy */
12265 You("finish drawing energy from your surroundings.");
12270 *Enter_Blitz
= "Enter Blitz Command[. to end]: ";
12272 /* Keep commands that reference the same blitz together
12273 * Keep the BLITZ_START before the BLITZ_CHAIN before the BLITZ_END
12275 static const struct blitz_tab blitzes
[] = {
12276 {"LLDDR", 5, blitz_chi_strike
, T_CHI_STRIKE
, BLITZ_START
},
12277 {"LLDDRDR", 7, blitz_chi_strike
, T_CHI_STRIKE
, BLITZ_START
},
12278 {"RR", 2, blitz_dash
, T_DASH
, BLITZ_START
},
12279 {"LL", 2, blitz_dash
, T_DASH
, BLITZ_START
},
12280 {"UURRDDL", 7, blitz_e_fist
, T_E_FIST
, BLITZ_START
},
12281 {"URURRDDLDL", 10, blitz_e_fist
, T_E_FIST
, BLITZ_START
},
12282 {"LDL", 3, blitz_combo_strike
, T_COMBO_STRIKE
, BLITZ_CHAIN
},
12283 {"RUR", 3, blitz_combo_strike
, T_COMBO_STRIKE
, BLITZ_CHAIN
},
12284 {"LDDL", 4, blitz_draining_punch
, T_DRAINING_PUNCH
, BLITZ_CHAIN
},
12285 {"RUUR", 4, blitz_draining_punch
, T_DRAINING_PUNCH
, BLITZ_CHAIN
},
12286 {"LRL", 3, blitz_pummel
, T_PUMMEL
, BLITZ_CHAIN
},
12287 {"RLR", 3, blitz_pummel
, T_PUMMEL
, BLITZ_CHAIN
},
12288 {"DDDD", 4, blitz_g_slam
, T_G_SLAM
, BLITZ_END
},
12289 {"DUDUUDDD", 8, blitz_spirit_bomb
, T_SPIRIT_BOMB
, BLITZ_END
},
12290 {"", 0, (void *)0, 0, BLITZ_END
} /* Array terminator */
12293 #define MAX_BLITZ 50
12294 #define MIN_CHAIN 2
12295 #define MAX_CHAIN 5
12297 /* parse blitz input */
12301 int i
, j
, dx
, dy
, bdone
= 0, tech_no
;
12304 int blitz_chain
[MAX_CHAIN
], blitz_num
;
12306 tech_no
= (get_tech_no(T_BLITZ
));
12308 if (tech_no
== -1) {
12313 You("are too weak to attempt this! You need at least 10 points of mana!");
12314 if (flags
.moreforced
&& !MessagesSuppressed
) display_nhwindow(WIN_MESSAGE
, TRUE
); /* --More-- */
12320 if (!getdir((char *)0)) return(0);
12321 if (!u
.dx
&& !u
.dy
) {
12324 if (!isok(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
)) {
12333 for (i
= 0; i
< MAX_BLITZ
; i
++) {
12334 if (!getdir(Enter_Blitz
)) return(0); /* Get directional input */
12335 if (!u
.dx
&& !u
.dy
&& !u
.dz
) break;
12339 } else if (u
.dx
== 1) {
12346 } else if (u
.dy
== 1) {
12353 } else if (u
.dz
== 1) {
12363 /* Point of no return - You've entered and terminated a blitz, so... */
12367 /* You can't put two of the same blitz in a row */
12369 while(strncmp(bp
, ".", 1)) {
12371 for (j
= 0; blitzes
[j
].blitz_len
; j
++) {
12372 if (blitz_num
>= MAX_CHAIN
||
12373 blitz_num
>= (MIN_CHAIN
+ (techlevX(tech_no
) / 10)))
12374 break; /* Trying to chain too many blitz commands */
12375 else if (!strncmp(bp
, blitzes
[j
].blitz_cmd
, blitzes
[j
].blitz_len
)) {
12376 /* Trying to chain in a command you don't know yet */
12377 if (!tech_known(blitzes
[j
].blitz_tech
))
12380 /* Check if trying to chain two of the exact same
12381 * commands in a row
12383 if (j
== blitz_chain
[(blitz_num
- 1)])
12385 /* Trying to chain after chain finishing command */
12386 if (blitzes
[blitz_chain
[(blitz_num
- 1)]].blitz_type
12389 /* Trying to put a chain starter after starting
12391 * Note that it's OK to put two chain starters in a
12394 if ((blitzes
[j
].blitz_type
== BLITZ_START
) &&
12395 (blitzes
[blitz_chain
[(blitz_num
- 1)]].blitz_type
12399 bp
+= blitzes
[j
].blitz_len
;
12400 blitz_chain
[blitz_num
] = j
;
12411 for (i
= 0; i
< blitz_num
; i
++) {
12414 if (!( (*blitzes
[blitz_chain
[i
]].blitz_funct
)() )) break;
12427 menu_item
*selected
;
12430 tmpwin
= create_nhwindow(NHW_MENU
);
12431 start_menu(tmpwin
);
12432 any
.a_void
= 0; /* zero out all bits */
12434 sprintf(buf
, "%16s %10s %-17s", "[LU = Left Up]", "[U = Up]", "[RU = Right Up]");
12435 add_menu(tmpwin
, NO_GLYPH
, &any
, 0, 0, ATR_NONE
, buf
, MENU_UNSELECTED
);
12436 sprintf(buf
, "%16s %10s %-17s", "[L = Left]", "", "[R = Right]");
12437 add_menu(tmpwin
, NO_GLYPH
, &any
, 0, 0, ATR_NONE
, buf
, MENU_UNSELECTED
);
12438 sprintf(buf
, "%16s %10s %-17s", "[LD = Left Down]", "[D = Down]", "[RD = Right Down]");
12439 add_menu(tmpwin
, NO_GLYPH
, &any
, 0, 0, ATR_NONE
, buf
, MENU_UNSELECTED
);
12441 sprintf(buf
, "%-30s %10s %s", "Name", "Type", "Command");
12442 add_menu(tmpwin
, NO_GLYPH
, &any
, 0, 0, ATR_NONE
, buf
, MENU_UNSELECTED
);
12444 for (i
= 0; blitzes
[i
].blitz_len
; i
++) {
12445 if (tech_known(blitzes
[i
].blitz_tech
)) {
12446 sprintf(buf
, "%-30s %10s %s",
12447 (i
&& blitzes
[i
].blitz_tech
== blitzes
[(i
-1)].blitz_tech
?
12448 "" : tech_names
[blitzes
[i
].blitz_tech
]),
12449 (blitzes
[i
].blitz_type
== BLITZ_START
?
12451 (blitzes
[i
].blitz_type
== BLITZ_CHAIN
?
12453 (blitzes
[i
].blitz_type
== BLITZ_END
?
12454 "finisher" : "unknown"))),
12455 blitzes
[i
].blitz_cmd
);
12457 add_menu(tmpwin
, NO_GLYPH
, &any
,
12458 0, 0, ATR_NONE
, buf
, MENU_UNSELECTED
);
12461 end_menu(tmpwin
, "Currently known blitz manoeuvers");
12463 n
= select_menu(tmpwin
, PICK_NONE
, &selected
);
12464 destroy_nhwindow(tmpwin
);
12473 tech_no
= (get_tech_no(T_CHI_STRIKE
));
12475 if (tech_no
== -1) {
12480 You("are too weak to attempt this! You need at least one point of mana!");
12483 You_feel("energy surge through your hands!");
12484 techt_inuse(tech_no
) = techlevX(tech_no
) + 4;
12494 tech_no
= (get_tech_no(T_E_FIST
));
12496 if (tech_no
== -1) {
12500 str
= makeplural(body_part(HAND
));
12501 You("focus the powers of the elements into your %s.", str
);
12502 techt_inuse(tech_no
) = rnd((int) (techlevX(tech_no
)/3 + 1)) + d(1,4) + 2;
12507 blitz_combo_strike()
12509 struct monst
*mtmp
;
12511 if (tech_inuse(T_COMBO_STRIKE
)) {
12513 u
.comboactive
= FALSE
;
12514 stopsingletechnique(T_COMBO_STRIKE
);
12517 You("do a combo strike!");
12521 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
12524 pline("But there was no target!");
12527 if (!attack(mtmp
)) return (0);
12528 else u
.combostrike
+= 10;
12533 blitz_draining_punch()
12535 struct monst
*mtmp
;
12540 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
12542 You("strike nothing.");
12545 if (!attack(mtmp
)) return (0);
12547 if (!mtmp
) return(0);
12549 if (mtmp
&& !(DEADMONSTER(mtmp
)) && mtmp
->mhp
> 0 && !resists_drli(mtmp
) && !resist(mtmp
, WEAPON_CLASS
, 0, NOTELL
) ) {
12552 pline("%s suddenly seems weaker!", Monnam(mtmp
));
12553 mtmp
->mhpmax
-= xtmp
;
12555 if (xtmp
< mtmp
->mhp
) showdmg(xtmp
);
12557 if ((mtmp
->mhp
-= xtmp
) <= 0 || !mtmp
->m_lev
) {
12558 pline("%s dies!", Monnam(mtmp
));
12567 /* Assumes u.dx, u.dy already set up */
12571 int i
= 0, tech_no
;
12572 struct monst
*mtmp
;
12573 tech_no
= (get_tech_no(T_PUMMEL
));
12575 if (tech_no
== -1) {
12579 You("let loose a barrage of blows!");
12584 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
12587 You("strike nothing.");
12590 if (!attack(mtmp
)) return (0);
12592 /* Perform the extra attacks
12594 for (i
= 0; (i
< 4); i
++) {
12595 if (rn2(90) > (techlevX(tech_no
) + 30)) break;
12600 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
12602 if (!mtmp
) return (1);
12603 if (!attack(mtmp
)) return (1);
12609 /* Assumes u.dx, u.dy already set up */
12613 int tech_no
, tmp
, canhitmon
, objenchant
;
12614 struct monst
*mtmp
;
12615 struct trap
*chasm
;
12617 tech_no
= (get_tech_no(T_G_SLAM
));
12619 if (tech_no
== -1) {
12623 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
12625 You("strike nothing.");
12628 if (!attack(mtmp
)) return (0);
12630 /* Slam the monster into the ground */
12631 mtmp
= m_at(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
);
12632 if (!mtmp
|| u
.uswallow
) return(1);
12634 You("hurl %s downwards...", mon_nam(mtmp
));
12635 if (Is_airlevel(&u
.uz
) || Is_waterlevel(&u
.uz
)) return(1);
12637 if (need_four(mtmp
)) canhitmon
= 4;
12638 else if (need_three(mtmp
)) canhitmon
= 3;
12639 else if (need_two(mtmp
)) canhitmon
= 2;
12640 else if (need_one(mtmp
)) canhitmon
= 1;
12641 else canhitmon
= 0;
12642 if (uarmf
&& uarmf
->oartifact
== ART_KILLCAP
) canhitmon
= 0;
12645 if (hit_as_four(&youmonst
)) objenchant
= 4;
12646 else if (hit_as_three(&youmonst
)) objenchant
= 3;
12647 else if (hit_as_two(&youmonst
)) objenchant
= 2;
12648 else if (hit_as_one(&youmonst
)) objenchant
= 1;
12649 else if (need_four(&youmonst
)) objenchant
= 4;
12650 else if (need_three(&youmonst
)) objenchant
= 3;
12651 else if (need_two(&youmonst
)) objenchant
= 2;
12652 else if (need_one(&youmonst
)) objenchant
= 1;
12653 else objenchant
= 0;
12655 objenchant
= GushLevel
/ 4;
12657 tmp
= (5 + rnd(6) + (techlevX(tech_no
) / 5));
12659 chasm
= maketrap(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
, PIT
, 0, FALSE
);
12661 if (!is_flyer(mtmp
->data
) && (!mtmp
->egotype_flying
) && !is_clinger(mtmp
->data
))
12662 mtmp
->mtrapped
= 1;
12663 if (!chasm
->hiddentrap
) chasm
->tseen
= 1;
12664 levl
[u
.ux
+ u
.dx
][u
.uy
+ u
.dy
].doormask
= 0;
12665 pline("%s slams into the ground, creating a crater!", Monnam(mtmp
));
12669 mselftouch(mtmp
, "Falling, ", TRUE
);
12670 if (!DEADMONSTER(mtmp
)) {
12671 if (objenchant
< canhitmon
)
12672 pline("%s doesn't seem to be harmed.", Monnam(mtmp
));
12673 else if ((mtmp
->mhp
-= tmp
) <= 0) {
12674 if(!cansee(u
.ux
+ u
.dx
, u
.uy
+ u
.dy
))
12675 pline("It is destroyed!");
12679 ? x_monnam(mtmp
, ARTICLE_THE
, "poor",
12680 mtmp
->mnamelth
? SUPPRESS_SADDLE
: 0, FALSE
)
12690 /* Assumes u.dx, u.dy already set up */
12695 tech_no
= (get_tech_no(T_DASH
));
12697 if (tech_no
== -1) {
12701 if ((!Punished
|| carried(uball
)) && !u
.utrap
)
12702 You("dash forwards!");
12703 hurtle(u
.dx
, u
.dy
, 2, FALSE
);
12704 multi
= 0; /* No paralysis with dash */
12709 blitz_power_surge()
12713 tech_no
= (get_tech_no(T_POWER_SURGE
));
12715 if (tech_no
== -1) {
12719 /* what the heck??? --Amy */
12721 You("cannot tap into your full potential in this form.");
12724 You("tap into the full extent of your power!");
12725 num
= 50 + (2 * techlevX(tech_no
));
12726 techt_inuse(tech_no
) = num
+ 1;
12729 if (u
.uen
> u
.uenmax
) u
.uen
= u
.uenmax
;
12733 /* Assumes u.dx, u.dy already set up */
12735 blitz_spirit_bomb()
12738 int sx
= u
.ux
, sy
= u
.uy
, i
;
12740 tech_no
= (get_tech_no(T_SPIRIT_BOMB
));
12742 if (tech_no
== -1) {
12746 You("gather your energy...");
12749 pline("But it fizzles out because you have less than 10 points of mana.");
12753 /* the damage was way too low... no wonder players never use finishers as the last chained blitz move,
12754 * because pummel is all-powerful! Therefore I increased the damage --Amy */
12755 num
= 10 + (techlevX(tech_no
) * 3);
12756 num
= (u
.uen
< num
? u
.uen
: num
);
12760 for( i
= 0; i
< 2; i
++) {
12761 if (!isok(sx
,sy
) || !cansee(sx
,sy
) ||
12762 IS_STWALL(levl
[sx
][sy
].typ
) || u
.uswallow
)
12765 /* Display the center of the explosion */
12766 tmp_at(DISP_FLASH
, explosion_to_glyph(EXPL_MAGICAL
, S_explode5
));
12769 tmp_at(DISP_END
, 0);
12774 /* Magical Explosion */
12775 explode(sx
, sy
, 10, (d(3,6) + num
), WAND_CLASS
, EXPL_MAGICAL
);
12779 /* for bad effects: add d50000 turns of timeout to a random tech */
12783 int i
, thisone
, choicenumber
;
12788 for (i
= 0; i
< MAXTECH
; i
++) {
12790 if (tech_list
[i
].t_id
== NO_TECH
) break;
12792 if (!choicenumber
|| (!rn2(choicenumber
+ 1))) {
12799 if (choicenumber
> 0 && thisone
>= 0) {
12800 techtout(thisone
) += rnd(50000);
12801 pline("Your %s technique is put on a lengthy timeout!", techname(thisone
));
12807 techcapincrease(increaseamount
)
12808 int increaseamount
;
12810 int i
, thisone
, choicenumber
;
12815 for (i
= 0; i
< MAXTECH
; i
++) {
12817 if (tech_list
[i
].t_id
== NO_TECH
) break;
12819 if (!choicenumber
|| (!rn2(choicenumber
+ 1))) {
12826 /* make this effect actually matter --Amy */
12827 if (!rn2(2) && choicenumber
> 1) {
12828 increaseamount
*= (50 + choicenumber
);
12829 increaseamount
/= 50;
12831 increaseamount
*= rnd(5);
12833 if (choicenumber
> 0 && thisone
>= 0) {
12834 techtout(thisone
) += increaseamount
;
12835 pline("Your %s technique's timeout increases!", techname(thisone
));
12844 int i
, thisone
, choicenumber
, attempts
;
12851 for (i
= 0; i
< MAXTECH
; i
++) {
12853 if (tech_list
[i
].t_id
== NO_TECH
) break;
12855 if (!choicenumber
|| (!rn2(choicenumber
+ 1))) {
12862 if (choicenumber
> 0 && thisone
>= 0 && attempts
< 10000) {
12863 if (tech_list
[thisone
].t_lev
< 130) {
12864 tech_list
[thisone
].t_lev
+= 1;
12865 pline("Your %s technique's level is drained to %d!", techname(thisone
), techlev(thisone
));
12878 int i
, thisone
, choicenumber
, attempts
;
12885 for (i
= 0; i
< MAXTECH
; i
++) {
12887 if (tech_list
[i
].t_id
== NO_TECH
) break;
12889 if (!choicenumber
|| (!rn2(choicenumber
+ 1))) {
12896 if (choicenumber
> 0 && thisone
>= 0 && attempts
< 10000) {
12897 if (tech_list
[thisone
].t_lev
< 120) {
12898 tech_list
[thisone
].t_lev
= 130;
12899 pline("Your %s technique becomes permanently unusable!", techname(thisone
));
12902 goto techdrainnewS
;
12912 for (i
= 0; i
< MAXTECH
; i
++) {
12913 if (techid(i
) == T_RESTORE_LIFE_LEVELS
)
12914 tech_list
[i
].t_lev
= 130;
12919 /* drain all of the player's techniques by one level --Amy */
12924 for (i
= 0; i
< MAXTECH
; i
++) {
12926 if (tech_list
[i
].t_id
== NO_TECH
) break;
12928 if (tech_list
[i
].t_lev
< 130) {
12929 tech_list
[i
].t_lev
+= 1;
12939 int i
, thisone
, choicenumber
, attempts
;
12946 for (i
= 0; i
< MAXTECH
; i
++) {
12948 if (tech_list
[i
].t_id
== NO_TECH
) break;
12950 if (!choicenumber
|| (!rn2(choicenumber
+ 1))) {
12957 if (choicenumber
> 0 && thisone
>= 0 && attempts
< 10000) {
12958 if (tech_list
[thisone
].t_lev
> 0) {
12959 tech_list
[thisone
].t_lev
-= 1;
12960 pline("Your %s technique leveled up to level %d!", techname(thisone
), techlev(thisone
));
12970 techlevelspecific(technumber
)
12974 int i
, thisone
, choicenumber
, attempts
;
12980 boolean foundtech
= FALSE
;
12982 for (i
= 0; i
< MAXTECH
; i
++) {
12984 if (tech_list
[i
].t_id
== NO_TECH
) break;
12985 if (tech_list
[i
].t_id
== technumber
) {
12992 if (foundtech
&& thisone
>= 0) {
12993 if (tech_list
[thisone
].t_lev
> 0) {
12994 tech_list
[thisone
].t_lev
-= 1;
12995 pline("Your %s technique leveled up to level %d!", techname(thisone
), techlev(thisone
));
12997 pline("Your %s technique has reached the maximum level already.", techname(thisone
));
13003 /* player learns a random "regular" tech, i.e. one not taught by leveling up skills or some such --Amy */
13005 learnrandomregulartech()
13007 switch (rnd(190)) {
13012 learntech_or_leveltech(T_BERSERK
, FROMOUTSIDE
, 1);
13013 You("learn how to perform berserk!");
13018 learntech_or_leveltech(T_KIII
, FROMOUTSIDE
, 1);
13019 You("learn how to perform kiii!");
13024 learntech_or_leveltech(T_RESEARCH
, FROMOUTSIDE
, 1);
13025 You("learn how to perform research!");
13030 learntech_or_leveltech(T_SURGERY
, FROMOUTSIDE
, 1);
13031 You("learn how to perform surgery!");
13036 learntech_or_leveltech(T_REINFORCE
, FROMOUTSIDE
, 1);
13037 You("learn how to perform reinforce memory!");
13042 learntech_or_leveltech(T_FLURRY
, FROMOUTSIDE
, 1);
13043 You("learn how to perform missile flurry!");
13048 learntech_or_leveltech(T_PRACTICE
, FROMOUTSIDE
, 1);
13049 You("learn how to perform weapon practice!");
13054 learntech_or_leveltech(T_EVISCERATE
, FROMOUTSIDE
, 1);
13055 You("learn how to perform eviscerate!");
13060 learntech_or_leveltech(T_HEAL_HANDS
, FROMOUTSIDE
, 1);
13061 You("learn how to perform healing hands!");
13066 learntech_or_leveltech(T_CALM_STEED
, FROMOUTSIDE
, 1);
13067 You("learn how to perform calm steed!");
13072 learntech_or_leveltech(T_TURN_UNDEAD
, FROMOUTSIDE
, 1);
13073 You("learn how to perform turn undead!");
13078 learntech_or_leveltech(T_VANISH
, FROMOUTSIDE
, 1);
13079 You("learn how to perform vanish!");
13084 learntech_or_leveltech(T_CUTTHROAT
, FROMOUTSIDE
, 1);
13085 You("learn how to perform cutthroat!");
13089 learntech_or_leveltech(T_BLESSING
, FROMOUTSIDE
, 1);
13090 You("learn how to perform blessing!");
13095 learntech_or_leveltech(T_E_FIST
, FROMOUTSIDE
, 1);
13096 You("learn how to perform elemental fist!");
13101 learntech_or_leveltech(T_PRIMAL_ROAR
, FROMOUTSIDE
, 1);
13102 You("learn how to perform primal roar!");
13106 learntech_or_leveltech(T_LIQUID_LEAP
, FROMOUTSIDE
, 1);
13107 You("learn how to perform liquid leap!");
13112 learntech_or_leveltech(T_CRIT_STRIKE
, FROMOUTSIDE
, 1);
13113 You("learn how to perform critical strike!");
13118 learntech_or_leveltech(T_SIGIL_CONTROL
, FROMOUTSIDE
, 1);
13119 You("learn how to perform sigil of control!");
13124 learntech_or_leveltech(T_SIGIL_TEMPEST
, FROMOUTSIDE
, 1);
13125 You("learn how to perform sigil of tempest!");
13130 learntech_or_leveltech(T_SIGIL_DISCHARGE
, FROMOUTSIDE
, 1);
13131 You("learn how to perform sigil of discharge!");
13136 learntech_or_leveltech(T_RAISE_ZOMBIES
, FROMOUTSIDE
, 1);
13137 You("learn how to perform raise zombies!");
13140 learntech_or_leveltech(T_REVIVE
, FROMOUTSIDE
, 1);
13141 You("learn how to perform revivification!");
13146 learntech_or_leveltech(T_WARD_FIRE
, FROMOUTSIDE
, 1);
13147 You("learn how to perform ward against fire!");
13152 learntech_or_leveltech(T_WARD_COLD
, FROMOUTSIDE
, 1);
13153 You("learn how to perform ward against cold!");
13158 learntech_or_leveltech(T_WARD_ELEC
, FROMOUTSIDE
, 1);
13159 You("learn how to perform ward against electricity!");
13164 learntech_or_leveltech(T_TINKER
, FROMOUTSIDE
, 1);
13165 You("learn how to perform tinker!");
13170 learntech_or_leveltech(T_RAGE
, FROMOUTSIDE
, 1);
13171 You("learn how to perform rage eruption!");
13176 learntech_or_leveltech(T_BLINK
, FROMOUTSIDE
, 1);
13177 You("learn how to perform blink!");
13182 learntech_or_leveltech(T_CHI_STRIKE
, FROMOUTSIDE
, 1);
13183 You("learn how to perform chi strike!");
13188 learntech_or_leveltech(T_DRAW_ENERGY
, FROMOUTSIDE
, 1);
13189 You("learn how to perform draw energy!");
13194 learntech_or_leveltech(T_CHI_HEALING
, FROMOUTSIDE
, 1);
13195 You("learn how to perform chi healing!");
13200 learntech_or_leveltech(T_DAZZLE
, FROMOUTSIDE
, 1);
13201 You("learn how to perform dazzle!");
13206 learntech_or_leveltech(T_BLITZ
, FROMOUTSIDE
, 1);
13207 You("learn how to perform chained blitz!");
13212 learntech_or_leveltech(T_PUMMEL
, FROMOUTSIDE
, 1);
13213 You("learn how to perform pummel!");
13218 learntech_or_leveltech(T_G_SLAM
, FROMOUTSIDE
, 1);
13219 You("learn how to perform ground slam!");
13224 learntech_or_leveltech(T_DASH
, FROMOUTSIDE
, 1);
13225 You("learn how to perform air dash!");
13230 learntech_or_leveltech(T_POWER_SURGE
, FROMOUTSIDE
, 1);
13231 You("learn how to perform power surge!");
13236 learntech_or_leveltech(T_SPIRIT_BOMB
, FROMOUTSIDE
, 1);
13237 You("learn how to perform spirit bomb!");
13242 learntech_or_leveltech(T_DRAW_BLOOD
, FROMOUTSIDE
, 1);
13243 You("learn how to perform draw blood!");
13246 learntech_or_leveltech(T_WORLD_FALL
, FROMOUTSIDE
, 1);
13247 You("learn how to perform world fall!");
13252 learntech_or_leveltech(T_CREATE_AMMO
, FROMOUTSIDE
, 1);
13253 You("learn how to perform create ammo!");
13258 learntech_or_leveltech(T_POKE_BALL
, FROMOUTSIDE
, 1);
13259 You("learn how to perform poke ball!");
13264 learntech_or_leveltech(T_ATTIRE_CHARM
, FROMOUTSIDE
, 1);
13265 You("learn how to perform attire charm!");
13270 learntech_or_leveltech(T_SUMMON_TEAM_ANT
, FROMOUTSIDE
, 1);
13271 You("learn how to perform summon team ant!");
13276 learntech_or_leveltech(T_JEDI_JUMP
, FROMOUTSIDE
, 1);
13277 You("learn how to perform jedi jump!");
13282 learntech_or_leveltech(T_CHARGE_SABER
, FROMOUTSIDE
, 1);
13283 You("learn how to perform charge saber!");
13288 learntech_or_leveltech(T_TELEKINESIS
, FROMOUTSIDE
, 1);
13289 You("learn how to perform telekinesis!");
13292 learntech_or_leveltech(T_EGG_BOMB
, FROMOUTSIDE
, 1);
13293 You("learn how to perform egg bomb!");
13298 learntech_or_leveltech(T_BOOZE
, FROMOUTSIDE
, 1);
13299 You("learn how to perform booze!");
13304 learntech_or_leveltech(T_IRON_SKIN
, FROMOUTSIDE
, 1);
13305 You("learn how to perform iron skin!");
13308 learntech_or_leveltech(T_POLYFORM
, FROMOUTSIDE
, 1);
13309 You("learn how to perform polyform!");
13314 learntech_or_leveltech(T_CONCENTRATING
, FROMOUTSIDE
, 1);
13315 You("learn how to perform concentrating!");
13318 learntech_or_leveltech(T_SUMMON_PET
, FROMOUTSIDE
, 1);
13319 You("learn how to perform summon pet!");
13323 learntech_or_leveltech(T_DOUBLE_THROWNAGE
, FROMOUTSIDE
, 1);
13324 You("learn how to perform double thrownage!");
13329 learntech_or_leveltech(T_SHIELD_BASH
, FROMOUTSIDE
, 1);
13330 You("learn how to perform shield bash!");
13334 learntech_or_leveltech(T_RECHARGE
, FROMOUTSIDE
, 1);
13335 You("learn how to perform recharge!");
13340 learntech_or_leveltech(T_SPIRITUALITY_CHECK
, FROMOUTSIDE
, 1);
13341 You("learn how to perform spirituality check!");
13344 learntech_or_leveltech(T_EDDY_WIND
, FROMOUTSIDE
, 1);
13345 You("learn how to perform eddy wind!");
13348 learntech_or_leveltech(T_BLOOD_RITUAL
, FROMOUTSIDE
, 1);
13349 You("learn how to perform blood ritual!");
13352 learntech_or_leveltech(T_ENT_S_POTION
, FROMOUTSIDE
, 1);
13353 You("learn how to perform ent's potion!");
13357 learntech_or_leveltech(T_LUCKY_GAMBLE
, FROMOUTSIDE
, 1);
13358 You("learn how to perform lucky gamble!");
13361 learntech_or_leveltech(T_DECONTAMINATE
, FROMOUTSIDE
, 1);
13362 You("learn how to perform decontaminate!");
13365 learntech_or_leveltech(T_WONDERSPELL
, FROMOUTSIDE
, 1);
13366 You("learn how to perform wonderspell!");
13369 learntech_or_leveltech(T_RESET_TECHNIQUE
, FROMOUTSIDE
, 1);
13370 You("learn how to perform reset technique!");
13374 learntech_or_leveltech(T_DIAMOND_BARRIER
, FROMOUTSIDE
, 1);
13375 You("learn how to perform diamond barrier!");
13380 learntech_or_leveltech(T_ZAP_EM
, FROMOUTSIDE
, 1);
13381 You("learn how to perform zap em!");
13386 learntech_or_leveltech(T_CARD_TRICK
, FROMOUTSIDE
, 1);
13387 You("learn how to perform card trick!");
13390 learntech_or_leveltech(T_SKILLOMORPH
, FROMOUTSIDE
, 1);
13391 You("learn how to perform skillomorph!");
13396 learntech_or_leveltech(T_TERRAIN_CLEANUP
, FROMOUTSIDE
, 1);
13397 You("learn how to perform terrain cleanup!");
13402 learntech_or_leveltech(T_PREACHING
, FROMOUTSIDE
, 1);
13403 You("learn how to perform preaching!");
13408 learntech_or_leveltech(T_ON_THE_SAME_TEAM
, FROMOUTSIDE
, 1);
13409 You("learn how to perform on the same team!");
13412 learntech_or_leveltech(T_PERMAMORPH
, FROMOUTSIDE
, 1);
13413 You("learn how to perform permamorph!");
13416 learntech_or_leveltech(T_SPELL_SPAM
, FROMOUTSIDE
, 1);
13417 You("learn how to perform spell spam!");
13420 learntech_or_leveltech(T_ROCK_TO_POISON
, FROMOUTSIDE
, 1);
13421 You("learn how to perform rock-to-poison!");
13424 learntech_or_leveltech(T_HARDCORE_ALIENIZATION
, FROMOUTSIDE
, 1);
13425 You("learn how to perform hardcore alienization!");
13435 /* can you use a martial arts technique? normally you have to be bare-handed, but there may be exceptions --Amy */
13437 canuseunarmedtechs()
13439 /* dual-wielding prevents it entirely */
13440 if (u
.twoweap
&& uswapwep
) return FALSE
;
13442 /* godae musul is a special artifact that is suitable for martial arts moves */
13443 if (uwep
&& uwep
->oartifact
== ART_GODAE_MUSUL
) return TRUE
;
13444 /* and so is blammer of doom */
13445 if (uwep
&& uwep
->oartifact
== ART_BLAMMER_OF_DOOM
) return TRUE
;
13447 /* supermarket cashier can use martial arts moves with all tin openers because he knows "tin-fu" */
13448 if (uwep
&& Role_if(PM_SUPERMARKET_CASHIER
) && (uwep
->otyp
== LASER_TIN_OPENER
|| uwep
->otyp
== TIN_OPENER
|| uwep
->otyp
== BUDO_NO_SASU
|| uwep
->otyp
== JEONTU_GEOM
) ) return TRUE
;
13450 if (u
.martialstyle
== MARTIALSTYLE_HAIDONGGUMDO
&& uwep
&& uwep
->otyp
== JEONTU_GEOM
) return TRUE
;
13452 /* everyone else needs to be bare-handed */
13453 if (uwep
) return FALSE
;
13459 resettechniqueextra()
13463 pline("Choose a technique to reset. The prompt will loop until you actually make a choice.");
13465 for (numtechs
= 0; numtechs
< MAXTECH
&& techid(numtechs
) != NO_TECH
; numtechs
++) {
13466 if (techid(numtechs
) == T_RESET_TECHNIQUE
) continue;
13467 if (techtout(numtechs
) > 0) {
13468 pline("Your %s technique is currently on timeout.", techname(numtechs
));
13469 if (yn("Make this technique usable again?") == 'y') {
13470 techtout(numtechs
) = 0;
13471 pline("The timeout on your %s technique has been set to zero.", techname(numtechs
));
13472 goto resettechdone
;
13476 pline("If you don't feel like resetting a technique right now, you can choose to reset none at all.");
13477 if (yn("Do you want to reset no technique at all?") == 'y') {
13478 goto resettechdone
;
13480 goto resetretrying
;
13488 wiz_debug_cmd() /* in this case, allow controlled loss of techniques */
13490 int tech_no
, id
, n
= 0;
13492 if (gettech(&tech_no
)) {
13493 id
= techid(tech_no
);
13494 if (id
== NO_TECH
) {
13495 impossible("Unknown technique ([%d])?", tech_no
);
13498 mask
= tech_list
[tech_no
].t_intrinsic
;
13499 if (mask
& FROMOUTSIDE
) n
++;
13500 if (mask
& FROMRACE
) n
++;
13501 if (mask
& FROMEXPER
) n
++;
13503 impossible("No intrinsic masks set (0x%lX).", mask
);
13507 if (mask
& FROMOUTSIDE
&& !n
--) mask
= FROMOUTSIDE
;
13508 if (mask
& FROMRACE
&& !n
--) mask
= FROMRACE
;
13509 if (mask
& FROMEXPER
&& !n
--) mask
= FROMEXPER
;
13510 learntech(id
, mask
, -1);
13511 if (!tech_known(id
))
13512 You("lose the ability to perform %s.", tech_names
[id
]);