View difference between Paste ID: pe2dkLtx and vgz5yrhx
SHOW: | | - or go back to the newest paste.
1
if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
2
local Player,Mouse,mouse,UserInputService,ContextActionService = owner
3
do
4
	print("FE Compatibility code by Mokiros")
5
	script.Parent = Player.Character
6
7
	--RemoteEvent for communicating
8
	local Event = Instance.new("RemoteEvent")
9
	Event.Name = "UserInput_Event"
10
11
	--Fake event to make stuff like Mouse.KeyDown work
12
	local function fakeEvent()
13
		local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
14
		t.connect = t.Connect
15
		return t
16
	end
17
18
	--Creating fake input objects with fake variables
19
    local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
20
	local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
21
	local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
22
		CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
23
	end}
24
	--Merged 2 functions into one by checking amount of arguments
25
	CAS.UnbindAction = CAS.BindAction
26
27
	--This function will trigger the events that have been :Connect()'ed
28
	local function te(self,ev,...)
29
		local t = m[ev]
30
		if t and t._fakeEvent and t.Function then
31
			t.Function(...)
32
		end
33
	end
34
	m.TrigEvent = te
35
	UIS.TrigEvent = te
36
37
	Event.OnServerEvent:Connect(function(plr,io)
38
	    if plr~=Player then return end
39
		if io.isMouse then
40
			m.Target = io.Target
41
			m.Hit = io.Hit
42
		else
43
			local b = io.UserInputState == Enum.UserInputState.Begin
44
			if io.UserInputType == Enum.UserInputType.MouseButton1 then
45
				return m:TrigEvent(b and "Button1Down" or "Button1Up")
46
			end
47
			for _,t in pairs(CAS.Actions) do
48
				for _,k in pairs(t.Keys) do
49
					if k==io.KeyCode then
50
						t.Function(t.Name,io.UserInputState,io)
51
					end
52
				end
53
			end
54
			m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
55
			UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
56
	    end
57
	end)
58
	Event.Parent = NLS([==[
59
	local Player = owner
60
	local Event = script:WaitForChild("UserInput_Event")
61
62
	local UIS = game:GetService("UserInputService")
63
	local input = function(io,a)
64
		if a then return end
65
		--Since InputObject is a client-side instance, we create and pass table instead
66
		Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
67
	end
68
	UIS.InputBegan:Connect(input)
69
	UIS.InputEnded:Connect(input)
70
71
	local h,t
72
	--Give the server mouse data 30 times every second, but only if the values changed
73
	--If player is not moving their mouse, client won't fire events
74
	while wait(1/30) do
75
		if h~=Mouse.Hit or t~=Mouse.Target then
76
			h,t=Mouse.Hit,Mouse.Target
77
			Event:FireServer({isMouse=true,Target=t,Hit=h})
78
		end
79
	end]==],Player.Character)
80
	Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
81
end
82
83
function giant(p, size)	
84
	local pchar = p.Character
85
	if pchar then
86
		local function scale(chr,scl)
87
		
88
			for _,v in pairs(pchar:GetChildren()) do
89
				if v:IsA("Hat") then
90
					v:Clone()
91
					v.Parent = game.Lighting
92
				end
93-
local plr = game.Players.LocalPlayer
93+
94
				
95
		    local Head = chr['Head']
96
		    local Torso = chr['Torso']
97
		    local LA = chr['Left Arm']
98
		    local RA = chr['Right Arm']
99-
local sgui = Instance.new("ScreenGui", game.Players.LocalPlayer.PlayerGui)
99+
100
		    local RL = chr['Right Leg']
101
		    local HRP = chr['HumanoidRootPart']
102
		
103
		    wait(0.1)
104
		   
105
		    Head.formFactor = 3
106
		    Torso.formFactor = 3
107
		    LA.formFactor = 3
108
		    RA.formFactor = 3
109
		    LL.formFactor = 3
110
		    RL.formFactor = 3
111
		    HRP.formFactor = 3
112
		    
113
		    Head.Size = Vector3.new(scl * 2, scl, scl)
114
		    Torso.Size = Vector3.new(scl * 2, scl * 2, scl)
115
		    LA.Size = Vector3.new(scl, scl * 2, scl)
116
		    RA.Size = Vector3.new(scl, scl * 2, scl)
117
		    LL.Size = Vector3.new(scl, scl * 2, scl)
118
		    RL.Size = Vector3.new(scl, scl * 2, scl)
119
		    HRP.Size = Vector3.new(scl * 2, scl * 2, scl)
120
		    
121
		    local Motor1 = Instance.new('Motor6D', Torso)
122
		    Motor1.Part0 = Torso
123
		    Motor1.Part1 = Head
124
	    	Motor1.C0 = CFrame.new(0, 1 * scl, 0) * CFrame.Angles(-1.6, 0, 3.1)
125
	    	Motor1.C1 = CFrame.new(0, -0.5 * scl, 0) * CFrame.Angles(-1.6, 0, 3.1)
126
	    	Motor1.Name = "Neck"
127
				    
128
	    	local Motor2 = Instance.new('Motor6D', Torso)
