daily pastebin goal
41%
SHARE
TWEET

Untitled

a guest Jan 29th, 2018 69 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. newEntity{ base = "BASE_GREATSWORD",
  2.     power_source = {technique=true, arcane=true}, define_as = "DETHBLYD",
  3.     name = "Dethblyd", unique=true, image = "object/artifact/dethblyd.png",
  4.     moddable_tile = "special/%s_dethblyd", moddable_tile_big = true,
  5.     unided_name = "pitch black sword", color=colors.BLACK,
  6.     desc = [[Grushgore the Destroyer was as famous for his incredible brutality as he was for his childlike intelligence. He wasn't known for his subtlety of naming, but there's no denying the power of his massive sword.]],
  7.     require = { stat = { str=35 }, },
  8.     level_range = {40, 50},
  9.     rarity = 240,
  10.     cost = 280,
  11.     material_level = 5,
  12.     sentient=true,
  13.     stacks=0,
  14.     combat = {
  15.         dam = 70,
  16.         apr = 18,
  17.         physcrit = 20,
  18.         dammod = {str=1.3, mag = 0.1},
  19.         lifesteal = 5,
  20.         special_on_hit = {desc="Increases all damage dealt, and reduces all damage taken, by 1%, stacking up to 10 times. Resets after 10 turns without attacking.", on_kill=1, fct=function(combat, who, target)
  21.             local o, item, inven_id = who:findInAllInventoriesBy("define_as", "DETHBLYD")
  22.             if not o or not who:getInven(inven_id).worn then return end
  23.             o.stacks = math.min(o.stacks + 1, 10)
  24.             who:onTakeoff(o, inven_id, true)
  25.             o.wielder.inc_damage.all = o.stacks
  26.             o.wielder.resists.all = o.stacks
  27.             who:onWear(o, inven_id, true)
  28.         end},
  29.     },
  30.     wielder = {
  31.         inc_stats = { [Stats.STAT_STR] = 10, [Stats.STAT_MAG] = 8, [Stats.STAT_CON] = 5},
  32.         talents_types_mastery = {
  33.             ["corruption/brutality"] = 0.2,
  34.             ["corruption/wrath"] = 0.2,
  35.             ["corruption/torture"] = 0.1,
  36.         },
  37.         inc_damage={},
  38.         resists={},
  39.         talent_cd_reduction= {
  40.             [Talents.T_DRAINING_ASSAULT] = 1,
  41.             [Talents.T_ABDUCTION] = 1,
  42.             [Talents.T_DETONATING_CHARGE] = 1,
  43.         },
  44.     },
  45.     act = function(self)
  46.         self:useEnergy()
  47.         self:regenPower()
  48.         if not self.worn_by then return end
  49.         if game.level and not game.level:hasEntity(self.worn_by) and not self.worn_by.player then self.worn_by=nil return end
  50.         if self.worn_by:attr("dead") then return end
  51.         local who = self.worn_by
  52.         local o, item, inven_id = who:findInAllInventoriesBy("define_as", "DETHBLYD")
  53.         if self.stacks > 0 and self.power == self.max_power then
  54.             who:onTakeoff(self, inven_id, true)
  55.             self.stacks=0
  56.             self.wielder.inc_damage={}
  57.             self.wielder.resists={}
  58.             who:onWear(self, inven_id, true)
  59.             self.power=10
  60.         end
  61.     end,
  62.     max_power = 10, power_regen = 1,
  63.     use_power = { name = "", power = 10, hidden = true, use = function(self, who) return end},
  64.     on_wear = function(self, who)
  65.         self.worn_by = who
  66.     end,
  67.     on_takeoff = function(self, who)
  68.         self.worn_by = nil
  69.     end,
  70. }
RAW Paste Data
Pastebin PRO WINTER Special!
Get 40% OFF Pastebin PRO accounts!
Top