View difference between Paste ID: U75S8ihR and hmAwDjLw
SHOW: | | - or go back to the newest paste.
1
--[[ FPS M1911 by KillerDarkness0105/Codex#6685]]--
2
3
4
Player=game:GetService("Players").LocalPlayer
5
Character=Player.Character
6
PlayerGui=Player.PlayerGui
7
Backpack=Player.Backpack
8
Torso=Character.Torso
9
Head=Character.Head
10
Humanoid=Character.Humanoid
11
LeftArm=Character["Left Arm"]
12
LeftLeg=Character["Left Leg"]
13
RightArm=Character["Right Arm"]
14
RightLeg=Character["Right Leg"]
15
LS=Torso["Left Shoulder"]
16
LH=Torso["Left Hip"]
17
RS=Torso["Right Shoulder"]
18
RH=Torso["Right Hip"]
19
Face = Head.face
20
Neck=Torso.Neck
21
it=Instance.new
22
attacktype=1
23
attacktype2=1
24
vt=Vector3.new
25
it=Instance.new
26
cf=CFrame.new
27
cn=CFrame.new
28
euler=CFrame.fromEulerAnglesXYZ
29
angles=CFrame.Angles
30
necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
31
necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
32
LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0)
33
LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0)
34
RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0)
35
RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0)
36
RootPart=Character.HumanoidRootPart
37
RootJoint=RootPart.RootJoint
38
RootCF=euler(-1.57,0,3.14)
39
attack = false
40
local Effects = {}
41
 attackspeed = 0.14 
42
 df = false
43
 Swing = 1
44
local sine = 0
45
local change = 1
46
local val = 0
47
local speed = 0
48
local rs = game:GetService("RunService").RenderStepped
49
cam = workspace.CurrentCamera
50
local RbxUtility = LoadLibrary("RbxUtility")
51
local Create = RbxUtility.Create
52
deb = game:GetService("Debris")
53
Player.CameraMode = 1
54
local aim = false
55
mouse = Player:GetMouse()
56
57
			local lerp = function(a, b, t)
58
			    	return a * (1 - t) + b * t
59
 end
60
 
61
 
62
 
63
 
64
 
65
 
66
 
67
 
68
 
69
 
70
 	         local accuracymain = Instance.new("ScreenGui", Player.PlayerGui)
71
72
accuracymain.Name = 'GunAccuracyFrame'
73
74
local accuracyFrame = Instance.new("Frame", accuracymain)
75
76
accuracyFrame.Size = UDim2.new(0, 30, 0, 30)
77
78
accuracyFrame.BackgroundTransparency = 1
79
80
game:service'RunService'.RenderStepped:connect(function()
81
82
    accuracyFrame.Position = UDim2.new(0, Player:GetMouse().X-accuracyFrame.Size.X.Offset/2, 0, Player:GetMouse().Y-accuracyFrame.Size.Y.Offset/2)
83
84
end)
85
86
local accuracy1 = Instance.new("Frame", accuracyFrame)
87
88
accuracy1.BackgroundColor = BrickColor.new("White")
89
90
accuracy1.Size = UDim2.new(0, 8, 0, 2)
91
92
accuracy1.Position = UDim2.new(0, 0, .5, -1)
93
94
local accuracy2 = Instance.new("Frame", accuracyFrame)
95
96
accuracy2.BackgroundColor = BrickColor.new("White")
97
98
accuracy2.Size = UDim2.new(0, 8, 0, 2)
99
100
accuracy2.Position = UDim2.new(1, -8, .5, -1)
101
102
local accuracy3 = Instance.new("Frame", accuracyFrame)
103
104
accuracy3.BackgroundColor = BrickColor.new("White")
105
106
accuracy3.Size = UDim2.new(0, 2, 0, 8)
107
108
accuracy3.Position = UDim2.new(.5, -1, 0, 0)
109
110
local accuracy4 = Instance.new("Frame", accuracyFrame)
111
112
accuracy4.BackgroundColor = BrickColor.new("White")
113
114
accuracy4.Size = UDim2.new(0, 2, 0, 8)
115
116
accuracy4.Position = UDim2.new(.5, -1, 1, -8)
117
118
accuracyFrame.Visible = true
119
120
	         
121
    mouse.Icon = "http://www.roblox.com/asset?id=75216962"
122
		
123
 
124
 
125
 
126
 
127
	
128
129
New = function(Object, Parent, Name, Data)
130
	local Object = Instance.new(Object)
131
	for Index, Value in pairs(Data or {}) do
132
		Object[Index] = Value
133
	end
134
	Object.Parent = Parent
135
	Object.Name = Name
136
	return Object
