Lines Matching defs:playerp
82 descrlocation(struct player *playerp, phbool shortflag)
95 if (playerp->p_specialtype == SC_VALAR)
98 if ((circle = CIRCLE(playerp->p_x, playerp->p_y)) >= 1000.0) {
99 if (MAX(fabs(playerp->p_x), fabs(playerp->p_y)) > D_BEYOND)
119 if (playerp->p_x == 0.0 && playerp->p_y == 0.0)
145 quadrant = ((playerp->p_x > 0.0) ? 1 : 0);
146 quadrant += ((playerp->p_y >= 0.0) ? 2 : 0);
156 label, playerp->p_x, playerp->p_y);
464 descrtype(struct player *playerp, phbool shortflag)
483 type = playerp->p_type;
485 switch (playerp->p_specialtype) {
487 type = playerp->p_type;
517 if (playerp->p_crowns > 0) {
526 findname(const char *name, struct player *playerp)
531 while (fread((char *) playerp, SZ_PLAYERSTRUCT, 1, Playersfp) == 1) {
532 if (strcmp(playerp->p_name, name) == 0) {
533 if (playerp->p_status != S_NOTUSED || Wizard)
566 freerecord(struct player *playerp, long loc)
568 playerp->p_name[0] = CH_MARKDELETE;
569 playerp->p_status = S_NOTUSED;
570 writerecord(playerp, loc);
694 writerecord(struct player *playerp, long place)
697 fwrite((char *) playerp, SZ_PLAYERSTRUCT, 1, Playersfp);
772 readrecord(struct player *playerp, long loc)
775 fread((char *) playerp, SZ_PLAYERSTRUCT, 1, Playersfp);
870 initplayer(struct player *playerp)
872 playerp->p_experience =
873 playerp->p_level =
874 playerp->p_strength =
875 playerp->p_sword =
876 playerp->p_might =
877 playerp->p_energy =
878 playerp->p_maxenergy =
879 playerp->p_shield =
880 playerp->p_quickness =
881 playerp->p_quksilver =
882 playerp->p_speed =
883 playerp->p_magiclvl =
884 playerp->p_mana =
885 playerp->p_brains =
886 playerp->p_poison =
887 playerp->p_gems =
888 playerp->p_sin =
889 playerp->p_1scratch =
890 playerp->p_2scratch = 0.0;
892 playerp->p_gold = ROLL(50.0, 75.0) + 0.1; /* give some gold */
894 playerp->p_x = ROLL(-125.0, 251.0);
895 playerp->p_y = ROLL(-125.0, 251.0); /* give random x, y */
898 playerp->p_ring.ring_type = R_NONE;
899 playerp->p_ring.ring_duration = 0;
900 playerp->p_ring.ring_inuse = FALSE;
902 playerp->p_age = 0L;
904 playerp->p_degenerated = 1; /* don't degenerate initially */
906 playerp->p_type = C_FIGHTER; /* default */
907 playerp->p_specialtype = SC_NONE;
908 playerp->p_lives =
909 playerp->p_crowns =
910 playerp->p_charms =
911 playerp->p_amulets =
912 playerp->p_holywater =
913 playerp->p_lastused = 0;
914 playerp->p_status = S_NOTUSED;
915 playerp->p_tampered = T_OFF;
916 playerp->p_istat = I_OFF;
918 playerp->p_palantir =
919 playerp->p_blessing =
920 playerp->p_virgin =
921 playerp->p_blindness = FALSE;
923 playerp->p_name[0] =
924 playerp->p_password[0] =
925 playerp->p_login[0] = '\0';
976 descrstatus(struct player *playerp)
978 switch (playerp->p_status) {
980 if (playerp->p_energy < 0.2 * (playerp->p_maxenergy + playerp->p_shield))
983 if (playerp->p_blindness)