View difference between Paste ID: D6RrmMCw and mxTVnJfQ
SHOW: | | - or go back to the newest paste.
1
-- This script has been converted to FE by iPxter
2
3-
me = game.Players.LocalPlayer.Name 
3+
4
if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
5
local Player,Mouse,mouse,UserInputService,ContextActionService = owner
6
do
7
	print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
8
	script.Parent = Player.Character
9
10
	--RemoteEvent for communicating
11
	local Event = Instance.new("RemoteEvent")
12
	Event.Name = "UserInput_Event"
13
14
	--Fake event to make stuff like Mouse.KeyDown work
15
	local function fakeEvent()
16
		local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
17
		t.connect = t.Connect
18
		return t
19
	end
20
21
	--Creating fake input objects with fake variables
22
    local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
23
	local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
24
	local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
25
		CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
26
	end}
27
	--Merged 2 functions into one by checking amount of arguments
28
	CAS.UnbindAction = CAS.BindAction
29
30
	--This function will trigger the events that have been :Connect()'ed
31
	local function te(self,ev,...)
32
		local t = m[ev]
33
		if t and t._fakeEvent and t.Function then
34
			t.Function(...)
35
		end
36
	end
37
	m.TrigEvent = te
38
	UIS.TrigEvent = te
39
40
	Event.OnServerEvent:Connect(function(plr,io)
41
	    if plr~=Player then return end
42
		if io.isMouse then
43
			m.Target = io.Target
44
			m.Hit = io.Hit
45
		else
46
			local b = io.UserInputState == Enum.UserInputState.Begin
47
			if io.UserInputType == Enum.UserInputType.MouseButton1 then
48
				return m:TrigEvent(b and "Button1Down" or "Button1Up")
49
			end
50
			for _,t in pairs(CAS.Actions) do
51
				for _,k in pairs(t.Keys) do
52
					if k==io.KeyCode then
53
						t.Function(t.Name,io.UserInputState,io)
54
					end
55
				end
56
			end
57
			m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
58
			UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
59
	    end
60
	end)
61
	Event.Parent = NLS([==[
62
	local Player = game:GetService("Players").LocalPlayer
63
	local Event = script:WaitForChild("UserInput_Event")
64
65
	local UIS = game:GetService("UserInputService")
66
	local input = function(io,a)
67
		if a then return end
68
		--Since InputObject is a client-side instance, we create and pass table instead
69
		Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
70
	end
71
	UIS.InputBegan:Connect(input)
72
	UIS.InputEnded:Connect(input)
73
74
	local Mouse = Player:GetMouse()
75
	local h,t
76
	--Give the server mouse data 30 times every second, but only if the values changed
77
	--If player is not moving their mouse, client won't fire events
78
	while wait(1/30) do
79
		if h~=Mouse.Hit or t~=Mouse.Target then
80
			h,t=Mouse.Hit,Mouse.Target
81
			Event:FireServer({isMouse=true,Target=t,Hit=h})
82
		end
83
	end]==],Player.Character)
84
	Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
