Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Carapace Boss - Code #2171

Merged
merged 18 commits into from
Apr 25, 2018
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Impact particle
  • Loading branch information
TideSofDarK committed Apr 23, 2018
commit 3a28ae9bf8ce82b0534e76a8250f352a985e2b63
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@

"precache"
{
"particle" "particles/units/heroes/hero_stormspirit/stormspirit_ball_lightning_sphere.vpcf"
"particle" "particles/units/heroes/hero_skeletonking/skeletonking_hellfireblast_explosion.vpcf"
"particle" "particles/units/heroes/hero_pugna/pugna_ward_sphereinner.vpcf"
"particle" "particles/units/heroes/hero_crystalmaiden/maiden_base_attack_trail_c.vpcf"
"particle" "particles/units/heroes/hero_crystalmaiden/maiden_base_attack_trail.vpcf"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ if IsServer() then
for k,v in pairs(self.crystals) do
if v.particle then
local angle = self.angle * k
ParticleManager:SetParticleControl(v.particle, 0, self:GetCrystalPosition(angle))
ParticleManager:SetParticleControl(v.particle, 4, self:GetCrystalPosition(angle))
end
end
Expand Down Expand Up @@ -233,19 +234,25 @@ if IsServer() then
}
ApplyDamage(damageTable)

local impact = ParticleManager:CreateParticle("particles/units/heroes/hero_rattletrap/rattletrap_rocket_flare_explosion_flash_c.vpcf", PATTACH_CUSTOMORIGIN, caster)
ParticleManager:SetParticleControl(impact, 3, self:GetCrystalPosition(self.angle * k))
-- ParticleManager:SetParticleControl(impact, 3, self:GetCrystalPosition(self.angle * k))
ParticleManager:ReleaseParticleIndex(impact)

caster:EmitSound("Hero_Crystal.CrystalNova.Yulsaria")

if self.crystals[k].taken >= self.crystals[k].threshold then
self.crystals[k].full = true
ParticleManager:DestroyParticle(self.crystals[k].particle, true)

self.crystals[k].particle = ParticleManager:CreateParticle("particles/units/heroes/hero_pugna/pugna_ward_sphereinner.vpcf", PATTACH_CUSTOMORIGIN, caster)
ParticleManager:SetParticleControl(self.crystals[k].particle, 3, self:GetCrystalPosition(self.angle * k))
self.crystals[k].particle = ParticleManager:CreateParticle("particles/units/heroes/hero_stormspirit/stormspirit_ball_lightning_sphere.vpcf", PATTACH_CUSTOMORIGIN, caster)

local distance = ability:GetSpecialValueFor("crystal_distance")
local range = ability:GetSpecialValueFor("range")
local width = range * (self.angle / distance)

-- TODO: Replace with proper indicator
Timers:CreateTimer(function ( )
Timers:CreateTimer(function ()
if not IsValidEntity(caster) or not caster:IsAlive() then return nil end

if not self.crystals[k].particle then return nil end
Expand Down Expand Up @@ -291,7 +298,7 @@ if IsServer() then
caster:GetAbsOrigin(),
direction,
range,
width,
width/2,
caster:GetTeamNumber(),
DOTA_UNIT_TARGET_TEAM_ENEMY,
DOTA_UNIT_TARGET_ALL,
Expand Down