Garry's Mod

Lua
Lua
Text
Image
Video

I wanna make a script that when you press g in choses randomly one of the act animations, i made this but it isnt working! alias acts "alias act_list "agree becon bow cheer dance disagree forward group halt laugh muscle pers robot salute wave zombie"; act_list" alias agree "act agree" alias becon "act becon" alias bow "act bow" alias cheer "act cheer" alias dance "act dance" alias disagree "act disagree" alias forward "act forward" alias group "act group" alias halt "act halt" alias laugh "act laugh" alias muscle "act muscle" alias pers "act pers" alias robot "act robot" alias salute "act salute" alias wave "act wave" alias zombie "act zombie" bind "g" "acts"

Tired of manually preaparing the list of enabled addons?
"""
function CallEnabledAddons()
	local Addons = engine.GetAddons()
	for _, Addon in pairs(Addons) do
		if Addon["mounted"] == true then
			local AddonTitle = Addon["title"]
			local AddonID = Addon["wsid"]
			
			local AddonMessage = "Addon: " .. AddonTitle .. ", workshop link: https://steamcommunity.com/sharedfiles/filedetails/?id=" .. AddonID
			print(AddonMessage)
		end
	end
end

if CLIENT then
	concommand.Add("call_enabled_addons", function()
		CallEnabledAddons()
	end)
end
"""
Use that code above, lunch it on the lua_openscript_cl and then you can use command: call_enabled_addons. This command will print for you list of the enabled addons with workshop links!

Tired of manually preaparing the list of enabled addons? """ function CallEnabledAddons() local Addons = engine.GetAddons() for _, Addon in pairs(Addons) do if Addon["mounted"] == true then local AddonTitle = Addon["title"] local AddonID = Addon["wsid"] local AddonMessage = "Addon: " .. AddonTitle .. ", workshop link: steamcommunity.com/sharedfiles/f…" .. AddonID print(AddonMessage) end end end if CLIENT then concommand.Add("call_enabled_addons", fu…

ttthmm1