summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2020-04-26 09:38:11 -0300
committerJesusaves <cpntb1@ymail.com>2020-04-26 09:38:11 -0300
commitb9162b20aad437fd3467879254aeccbe99dd0028 (patch)
tree8ea83a777c217cf72ebe0832a092792e9582cf2a
parentb73a753958168b32c2449b7b20439ae081e0126d (diff)
downloadserverdata-b9162b20aad437fd3467879254aeccbe99dd0028.tar.gz
serverdata-b9162b20aad437fd3467879254aeccbe99dd0028.tar.bz2
serverdata-b9162b20aad437fd3467879254aeccbe99dd0028.tar.xz
serverdata-b9162b20aad437fd3467879254aeccbe99dd0028.zip
Here we go, Micksha's latest and most favorite weapon: Scented Grenade.
Everyone will frown at you if you use it.
-rw-r--r--db/re/item_db.conf15
-rw-r--r--npc/items/grenade.txt17
2 files changed, 32 insertions, 0 deletions
diff --git a/db/re/item_db.conf b/db/re/item_db.conf
index a3b3ed0ae..c3458b69b 100644
--- a/db/re/item_db.conf
+++ b/db/re/item_db.conf
@@ -15966,6 +15966,21 @@ item_db: (
doevent "rand_mp_heal::OnUse";
">
},
+{
+ Id: 8019
+ AegisName: "ScentGrenade"
+ Name: "Scented Grenade"
+ Type: "IT_USABLE"
+ Buy: 700
+ Sell: 350
+ Weight: 40
+ Refine: false
+ Delay: 500
+ UseEffect: "FX_SMOKEBOMB"
+ Script: <"
+ callfunc "massprovoke", rand(3,9);
+ ">
+},
)
diff --git a/npc/items/grenade.txt b/npc/items/grenade.txt
index 40959ad94..226712691 100644
--- a/npc/items/grenade.txt
+++ b/npc/items/grenade.txt
@@ -65,3 +65,20 @@ function script areasc2 {
return;
}
+// massprovoke(range, {map, x, y}) - player only
+function script massprovoke {
+ getmapxy(.@m$, .@x, .@y, 0);
+ .@r=getarg(0, 3);
+ .@m$=getarg(1, .@m$);
+ .@x=getarg(2, .@x);
+ .@y=getarg(3, .@y);
+
+ .@c=getunits(BL_MOB, .@mbs, false, .@m$, .@x-.@r, .@y-.@r, .@x+.@r, .@y+.@r);
+ for (.@i = 0; .@i < .@c; .@i++) {
+ //sc_start .@s, .@d, 1, 10000, SCFLAG_NONE, .@mbs[.@i];
+ aggravate .@mbs[.@i];
+ specialeffect(FX_MAGIC, AREA, .@mbs[.@i]);
+ }
+ return;
+}
+