mirror of
https://github.com/tbamud/tbamud.git
synced 2026-03-03 19:40:16 +01:00
Added hitroll and damroll fields to DG, and made Triggers attached to players show on stat
This commit is contained in:
parent
bc95dfe20e
commit
19766c1be6
2 changed files with 17 additions and 4 deletions
|
|
@ -632,7 +632,14 @@ void find_replacement(void *go, struct script_data *sc, trig_data *trig,
|
|||
}
|
||||
break;
|
||||
case 'd':
|
||||
if (!str_cmp(field, "dex")) {
|
||||
if (!str_cmp(field, "damroll")) {
|
||||
if (subfield && *subfield) {
|
||||
int addition = atoi(subfield);
|
||||
GET_DAMROLL(c) = MAX(1, GET_DAMROLL(c) + addition);
|
||||
}
|
||||
snprintf(str, slen, "%d", GET_DAMROLL(c));
|
||||
}
|
||||
else if (!str_cmp(field, "dex")) {
|
||||
if (subfield && *subfield) {
|
||||
int addition = atoi(subfield);
|
||||
int max = (IS_NPC(c) || IS_ADMIN(c, ADMLVL_GRGOD)) ? 25 : 18;
|
||||
|
|
@ -731,6 +738,13 @@ void find_replacement(void *go, struct script_data *sc, trig_data *trig,
|
|||
}
|
||||
snprintf(str, slen, "%d", GET_HIT(c));
|
||||
}
|
||||
else if (!str_cmp(field, "hitroll")) {
|
||||
if (subfield && *subfield) {
|
||||
int addition = atoi(subfield);
|
||||
GET_HITROLL(c) = MAX(1, GET_HITROLL(c) + addition);
|
||||
}
|
||||
snprintf(str, slen, "%d", GET_HITROLL(c));
|
||||
}
|
||||
else if (!str_cmp(field, "hunger")) {
|
||||
if (subfield && *subfield) {
|
||||
int addition = atoi(subfield);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue