Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if CLIENT then
- local moon = GetGlobalEntity("vagineer")
- first = true
- hook.Add("PostDrawSkyBox", "draw test moon", function()
- if moon:IsValid() then
- if first then
- moon:SetNoDraw(true)
- function moon:BuildBonePositions()
- for i=0, self:GetBoneCount() do
- local name = self:GetBoneName(i):lower()
- if name == "prp_helmet" then continue end
- if name == "bip_head" or name == "bip_neck" then
- local matrix = self:GetBoneMatrix(i)
- if matrix then
- matrix:Scale(Vector()*100)
- self:SetBoneMatrix(i, matrix)
- end
- else
- local matrix = self:GetBoneMatrix(i)
- if matrix then
- matrix:Scale(Vector()*0.001)
- matrix:SetTranslation(self:GetPos())
- self:SetBoneMatrix(i, matrix)
- end
- end
- end
- end
- first = false
- end
- local t = CurTime() * 10
- moon:SetPos(LocalPlayer():GetPos() + Vector()*100)
- moon:SetAngles(Angle(t, t, t))
- moon:DrawModel()
- end
- end)
- end
- if SERVER then
- for _, ent in pairs(ents.FindByModel("models/player/engineer.mdl")) do
- ent:Remove()
- end
- local ent = ents.Create("prop_dynamic")
- ent:SetModel("models/player/engineer.mdl")
- ent:SetPos(Vector(729.93017578125,1549.1125488281,-13127.432617188) )
- ent:Spawn()
- for i=0, ent:GetFlexNum() do
- ent:SetFlexWeight(i, math.random()*0.4)
- end
- SetGlobalEntity("vagineer", ent)
- end
Advertisement
Add Comment
Please, Sign In to add comment