I am currently working on an FPS framework (mainly milsim) I made a team script to that players on a certain team, get a certain load-out/rifle. Im having problems with this one part and was wondering what is causing it and if there is a way to fix it. Thanks!
local gun --LOAD THE GUN MODEL FOR TEAM1 if player.Team == game.Teams.Team1 then if weaponType == 1 then gun = self.primary2 else if player.Team == game.Teams.Team2 then if weaponType == 1 then gun = self.primary1 elseif weaponType == 2 then gun = self.secondary end end end end --CLONE THE GUN MODEL AND PUT IT IN THE WORKSPACE self.current = gun:clone() self.current.Parent = game.Workspace