85
end
86
color1 = "Dark grey" 
87
color2 ="Really black" 
88
me = owner.Name 
89
lord1 = game.Players[me]
90
lord2 = lord1.Character
91
mod = Instance.new("Model") 
92
mod.Parent = lord2
93
mod.Name = ""..me.."'s Elevator" 
94
hum = Instance.new("Humanoid") 
95
hum.MaxHealth = 0 
96
hum.Parent = mod 
97
eng = Instance.new("SpawnLocation") 
98
eng.Parent = mod 
99
eng.Name = "Head" 
100
eng.Size = Vector3.new(12,1,12) 
101
eng.BrickColor = BrickColor.new(color1) 
102
eng.TopSurface = "Smooth" 
103
eng.BottomSurface = "Smooth" 
104
eng.Position = lord1.Character.Torso.Position + Vector3.new(0,100,0) 
105
control = Instance.new("VehicleSeat") 
106
control.Parent = mod 
107
control.Size = Vector3.new(2,1,2) 
108
control.BrickColor = BrickColor.new("Lime green") 
109
control.TopSurface = "Smooth" 
110
control.BottomSurface = "Smooth" 
111
control:BreakJoints() 
112
weld = Instance.new("Weld") 
113
weld.Parent = eng 
114
weld.Part0 = eng 
115
weld.Part1 = control 
116
weld.C0 = CFrame.new(0,1,0) * CFrame.Angles(0,math.pi,0) 
117
s1 = Instance.new("Seat") 
118
s1.Parent = mod 
119
s1.Size = Vector3.new(2,1,2) 
120
s1.BrickColor = BrickColor.new(color2) 
121
s1.BottomSurface = "Smooth" 
122
s1:BreakJoints() 
123
weld = Instance.new("Weld") 
124
weld.Parent = eng 
125
weld.Part0 = eng 
126
weld.Part1 = s1 
127
weld.C0 = CFrame.new(5,1,5) * CFrame.Angles(0,math.pi,0) 
128
s2 = Instance.new("Seat") 
129
s2.Parent = mod 
130
s2.Size = Vector3.new(2,1,2) 
131
s2.BrickColor = BrickColor.new(color2) 
132
s2.BottomSurface = "Smooth" 
133
s2:BreakJoints() 
134
weld = Instance.new("Weld") 
135
weld.Parent = eng 
136
weld.Part0 = eng 
137
weld.Part1 = s2 
138
weld.C0 = CFrame.new(5,1,-5) * CFrame.Angles(0,math.pi,0) 
139
s3 = Instance.new("Seat") 
140
s3.Parent = mod 
141
s3.Size = Vector3.new(2,1,2) 
142
s3.BrickColor = BrickColor.new(color2) 
143
s3.BottomSurface = "Smooth" 
144
s3:BreakJoints() 
145
weld = Instance.new("Weld") 
146
weld.Parent = eng 
147
weld.Part0 = eng 
148
weld.Part1 = s3 
149
weld.C0 = CFrame.new(-5,1,-5) * CFrame.Angles(0,math.pi,0) 
150
s4 = Instance.new("Seat") 
151
s4.Parent = mod 
152
s4.Size = Vector3.new(2,1,2) 
153
s4.BrickColor = BrickColor.new(color2) 
154
s4.BottomSurface = "Smooth" 
155
s4:BreakJoints() 
156
weld = Instance.new("Weld") 
157
weld.Parent = eng 
158
weld.Part0 = eng 
159
weld.Part1 = s4 
160
weld.C0 = CFrame.new(-5,1,5) * CFrame.Angles(0,math.pi,0) 
161
162
163
-------Gui--------by lord1sheen 
164
local starter = Instance.new("ScreenGui") 
165
starter.Parent = lord1.PlayerGui 
166
167
script.Parent = starter 
168
169
170
local fu1 = Instance.new("Frame") 
171
fu1.Parent = starter 
172
fu1.Position = UDim2.new(0,1000,0,540) 
173
174
local u1 = Instance.new("TextButton") 
175
u1.Text = "+30" 
176
u1.Size = UDim2.new(0,40,0,20) 
177
u1.Parent = fu1 
178
u1.FontSize = "Size12" 
179
u1.BorderSizePixel = 3 
180
u1.Transparency = 0.2 
181
u1.Name = "u" 
182
u1.TextColor = BrickColor.new("Really red") 
183
u1.BackgroundColor = BrickColor.new("Really black") 
184
u1.Position = UDim2.new(0,0,0,-200) 
185
function click() 
186
for i = 1, 10 do 
187
wait() 
188
lord2[mod.Name].Head.Hover.position = Vector3.new(lord2[mod.Name].Head.Hover.position.X, lord2[mod.Name].Head.Hover.position.Y+3, lord2[mod.Name].Head.Hover.position.Z)
189
wait(0.1)
190
end 
191
end 
192
u1.MouseButton1Down:connect(click) 
193
194
195
local fu2 = Instance.new("Frame") 
196
fu2.Parent = starter 
197
fu2.Position = UDim2.new(0,1000,0,560) 
198
199
local u2 = Instance.new("TextButton") 
200
u2.Text = "+22.5" 
201
u2.Size = UDim2.new(0,40,0,20) 
202
u2.Parent = fu2 
203
u2.FontSize = "Size12" 
204
u2.BorderSizePixel = 3 
205
u2.Transparency = 0.2 
206
u2.Name = "u" 
207
u2.TextColor = BrickColor.new("Really red") 
208
u2.BackgroundColor = BrickColor.new("Really black") 
209
u2.Position = UDim2.new(0,0,0,-200) 
210
function click() 
211
for i = 1, 10 do 
212
wait() 
213
lord2[mod.Name].Head.Hover.position = Vector3.new(lord2[mod.Name].Head.Hover.position.X, lord2[mod.Name].Head.Hover.position.Y+2.25, lord2[mod.Name].Head.Hover.position.Z)
214
wait(0.1)
215
end 
216
end 
217
u2.MouseButton1Down:connect(click) 
218
219
220
local fu3 = Instance.new("Frame") 
221
fu3.Parent = starter 
222
fu3.Position = UDim2.new(0,1000,0,580) 
223
224
local u3 = Instance.new("TextButton") 
225
u3.Text = "+15" 
226
u3.Size = UDim2.new(0,40,0,20) 
227
u3.Parent = fu3 
228
u3.FontSize = "Size12" 
229
u3.BorderSizePixel = 3 
230
u3.Transparency = 0.2 
231
u3.Name = "u" 
232
u3.TextColor = BrickColor.new("Really red") 
233
u3.BackgroundColor = BrickColor.new("Really black") 
234
u3.Position = UDim2.new(0,0,0,-200) 
235
function click() 
236
for i = 1, 10 do 
237
wait() 
238
lord2[mod.Name].Head.Hover.position = Vector3.new(lord2[mod.Name].Head.Hover.position.X, lord2[mod.Name].Head.Hover.position.Y+1.5, lord2[mod.Name].Head.Hover.position.Z)
239
wait(0.1)
240
end 
241
end 
242
u3.MouseButton1Down:connect(click) 
243
244
245
local fu4 = Instance.new("Frame") 
246
fu4.Parent = starter 
247
fu4.Position = UDim2.new(0,1000,0,600) 
248
249
local u4 = Instance.new("TextButton") 
250
u4.Text = "+7.5" 
251
u4.Size = UDim2.new(0,40,0,20) 
252
u4.Parent = fu4 
253
u4.FontSize = "Size12" 
254
u4.BorderSizePixel = 3 
255
u4.Transparency = 0.2 
256
u4.Name = "u" 
257
u4.TextColor = BrickColor.new("Really red") 
258
u4.BackgroundColor = BrickColor.new("Really black") 
259
u4.Position = UDim2.new(0,0,0,-200) 
260
function click() 
261
for i = 1, 10 do 
262
wait() 
263
lord2[mod.Name].Head.Hover.position = Vector3.new(lord2[mod.Name].Head.Hover.position.X, lord2[mod.Name].Head.Hover.position.Y+0.75, lord2[mod.Name].Head.Hover.position.Z)
264
wait(0.1)
265
end 
266
end 
267
u4.MouseButton1Down:connect(click) 
268
269
270
local fd4 = Instance.new("Frame") 
271
fd4.Parent = starter 
272
fd4.Position = UDim2.new(0,1000,0,620) 
273
274
local d4 = Instance.new("TextButton") 
275
d4.Text = "-7.5" 
276
d4.Size = UDim2.new(0,40,0,20) 
277
d4.Parent = fd4 
278
d4.FontSize = "Size12" 
279
d4.BorderSizePixel = 3 
280
d4.Transparency = 0.2 
281
d4.Name = "d" 
282
d4.TextColor = BrickColor.new("Really red") 
283
d4.BackgroundColor = BrickColor.new("Really black") 
284
d4.Position = UDim2.new(0,0,0,-200) 
285
function click() 
286
for i = 1, 10 do 
287
wait() 
288
lord2[mod.Name].Head.Hover.position = Vector3.new(lord2[mod.Name].Head.Hover.position.X, lord2[mod.Name].Head.Hover.position.Y-0.75, lord2[mod.Name].Head.Hover.position.Z)
289
wait(0.1)
290
end 
291
end 
292
d4.MouseButton1Down:connect(click) 
293
294
295
local fd3 = Instance.new("Frame") 
296
fd3.Parent = starter 
297
fd3.Position = UDim2.new(0,1000,0,640) 
298
299
local d3 = Instance.new("TextButton") 
300
d3.Text = "-15" 
301
d3.Size = UDim2.new(0,40,0,20) 
302
d3.Parent = fd3 
303
d3.FontSize = "Size12" 
304
d3.BorderSizePixel = 3 
305
d3.Transparency = 0.2 
306
d3.Name = "d" 
307
d3.TextColor = BrickColor.new("Really red") 
308
d3.BackgroundColor = BrickColor.new("Really black") 
309
d3.Position = UDim2.new(0,0,0,-200) 
310
function click() 
311
for i = 1, 10 do 
312
wait() 
313
lord2[mod.Name].Head.Hover.position = Vector3.new(lord2[mod.Name].Head.Hover.position.X, lord2[mod.Name].Head.Hover.position.Y-1.5, lord2[mod.Name].Head.Hover.position.Z)
314
wait(0.1)
315
end 
316
end 
317
d3.MouseButton1Down:connect(click) 
318
319
320
local fd2 = Instance.new("Frame") 
321
fd2.Parent = starter 
322
fd2.Position = UDim2.new(0,1000,0,660) 
323
324
local d2 = Instance.new("TextButton") 
325
d2.Text = "-22.5" 
326
d2.Size = UDim2.new(0,40,0,20) 
327
d2.Parent = fd2 
328
d2.FontSize = "Size12" 
329
d2.BorderSizePixel = 3 
330
d2.Transparency = 0.2 
331
d2.Name = "d" 
332
d2.TextColor = BrickColor.new("Really red") 
333
d2.BackgroundColor = BrickColor.new("Really black") 
334
d2.Position = UDim2.new(0,0,0,-200) 
335
function click() 
336
for i = 1, 10 do 
337
wait() 
338
lord2[mod.Name].Head.Hover.position = Vector3.new(lord2[mod.Name].Head.Hover.position.X, lord2[mod.Name].Head.Hover.position.Y-2.25, lord2[mod.Name].Head.Hover.position.Z)
339
wait(0.1)
340
end 
341
end 
342
d2.MouseButton1Down:connect(click) 
343
344
345
local fd1 = Instance.new("Frame") 
346
fd1.Parent = starter 
347
fd1.Position = UDim2.new(0,1000,0,680) 
348
349
local d1 = Instance.new("TextButton") 
350
d1.Text = "-30" 
351
d1.Size = UDim2.new(0,40,0,20) 
352
d1.Parent = fd1 
353
d1.FontSize = "Size12" 
354
d1.BorderSizePixel = 3 
355
d1.Transparency = 0.2 
356
d1.Name = "d" 
357
d1.TextColor = BrickColor.new("Really red") 
358
d1.BackgroundColor = BrickColor.new("Really black") 
359
d1.Position = UDim2.new(0,0,0,-200) 
360
function click() 
361
for i = 1, 10 do 
362
wait() 
363
lord2[mod.Name].Head.Hover.position = Vector3.new(lord2[mod.Name].Head.Hover.position.X, lord2[mod.Name].Head.Hover.position.Y-3, lord2[mod.Name].Head.Hover.position.Z)
364
wait(0.1)
365
end 
366
end 
367
d1.MouseButton1Down:connect(click) 
368
369
370
371
-------AI program--------by zethal
372
373
374
---Driving Systems--- 
375
bv = Instance.new("BodyVelocity") 
376
bv.Parent = eng 
377
bv.maxForce = Vector3.new(math.huge,0,math.huge) 
378
bv.velocity = Vector3.new(0,-5,0) 
379
bav = Instance.new("BodyAngularVelocity") 
380
bav.Parent = eng 
381
bav.maxTorque = Vector3.new(math.huge,math.huge,math.huge) 
382
bav.angularvelocity = Vector3.new(0,0,0) 
383
hov = Instance.new("BodyPosition") 
384
hov.Name = "Hover" 
385
hov.Parent = eng 
386
hov.maxForce = Vector3.new(0,math.huge,0) 
387
hov.position = Vector3.new(0,9,0) 
388
bg = Instance.new("BodyGyro") 
389
bg.Parent = eng 
390
bg.maxTorque = Vector3.new(math.huge,0,math.huge) 
391
bg.P = 3e+003 
392
bg.D = 500 
393
parts = mod:GetChildren() 
394
for i = 1, #parts do 
395
if parts[i].className == "Part" or parts[i].className == "WedgePart" then 
396
parts[i].Locked = true 
397
end 
398
end 
399
400
401
while true do 
402
wait(0) 
403
if control.Throttle == 1 then 
404
bv.velocity = eng.CFrame.lookVector*-31 
405
end 
406
if control.Throttle == -1 then 
407
bv.velocity = eng.CFrame.lookVector*31 
408
end 
409
if control.Throttle == 0 then 
410
bv.velocity = Vector3.new(0,0,0) 
411
end 
412
if control.Steer == 1 then 
413
bav.angularvelocity = Vector3.new(0,-1.5,0) 
414
end 
415
if control.Steer == -1 then 
416
bav.angularvelocity = Vector3.new(0,1.5,0) 
417
end 
418
if control.Steer == 0 then 
419
bav.angularvelocity = Vector3.new(0,0,0) 
420
end 
421
422
end