summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2019-07-25 22:06:55 -0300
committerJesusaves <cpntb1@ymail.com>2019-07-25 22:06:55 -0300
commite8453063f688ab75f6cd31a4f8d8b63aaebb8208 (patch)
treedbd81f374b054448cad38027205106139ecf7bf0
parent7c53677b79dbc4d79f9964475c22193471c54b47 (diff)
downloadserverdata-e8453063f688ab75f6cd31a4f8d8b63aaebb8208.tar.gz
serverdata-e8453063f688ab75f6cd31a4f8d8b63aaebb8208.tar.bz2
serverdata-e8453063f688ab75f6cd31a4f8d8b63aaebb8208.tar.xz
serverdata-e8453063f688ab75f6cd31a4f8d8b63aaebb8208.zip
Raise Alcohol EXPUP values and expire them on death.
Beer: +5% EXP, Wine: +12% EXP. All values can go up to double with players, capped to the number of players on a 10x10 square from you.
-rw-r--r--db/re/item_db.conf4
-rw-r--r--npc/items/alcohol.txt20
2 files changed, 12 insertions, 12 deletions
diff --git a/db/re/item_db.conf b/db/re/item_db.conf
index f3aacf0c3..b20e20f07 100644
--- a/db/re/item_db.conf
+++ b/db/re/item_db.conf
@@ -766,7 +766,7 @@ item_db: (
Delay: 500
UseEffect: "EFFECT_HEAL"
Script: <"
- @taste = 8;
+ @taste = 12;
@Alcohol = 16;
doevent "alcohol_sc::OnUse";
">
@@ -941,7 +941,7 @@ item_db: (
@type = 1;
@rarity=4;
doevent "rand_sc_heal::OnUse";
- @taste = 3;
+ @taste = 5;
@Alcohol = 7;
doevent "alcohol_sc::OnUse";
">
diff --git a/npc/items/alcohol.txt b/npc/items/alcohol.txt
index 4f132fd52..81c6a6bd0 100644
--- a/npc/items/alcohol.txt
+++ b/npc/items/alcohol.txt
@@ -49,27 +49,27 @@ OnUse:
// Default value is 1 minute per alcohol point - you'll be somber after at most two hours.
// Taste is affected by users near you.
- // Each user raises exp bonus in 1%, capped to twice the beverage taste
+ // Each user raises exp bonus in 1%, capped to the beverage taste
// If you are with many people, drink a better beverage! ;-)
getmapxy(.@m$, .@x, .@y, 0);
.@bonus=getareausers(.@m$, .@x-10, .@y-10, .@x+10, .@y+10)-1;
- @taste+=min(@taste*2, .@bonus);
+ @taste+=min(@taste, .@bonus);
// Alcohol EXP Bonus - ponderate average, so having more VIT doesn't means
// more experience - only more time (be careful when mixing alcohol!)
- .@v=remaining_bonus(SC_CASH_PLUSEXP, true);
- .@t=remaining_bonus(SC_CASH_PLUSEXP, false)/1000;
+ .@v=remaining_bonus(SC_OVERLAPEXPUP, true);
+ .@t=remaining_bonus(SC_OVERLAPEXPUP, false)/1000;
if (.@t) .@val1 = ponderate_avg(@taste, @Alcohol, .@v, .@t);
else .@val1 = @taste;
// Put the delay in ms.
- .@delay = remaining_bonus(SC_CASH_PLUSEXP, false);
+ .@delay = remaining_bonus(SC_OVERLAPEXPUP, false);
.@delay = .@t + @Alcohol*.@deltatime;
// Reset EXP Bonus based on the new cumulative delay and average exp bonus
- sc_end SC_CASH_PLUSEXP;
- sc_start SC_CASH_PLUSEXP, .@delay, .@val1;
+ sc_end SC_OVERLAPEXPUP;
+ sc_start SC_OVERLAPEXPUP, .@delay, .@val1;
// Recalculate Alcohol Threshold and time
ALC_THRESHOLD+=@Alcohol;
@@ -78,11 +78,11 @@ OnUse:
ALC_DELAYTIME+=@Alcohol*.@deltatime;
// Debug comment if you need to check stuff
- //debugmes "%d %d | %d %d | f t ", remaining_bonus(SC_CASH_PLUSEXP, false), remaining_bonus(SC_CASH_PLUSEXP, true), remaining_bonus(SC_ATTHASTE_INFINITY, false), remaining_bonus(SC_ATTHASTE_INFINITY, true);
+ //debugmes "%d %d | %d %d | f t ", remaining_bonus(SC_OVERLAPEXPUP, false), remaining_bonus(SC_OVERLAPEXPUP, true), remaining_bonus(SC_ATTHASTE_INFINITY, false), remaining_bonus(SC_ATTHASTE_INFINITY, true);
// For debuff I'll use inc_sc_bonus utilities (exp gain = atk speed loss)
- @min=-(remaining_bonus(SC_CASH_PLUSEXP, true)*2);
- @max=-(remaining_bonus(SC_CASH_PLUSEXP, true)*2);
+ @min=-(remaining_bonus(SC_OVERLAPEXPUP, true)*2);
+ @max=-(remaining_bonus(SC_OVERLAPEXPUP, true)*2);
@type=SC_ATTHASTE_INFINITY;
@delay=@Alcohol*(.@deltatime/1000);
doevent "inc_sc_bonus::OnUse";