Changeset 752

Show
Ignore:
Timestamp:
03/07/08 18:28:55 (6 months ago)
Author:
GabeCunningham
Message:

Fix #459: Potions of Brawn etc are now described as "increasing (Strength) at the expense of a random attribute", and they will now never decrease and then increase the same stat. Partially fix #495: Added the fire_ball200 and cold_ball160 effects.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/src/effects.c

    r732 r752  
    413413                case EF_BRAWN: 
    414414                { 
    415                         int stat = rand_int(A_MAX); 
     415                        /* Pick a random stat to decrease other than strength */ 
     416                        int stat = rand_int(A_MAX-1) + 1; 
     417                         
    416418                        if (!do_dec_stat(stat, TRUE)) return FALSE; 
    417419                        if (do_inc_stat(A_STR)) *ident = TRUE; 
     
    421423                case EF_INTELLECT: 
    422424                { 
    423                         int stat = rand_int(A_MAX); 
     425                        /* Pick a random stat to decrease other than intelligence */ 
     426                        int stat = rand_int(A_MAX-1); 
     427                        if (stat >= A_INT) stat++; 
     428                         
    424429                        if (!do_dec_stat(stat, TRUE)) return FALSE; 
    425430                        if (do_inc_stat(A_INT)) *ident = TRUE; 
     
    429434                case EF_CONTEMPLATION: 
    430435                { 
    431                         int stat = rand_int(A_MAX); 
     436                        /* Pick a random stat to decrease other than wisdom */ 
     437                        int stat = rand_int(A_MAX-1); 
     438                        if (stat >= A_WIS) stat++; 
     439                         
    432440                        if (!do_dec_stat(stat, TRUE)) return FALSE; 
    433441                        if (do_inc_stat(A_WIS)) *ident = TRUE; 
     
    437445                case EF_TOUGHNESS: 
    438446                { 
    439                         int stat = rand_int(A_MAX); 
     447                        /* Pick a random stat to decrease other than constitution */ 
     448                        int stat = rand_int(A_MAX-1); 
     449                        if (stat >= A_CON) stat++; 
     450                         
    440451                        if (!do_dec_stat(stat, TRUE)) return FALSE; 
    441452                        if (do_inc_stat(A_CON)) *ident = TRUE; 
     
    445456                case EF_NIMBLENESS: 
    446457                { 
    447                         int stat = rand_int(A_MAX); 
     458                        /* Pick a random stat to decrease other than dexterity */ 
     459                        int stat = rand_int(A_MAX-1); 
     460                        if (stat >= A_DEX) stat++; 
     461                         
    448462                        if (!do_dec_stat(stat, TRUE)) return FALSE; 
    449463                        if (do_inc_stat(A_DEX)) *ident = TRUE; 
     
    453467                case EF_PLEASING: 
    454468                { 
    455                         int stat = rand_int(A_MAX); 
     469                        /* Pick a random stat to decrease other than charisma */ 
     470                        int stat = rand_int(A_MAX-1); 
     471                         
    456472                        if (!do_dec_stat(stat, TRUE)) return FALSE; 
    457473                        if (do_inc_stat(A_CHR)) *ident = TRUE; 
     
    11831199                } 
    11841200 
     1201                case EF_FIRE_BALL200: 
     1202                { 
     1203                        *ident = TRUE; 
     1204                        fire_ball(GF_FIRE, dir, 200, 3); 
     1205                        return TRUE; 
     1206                } 
     1207 
    11851208                case EF_COLD_BOLT: 
    11861209                { 
     
    12151238                        *ident = TRUE; 
    12161239                        fire_ball(GF_COLD, dir, 100, 2); 
     1240                        return TRUE; 
     1241                } 
     1242                 
     1243                case EF_COLD_BALL160: 
     1244                { 
     1245                        *ident = TRUE; 
     1246                        fire_ball(GF_COLD, dir, 160, 3); 
    12171247                        return TRUE; 
    12181248                } 
  • trunk/src/list-effects.h

    r732 r752  
    4545EFFECT(GAIN_CHR,       FALSE, "restores and increases your charisma") 
    4646EFFECT(GAIN_ALL,       FALSE, "restores and increases all your stats") 
    47 EFFECT(BRAWN,          FALSE, "raises your strength at the expense of your intelligence") 
    48 EFFECT(INTELLECT,      FALSE, "raises your intelligence at the expense of your constitution") 
    49 EFFECT(CONTEMPLATION,  FALSE, "raises your wisdom at the expense of your dexterity") 
    50 EFFECT(TOUGHNESS,      FALSE, "raises your constitution at the expense of your charisma") 
    51 EFFECT(NIMBLENESS,     FALSE, "raises your dexterity at the expense of your strength") 
    52 EFFECT(PLEASING,       FALSE, "raises your charisma at the expense of your wisdom") 
     47EFFECT(BRAWN,          FALSE, "raises your strength at the expense of a random attribute") 
     48EFFECT(INTELLECT,      FALSE, "raises your intelligence at the expense of a random attribute") 
     49EFFECT(CONTEMPLATION,  FALSE, "raises your wisdom at the expense of a random attribute") 
     50EFFECT(TOUGHNESS,      FALSE, "raises your constitution at the expense of a random attribute") 
     51EFFECT(NIMBLENESS,     FALSE, "raises your dexterity at the expense of a random attribute") 
     52EFFECT(PLEASING,       FALSE, "raises your charisma at the expense of a random attribute") 
    5353EFFECT(LOSE_STR,       FALSE, "reduces your strength with damage 5d5") 
    5454EFFECT(LOSE_INT,       FALSE, "reduces your intelligence with damage 5d5")