137
end
138
K1911 = New("Model",Character,"K1911",{})
139
Handle = New("Part",K1911,"Handle",{BrickColor = BrickColor.new("Dark stone grey"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.530000031, 1.11000001, 0.269999951),CFrame = CFrame.new(-34.6798782, 2.69211316, -16, 0.994522989, 0.104528531, 0, -0.104528464, 0.994521201, 0, 0, 0, 1.00000072),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
140
Triggermesh = New("Part",K1911,"Triggermesh",{BrickColor = BrickColor.new("Dark stone grey"),Reflectance = 0.10000000149012,FormFactor = Enum.FormFactor.Symmetric,Size = Vector3.new(0.179999992, 0.25999999, 0.0599999726),CFrame = CFrame.new(-34.2399559, 3.03731799, -15.9999371, 0.390543848, 0.920583785, -0.00219476013, 0.920583367, -0.390543371, 0.000196098365, -0.000676624477, -0.00209704484, -0.999998927),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
141
Mesh = New("SpecialMesh",Triggermesh,"Mesh",{Scale = Vector3.new(0.333333343, 0.466666669, 0.666666687),MeshId = "http://www.roblox.com/asset/?id=3270017",MeshType = Enum.MeshType.FileMesh,})
142
mot = New("Motor",Triggermesh,"mot",{Part0 = Triggermesh,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0.390543371, 0.920584202, -0.000676623837, 0.920582354, -0.39054364, -0.00209704298, -0.00219475664, 0.00019609835, -0.999997973),C1 = CFrame.new(0.401428223, 0.389298439, 6.29425049e-05, 0.994522274, -0.104528472, 0, 0.104528494, 0.994521677, 0, 0, 0, 1.00000024),})
143
bullethole = New("Part",K1911,"bullethole",{BrickColor = BrickColor.new("Dark stone grey"),Material = Enum.Material.SmoothPlastic,Shape = Enum.PartType.Cylinder,Size = Vector3.new(0.809999943, 0.189999968, 0.189999968),CFrame = CFrame.new(-33.333004, 3.3820014, -16, 1.00000179, -9.68575478e-08, 0, -1.11758709e-07, 0.999998868, 0, 0, 0, 1.00000119),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
144
mot = New("Motor",bullethole,"mot",{Part0 = bullethole,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000036, -2.98023224e-08, 0, -1.49011612e-08, 0.999999762, 0, 0, 0, 1.00000024),C1 = CFrame.new(1.26737976, 0.826895952, 0, 0.994522274, -0.104528472, 0, 0.104528494, 0.994521677, 0, 0, 0, 1.00000024),})
145
Part = New("Part",K1911,"Part",{Material = Enum.Material.SmoothPlastic,Reflectance = 0.11999999731779,Size = Vector3.new(1.98999989, 0.370000035, 0.289999992),CFrame = CFrame.new(-33.9300079, 3.37500191, -16, 1.00000036, -1.49011612e-08, 0, -2.23517418e-08, 0.999999762, 0, 0, 0, 1.00000024),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
146
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000036, -2.23517418e-08, 0, -1.49011612e-08, 0.999999762, 0, 0, 0, 1.00000024),C1 = CFrame.new(0.674381256, 0.757531166, 0, 0.994522274, -0.104528472, 0, 0.104528494, 0.994521677, 0, 0, 0, 1.00000024),})
147
Part = New("Part",K1911,"Part",{BrickColor = BrickColor.new("Dark stone grey"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(1.05999994, 0.179999977, 0.249999985),CFrame = CFrame.new(-33.8850136, 3.13003469, -16, 1.00000322, -1.71363354e-07, 0, -1.86264515e-07, 0.999997973, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
148
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000107, -6.70552254e-08, 0, -5.21540642e-08, 0.999999344, 0, 0, 0, 1.00000072),C1 = CFrame.new(0.744735718, 0.518609047, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
149
Part = New("Part",K1911,"Part",{BrickColor = BrickColor.new("Dark stone grey"),Material = Enum.Material.SmoothPlastic,Shape = Enum.PartType.Cylinder,Size = Vector3.new(0.620000005, 0.229999989, 0.229999989),CFrame = CFrame.new(-33.2650108, 3.1581521, -16, 1.00000322, -1.71363354e-07, 0, -1.86264515e-07, 0.999997973, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
150
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000107, -6.70552254e-08, 0, -5.21540642e-08, 0.999999344, 0, 0, 0, 1.00000072),C1 = CFrame.new(1.35840225, 0.611380339, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
151
Part = New("Part",K1911,"Part",{BrickColor = BrickColor.new("Dark stone grey"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.530000031, 1.07000005, 0.189999953),CFrame = CFrame.new(-34.611969, 2.67222261, -16, 0.994525135, 0.104528643, 0, -0.104528435, 0.99451983, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
152
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),C1 = CFrame.new(0.0696144104, -0.0126833916, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
153
Clip = New("Part",K1911,"Clip",{BrickColor = BrickColor.new("Really black"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.420000017, 1.07000005, 0.189999953),CFrame = CFrame.new(-34.6671104, 2.66717649, -16, 0.994525135, 0.104528643, 0, -0.104528435, 0.99451983, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0666667, 0.0666667, 0.0666667),})
154
mot = New("Motor",Clip,"mot",{Part0 = Clip,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),C1 = CFrame.new(0.0153045654, -0.023465395, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
155
bhole = New("Part",K1911,"bhole",{BrickColor = BrickColor.new("Really black"),Material = Enum.Material.SmoothPlastic,Shape = Enum.PartType.Cylinder,Size = Vector3.new(1.66999996, 0.169999972, 0.169999972),CFrame = CFrame.new(-33.7600136, 3.38231826, -16, 1.00000322, -1.71363354e-07, 0, -1.86264515e-07, 0.999997973, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0666667, 0.0666667, 0.0666667),})
156
mot = New("Motor",bhole,"mot",{Part0 = bhole,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000107, -6.70552254e-08, 0, -5.21540642e-08, 0.999999344, 0, 0, 0, 1.00000072),C1 = CFrame.new(0.84267807, 0.782576561, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
157
Part = New("Part",K1911,"Part",{BrickColor = BrickColor.new("Burnt Sienna"),Material = Enum.Material.Wood,Size = Vector3.new(0.370000064, 0.920000076, 0.280000001),CFrame = CFrame.new(-34.6795921, 2.66959429, -16, 0.994525135, 0.104528643, 0, -0.104528435, 0.99451983, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.415686, 0.223529, 0.0352941),})
158
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),C1 = CFrame.new(0.00263977051, -0.0223655701, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
159
Part = New("Part",K1911,"Part",{Material = Enum.Material.SmoothPlastic,Shape = Enum.PartType.Cylinder,Size = Vector3.new(0.289999962, 0.160000041, 0.160000041),CFrame = CFrame.new(-34.7095528, 2.37562132, -16, 1.09896426e-07, -1.71363354e-07, -1.00000322, -2.04281037e-14, 0.999997914, 1.86264515e-07, 1.00000215, 0, 1.09896298e-07),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
160
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.09896185e-07, -7.10542736e-15, 1.00000072, -5.21540642e-08, 0.999999285, 0, -1.00000107, 6.70552254e-08, 1.09896142e-07),C1 = CFrame.new(0.00357055664, -0.317860126, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
161
Part = New("Part",K1911,"Part",{Material = Enum.Material.SmoothPlastic,Shape = Enum.PartType.Cylinder,Size = Vector3.new(0.289999962, 0.160000026, 0.160000026),CFrame = CFrame.new(-34.6395531, 2.95001388, -16, 1.09896426e-07, -1.71363354e-07, -1.00000322, -2.04281037e-14, 0.999997795, 1.86264515e-07, 1.00000215, 0, 1.09896298e-07),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
162
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.09896185e-07, -7.10542736e-15, 1.00000072, -5.21540642e-08, 0.999999166, 0, -1.00000107, 6.70552254e-08, 1.09896142e-07),C1 = CFrame.new(0.0131454468, 0.260703087, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
163
Part = New("Part",K1911,"Part",{BrickColor = BrickColor.new("Really black"),Shape = Enum.PartType.Cylinder,Size = Vector3.new(0.189999953, 0.119999975, 0.119999975),CFrame = CFrame.new(-33.0400124, 3.15800071, -16, 1.00000322, -1.78813934e-07, 0, -1.86264515e-07, 0.999997735, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0666667, 0.0666667, 0.0666667),})
164
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000107, -6.70552254e-08, 0, -5.96046448e-08, 0.999999106, 0, 0, 0, 1.00000072),C1 = CFrame.new(1.58218384, 0.634748459, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
165
Part = New("Part",K1911,"Part",{Material = Enum.Material.Metal,Size = Vector3.new(0.110000029, 0.109999999, 0.200000003),CFrame = CFrame.new(-34.8181458, 3.55000734, -15.9967442, 1.00000322, -1.86264515e-07, 0, -1.86264515e-07, 0.999997735, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
166
mot = New("Motor",Part,"mot",{Part0 = Part,C1 = CFrame.new(-0.0431270599, 0.729999065, -0.00174999237, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
167
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000107, -6.70552254e-08, 0, -6.70552254e-08, 0.999999106, 0, 0, 0, 1.00000072),C1 = CFrame.new(-0.227184296, 0.838742256, 0.00325584412, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
168
Part = New("Part",K1911,"Part",{Material = Enum.Material.Metal,Size = Vector3.new(0.110000029, 0.0500000007, 0.0500000082),CFrame = CFrame.new(-34.8181458, 3.63000631, -16.0717449, 1.00000322, -1.86264515e-07, 0, -1.86264515e-07, 0.999997735, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
169
mot = New("Motor",Part,"mot",{Part0 = Part,C1 = CFrame.new(-0.0431270599, 0.729999065, -0.00174999237, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
170
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000107, -6.70552254e-08, 0, -6.70552254e-08, 0.999999106, 0, 0, 0, 1.00000072),C1 = CFrame.new(-0.235546112, 0.918303013, -0.0717449188, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
171
Part = New("Part",K1911,"Part",{Material = Enum.Material.Metal,Size = Vector3.new(0.110000029, 0.0500000007, 0.0500000007),CFrame = CFrame.new(-34.8181419, 3.62999988, -15.9217443, 1.00000322, -1.86264515e-07, 0, -1.86264515e-07, 0.999997735, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
172
mot = New("Motor",Part,"mot",{Part0 = Part,C1 = CFrame.new(-0.0431270599, 0.729999065, -0.00174999237, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
173
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000107, -6.70552254e-08, 0, -6.70552254e-08, 0.999999106, 0, 0, 0, 1.00000072),C1 = CFrame.new(-0.235542297, 0.918297052, 0.0782556534, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
174
Part = New("Part",K1911,"Part",{BrickColor = BrickColor.new("Dark stone grey"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.10999997, 0.179999977, 0.0500000007),CFrame = CFrame.new(-34.220005, 3.02002287, -16, 0.981630385, -0.190809816, 0, 0.190808371, 0.981624961, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
175
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0.981628299, 0.190808743, 0, -0.19080928, 0.981626272, 0, 0, 0, 1.00000072),C1 = CFrame.new(0.42307663, 0.374183416, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
176
Part = New("Part",K1911,"Part",{Material = Enum.Material.Metal,Size = Vector3.new(0.100000069, 0.139999986, 0.0800000057),CFrame = CFrame.new(-33.0113029, 3.55999947, -16, 1.00000322, -1.78813934e-07, 0, -2.01165676e-07, 0.999997735, 0, 0, 0, 1.00000215),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
177
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000107, -8.19563866e-08, 0, -5.96046448e-08, 0.999999106, 0, 0, 0, 1.00000072),C1 = CFrame.new(1.56871414, 1.03754616, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
178
Part = New("Part",K1911,"Part",{Material = Enum.Material.Metal,Shape = Enum.PartType.Cylinder,Size = Vector3.new(0.080000028, 0.119999945, 0.119999945),CFrame = CFrame.new(-34.9629974, 3.43419743, -16, 0, -1.86264515e-07, 1.00000334, 0, 0.999997735, -1.93715096e-07, -1.00000226, 0, 0),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
179
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0, 0, -1.00000083, -6.70552254e-08, 0.999999106, 0, 1.00000119, -7.4505806e-08, 0),C1 = CFrame.new(-0.359138489, 0.708425283, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
180
Part = New("Part",K1911,"Part",{Material = Enum.Material.Metal,Size = Vector3.new(0.120000049, 0.160000026, 0.0800000727),CFrame = CFrame.new(-34.9034996, 3.41254854, -16, 0.777148902, 0.62932241, 0, -0.629318953, 0.777144134, 0, 0, 0, 1.00000238),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
181
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0.777147114, -0.629319727, 0, 0.629321098, 0.777145267, 0, 0, 0, 1.00000095),C1 = CFrame.new(-0.297702789, 0.693114519, 0, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
182
Part = New("Part",K1911,"Part",{Transparency = 1,Transparency = 1,Size = Vector3.new(0.459999889, 0.24000001, 0.179999948),CFrame = CFrame.new(-33.6749954, 3.41999912, -15.9449997, 1.00000358, -1.93715096e-07, 0, -2.01165676e-07, 0.999997735, 0, 0, 0, 1.00000238),CanCollide = false,BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,})
183
mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 1.00000143, -8.19563866e-08, 0, -7.4505806e-08, 0.999999106, 0, 0, 0, 1.00000095),C1 = CFrame.new(0.923290253, 0.828937769, 0.0550003052, 0.994522989, -0.104528464, 0, 0.104528531, 0.994521201, 0, 0, 0, 1.00000072),})
184
185
				 local NewInstance = function(instance,parent,properties)
186
		    local inst = Instance.new(instance,parent)
187
		    if(properties)then
188
		        for i,v in next, properties do
189
		            pcall(function() inst[i] = v end)
190
		        end
191
		    end
192
		    return inst;
193
		end
194
		
195
		
196
		local HW = NewInstance('Weld',Character,{Part0=RightArm,Part1=Handle,C0 = CFrame.new(0,-0.72,-0.14)*CFrame.Angles(math.rad(-95),math.rad(90),math.rad(0))})
197
		
198
		
199
		
200
				
201
				       so = function(id,par,vol,pit)
202
		coroutine.resume(coroutine.create(function()
203
		local sou = Instance.new("Sound",par or workspace)
204
		sou.Volume=vol
205
		sou.Pitch=pit or 1
206
		sou.SoundId=id
207
		sou:play()
208
		game:GetService("Debris"):AddItem(sou,8)
209
		end))
210
		end
211
		
212
		
213
	function clerp(a,b,t)
214
		local qa = {QuaternionFromCFrame(a)}
215
		local qb = {QuaternionFromCFrame(b)}
216
		local ax, ay, az = a.x, a.y, a.z
217
		local bx, by, bz = b.x, b.y, b.z
218
		local _t = 1-t
219
		return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
220
		end
221
		 
222
		function QuaternionFromCFrame(cf)
223
		local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
224
		local trace = m00 + m11 + m22
225
		if trace > 0 then
226
		local s = math.sqrt(1 + trace)
227
		local recip = 0.5/s
228
		return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
229
		else
230
		local i = 0
231
		if m11 > m00 then
232
		i = 1
233
		end
234
		if m22 > (i == 0 and m00 or m11) then
235
		i = 2
236
		end
237
		if i == 0 then
238
		local s = math.sqrt(m00-m11-m22+1)
239
		local recip = 0.5/s
240
		return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
241
		elseif i == 1 then
242
		local s = math.sqrt(m11-m22-m00+1)
243
		local recip = 0.5/s
244
		return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
245
		elseif i == 2 then
246
		local s = math.sqrt(m22-m00-m11+1)
247
		local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
248
		end
249
		end
250
		end
251
		
252
253
		
254
		function QuaternionToCFrame(px, py, pz, x, y, z, w)
255
		local xs, ys, zs = x + x, y + y, z + z
256
		local wx, wy, wz = w*xs, w*ys, w*zs
257
		local xx = x*xs
258
		local xy = x*ys
259
		local xz = x*zs
260
		local yy = y*ys
261
		local yz = y*zs
262
		local zz = z*zs
263
		return CFrame.new(px, py, pz,1-(yy+zz), xy - wz, xz + wy,xy + wz, 1-(xx+zz), yz - wx, xz - wy, yz + wx, 1-(xx+yy))
264
		end
265
		function QuaternionSlerp(a, b, t)
266
		local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
267
		local startInterp, finishInterp;
268
		if cosTheta >= 0.0001 then
269
		if (1 - cosTheta) > 0.0001 then
270
		local theta = math.acos(cosTheta)
271
		local invSinTheta = 1/math.sin(theta)
272
		startInterp = math.sin((1-t)*theta)*invSinTheta
273
		finishInterp = math.sin(t*theta)*invSinTheta  
274
		else
275
		startInterp = 1-t
276
		finishInterp = t
277
		end
278
		else
279
		if (1+cosTheta) > 0.0001 then
280
		local theta = math.acos(-cosTheta)
281
		local invSinTheta = 1/math.sin(theta)
282
		startInterp = math.sin((t-1)*theta)*invSinTheta
283
		finishInterp = math.sin(t*theta)*invSinTheta
284
		else
285
		startInterp = t-1
286
		finishInterp = t
287
		end
288
		end
289
		return a[1]*startInterp + b[1]*finishInterp, a[2]*startInterp + b[2]*finishInterp, a[3]*startInterp + b[3]*finishInterp, a[4]*startInterp + b[4]*finishInterp
290
		end
291
		    mouse=Player:GetMouse()
292
--save shoulders
293
		RSH, LSH=nil, nil
294
		--welds
295
		RW, LW=Instance.new("Weld"), Instance.new("Weld")
296
		RW.Name="Right Shoulder" LW.Name="Left Shoulder"
297
		LH=Torso["Left Hip"]
298
		RH=Torso["Right Hip"]
299
		TorsoColor=Torso.BrickColor
300
		function NoOutline(Part)
301
		Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
302
		end
303
		player=Player
304
		ch=Character
305
		RSH=ch.Torso["Right Shoulder"]
306
		LSH=ch.Torso["Left Shoulder"]
307
		--
308
		RSH.Parent=nil
309
		LSH.Parent=nil
310
		--
311
		RW.Name="Right Shoulder"
312
		RW.Part0=ch.Torso
313
		RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5)
314
		RW.C1=cf(0, 0.5, 0)
315
		RW.Part1=ch["Right Arm"]
316
		RW.Parent=ch.Torso
317
		--
318
		LW.Name="Left Shoulder"
319
		LW.Part0=ch.Torso
320
		LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
321
		LW.C1=cf(0, 0.5, 0)
322
		LW.Part1=ch["Left Arm"]
323
		LW.Parent=ch.Torso
324
		
325
				    ArtificialHB = Instance.new("BindableEvent", script)
326
		ArtificialHB.Name = "Heartbeat"
327
		 
328
		script:WaitForChild("Heartbeat")
329
		 
330
		frame = 1 / 80
331
		tf = 0
332
		allowframeloss = false
333
		tossremainder = false
334
		lastframe = tick()
335
		script.Heartbeat:Fire()
336
		game:GetService("RunService").Heartbeat:connect(function(s, p)
337
		    tf = tf + s
338
		    if tf >= frame then
339
		        if allowframeloss then
340
		            script.Heartbeat:Fire()
341
		            lastframe = tick()
342
		        else
343
		            for i = 1, math.floor(tf / frame) do
344
		                script.Heartbeat:Fire()
345
		            end
346
		            lastframe = tick()
347
		        end
348
		        if tossremainder then
349
		            tf = 0
350
		        else
351
		            tf = tf - frame * math.floor(tf / frame)
352
		        end
353
		    end
354
		end)
355
		 
356
--[[]
357
		function swait(num)
358
		    if num == 0 or num == nil then
359
		        ArtificialHB.Event:wait()
360
		    else
361
		        for i = 0, num do
362
		            ArtificialHB.Event:wait()
363
		        end
364
		    end
365
	end
366
367
	]]
368
	
369
370
	function swait(num)
371
	if num == 0 or num == nil then
372
		game:service("RunService").Stepped:wait()
373
	else
374
		for i = 0, num do
375
			game:service("RunService").Stepped:wait()
376
		end
377
	end
378
end
379
380
381
game:GetService("UserInputService").MouseIconEnabled = false
382
383
384
385
386
387
388
389
390
 
391
392
393
394
395
396
		function RemoveOutlines(part)
397
		    part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10
398
		end
399
		   
400
401
402
403
404
405
406
407
408
409
		F1 = Instance.new("Folder", Character)
410
		F1.Name = "Effects Folder"
411
		F2 = Instance.new("Folder", F1)
412
		F2.Name = "Effects"
413
		Triangle = function(a, b, c)
414
		end
415
		
416
MagicBlock = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type, parent)
417
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
418
  prt.Anchored = true
419
  prt.CFrame = cframe
420
  msh = mesh("BlockMesh", prt, "", "", vt(0, 0, 0), vt(x1, y1, z1))
421
  game:GetService("Debris"):AddItem(prt, 10)
422
  if Type == 1 or Type == nil then
423
    table.insert(Effects, {prt, "Block1", delay, x3, y3, z3, msh})
424
  else
425
    if Type == 2 then
426
      table.insert(Effects, {prt, "Block2", delay, x3, y3, z3, msh})
427
    else
428
      if Type == 3 then
429
        table.insert(Effects, {prt, "Block3", delay, x3, y3, z3, msh, prt.CFrame * euler(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)), 0})
430
      end
431
    end
432
  end
433
end
434
MagicSkull = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, goe)
435
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
436
  prt.Anchored = true
437
  prt.CFrame = cframe
438
  msh = mesh("SpecialMesh", prt, "FileMesh", "14028428", vt(0, 0, 0), vt(x1, y1, z1))
439
  game:GetService("Debris"):AddItem(prt, 10)
440
  table.insert(Effects, {prt, "Skull", delay, x3, y3, z3, msh, goe})
441
end
442
MagicCircle = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
443
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
444
  prt.Anchored = true
445
  prt.CFrame = cframe
446
  local msh = mesh("SpecialMesh", prt, "Sphere", "nil", vt(0, 0, 0), vt(x1, y1, z1))
447
  game:GetService("Debris"):AddItem(prt, 10)
448
  table.insert(Effects, {prt, "Cylinder", delay, x3, y3, z3, msh})
449
end
450
MagicRing = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
451
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt(0.5, 0.5, 0.5))
452
  prt.Anchored = true
453
  prt.CFrame = cframe * cf(x2, y2, z2)
454
  local msh = mesh("SpecialMesh", prt, "FileMesh", "3270017", vt(0, 0, 0), vt(x1, y1, z1))
455
  game:GetService("Debris"):AddItem(prt, 10)
456
  table.insert(Effects, {prt, "Cylinder", delay, x3, y3, z3, msh})
457
end
458
MagicCircle2 = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, push)
459
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
460
  prt.Anchored = true
461
  prt.CFrame = cframe
462
  local msh = mesh("SpecialMesh", prt, "Sphere", "nil", vt(0, 0, 0), vt(x1, y1, z1))
463
  game:GetService("Debris"):AddItem(prt, 10)
464
  table.insert(Effects, {prt, "Blood", delay, x3, y3, z3, msh, push})
465
end
466
MagicCylinder = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
467
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
468
  prt.Anchored = true
469
  prt.CFrame = cframe
470
  local msh = mesh("CylinderMesh", prt, "", "", vt(0, 0, 0), vt(x1, y1, z1))
471
  game:GetService("Debris"):AddItem(prt, 10)
472
  table.insert(Effects, {prt, "Cylinder", delay, x3, y3, z3, msh})
473
end
474
MagicCylinder2 = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, goe)
475
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
476
  prt.Anchored = true
477
  prt.CFrame = cframe
478
  local msh = mesh("CylinderMesh", prt, "", "", vt(0, 0, 0), vt(x1, y1, z1))
479
  game:GetService("Debris"):AddItem(prt, 10)
480
  table.insert(Effects, {prt, "Cylinder2", delay, x3, y3, z3, msh, goe})
481
end
482
MagicHead = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
483
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
484
  prt.Anchored = true
485
  prt.CFrame = cframe
486
  local msh = mesh("SpecialMesh", prt, "Head", "nil", vt(0, 0, 0), vt(x1, y1, z1))
487
  game:GetService("Debris"):AddItem(prt, 10)
488
  table.insert(Effects, {prt, "Cylinder", delay, x3, y3, z3, msh})
489
end
490
ClangEffect = function(brickcolor, cframe, duration, decrease, size, power)
491
  local prt = part(3, workspace, 0, 1, brickcolor, "Effect", vt())
492
  prt.Anchored = true
493
  prt.CFrame = cframe
494
  local msh = mesh("BlockMesh", prt, "", "", vt(0, 0, 0), vt(5, 5, 5))
495
  game:GetService("Debris"):AddItem(prt, 10)
496
  table.insert(Effects, {prt, "CylinderClang", duration, decrease, size, power, prt.CFrame, nil})
497
end
498
MagicWave = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
499
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
500
  prt.Anchored = true
501
  prt.CFrame = cframe
502
  local msh = mesh("SpecialMesh", prt, "FileMesh", "20329976", vt(0, 0, 0), vt(x1, y1, z1))
503
  game:GetService("Debris"):AddItem(prt, 10)
504
  table.insert(Effects, {prt, "Cylinder", delay, x3, y3, z3, msh})
505
end
506
MagicFire = function(brickcolor, cframe, x1, y1, z1, delay)
507
  local prt = part(3, workspace, 0, 0, brickcolor, "Effect", vt())
508
  prt.Anchored = true
509
  prt.CFrame = cframe
510
  msh = mesh("BlockMesh", prt, "", "", vt(0, 0, 0), vt(x1, y1, z1))
511
  game:GetService("Debris"):AddItem(prt, 10)
512
  table.insert(Effects, {prt, "Fire", delay, 1, 1, 1, msh})
513
end
514
MagicFireWave = function(brickcolor, cframe, x1, y1, z1)
515
  local prt = part(3, workspace, 0, 1, brickcolor, "Effect", vt())
516
  prt.Anchored = true
517
  prt.CFrame = cframe
518
  msh = mesh("BlockMesh", prt, "", "", vt(0, 0, 0), vt(x1, y1, z1))
519
  d = Instance.new("Decal")
520
  d.Parent = prt
521
  d.Texture = "http://www.roblox.com/asset/?id=26356434"
522
  d.Face = "Top"
523
  d = Instance.new("Decal")
524
  d.Parent = prt
525
  d.Texture = "http://www.roblox.com/asset/?id=26356434"
526
  d.Face = "Bottom"
527
  game:GetService("Debris"):AddItem(prt, 10)
528
  table.insert(Effects, {prt, "FireWave", 1, 30, math.random(400, 600) / 100, msh})
529
end
530
ElecEffect = function(cff, x, y, z)
531
  local prt = part(3, workspace, 0, 0, BrickColor.new("White"), "Part", vt(1, 1, 1))
532
  prt.Anchored = true
533
  prt.CFrame = cff * cf(math.random(-x, x), math.random(-y, y), math.random(-z, z))
534
  prt.CFrame = cf(prt.Position)
535
  game:GetService("Debris"):AddItem(prt, 10)
536
  xval = math.random() / 3
537
  yval = math.random() / 3
538
  zval = math.random() / 3
539
  msh = mesh("BlockMesh", prt, "", "", vt(0, 0, 0), vt(xval, yval, zval))
540
  Effects[#Effects + 1] = {prt, "Elec", 0.2, x, y, z, xval, yval, zval, msh}
541
end
542
		
543
		function FindNearestTorso(Position, Distance, SinglePlayer)
544
			if SinglePlayer then
545
				return (SinglePlayer.Torso.CFrame.p - Position).magnitude < Distance
546
			end
547
			local List = {}
548
			for i, v in pairs(workspace:GetChildren()) do
549
				if v:IsA("Model") then
550
					if v:findFirstChild("Torso") then
551
						if v ~= Character then
552
							if (v.Torso.Position - Position).magnitude <= Distance then
553
								table.insert(List, v)
554
							end 
555
						end 
556
					end 
557
				end 
558
			end
559
			return List
560
		end
561
		
562
		
563
		function CreatePart(Parent, Material, Reflectance, Transparency, BColor, Name, Size)
564
	local Part = Create("Part"){
565
		Parent = Parent,
566
		Reflectance = Reflectance,
567
		Transparency = Transparency,
568
		CanCollide = false,
569
		Locked = true,
570
		BrickColor = BrickColor.new(tostring(BColor)),
571
		Name = Name,
572
		Size = Size,
573
		Material = Material,
574
	}
575
	RemoveOutlines(Part)
576
	return Part
577
end
578
	
579
function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale)
580
	local Msh = Create(Mesh){
581
		Parent = Part,
582
		Offset = OffSet,
583
		Scale = Scale,
584
	}
585
	if Mesh == "SpecialMesh" then
586
		Msh.MeshType = MeshType
587
		Msh.MeshId = MeshId
588
	end
589
	return Msh
590
end
591
		
592
		
593
		
594
function BlockEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
595
	local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
596
	prt.Anchored = true
597
	prt.CFrame = cframe
598
	local msh = CreateMesh("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
599
	game:GetService("Debris"):AddItem(prt, 10)
600
	if Type == 1 or Type == nil then
601
		table.insert(Effects, {
602
			prt,
603
			"Block1",
604
			delay,
605
			x3,
606
			y3,
607
			z3,
608
			msh
609
		})
610
	elseif Type == 2 then
611
		table.insert(Effects, {
612
			prt,
613
			"Block2",
614
			delay,
615
			x3,
616
			y3,
617
			z3,
618
			msh
619
		})
620
	end
621
end
622
623
function SphereEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
624
	local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
625
	prt.Anchored = true
626
	prt.CFrame = cframe
627
	prt.Name = "prt"
628
	local msh = CreateMesh("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
629
	game:GetService("Debris"):AddItem(prt, 10)
630
	table.insert(Effects, {
631
		prt,
632
		"Cylinder",
633
		delay,
634
		x3,
635
		y3,
636
		z3,
637
		msh
638
	})
639
end
640
641
function RingEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
642
local prt=CreatePart(workspace,"Neon",0,0,brickcolor,"Effect",vt(.5,.5,.5))--part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt(0.5,0.5,0.5))
643
prt.Anchored=true
644
prt.CFrame=cframe
645
msh=CreateMesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=3270017",vt(0,0,0),vt(x1,y1,z1))
646
game:GetService("Debris"):AddItem(prt,2)
647
coroutine.resume(coroutine.create(function(Part,Mesh,num) 
648
for i=0,1,delay do
649
swait()
650
Part.Transparency=i
651
Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
652
end
653
Part.Parent=nil
654
end),prt,msh,(math.random(0,1)+math.random())/5)
655
end
656
657
function CylinderEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
658
	local prt = CreatePart(workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
659
	prt.Anchored = true
660
	prt.CFrame = cframe
661
	local msh = CreateMesh("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
662
	game:GetService("Debris"):AddItem(prt, 10)
663
	table.insert(Effects, {
664
		prt,
665
		"Cylinder",
666
		delay,
667
		x3,
668
		y3,
669
		z3,
670
		msh
671
	})
672
end
673
674
function WaveEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
675
	local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
676
	prt.Anchored = true
677
	prt.CFrame = cframe
678
	local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "rbxassetid://20329976", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
679
	game:GetService("Debris"):AddItem(prt, 10)
680
	table.insert(Effects, {
681
		prt,
682
		"Cylinder",
683
		delay,
684
		x3,
685
		y3,
686
		z3,
687
		msh
688
	})
689
end
690
691
function SpecialEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
692
	local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
693
	prt.Anchored = true
694
	prt.CFrame = cframe
695
	local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "rbxassetid://24388358", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
696
	game:GetService("Debris"):AddItem(prt, 10)
697
	table.insert(Effects, {
698
		prt,
699
		"Cylinder",
700
		delay,
701
		x3,
702
		y3,
703
		z3,
704
		msh
705
	})
706
end
707
708
709
function MoonEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
710
	local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
711
	prt.Anchored = true
712
	prt.CFrame = cframe
713
	local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "rbxassetid://259403370", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
714
	game:GetService("Debris"):AddItem(prt, 10)
715
	table.insert(Effects, {
716
		prt,
717
		"Cylinder",
718
		delay,
719
		x3,
720
		y3,
721
		z3,
722
		msh
723
	})
724
end
725
726
function HeadEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
727
	local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
728
	prt.Anchored = true
729
	prt.CFrame = cframe
730
	local msh = CreateMesh("SpecialMesh", prt, "Head", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
731
	game:GetService("Debris"):AddItem(prt, 10)
732
	table.insert(Effects, {
733
		prt,
734
		"Cylinder",
735
		delay,
736
		x3,
737
		y3,
738
		z3,
739
		msh
740
	})
741
end
742
743
function BreakEffect(brickcolor, cframe, x1, y1, z1)
744
	local prt = CreatePart(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
745
	prt.Anchored = true
746
	prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
747
	local msh = CreateMesh("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
748
	local num = math.random(10, 50) / 1000
749
	game:GetService("Debris"):AddItem(prt, 10)
750
	table.insert(Effects, {
751
		prt,
752
		"Shatter",
753
		num,
754
		prt.CFrame,
755
		math.random() - math.random(),
756
		0,
757
		math.random(50, 100) / 100
758
	})
759
end
760
		
761
function FindNearestHead(Position, Distance, SinglePlayer)
762
	if SinglePlayer then
763
		return Distance > (SinglePlayer.Torso.CFrame.p - Position).magnitude
764
	end
765
	local List = {}
766
	for i, v in pairs(workspace:GetChildren()) do
767
		if v:IsA("Model") and v:findFirstChild("Head") and v ~= Character and Distance >= (v.Head.Position - Position).magnitude then
768
			table.insert(List, v)
769
		end
770
	end
771
	return List
772
end
773
		
774
775
776
function Bullets(thinggy,place,size,color,velocity,damage,bounce,collide,rotation)
777
    swait()
778
	   local Bullet = Instance.new("Part",Workspace)
779
	Bullet.Locked = true
780
	Bullet.Name = "Bullet"
781
	Bullet.Anchored = bounce
782
	Bullet.CanCollide = collide
783
	Bullet.Transparency = 0.24
784
	Bullet.BrickColor = BrickColor.new(color)
785
	Bullet.Size = Vector3.new(0.2,0.2,5)
786
	Bullet.Material = "Neon"
787
	Bullet.Orientation = vt(0,0,0)
788
		local Bulletforce = Instance.new("BodyForce")
789
	Bulletforce.force = Vector3.new(0,Bullet:GetMass()*166.2,0)
790
	Bulletforce.Parent = Bullet
791
	Bullet.CFrame = thinggy.CFrame*CFrame.new(0.75,0.74,0)
792
	local bv = Instance.new("BodyVelocity",Bullet)
793
	bv.maxForce = Vector3.new(math.huge,math.huge,math.huge)
794
    Bullet.CFrame = CFrame.new(Bullet.Position,mouse.Hit.p)
795
		bv.velocity = Bullet.CFrame.lookVector*velocity
796
		deb:AddItem(bv,0.4)
797
deb:AddItem(Bullet,30)
798
			
799
			Bullet.Touched:connect(function(hit)
800
801
	if (hit.Parent.Parent ~= Character and hit.Parent ~= Character and hit.Name ~= "prt" and hit.Name ~= "Effect" and hit.Name ~= "Bullet" and Bullet.Anchored == false and hit.Name ~= "block" and hit.Name ~= "Shell") then
802
	    	    local hitsound = Instance.new("Sound", Bullet)
803
    hitsound.Volume = 3
804
    hitsound.PlayOnRemove = true
805
    hitsound.SoundId = "http://roblox.com/asset/?id=578289949"
806
    hitsound.Pitch = 1
807
    hitsound:Destroy()
808
    deb:AddItem(hitsound, 4)
809
	Bullet.Anchored = true
810
	Bullet.Transparency = 1
811
	deb:AddItem(Bullet, 4)
812
	if hit.Parent:FindFirstChildOfClass("Humanoid") ~= nil then
813
	    	    	    local bullethitsound = Instance.new("Sound", Bullet)
814
    bullethitsound.Volume = 4
815
    bullethitsound.PlayOnRemove = true
816
    bullethitsound.SoundId = "http://roblox.com/asset/?id=1452522753"
817
    bullethitsound.Pitch = 1
818
    bullethitsound:Destroy()
819
    deb:AddItem(bullethitsound, 4)
820
    hit.Parent:FindFirstChildOfClass("Humanoid"):TakeDamage(math.random(23,42))
821
    blood(12,Bullet.CFrame)
822
end
823
if hit.Parent:FindFirstChildOfClass("Humanoid") == nil then
824
        for i = 1,math.random(2,7) do
825
    local block = Instance.new("Part",Workspace)
826
    block.BrickColor = hit.BrickColor
827
    block.CFrame = Bullet.CFrame*CFrame.new(math.random(-4,6),math.random(1,3),math.random(-7,8))
828
    block.Size = vt(0.3,0.4,0.3)
829
    block.Name = "block"
830
    block.Material = hit.Material
831
    block.Velocity = vt(math.random(-22,33),math.random(-20,40),math.random(-10,20))
832
    	deb:AddItem(block,8)
833
end
834
end
835
coroutine.resume(coroutine.create(function()
836
BlockEffect(BrickColor.new("New Yeller"), CFrame.new(Bullet.Position), 2, 2, 2, 1.5, 1.5, 1.5, 0.06)
837
	   
838
	        end))
839
		end
840
	end)
841
coroutine.resume(coroutine.create(function()
842
    wait(0.5)
843
    while true do
844
        swait()
845
        Bullet.Velocity = Bullet.Velocity - Vector3.new(0, 14.81*.2, 0)
846
end
847
end))
848
849
		end
850
	
851
852
853
	function blood(amount,pp)
854
	    
855
		              		               	for i = 1,amount do
856
	local bloodpart = Instance.new("Part",Workspace)
857
	bloodpart.Color = Color3.fromRGB(64,0,0)
858
	bloodpart.Size = vt(0.2,0.08,0.2)
859
	bloodpart.Archivable = true
860
	bloodpart.CFrame = pp
861
	bloodpart:BreakJoints()
862
	bloodpart.Velocity = (pp * CFrame.Angles(math.rad(math.random(20,30)*8), -math.rad(-40), math.rad(-20))).lookVector * 23
863
	deb:AddItem(bloodpart,8)
864
end
865
	 end
866
867
868
869
870
871
872-
local ammo = 8
872+
local ammo = math.huge
873
  function reload()
874
        
875
    attack = true
876
		    RW.C1 = clerp(RW.C1, CFrame.new(0, 0.5, 0) *angles(0,0,0),1)
877
LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * angles(0,0,0),1)
878
Torso.Neck.C1 = clerp(Torso.Neck.C1,necko2 *angles(0,0,0),1)
879
    			   for i = 0,1.6,0.1 do
880
			       swait()
881
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(9),math.rad(0),math.rad(0)),.1)
882
RW.C0 = clerp(RW.C0, CFrame.new(0.7, 0.5, -0.3) * angles(math.rad(90), math.rad(0), math.rad(-23)),.2)
883
LW.C0 = clerp(LW.C0, CFrame.new(-.75, 0.5, -.9) * angles(math.rad(70), math.rad(-12), math.rad(47)),.2)
884
HW.C0 = clerp(HW.C0, CFrame.new(0,-1,-0.14)*CFrame.Angles(math.rad(-90),math.rad(90),math.rad(0)),0.15)
885
end
886
   local Clip2 = Instance.new("Part")
887
Clip2.Parent = Workspace
888
Clip2.Size = Vector3.new(.2,.7,.2)
889
Clip2.Archivable = true
890
Clip2.Transparency = 0
891
Clip2.CanCollide = true
892
Clip2.Anchored = true
893
Clip2.BrickColor = BrickColor.New("Black")
894
Clip2.Material = "Metal"
895
Clip2.CFrame = LeftArm.CFrame
896
so("rbxassetid://1042833810",Handle,1,1)
897
Clip.Transparency = 1
898
Clip2:BreakJoints()
899
Clip2.Anchored = false
900
Clip2.Velocity = (LeftArm.CFrame * CFrame.Angles(math.rad(math.random(20,30)*8), -math.rad(-40), math.rad(-20))).lookVector * 42
901
game:service'Debris':AddItem(Clip2,10)
902
903
    			   for i = 0,1.6,0.1 do
904
			       swait()
905
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(9),math.rad(0),math.rad(23)),.15)
906
RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(108), math.rad(0), math.rad(63)),.1)
907
LW.C0 = clerp(LW.C0, CFrame.new(-1.25, 0.5, 0) * angles(math.rad(87), math.rad(32), math.rad(-47-6*i)),.34)
908
HW.C0 = clerp(HW.C0, CFrame.new(0,-1,-0.34)*CFrame.Angles(math.rad(-70),math.rad(90),math.rad(0)),0.15)
909
end
910
911
912
    			   for i = 0,1.8,0.1 do
913
			       swait()
914
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(18),math.rad(0),math.rad(27)),.15)
915
RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(100), math.rad(0), math.rad(63)),.2)
916
LW.C0 = clerp(LW.C0, CFrame.new(-1.25, 0.5, 0) * angles(math.rad(-17), math.rad(0), math.rad(4)),.2)
917
HW.C0 = clerp(HW.C0, CFrame.new(0,-1,-0.34)*CFrame.Angles(math.rad(-70),math.rad(90),math.rad(0)),0.15)
918
end
919
920
921
922
923
924
925
local Clip3 = Instance.new("Part")
926
Clip3.Parent = Workspace
927
Clip3.Size = Vector3.new(.2,.7,.2)
928
Clip3.Archivable = true
929
Clip3.Transparency = 0
930
Clip3.CanCollide = false
931
Clip3.BrickColor = BrickColor.new("Black")
932
Clip3.Material = "Metal"
933
local Clip3weld = Instance.new("Weld")
934
Clip3weld.Parent = Clip3
935
Clip3weld.Part0 = LeftArm
936
Clip3weld.Part1 = Clip3
937
Clip3weld.C1 = CFrame.new(-0.12, .65, -0.7)*CFrame.Angles(math.rad(-80),math.rad(0),math.rad(0))
938
		Clip3weld.Part0 = LeftArm
939
		
940
		
941
so("rbxassetid://1042833484",Handle,1,1)
942
    			   for i = 0,1.7,0.1 do
943
			       swait()
944
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(9),math.rad(0),math.rad(0)),.1)
945
RW.C0 = clerp(RW.C0, CFrame.new(0.7, 0.5, -0.3) * angles(math.rad(90), math.rad(0), math.rad(-23)),.2)
946
LW.C0 = clerp(LW.C0, CFrame.new(-.87, 0.5, -.9) * angles(math.rad(60), math.rad(-12), math.rad(62)),.25)
947
HW.C0 = clerp(HW.C0, CFrame.new(0,-1,-0.14)*CFrame.Angles(math.rad(-90),math.rad(90),math.rad(0)),0.15)
948
end
949
950
Clip3:Destroy()
951
Clip.Transparency = 0
952
so("rbxassetid://170160994",Handle,1,1)
953
954
955
956
957
    			   for i = 0,1.6,0.1 do
958
			       swait()
959
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(14),math.rad(0),math.rad(-14)),.1)
960
RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(-33)),.2)
961
LW.C0 = clerp(LW.C0, CFrame.new(-.75, 0.7, -.8) * angles(math.rad(60), math.rad(-12), math.rad(57)),.13)
962
HW.C0 = clerp(HW.C0, CFrame.new(0,-1,-0.14)*CFrame.Angles(math.rad(-100),math.rad(90),math.rad(0)),0.15)
963
end
964
965
966
967
so("rbxassetid://170160964",Handle  ,1,1)
968
969
970
    			   for i = 0,1.6,0.1 do
971
			       swait()
972
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(14),math.rad(0),math.rad(-8)),.1)
973
RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(-33)),.2)
974
LW.C0 = clerp(LW.C0, CFrame.new(-.75, 0.7, -1) * angles(math.rad(60), math.rad(-12), math.rad(37)),.2)
975
HW.C0 = clerp(HW.C0, CFrame.new(0,-1,-0.14)*CFrame.Angles(math.rad(-100),math.rad(90),math.rad(0)),0.15)
976
end
977
ammo = 8
978
attack = false
979
    end
980
    
981
    local recoil = 0
982
    local maxrecoil = 0
983
    
984
    
985
    function shoot()
986
        recoil = recoil + .6
987
        ammo = ammo - 1
988
        local Shell = Instance.new("Part")
989
Shell.Parent = Workspace
990
Shell.Size = Vector3.new(.1,.3,.1)
991
Shell.Archivable = true
992
Shell.Transparency = 0
993
Shell.Name = "Shell"
994
Shell.CanCollide = true
995
Shell.BrickColor = BrickColor.new("New Yeller")
996
Shell.Material = "Neon"
997
Shell.CFrame = bhole.CFrame*CFrame.new(-0.2,0.5,0)
998
Shell.Velocity = (bhole.CFrame * CFrame.Angles(math.rad(math.random(20,30)*8), -math.rad(-40), math.rad(-20))).lookVector * 42
999
1000
1001
            local SLight = Instance.new('PointLight', bullethole)
1002
            SLight.Range = 12
1003
            SLight.Color = Color3.new(1,.6,.1)
1004
            SLight.Brightness = 3
1005
            game:service'Debris':AddItem(SLight, .05)
1006
1007
1008
1009
game:service'Debris':AddItem(Shell,7)
1010
1011
so("rbxassetid://966405773",bullethole,1,1)
1012
Bullets(bullethole,0,0,"New Yeller",300,25.5,false,false)      
1013
1014
    
1015
            accuracy1.Position = UDim2.new(0, -recoil*10, .5, -1)
1016
1017
            accuracy2.Position = UDim2.new(1, -8 + recoil*10, .5, -1)
1018
1019
            accuracy3.Position = UDim2.new(.5, -1, 0, -recoil*10)
1020
1021
            accuracy4.Position = UDim2.new(.5, -1, 1, -8 + recoil*10)
1022
            
1023
 Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(math.rad(math.random(-26.35*1.8,26.35*1.8)*recoil),math.rad(math.random(-26.35*1.8,26.35*1.8)*recoil),0.35*1.8*recoil),0.14)
1024
            
1025
            
1026
RW.C0 = clerp(RW.C0, CFrame.new(0, 0.67, -0.25) * angles(math.rad(114), math.rad(0), math.rad(0)),.2)
1027
LW.C0 = clerp(LW.C0,  CFrame.new(-.35, 0.67, -0.66) *  angles(math.rad(104), math.rad(0), math.rad(37)),.4)
1028
HW.C0 = clerp(HW.C0, CFrame.new(0,-0.92,-0.24)*CFrame.Angles(math.rad(-25),math.rad(90),math.rad(0)),0.6)
1029
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-12),math.rad(0),math.rad(0)),.4)
1030
	       attack = false
1031
        
1032
    end
1033
1034
1035
			   	     		 mouse.KeyDown:connect(function(key)
1036
			   	     		     
1037
		     if key == 'r' and attack == false  then
1038
		         reload()
1039
	         end
1040
         end)
1041
1042
1043
	     		 mouse.Button1Down:connect(function()
1044
		     if attack == false and ammo > 0 then
1045
		         if Swing == 2 then
1046
		             Humanoid.WalkSpeed = 16
1047
		             end
1048
		         shoot()
1049
	         end
1050
	         end)
1051
		 
1052
		
1053
		
1054
	     		 mouse.Button2Down:connect(function()
1055
		         aim = true
1056
		         Character.Humanoid.WalkSpeed = 16
1057
		         accuracyFrame.Visible = false
1058
	         end)
1059
		 
1060
		 
1061
		 	     		 mouse.Button2Up:connect(function()
1062
		         aim = false
1063
		         accuracyFrame.Visible = true
1064
	         end)
1065
	         
1066
	         
1067
	         
1068
1069
		
1070
		
1071
								 mouse.KeyDown:connect(function(key)
1072
    if string.byte(key) == 48 then
1073
		Swing = 2
1074
		aim = false
1075
Humanoid.WalkSpeed = 32
1076
end
1077
1078
end)
1079
1080
mouse.KeyUp:connect(function(key)
1081
    if string.byte(key) == 48 then
1082
		Swing = 1
1083
Humanoid.WalkSpeed = 16
1084
1085
end
1086
end)
1087
local look = 0
1088
1089
1090
		
1091
		while true do
1092
		    swait()
1093
		    sine = sine + change
1094
		    local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
1095
local velderp=RootPart.Velocity.y
1096
		    RightArm.LocalTransparencyModifier = 0
1097
		    LeftArm.LocalTransparencyModifier = 0
1098
for _,v in pairs(K1911:GetChildren()) do
1099
        v.LocalTransparencyModifier = 0
1100
end
1101
1102
1103
1104
    if recoil > 0 then
1105
               recoil =  recoil - .025
1106
            accuracy1.Position = UDim2.new(0, -recoil*10, .5, -1)
1107
1108
            accuracy2.Position = UDim2.new(1, -8 + recoil*10, .5, -1)
1109
1110
            accuracy3.Position = UDim2.new(.5, -1, 0, -recoil*10)
1111
1112
            accuracy4.Position = UDim2.new(.5, -1, 1, -8 + recoil*10)
1113
    
1114
    end
1115
    
1116
1117
if attack == false then
1118
    
1119
    HW.C0 = clerp(HW.C0, CFrame.new(0,-0.72,-0.14)*CFrame.Angles(math.rad(-95),math.rad(90),math.rad(0)),0.15)
1120
		    RW.C1 = clerp(RW.C1, CFrame.new(0, 0.5, 0) * angles(-math.asin((mouse.Hit.p-mouse.Origin.p).unit.y),0,0),.25)
1121
LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * angles(-math.asin((mouse.Hit.p-mouse.Origin.p).unit.y),0,0),.25)
1122
Torso.Neck.C1 = clerp(Torso.Neck.C1,necko2 *angles(math.asin((mouse.Hit.p-mouse.Origin.p).unit.y),0,0),.25)
1123
 Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0,0,0),0.08)
1124
if aim == false and torvel <1 then
1125
     cam.FieldOfView = lerp(cam.FieldOfView, 90, 0.076)
1126
    		    RW.C0 = clerp(RW.C0, CFrame.new(0.95, 0.3, -0.2) * angles(math.rad(90), math.rad(0), math.rad(0)+RootPart.RotVelocity.Y / 16),.2)
1127
LW.C0 = clerp(LW.C0, CFrame.new(-.15, 0.3, -.65) * angles(math.rad(80), math.rad(0), math.rad(53)- RootPart.RotVelocity.Y / 32),.2)
1128
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(0)),.25)
1129
end
1130
if aim == false and torvel>1 and torvel<28 then
1131
 cam.FieldOfView = lerp(cam.FieldOfView, 100, 0.076)
1132
 Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0+0.57*math.cos(sine/8),0+0.34*math.sin(sine/4),0),0.15)
1133
 		    RW.C0 = clerp(RW.C0, CFrame.new(0.95, 0.3, -0.2) * angles(math.rad(90), math.rad(0), math.rad(0)+RootPart.RotVelocity.Y / 16),.2)
1134
LW.C0 = clerp(LW.C0, CFrame.new(-.15, 0.3, -.65) * angles(math.rad(80), math.rad(0), math.rad(53)- RootPart.RotVelocity.Y / 32),.2)
1135
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(0)),.25)
1136
end
1137
1138
if aim == false and torvel>28 then
1139
 cam.FieldOfView = lerp(cam.FieldOfView, 120, 0.076)
1140
      Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0+0.67*math.cos(sine/6),0+0.44*math.sin(sine/3),0),0.15)
1141
		    RW.C0 = clerp(RW.C0, CFrame.new(0.95, 0.4, -0.2) * angles(math.rad(60), math.rad(0), math.rad(0)+RootPart.RotVelocity.Y / 16),.2)
1142
LW.C0 = clerp(LW.C0, CFrame.new(-.15, 0.3, -.65) * angles(math.rad(30), math.rad(0), math.rad(53)- RootPart.RotVelocity.Y / 32),.2)
1143
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(12),math.rad(0),math.rad(-16)),.25)
1144
end
1145
1146
if aim == true then
1147
     cam.FieldOfView = lerp(cam.FieldOfView, 80, 0.076)
1148
     
1149
Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(17),math.rad(14),math.rad(0)),.34)
1150
RW.C0 = clerp(RW.C0, CFrame.new(0, 0.33, -0.7) * angles(math.rad(90), math.rad(0), math.rad(0)+RootPart.RotVelocity.Y / 16),.34)
1151
LW.C0 = clerp(LW.C0, CFrame.new(-.65, 0.33, -1.15) * angles(math.rad(80), math.rad(0), math.rad(37)- RootPart.RotVelocity.Y / 32),.34)
1152
end
1153
1154
if aim == true and torvel>1 then
1155
     Humanoid.CameraOffset = Humanoid.CameraOffset:lerp(Vector3.new(0+0.17*math.cos(sine/8),0+0.14*math.sin(sine/4),0),0.15)
1156
     Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(17),math.rad(14),math.rad(0)),.34)
1157
RW.C0 = clerp(RW.C0, CFrame.new(0, 0.33, -0.7) * angles(math.rad(90), math.rad(0), math.rad(0)+RootPart.RotVelocity.Y / 16),.34)
1158
LW.C0 = clerp(LW.C0, CFrame.new(-.65, 0.33, -1.15) * angles(math.rad(80), math.rad(0), math.rad(37)- RootPart.RotVelocity.Y / 32),.34)
1159
end
1160
end
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
    if 0 < #Effects then
1178
        for e = 1, #Effects do
1179
          if Effects[e] ~= nil then
1180
            local Thing = Effects[e]
1181
            if Thing ~= nil then
1182
              local Part = Thing[1]
1183
              local Mode = Thing[2]
1184
              local Delay = Thing[3]
1185
              local IncX = Thing[4]
1186
              local IncY = Thing[5]
1187
              local IncZ = Thing[6]
1188
              if Thing[2] == "CylinderClang" then
1189
                if Thing[3] <= 1 then
1190
                  Thing[1].CFrame = Thing[1].CFrame * CFrame.new(0, 2.5 * Thing[5], 0) * CFrame.fromEulerAnglesXYZ(Thing[6], 0, 0)
1191
                  Thing[7] = Thing[1].CFrame
1192
                  effect("New Yeller", 0, Thing[8], Thing[7])
1193
                  Thing[8] = Thing[7]
1194
                  Thing[3] = Thing[3] + Thing[4]
1195
                else
1196
                  Part.Parent = nil
1197
                  table.remove(Effects, e)
1198
                end
1199
              end
1200
              if Thing[2] == "showDamage" then
1201
                if Thing[6] < Thing[5] then
1202
                  Thing[6] = Thing[6] + 1
1203
                else
1204
                  if Thing[6] < Thing[7] then
1205
                    Thing[4].position = Thing[4].position + vt(0, -0.2, 0)
1206
                    Thing[6] = Thing[6] + 1
1207
                  else
1208
                    if Thing[6] < Thing[8] then
1209
                      Thing[6] = Thing[6] + 1
1210
                    else
1211
                      if Thing[6] < Thing[9] then
1212
                        Thing[6] = Thing[6] + 1
1213
                        Thing[4].position = Thing[4].position + vt(0, 0.2, 0)
1214
                        Thing[3].TextStrokeTransparency = Thing[3].TextStrokeTransparency + 0.1
1215
                        Thing[3].TextTransparency = Thing[3].TextTransparency + 0.1
1216
                      else
1217
                        Thing[1].Parent = nil
1218
                        table.remove(Effects, e)
1219
                      end
1220
                    end
1221
                  end
1222
                end
1223
              end
1224
              if Thing[2] == "PartiEmi" then
1225
                Thing[3] = Thing[3] - 1
1226
                if Thing[3] <= 0 then
1227
                  Thing[1].Enabled = false
1228
                  table.remove(Effects, e)
1229
                end
1230
              end
1231
              if Thing[2] == "AdjuEff" then
1232
                if 0 < Thing[3] then
1233
                  Thing[3] = Thing[3] - 1
1234
                  Thing[1].Size = Thing[1].Size + UDim2.new(0.2, 0, 0.2, 0)
1235
                  Thing[1].StudsOffset = Thing[1].StudsOffset + vt(0, -0.2, 0)
1236
                  Thing[4].ImageTransparency = Thing[4].ImageTransparency + 0.1
1237
                else
1238
                  Thing[1].Parent = nil
1239
                  table.remove(Effects, e)
1240
                end
1241
              end
1242
              if Thing[2] ~= "Shoot" and Thing[2] ~= "DecreaseStat" and Thing[2] ~= "Wave" and Thing[2] ~= "FireWave" and Thing[2] ~= "showDamage" and Thing[2] ~= "PartiEmi" and Thing[2] ~= "AdjuEff" then
1243
                if Thing[1].Transparency <= 1 then
1244
                  if Thing[2] == "Block1" then
1245
                    Thing[1].CFrame = Thing[1].CFrame * euler(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
1246
                    Mesh = Thing[7]
1247
                    Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
1248
                    Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1249
                  else
1250
                    if Thing[2] == "Block2" then
1251
                      Thing[1].CFrame = Thing[1].CFrame
1252
                      Mesh = Thing[7]
1253
                      Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
1254
                      Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1255
                    else
1256
                      if Thing[2] == "Block3" then
1257
                        Thing[9] = Thing[9] + 0.5
1258
                        Thing[1].CFrame = Thing[8] * cf(0, Thing[9], 0)
1259
                        Thing[1].CFrame = Thing[1].CFrame * euler(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
1260
                        Mesh = Thing[7]
1261
                        Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
1262
                        Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1263
                      else
1264
                        if Thing[2] == "Skull" then
1265
                          Thing[1].CFrame = Thing[1].CFrame * cf(0, Thing[8] / 2, -Thing[8])
1266
                          Mesh = Thing[7]
1267
                          Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
1268
                          Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1269
                        else
1270
                          if Thing[2] == "Cylinder" then
1271
                            Mesh = Thing[7]
1272
                            Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
1273
                            Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1274
                          else
1275
                            if Thing[2] == "Cylinder2" then
1276
                              Thing[1].CFrame = Thing[1].CFrame * cf(0, Thing[8], 0)
1277
                              Mesh = Thing[7]
1278
                              Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
1279
                              Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1280
                            else
1281
                              if Thing[2] == "Blood" then
1282
                                Mesh = Thing[7]
1283
                                Thing[1].CFrame = Thing[1].CFrame * cf(0, 0.5, 0)
1284
                                Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6])
1285
                                Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1286
                              else
1287
                                if Thing[2] == "Elec" then
1288
                                  Mesh = Thing[10]
1289
                                  Mesh.Scale = Mesh.Scale + vt(Thing[7], Thing[8], Thing[9])
1290
                                  Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1291
                                else
1292
                                  if Thing[2] == "Disappear" then
1293
                                    Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1294
                                  end
1295
                                end
1296
                              end
1297
                            end
1298
                          end
1299
                        end
1300
                      end
1301
                    end
1302
                  end
1303
                else
1304
                  Part.Parent = nil
1305
                  table.remove(Effects, e)
1306
        end
1307
        end
1308
          end
1309
        end
1310
      end
1311
    end
1312
1313
1314
end