Upscalefanatic3

(Roblox) [FE] Autotrain 2.5 | VOID

Jun 6th, 2020
292
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  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,player,game,owner = owner,game
  3. local RealPlayer = Player
  4. do
  5. local rp = RealPlayer
  6. script.Parent = rp.Character
  7.  
  8. --RemoteEvent for communicating
  9. local Event = Instance.new("RemoteEvent")
  10. Event.Name = "UserInput_Event"
  11.  
  12. --Fake event to make stuff like Mouse.KeyDown work
  13. local function fakeEvent()
  14. local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end}
  15. t.connect = t.Connect
  16. return t
  17. end
  18.  
  19. --Creating fake input objects with fake variables
  20. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  21. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  22. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  23. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  24. end}
  25. --Merged 2 functions into one by checking amount of arguments
  26. CAS.UnbindAction = CAS.BindAction
  27.  
  28. --This function will trigger the events that have been :Connect()'ed
  29. local function te(self,ev,...)
  30. local t = m[ev]
  31. if t and t._fakeEvent then
  32. for _,f in pairs(t.Functions) do
  33. f(...)
  34. end
  35. end
  36. end
  37. m.TrigEvent = te
  38. UIS.TrigEvent = te
  39.  
  40. Event.OnServerEvent:Connect(function(plr,io)
  41. if plr~=rp then return end
  42. m.Target = io.Target
  43. m.Hit = io.Hit
  44. if not io.isMouse then
  45. local b = io.UserInputState == Enum.UserInputState.Begin
  46. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  47. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  48. end
  49. for _,t in pairs(CAS.Actions) do
  50. for _,k in pairs(t.Keys) do
  51. if k==io.KeyCode then
  52. t.Function(t.Name,io.UserInputState,io)
  53. end
  54. end
  55. end
  56. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  57. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  58. end
  59. end)
  60. Event.Parent = NLS([==[
  61. local Player = game:GetService("Players").LocalPlayer
  62. local Event = script:WaitForChild("UserInput_Event")
  63.  
  64. local Mouse = Player:GetMouse()
  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,Hit=Mouse.Hit,Target=Mouse.Target})
  70. end
  71. UIS.InputBegan:Connect(input)
  72. UIS.InputEnded:Connect(input)
  73.  
  74. local h,t
  75. --Give the server mouse data 30 times every second, but only if the values changed
  76. --If player is not moving their mouse, client won't fire events
  77. while wait(1/30) do
  78. if h~=Mouse.Hit or t~=Mouse.Target then
  79. h,t=Mouse.Hit,Mouse.Target
  80. Event:FireServer({isMouse=true,Target=t,Hit=h})
  81. end
  82. end]==],Player.Character)
  83.  
  84. ----Sandboxed game object that allows the usage of client-side methods and services
  85. --Real game object
  86. local _rg = game
  87.  
  88. --Metatable for fake service
  89. local fsmt = {
  90. __index = function(self,k)
  91. local s = rawget(self,"_RealService")
  92. if s then return s[k] end
  93. end,
  94. __newindex = function(self,k,v)
  95. local s = rawget(self,"_RealService")
  96. if s then s[k]=v end
  97. end,
  98. __call = function(self,...)
  99. local s = rawget(self,"_RealService")
  100. if s then return s(...) end
  101. end
  102. }
  103. local function FakeService(t,RealService)
  104. t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService
  105. return setmetatable(t,fsmt)
  106. end
  107.  
  108. --Fake game object
  109. local g = {
  110. GetService = function(self,s)
  111. return self[s]
  112. end,
  113. Players = FakeService({
  114. LocalPlayer = FakeService({GetMouse=function(self)return m end},Player)
  115. },"Players"),
  116. UserInputService = FakeService(UIS,"UserInputService"),
  117. ContextActionService = FakeService(CAS,"ContextActionService"),
  118. }
  119. rawset(g.Players,"localPlayer",g.Players.LocalPlayer)
  120. g.service = g.GetService
  121.  
  122. g.RunService = FakeService({
  123. RenderStepped = _rg:GetService("RunService").Heartbeat,
  124. BindToRenderStep = function(self,name,_,fun)
  125. self._btrs[name] = self.Heartbeat:Connect(fun)
  126. end,
  127. UnbindFromRenderStep = function(self,name)
  128. self._btrs[name]:Disconnect()
  129. end,
  130. },"RunService")
  131.  
  132. setmetatable(g,{
  133. __index=function(self,s)
  134. return _rg:GetService(s) or typeof(_rg[s])=="function"
  135. and function(_,...)return _rg[s](_rg,...)end or _rg[s]
  136. end,
  137. __newindex = fsmt.__newindex,
  138. __call = fsmt.__call
  139. })
  140. --Changing owner to fake player object to support owner:GetMouse()
  141. game,owner = g,g.Players.LocalPlayer
  142. end
  143.  
  144.  
  145. --[[
  146. script by tollepuxis
  147. used on dragon ball rage
  148. autosave
  149. auto-ki
  150. auto-combat
  151. keybinds:
  152. Z - Force-Charge
  153. X - Force-Ki
  154. V - Force-Combat
  155. --]]
  156.  
  157. local Player = game:GetService("Players").LocalPlayer
  158. local PlayerGui = Player.PlayerGui
  159. local mouse = Player:GetMouse()
  160. local KiArm = "Right"
  161. function Notify(txt,type)
  162. local tgui = Instance.new("ScreenGui")
  163. local tlabel = Instance.new("TextLabel")
  164. tgui.Parent = game:GetService("CoreGui")
  165. tlabel.Parent = tgui
  166. tlabel.Text = txt
  167. tlabel.Parent = tgui
  168. tlabel.Size = UDim2.new(1,0,.05,0)
  169. tlabel.BackgroundColor3 = Color3.new(.3,.3,.3)
  170. tlabel.TextColor3 = Color3.new(0,1,0)
  171. tlabel.Font = "Code"
  172. tlabel.TextScaled = true
  173. tlabel.Position = UDim2.new(0,0,1,0)
  174. tlabel:TweenPosition(UDim2.new(0,0,.35,0),'InOut','Sine',.5)
  175. tlabel.BackgroundColor3 = Color3.fromRGB(30,30,30)
  176. tlabel.BorderSizePixel = 0
  177. local tfr = Instance.new("Frame",tlabel)
  178. tfr.Size = UDim2.new(1,0,.25,0)
  179. tfr.Position = UDim2.new(0,0,1,0)
  180. tfr.BackgroundColor3 = Color3.fromRGB(20,20,20)
  181. tgui.Name = "Notify"
  182. tfr.BorderSizePixel = 0
  183. local type = type or nil
  184. if type==nil then
  185. tlabel.TextColor3 = Color3.new(0,1,0)
  186. else
  187. tlabel.TextColor3 = Color3.new(1,0,0)
  188. end
  189. game:GetService("Debris"):AddItem(tgui,6)
  190. end
  191. Notify("Loading...")
  192. wait(5)
  193. local IsProto = false
  194. local IsSynapse = false
  195. local IsElysian = false
  196. function CheckExploit()
  197. if is_protosmasher_caller~=nil then
  198. IsProto = true
  199. elseif elysianexecute~=nil then
  200. IsElysian = true
  201. elseif Synapse~=nil then
  202. IsSynapse = true
  203. elseif not is_protosmasher_caller and not Synapse and not elysianexecute then
  204. return false
  205. end
  206. end
  207.  
  208. CheckExploit()
  209. local version = "0.1.41"
  210. if IsProto then
  211. Notify("Loaded ".. version.. " for PROTOSMASHER")
  212. else
  213. Notify("I'm sorry, but this can only be used on PROTOSMASHER.")
  214. end
  215.  
  216. function SaveGame()
  217. local Remote = game.ReplicatedStorage.Remotes.Save
  218. local Result = Remote:InvokeServer()
  219. if Result==true then
  220. Notify("Saved.")
  221. else
  222. Notify("Error while saving on ".. "","Error")
  223. end
  224. end
  225.  
  226. function TypeCombat()
  227. local EventFunc =
  228. {
  229. ["LeftLowerArm"] = Player.Character.LeftLowerArm,
  230. ["RightUpperArm"] = Player.Character.RightUpperArm,
  231. ["LeftFoot"] = Player.Character.LeftFoot,
  232. ["RightHand"] = Player.Character.RightHand,
  233. ["RightLowerArm"] = Player.Character.RightLowerArm,
  234. ["LeftUpperLeg"] = Player.Character.LeftUpperLeg,
  235. ["LeftUpperArm"] = Player.Character.LeftUpperArm,
  236. ["Character"] = Player.Character,
  237. ["LeftHand"] = Player.Character.LeftHand,
  238. ["RightFoot"] = Player.Character.RightFoot,
  239. ["Humanoid"] = Player.Character.Humanoid,
  240. ["RightLowerLeg"] = Player.Character.RightLowerLeg,
  241. ["RightUpperLeg"] = Player.Character.RightUpperLeg,
  242. ["LeftLowerLeg"] = Player.Character.LeftLowerLeg
  243. }
  244. local Event = game:GetService("ReplicatedStorage").Remotes.Training.Combat
  245. Event:InvokeServer(EventFunc)
  246. end
  247.  
  248. function TypeKiBlast()
  249. local EventFunc = KiArm
  250. local Event = game:GetService("ReplicatedStorage").Remotes.Actions.EnergyBlast
  251. Event:InvokeServer(EventFunc)
  252. if KiArm=="Right" then
  253. KiArm="Left"
  254. else
  255. KiArm="Right"
  256. end
  257. end
  258.  
  259. function TypeChargeStart()
  260. local EventFunc1 = Player.Status
  261. local EventFunc2 = Player.Character.UpperTorso
  262. local EventFunc3 = Player.Character.Humanoid
  263. local Event = game:GetService("ReplicatedStorage").Remotes.Training.Charge
  264. Event:InvokeServer(EventFunc1,EventFunc2,EventFunc3)
  265. end
  266.  
  267. function TypeDefense()
  268. local EventFunc1 = Player.Stats
  269. local EventFunc2 = Player.Status
  270. local EventFunc3 = Player.Character.Humanoid
  271. local EventFunc4 = Player.Character.RightHand
  272. local Event = game:GetService("ReplicatedStorage").Remotes.Training.Defense
  273. Event:InvokeServer(EventFunc1, EventFunc2, nil, EventFunc4)
  274. end
  275.  
  276. function TypeChargeEnd()
  277. local Event = game:GetService("ReplicatedStorage").Remotes.Training.ChargeFinish
  278. Event:FireServer()
  279. end
  280. KiBlasting = false--bool
  281. Punching = false --bool
  282. Defense = false --bool
  283. KeyDown = function(key)
  284. key=key:lower()
  285. if key=="z" then
  286. spawn(function() TypeChargeStart() end)
  287. elseif key=="x" then
  288. KiBlasting = true
  289. repeat
  290. spawn(function() TypeKiBlast() end)
  291. wait()
  292. until KiBlasting==false
  293. elseif key=="v" then
  294. Punching=true
  295. repeat
  296. spawn(function() TypeCombat() end)
  297. wait()
  298. until Punching==false
  299. elseif key=="f" then
  300. Defense=true
  301. repeat
  302. spawn(function() TypeDefense() end)
  303. wait()
  304. until Defense==false
  305. end
  306. end
  307.  
  308. KeyUp = function(key)
  309. key=key:lower()
  310. if key=="x" then
  311. KiBlasting=false
  312. elseif key=="v" then
  313. Punching=false
  314. elseif key=="z" then
  315. TypeChargeEnd()
  316. elseif key=="f" then
  317. Defense = false
  318. end
  319. end
  320.  
  321. mouse.KeyDown:Connect(KeyDown)
  322. mouse.KeyUp:Connect(KeyUp)
  323. wait(6)
  324. while true do
  325. SaveGame()
  326. wait(30)
  327. end
Add Comment
Please, Sign In to add comment