• Why isn't this SWEP code working?
    2 replies, posted
Hello, I'm making a SWEP. It works fine, but there is one problem I need to fix. The SWEP is a scoped AK 47, and I tried to add the scope via Clavus's SWEP construction kit. However, the code I used for adding the scope to the viewmodel isn't working. I tried using the bone for the AK47 model from CSS I was looking for, but that didn't work. So, I created my own bone. But, that doesn't work either. What could be causing this? I need help. Code: [CODE]SWEP.ViewModelBoneMods = { ["ValveBiped.base"] = { scale = Vector(0.009, 0.009, 0.009), pos = Vector(0, 0, 0), angle = Angle(0, 0, 0) } } SWEP.VElements = { ["barrel"] = { type = "Model", model = "models/cw2/attachments/pso.mdl", bone = "ValveBiped.base", rel = "", pos = Vector(0.321, 2.851, 9.114), angle = Angle(-1.695, -2.25, -89.311), size = Vector(1.144, 1.144, 1.144), color = Color(255, 255, 255, 255), surpresslightning = false, material = "", skin = 0, bodygroup = {} } } [/CODE] Could one of the possibilities be that I didn't set a skin, so it appears invisible?
Have you added the constructor base code to the SWEP as well?
Oh, no, I haven't. My mistake.
Sorry, you need to Log In to post a reply to this thread.