BuildingHelper icon indicating copy to clipboard operation
BuildingHelper copied to clipboard

BuildingHelper:UpgradeBuilding

Open SirWayN3 opened this issue 6 years ago • 1 comments

I just found an error and some suggestions regarding this function.

Error: function BuildingHelper:BlockPSO(size, location) -- if size == 0 then return end -- size can be nil, when no KV "PathingSize" has been set if size == 0 or size == nil then return end

Suggestions:

  1. Add Upgrade Duration to the Function
  2. Add Modifier Copy & Paste from the old Building to the new.
  3. Make new Building selected by Default
  4. Remove Building Invulnerable from newly spawned Building

SirWayN3 avatar Apr 24 '19 06:04 SirWayN3

To 3: directly after local new_building = BuildingHelper:PlaceBuilding( -- Remove invulnerability on npc_dota_building baseclass new_building:RemoveModifierByName("modifier_invulnerable")

SirWayN3 avatar Apr 24 '19 06:04 SirWayN3