SmileSimple Key Recorder & Play version 0.1

Posts 1–7 of 7 · Page 1 of 1
Simple Key Recorder & Play version 0.1
How to install
Well yer m8 it goes in
garrysmod/lua/autorun/client/keyrecorder.lua make sure to add the code aswell

How to use
lua_openscript_cl autorun/client/keyrecorder.lua

Then type

SuchIsGood_RecordKeys_Enable - To record keys Enable / Disable in the function!
SuchIsGood_PlayKeysBack - Play the keys back you pressed Enable / Disable in the function!
SuchIsGood_UnBindFuck - UnPresses the keys if they mess up!

This is currently version 0.1 expect bugs, Updates in the future, Via pastebin!

Code:
print("Auto key recoder loaded, Coded by SuchIsGood!")
local SuchIsGood = {}

SuchIsGood.RecordKeys = {}

SuchIsGood.RecordKeys.BindUse = {"-forward","-back","-moveright","-moveleft","-duck","-jump"}
SuchIsGood.RecordKeys.BindUsed = {"+forward","+back","+moveright","+moveleft","+duck","+jump"}

SuchIsGood.RecKey_Bool = false
SuchIsGood.PlayKey_Bool = false

local i = 0
local Play_Rec_Int = 0

hook.Add("PlayerBindPress", "PBP", function(p,k,b)
	if SuchIsGood.RecKey_Bool == false then return end
	if table.HasValue(SuchIsGood.RecordKeys.BindUsed, k) then
		i = i + 1
		print("Recorded Bind: "..k)
		local mbk = string.gsub(k,"+","-")
		SuchIsGood.RecordKeys[i] = {People = p, PlusKey = k, MinusKey = mbk, Bind = b}
	end
end)

concommand.Add("SuchIsGood_RecordKeys_Enable", function(p,c,a)
	if SuchIsGood.RecKey_Bool == false then
		SuchIsGood.RecKey_Bool = true
		print("Recording Keys!")
	elseif SuchIsGood.RecKey_Bool == true then
		SuchIsGood.RecKey_Bool = false
		print("Stopped Recording Keys!")
	end
end)

concommand.Add("SuchIsGood_PlayKeysBack", function(p,c,a)
	if SuchIsGood.PlayKey_Bool == false then
		SuchIsGood.PlayKey_Bool = true
		print("Playing Back!")
	elseif SuchIsGood.PlayKey_Bool == true then
		SuchIsGood.PlayKey_Bool = false
		print("Stopped Playing Back!")
	end
end)

concommand.Add("SuchIsGood_UnBindFuck", function(p,c,a)
	for _,unfuckery in pairs(SuchIsGood.RecordKeys.BindUse) do
		LocalPlayer():ConCommand(tostring(unfuckery))
	end
end)

timer.Create("SuchIsGood.PlayKey_Bool", 1, 0, function()
	if SuchIsGood.PlayKey_Bool == false or i == 0 then return end
	Play_Rec_Int = Play_Rec_Int + 1
		print("Playing Key "..SuchIsGood.RecordKeys[Play_Rec_Int].PlusKey)
		LocalPlayer():ConCommand(SuchIsGood.RecordKeys[Play_Rec_Int].PlusKey)
		timer.Simple(0.2, function() LocalPlayer():ConCommand(SuchIsGood.RecordKeys[Play_Rec_Int].MinusKey) end)
	if i == Play_Rec_Int then
		print("Unbind Fucking Keys")
		RunConsoleCommand("SuchIsGood_UnBindFuck")
	end
end)
Code:
http://pastebin.com/B7r8581X
Quote Originally Posted by Libbykona View Post
Wtf is a key?
Just bind it for a key
bind r SuchIsGood_RecordKeys_Enable
bind p SuchIsGood_PlayKeysBack
bind u SuchIsGood_UnBindFuck

A key is when you press w to go forward therefore w is the key, How ever if you read the description when you press keys you can record them and play it back this is only version 0.1.
Quote Originally Posted by suchisgood View Post
bind r SuchIsGood_RecordKeys_Enable
bind p SuchIsGood_PlayKeysBack
bind u SuchIsGood_UnBindFuck

A key is when you press w to go forward therefore w is the key, How ever if you read the description when you press keys you can record them and play it back this is only version 0.1.
Point of this?
hardcore deathrun run bot
Quote Originally Posted by polivilas View Post
hardcore deathrun run bot
Quote Originally Posted by CoLDarkness View Post
Point of this?
It's going to be a bhop recorder movement, Terrible guessers, Someone requested because they're terrible at lua.

http://www.mpgh.net/forum/782-garrys...-recorder.html
Posts 1–7 of 7 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Talk with us