diff options
author | James Haley | 2010-10-05 01:50:11 +0000 |
---|---|---|
committer | James Haley | 2010-10-05 01:50:11 +0000 |
commit | af2746a42ce2fbce209d813c057449df32f71473 (patch) | |
tree | fd0755663004c450f8a551afa83d2778668f7881 /src | |
parent | aedeaac6b7f27f5400bcae7f391c457ebad4da59 (diff) | |
download | chocolate-doom-af2746a42ce2fbce209d813c057449df32f71473.tar.gz chocolate-doom-af2746a42ce2fbce209d813c057449df32f71473.tar.bz2 chocolate-doom-af2746a42ce2fbce209d813c057449df32f71473.zip |
Fix to LEGO cheat so it doesn't cause an invalid access to invsigil[-1]
in the status bar code, though it IS still possible to acquire and use
Sigil type -1, just as it is in vanilla, with some extreme side effects.
Subversion-branch: /branches/strife-branch
Subversion-revision: 2157
Diffstat (limited to 'src')
-rw-r--r-- | src/strife/st_stuff.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/strife/st_stuff.c b/src/strife/st_stuff.c index 57b099ef..bd1061a9 100644 --- a/src/strife/st_stuff.c +++ b/src/strife/st_stuff.c @@ -801,25 +801,28 @@ boolean ST_Responder(event_t* ev) P_GiveItemToPlayer(plyr, SPR_HELT, MT_TOKEN_TOUGHNESS); } - // villsa [STRIFE] + // villsa [STRIFE] if(cht_CheckCheat(&cheat_lego, ev->data2)) { plyr->st_update = true; if(plyr->weaponowned[wp_sigil]) { - plyr->weaponowned[wp_sigil] = true; if(++plyr->sigiltype > 4) { plyr->sigiltype = -1; - plyr->pendingweapon = wp_sigil; - plyr->weaponowned[wp_sigil] = true; + plyr->pendingweapon = wp_fist; + plyr->weaponowned[wp_sigil] = false; } } else { plyr->weaponowned[wp_sigil] = true; - plyr->sigiltype = -1; + plyr->sigiltype = 0; } + // BUG: This brings up a bad version of the Sigil (sigiltype -1) which + // causes some VERY interesting behavior, when you type LEGO for the + // sixth time. This shouldn't be done when taking it away, and yet it + // is here... verified with vanilla. plyr->pendingweapon = wp_sigil; } |