129
	    	Motor2.Part0 = Torso
130
	    	Motor2.Part1 = LA
131
	    	Motor2.C0 = CFrame.new(-1 * scl, 0.5 * scl, 0) * CFrame.Angles(0, -1.6, 0)
132
	    	Motor2.C1 = CFrame.new(0.5 * scl, 0.5 * scl, 0) * CFrame.Angles(0, -1.6, 0)
133
	    	Motor2.Name = "Left Shoulder"
134
	    	
135
	    	local Motor3 = Instance.new('Motor6D', Torso)
136
	   		Motor3.Part0 = Torso
137
	    	Motor3.Part1 = RA
138
	    	Motor3.C0 = CFrame.new(1 * scl, 0.5 * scl, 0) * CFrame.Angles(0, 1.6, 0)
139
	    	Motor3.C1 = CFrame.new(-0.5 * scl, 0.5 * scl, 0) * CFrame.Angles(0, 1.6, 0)
140
	    	Motor3.Name = "Right Shoulder"
141
	    	
142
	    	local Motor4 = Instance.new('Motor6D', Torso)
143
	    	Motor4.Part0 = Torso
144
	    	Motor4.Part1 = LL
145
	    	Motor4.C0 = CFrame.new(-1 * scl, -1 * scl, 0) * CFrame.Angles(0, -1.6, 0)
146
	    	Motor4.C1 = CFrame.new(-0.5 * scl, 1 * scl, 0) * CFrame.Angles(0, -1.6, 0)
147
	    	Motor4.Name = "Left Hip"
148
	    	
149
	    	local Motor5 = Instance.new('Motor6D', Torso)
150
	    	Motor5.Part0 = Torso
151
	    	Motor5.Part1 = RL
152
	    	Motor5.C0 = CFrame.new(1 * scl, -1 * scl, 0) * CFrame.Angles(0, 1.6, 0)
153
	    	Motor5.C1 = CFrame.new(0.5 * scl, 1 * scl, 0) * CFrame.Angles(0, 1.6, 0)
154
	    	Motor5.Name = "Right Hip"
155
	    	
156
	    	local Motor6 = Instance.new('Motor6D', HRP)
157
	    	Motor6.Part0 = HRP
158
	    	Motor6.Part1 = Torso
159
	    	Motor6.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(-1.6, 0, -3.1)
160
	    	Motor6.C1 = CFrame.new(0, 0, 0) * CFrame.Angles(-1.6, 0, -3.1)
161
	    	    
162
		end
163
		
164
		scale(pchar, size)
165
		pchar.Humanoid.WalkSpeed = 15 * size
166
	
167
		for _,v in pairs(game.Lighting:GetChildren()) do
168
			if v:IsA("Hat") then
169
				v.Parent = pchar
170
			end
171
		end
172
	end
173
end
174
175
local plr = owner
176
giant(plr,1)
177
178
179
local csize = 1
180
181
local sgui = Instance.new("ScreenGui", owner.PlayerGui)
182
local base = Instance.new("Frame", sgui)
183
base.BackgroundTransparency = 1
184
base.Size = UDim2.new(0, 110, 0, 200)
185
base.Position = UDim2.new(1, -120, 1, -180)
186
local indicator = Instance.new("TextLabel", base)
187
indicator.Size = UDim2.new(1, 0, 0, 25)
188
indicator.TextColor3 = Color3.new(1, 1, 1)
189
indicator.BackgroundTransparency = 0
190
indicator.FontSize = Enum.FontSize.Size18
191
indicator.Font = Enum.Font.SourceSans
192
indicator.Text = "Current Size: 3"
193
local PlusOne = Instance.new("TextButton", base)
194
PlusOne.BackgroundColor3 = Color3.new(214/255, 214/255, 214/255)
195
PlusOne.Position = UDim2.new(0, 0, 0, 40)
196
PlusOne.Size = UDim2.new(1, 0, 0.5, -50)
197
PlusOne.BorderSizePixel = 2
198
PlusOne.Font = Enum.Font.SourceSansBold
199
PlusOne.FontSize = Enum.FontSize.Size24
200
PlusOne.Text = "+.1 Size"
201
local MinusOne = Instance.new("TextButton", base)
202
MinusOne.BackgroundColor3 = Color3.new(214/255, 214/255, 214/255)
203
MinusOne.Position = UDim2.new(0, 0, 0.5, 10)
204
MinusOne.Size = UDim2.new(1, 0, 0.5, -50)
205
MinusOne.Text = "-.1 Size"
206
MinusOne.BorderSizePixel = 2
207
MinusOne.Font = Enum.Font.SourceSansBold
208
MinusOne.FontSize = Enum.FontSize.Size24
209
210
PlusOne.MouseButton1Down:connect(function()
211
	csize = csize + .1
212
	giant(plr, csize)
213
	indicator.Text = "Current Size: "..tostring(csize)
214
end)
215
216
MinusOne.MouseButton1Down:connect(function()
217
	csize = csize - .1
218
	giant(plr, csize)
219
	indicator.Text = "Current Size: "..tostring(csize)
220
end)