mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-11 21:01:29 +00:00
Attempting manual merge for Nature's Bounty
This commit is contained in:
parent
b2d5ad6904
commit
88b9f96b91
@ -1,5 +1,8 @@
|
||||
EQEMu Changelog (Started on Sept 24, 2003 15:50)
|
||||
-------------------------------------------------------
|
||||
== 04/04/2013 ==
|
||||
demonstar55: Implemented SE_ForageAdditionalItems as a bonus
|
||||
required SQL: 2013_04_04_NaturesBounty.sql
|
||||
|
||||
== 04/03/2013 ==
|
||||
demonstar55: Overloaded Mob::Say_StringID with the option to provide a message type
|
||||
|
||||
@ -457,7 +457,7 @@ typedef enum {
|
||||
#define SE_ReduceReuseTimer 310 // implemented
|
||||
#define SE_CombatSkills 311 // implemented
|
||||
#define SE_Sanctuary 312 // *not implemented
|
||||
#define SE_ForageAdditionalItems 313 // *not implemented[AA] - chance to forage additional items
|
||||
#define SE_ForageAdditionalItems 313 // implemented[AA] - chance to forage additional items
|
||||
#define SE_Invisibility2 314 // implemented - fixed duration invisible
|
||||
#define SE_InvisVsUndead2 315 // implemented - fixed duration ITU
|
||||
//#define SE_Unknown316 316 // not used
|
||||
|
||||
12
utils/sql/git/required/2013_04_04_NaturesBounty.sql
Normal file
12
utils/sql/git/required/2013_04_04_NaturesBounty.sql
Normal file
@ -0,0 +1,12 @@
|
||||
-- Nature's Bounty
|
||||
INSERT INTO `altadv_vars` (`skill_id`, `name`, `cost`, `max_level`, `hotkey_sid`, `hotkey_sid2`, `title_sid`, `desc_sid`, `type`, `spellid`, `prereq_skill`, `prereq_minpoints`, `spell_type`, `spell_refresh`, `classes`, `berserker`, `class_type`, `cost_inc`, `aa_expansion`, `special_category`, `sof_type`, `sof_cost_inc`, `sof_max_level`, `sof_next_skill`, `clientver`, `account_time_required`, `sof_current_level`, `sof_next_id`, `level_inc`) VALUES ('1230', 'Nature''s Bounty', '1', '3', '4294967295', '4294967295', '1230', '1230', '7', '0', '0', '0', '0', '0', '80', '0', '51', '1', '8', '4294967295', '3', '0', '6', '1230', '1', '0', '0', '5000', '2');
|
||||
INSERT INTO `aa_effects` (`id`, `aaid`, `slot`, `effectid`, `base1`, `base2`) VALUES ('2368', '1230', '1', '313', '15', '0');
|
||||
INSERT INTO `aa_effects` (`id`, `aaid`, `slot`, `effectid`, `base1`, `base2`) VALUES ('2369', '1231', '1', '313', '20', '0');
|
||||
INSERT INTO `aa_effects` (`id`, `aaid`, `slot`, `effectid`, `base1`, `base2`) VALUES ('2370', '1232', '1', '313', '25', '0');
|
||||
|
||||
-- Survivalist
|
||||
INSERT INTO `altadv_vars` (`skill_id`, `name`, `cost`, `max_level`, `hotkey_sid`, `hotkey_sid2`, `title_sid`, `desc_sid`, `type`, `spellid`, `prereq_skill`, `prereq_minpoints`, `spell_type`, `spell_refresh`, `classes`, `berserker`, `class_type`, `cost_inc`, `aa_expansion`, `special_category`, `sof_type`, `sof_cost_inc`, `sof_max_level`, `sof_next_skill`, `clientver`, `account_time_required`, `sof_current_level`, `sof_next_id`, `level_inc`) VALUES ('5000', 'Survivalist', '2', '3', '4294967295', '4294967295', '5000', '5000', '7', '4294967295', '1230', '3', '0', '0', '80', '0', '71', '0', '12', '4294967295', '3', '0', '6', '1230', '1', '0', '3', '0', '2');
|
||||
INSERT INTO `aa_effects` (`id`, `aaid`, `slot`, `effectid`, `base1`, `base2`) VALUES ('2371', '5000', '1', '313', '50', '0');
|
||||
INSERT INTO `aa_effects` (`id`, `aaid`, `slot`, `effectid`, `base1`, `base2`) VALUES ('2372', '5001', '1', '313', '75', '0');
|
||||
INSERT INTO `aa_effects` (`id`, `aaid`, `slot`, `effectid`, `base1`, `base2`) VALUES ('2373', '5002', '1', '313', '100', '0');
|
||||
|
||||
@ -238,6 +238,7 @@
|
||||
#define DISCIPLINE_REUSE_MSG2 5808 //You can use the ability %1 again in %2 minute(s) %3 seconds.
|
||||
#define FAILED_TAUNT 5811 //You have failed to taunt your target.
|
||||
#define AA_NO_TARGET 5825 //You must first select a target for this ability!
|
||||
#define FORAGE_MASTERY 6012 //Your forage mastery has enabled you to find something else!
|
||||
#define GUILD_BANK_CANNOT_DEPOSIT 6097 // Cannot deposit this item. Containers must be empty, and only one of each LORE and no NO TRADE or TEMPORARY items may be deposited.
|
||||
#define GUILD_BANK_FULL 6098 // There is no more room in the Guild Bank.
|
||||
#define GUILD_BANK_TRANSFERRED 6100 // '%1' transferred to Guild Bank from Deposits.
|
||||
|
||||
@ -835,6 +835,9 @@ void Client::ApplyAABonuses(uint32 aaid, uint32 slots, StatBonuses* newbon)
|
||||
case SE_ConsumeProjectile:
|
||||
newbon->ConsumeProjectile += base1;
|
||||
break;
|
||||
case SE_ForageAdditionalItems:
|
||||
newbon->ForageAdditionalItems += base1;
|
||||
break;
|
||||
case SE_ArcheryDamageModifier:
|
||||
newbon->ArcheryDamageModifier += base1;
|
||||
break;
|
||||
@ -2192,6 +2195,10 @@ void Mob::ApplySpellsBonuses(uint16 spell_id, uint8 casterlevel, StatBonuses* ne
|
||||
newbon->ConsumeProjectile += effect_value;
|
||||
break;
|
||||
|
||||
case SE_ForageAdditionalItems:
|
||||
newbon->ForageAdditionalItems += effect_value;
|
||||
break;
|
||||
|
||||
case SE_ArcheryDamageModifier:
|
||||
newbon->ArcheryDamageModifier += effect_value;
|
||||
break;
|
||||
@ -3331,6 +3338,12 @@ void Mob::NegateSpellsBonuses(uint16 spell_id)
|
||||
itembonuses.ConsumeProjectile = effect_value;
|
||||
break;
|
||||
|
||||
case SE_ForageAdditionalItems:
|
||||
spellbonuses.ForageAdditionalItems = effect_value;
|
||||
aabonuses.ForageAdditionalItems = effect_value;
|
||||
itembonuses.ForageAdditionalItems = effect_value;
|
||||
break;
|
||||
|
||||
case SE_ArcheryDamageModifier:
|
||||
spellbonuses.ArcheryDamageModifier = effect_value;
|
||||
aabonuses.ArcheryDamageModifier = effect_value;
|
||||
@ -3473,4 +3486,4 @@ void Mob::NegateSpellsBonuses(uint16 spell_id)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -810,7 +810,7 @@ public:
|
||||
void LogSQL(const char *fmt, ...);
|
||||
bool CanFish();
|
||||
void GoFish();
|
||||
void ForageItem();
|
||||
void ForageItem(bool guarantee = false);
|
||||
//Calculate vendor price modifier based on CHA: (reverse==selling)
|
||||
float CalcPriceMod(Mob* other = 0, bool reverse = false);
|
||||
void ResetTrade();
|
||||
|
||||
@ -345,6 +345,7 @@ struct StatBonuses {
|
||||
bool FrontalBackstabMinDmg; // Allow frontal backstabs for min damage
|
||||
uint8 FrontalBackstabChance; // Chance to backstab from the front for full damage
|
||||
uint8 ConsumeProjectile; // Chance to not consume arrow.
|
||||
uint8 ForageAdditionalItems; // Chance to forage another item.
|
||||
uint16 ArcheryDamageModifier; // Increase Archery Damage by percent
|
||||
bool SecondaryDmgInc; // Allow off hand weapon to recieve damage bonus.
|
||||
uint16 GiveDoubleAttack; // Allow classes to double attack with a specified chance.
|
||||
|
||||
@ -400,7 +400,7 @@ void Client::GoFish()
|
||||
}
|
||||
}
|
||||
|
||||
void Client::ForageItem() {
|
||||
void Client::ForageItem(bool guarantee) {
|
||||
|
||||
int skill_level = GetSkill(FORAGE);
|
||||
|
||||
@ -417,7 +417,7 @@ void Client::ForageItem() {
|
||||
};
|
||||
|
||||
// these may need to be fine tuned, I am just guessing here
|
||||
if (MakeRandomInt(0,199) < skill_level) {
|
||||
if (guarantee || MakeRandomInt(0,199) < skill_level) {
|
||||
uint32 foragedfood = 0;
|
||||
uint32 stringid = FORAGE_NOEAT;
|
||||
|
||||
@ -476,6 +476,12 @@ void Client::ForageItem() {
|
||||
}
|
||||
|
||||
parse->EventPlayer(EVENT_FORAGE_SUCCESS, this, "", inst != NULL ? inst->GetItem()->ID : 0);
|
||||
|
||||
int ChanceSecondForage = aabonuses.ForageAdditionalItems + itembonuses.ForageAdditionalItems + spellbonuses.ForageAdditionalItems;
|
||||
if(!guarantee && MakeRandomInt(0,99) < ChanceSecondForage) {
|
||||
this->Message_StringID(MT_Skills, FORAGE_MASTERY);
|
||||
this->ForageItem(true);
|
||||
}
|
||||
|
||||
} else {
|
||||
Message_StringID(MT_Skills, FORAGE_FAILED);
|
||||
|
||||
@ -2715,6 +2715,7 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial)
|
||||
case SE_SecondaryDmgInc:
|
||||
case SE_ArcheryDamageModifier:
|
||||
case SE_ConsumeProjectile:
|
||||
case SE_ForageAdditionalItems:
|
||||
case SE_FrontalBackstabChance:
|
||||
case SE_FrontalBackstabMinDmg:
|
||||
case SE_TripleBackstab:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user