mirror of
https://github.com/lifestorm/wnsrc.git
synced 2025-12-17 05:43:46 +03:00
Upload
This commit is contained in:
33
addons/pillpack/lua/effects/rappel_line.lua
Normal file
33
addons/pillpack/lua/effects/rappel_line.lua
Normal file
@@ -0,0 +1,33 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
function EFFECT:Init(effectdata)
|
||||
self.endPoint = effectdata:GetOrigin()
|
||||
local ent = effectdata:GetEntity()
|
||||
self.ent = ent:GetPuppet()
|
||||
self.ply = ent:GetPillUser()
|
||||
end
|
||||
|
||||
function EFFECT:Think()
|
||||
if not IsValid(self.ent) then return false end
|
||||
self:SetPos(self.ent:GetAttachment(self.ent:LookupAttachment("zipline")).Pos)
|
||||
self:SetRenderBoundsWS(self:GetPos(), self.endPoint)
|
||||
|
||||
return not self.ply:OnGround()
|
||||
end
|
||||
|
||||
local ropeMat = Material("cable/cable2")
|
||||
|
||||
function EFFECT:Render()
|
||||
--print("p")
|
||||
local color = Color(10, 10, 10)
|
||||
render.SetMaterial(ropeMat)
|
||||
render.DrawBeam(self:GetPos(), self.endPoint, 2, 0, 0, color)
|
||||
end
|
||||
63
addons/pillpack/lua/effects/warp_cannon.lua
Normal file
63
addons/pillpack/lua/effects/warp_cannon.lua
Normal file
@@ -0,0 +1,63 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
--Most of the credit for this goes to the people who made/helped with the strider cannon SWEP:
|
||||
-- http://www.garrysmod.org/downloads/?a=view&id=31329
|
||||
local flashMat = Material("Effects/blueblackflash")
|
||||
local pinchMat = Material("Effects/strider_pinch_dudv")
|
||||
local beamMat = Material("Effects/blueblacklargebeam")
|
||||
|
||||
function EFFECT:Init(effectdata)
|
||||
self.ent = effectdata:GetEntity()
|
||||
self.hitPos = effectdata:GetOrigin()
|
||||
self.startTime = CurTime()
|
||||
self.cycle = 0
|
||||
end
|
||||
|
||||
function EFFECT:Think()
|
||||
if not IsValid(self.ent) then return false end
|
||||
self:SetPos(self.ent:GetAttachment(self.ent:GetModel() == "models/combine_strider.mdl" and self.ent:LookupAttachment("BigGun") or self.ent:LookupAttachment("bellygun")).Pos)
|
||||
self:SetRenderBoundsWS(self:GetPos(), self.hitPos)
|
||||
if CurTime() - self.startTime > 2.4 then return false end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
function EFFECT:Render()
|
||||
local cycleF = (CurTime() - self.startTime) / 1.2
|
||||
--flash
|
||||
render.SetMaterial(flashMat)
|
||||
|
||||
if cycleF < .5 then
|
||||
render.DrawSprite(self:GetPos(), cycleF * 100, cycleF * 100, Color(0, 0, 0, 255))
|
||||
elseif cycleF < 1 then
|
||||
render.DrawSprite(self:GetPos(), cycleF * 100, cycleF * 100, Color(cycleF * 255, cycleF * 255, cycleF * 255, 255))
|
||||
else
|
||||
render.DrawSprite(self:GetPos(), 50, 50, Color(255, 255, 255, 255))
|
||||
end
|
||||
|
||||
if cycleF < 1 then
|
||||
--pinch
|
||||
pinchMat:SetFloat("$refractamount", cycleF)
|
||||
render.SetMaterial(pinchMat)
|
||||
render.UpdateRefractTexture()
|
||||
render.DrawSprite(self:GetPos(), cycleF * 150, cycleF * 150)
|
||||
|
||||
--Beam
|
||||
if cycleF > .5 then
|
||||
render.SetMaterial(beamMat)
|
||||
render.DrawBeam(self:GetPos(), self.hitPos, cycleF * 2, 0, 0, Color(255, 255, 255, (cycleF - .5) * 255))
|
||||
end
|
||||
elseif cycleF < 1.1 then
|
||||
--fired beam
|
||||
render.SetMaterial(beamMat)
|
||||
render.DrawBeam(LerpVector((cycleF - 1) * 10, self:GetPos(), self.hitPos), self.hitPos, (cycleF - 1) * 500, 0, 0)
|
||||
end
|
||||
end
|
||||
44
addons/pillpack/lua/effects/wow_doge.lua
Normal file
44
addons/pillpack/lua/effects/wow_doge.lua
Normal file
@@ -0,0 +1,44 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
function EFFECT:Init(effectdata)
|
||||
self:SetPos(effectdata:GetOrigin())
|
||||
self.color = HSVToColor(math.Rand(0, 360), .8, 1)
|
||||
self.vel = VectorRand()
|
||||
self.i = 0
|
||||
end
|
||||
|
||||
function EFFECT:Think()
|
||||
--[[self:SetPos(self.ent:GetAttachment(self.ent:LookupAttachment("zipline")).Pos)
|
||||
self:SetRenderBoundsWS(self:GetPos(),self.endPoint)]]
|
||||
self:SetPos(self:GetPos() + self.vel)
|
||||
self.i = self.i + 1
|
||||
if self.i > 100 then return false end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
local wow = Material("pillsprites/wow.png")
|
||||
|
||||
function EFFECT:Render()
|
||||
--[[cam.Start3D2D(self:GetPos(),LocalPlayer():EyeAngles()+Angle(90,0,0),1)
|
||||
/*surface.SetFont("CloseCaption_Bold")
|
||||
surface.SetTextColor(HSVToColor(math.Rand(0,360),1,.5))
|
||||
surface.SetTextPos(100,100)
|
||||
surface.GetTextSize(32)
|
||||
surface.DrawText("wow")
|
||||
draw.SimpleText("Oh No!", "CloseCaption_Bold", 0, 0, Color(255,255,255,255), TEXT_ALIGN_CENTER, TEXT_ALIGN_CENTER)
|
||||
draw.DrawText("TEXT", "CloseCaption_Bold", 1, 1, Color(255, 255, 255, 255), TEXT_ALIGN_CENTER)
|
||||
cam.End3D2D()]]
|
||||
cam.Start3D(EyePos(), EyeAngles())
|
||||
render.SetMaterial(wow)
|
||||
render.DrawSprite(self:GetPos(), 20, 10, self.color)
|
||||
cam.End3D()
|
||||
end
|
||||
Reference in New Issue
Block a user