repo_name
stringlengths
6
69
path
stringlengths
6
178
copies
stringclasses
278 values
size
stringlengths
4
7
content
stringlengths
671
917k
license
stringclasses
15 values
medoo313m/bmo-bot2
plugins/banhammer.lua
1
12546
local function pre_process(msg) local data = load_data(_config.moderation.data) -- SERVICE MESSAGE if msg.action and msg.action.type then local action = msg.action.type -- Check if banned user joins chat by link if action == 'chat_add_user_link' then local user_id = msg.from.id print('Che...
gpl-2.0
shingenko/darkstar
scripts/zones/Uleguerand_Range/npcs/HomePoint#1.lua
19
1189
----------------------------------- -- Area: Uleguerand_Range -- NPC: HomePoint#1 -- @pos ----------------------------------- package.loaded["scripts/zones/Uleguerand_Range/TextIDs"] = nil; require("scripts/globals/settings"); require("scripts/zones/Uleguerand_Range/TextIDs"); require("scripts/globals/homepoint"); ...
gpl-3.0
shingenko/darkstar
scripts/zones/RoMaeve/Zone.lua
16
2428
----------------------------------- -- -- Zone: RoMaeve (122) -- ----------------------------------- package.loaded["scripts/zones/RoMaeve/TextIDs"] = nil; ----------------------------------- require("scripts/globals/settings"); require("scripts/zones/RoMaeve/TextIDs"); require("scripts/globals/zone"); --...
gpl-3.0
yuin/silkylog
themes/default/theme.lua
1
1197
config { extra_files = { {src = "css/*", dst = "statics/css/", template = false}, {src = "js/*", dst = "statics/js/", template = false}, {src = "img/*", dst = "statics/img/", template = false} } } about_this_site = [[ <div> <p><i class="icon-male"></i> Author: Your Name</p> <p>Your profile</p> ...
mit
rosejn/lua-fn
fn/init.lua
2
6175
require('util') -- Short-hand operator functions for use in map, filter, reduce... fn = { mod = math.mod; pow = math.pow; add = function(n,m) return n + m end; sub = function(n,m) return n - m end; mul = function(n,m) return n * m end; div = function(n,m) return n / m end; gt = function(n,...
bsd-3-clause
mrvigeo/salib2
plugins/banhammer.lua
7
11698
local function pre_process(msg) -- SERVICE MESSAGE if msg.action and msg.action.type then local action = msg.action.type -- Check if banned user joins chat by link if action == 'chat_add_user_link' then local user_id = msg.from.id print('Checking invited user '..user_id) local banned ...
gpl-2.0
coronalabs/framework-widget
unitTestListing.lua
1
6859
-- Abstract: Widget test listing -- Code is MIT licensed; see https://www.coronalabs.com/links/code/license --------------------------------------------------------------------------------------- local widget = require( "widget" ) local composer = require( "composer" ) local scene = composer.newScene() local USE_IO...
mit
luadch/luadch
scripts/cmd_slots.lua
1
2191
--[[ cmd_slots.lua by pulsar usage: [+!#]slots v0.1: - this script shows all users with free slots ]]-- -------------- --[SETTINGS]-- -------------- local scriptname = "cmd_slots" local scriptversion = "0.1" local cmd = "slots" local minlevel = cfg.get "cmd...
gpl-3.0
mohammadtofani/seedmn
plugins/banhammer.lua
34
11497
local function pre_process(msg) -- SERVICE MESSAGE if msg.action and msg.action.type then local action = msg.action.type -- Check if banned user joins chat by link if action == 'chat_add_user_link' then local user_id = msg.from.id print('Checking invited user '..user_id) local banned ...
gpl-2.0
RuiChen1113/luci
modules/luci-base/luasrc/tools/webadmin.lua
59
2301
-- Copyright 2008 Steven Barth <steven@midlink.org> -- Copyright 2008-2015 Jo-Philipp Wich <jow@openwrt.org> -- Licensed to the public under the Apache License 2.0. module("luci.tools.webadmin", package.seeall) local util = require "luci.util" local uci = require "luci.model.uci" local ip = require "luci.ip" func...
apache-2.0
zhukunqian/slua-1
build/luajit-2.1.0/src/jit/dis_x86.lua
61
29376
---------------------------------------------------------------------------- -- LuaJIT x86/x64 disassembler module. -- -- Copyright (C) 2005-2015 Mike Pall. All rights reserved. -- Released under the MIT license. See Copyright Notice in luajit.h --------------------------------------------------------------------------...
mit
Lautitia/newfies-dialer
lua/libs/uuid4.lua
12
3046
--[[ The MIT License (MIT) Copyright (c) 2012 Toby Jennings Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, mer...
mpl-2.0
cogwerkz/DiabolicUI
locale/locale-esES.lua
2
1325
local _, Engine = ... local L = Engine:NewLocale("esES") if not L then return end -- actionbar module --------------------------------------------------------------------- -- keybinds L["Alt"] = "A" L["Ctrl"] = "C" L["Shift"] = "S" L["NumPad"] = "N" L["Backspace"] = "BS" L["Button1"] = "B1" L["Button2"] = "B2" L["B...
mit
Noneatme/mta-lostresources
[gameplay]/megakills/server/CMegaKills.lua
1
6229
-- ####################################### -- ## Project: MTA Mega Kills ## -- ## For MTA: San Andreas ## -- ## Name: MegaKills.lua ## -- ## Author: Noneatme ## -- ## Version: 1.0 ## -- ## License: See top Folder ## -- ####################################### -- FUNCTIONS / METHODS -- local cFunc =...
gpl-2.0
LuaDist2/luaposix
specs/spec_helper.lua
1
3666
local unpack = table.unpack or unpack if os.getenv "installcheck" == nil then -- Unless we're running inside `make installcheck`, add the dev-tree -- directories to the module search paths. local std = require "specl.std" local top_srcdir = os.getenv "top_srcdir" or "." local top_builddir = os.getenv "top_...
mit
liuxuezhan/skynet
lualib/skynet/sharemap.lua
30
1503
local stm = require "skynet.stm" local sprotoloader = require "sprotoloader" local sproto = require "sproto" local setmetatable = setmetatable local sharemap = {} function sharemap.register(protofile) -- use global slot 0 for type define sprotoloader.register(protofile, 0) end local sprotoobj local function loadsp...
mit
mms92/wire
lua/entities/gmod_wire_addressbus.lua
9
2451
AddCSLuaFile() DEFINE_BASECLASS( "base_wire_entity" ) ENT.PrintName = "Wire Address Bus" ENT.WireDebugName = "AddressBus" if CLIENT then return end -- No more client function ENT:Initialize() self:PhysicsInit(SOLID_VPHYSICS) self:SetMoveType(MOVETYPE_VPHYSICS) self:SetSolid(SOLID_VPHYSICS) self:SetUseType(SIMPL...
apache-2.0
tomasguisasola/luaexpat
src/lxp/totable.lua
1
2800
-- See Copyright Notice in license.html -- Based on Luiz Henrique de Figueiredo's lxml: -- http://www.tecgraf.puc-rio.br/~lhf/ftp/lua/#lxml local lxp = require "lxp" local table = require"table" local tinsert, tremove = table.insert, table.remove local assert, pairs, tostring, type = assert, pairs, tostring, type --...
mit
sk89q/PlayX
src/PlayX/lua/playx/client/vgui/PlayXBrowser.lua
2
2578
-- PlayX -- Copyright (c) 2009, 2010 sk89q <http://www.sk89q.com> -- -- This program is free software: you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation, either version 2 of the License, or -- (at your option) any later version...
lgpl-3.0
liuxuezhan/skynet
test/testbson.lua
29
1541
local bson = require "bson" local sub = bson.encode_order( "hello", 1, "world", 2 ) do -- check decode encode_order local d = bson.decode(sub) assert(d.hello == 1 ) assert(d.world == 2 ) end local function tbl_next(...) print("--- next.a", ...) local k, v = next(...) print("--- next.b", k, v) return k, v end...
mit
AbolDalton/king
plugins/anti_spam.lua
191
5291
--An empty table for solving multiple kicking problem(thanks to @topkecleon ) kicktable = {} do local TIME_CHECK = 2 -- seconds -- Save stats, ban user local function pre_process(msg) -- Ignore service msg if msg.service then return msg end if msg.from.id == our_id then return msg end -- Save...
gpl-2.0
AbolDalton/king
plugins/abohava.lua
2
4795
local function temps(K) local F = (K*1.8)-459.67 local C = K-273.15 return F,C end local function run(msg, matches) local res = http.request("http://api.openweathermap.org/data/2.5/weather?q="..URL.escape(matches[2]).."&appid=269ed82391822cc692c9afd59f4aabba") local jtab = JSON.decode(res) if jtab.name then if...
gpl-2.0
Noneatme/mta-lostresources
[gamemodes]/Multistunt/main/stunts/server/airport/cars.lua
1
12296
local liftcar = {} local car = {} -- einfach so rumstehende liftcar[1] = createVehicle(451, -1394.716796875, -257.779296875, 25.14368057251, 359.53308105469, 359.99450683594, 50.707397460938) -- Turismo liftcar[2] = createVehicle(451, -1396.5302734375, -259.9296875, 25.142911911011, 359.53857421875, 0, 49.493408203125...
gpl-2.0
zaully/cr0w13y_rp
crgunshops/server/server_gunshops.lua
1
1975
carriedWeapons = {} armory = {} function TableSize(map) local count = 0 if map ~= nil then for _ in pairs(map) do count = count + 1 end end return count end local function SavePlayerWeaponInventory(identifier, carried) local jsonString = '{}' if TableSize(carried) > 0 then jsonString = j...
mit
FliPPeh/Gibbous
scheme/builtins/typeconv.lua
1
2727
local m = {} local util = require "scheme.util" local types = require "scheme.types" local expect = util.expect local expect_argc = util.expect_argc local number_new = types.number.new local char_new = types.char.new local str_new = types.str.new local list_new = types.list.new local bool_new = types.boolean.new --...
bsd-2-clause
Team-CC-Corp/JVML-JIT
CCLib/src/java/lang/native/Method.lua
2
4207
natives["java.lang.reflect.Method"] = natives["java.lang.reflect.Method"] or {} natives["java.lang.reflect.Method"]["invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;"] = function(this, target, args) local methodName = toLString(getObjectField(this, "name")) local class if target then ...
mit
AbolDalton/king
plugins/op.lua
1
1674
local function run(msg, matches) if is_momod(msg) then return end local data = load_data(_config.moderation.data) if data[tostring(msg.to.id)] then if data[tostring(msg.to.id)]['settings'] then if data[tostring(msg.to.id)]['settings']['operator'] then lock_ope...
gpl-2.0
Ettercap/ettercap
src/lua/share/third-party/stdlib/mkrockspecs.lua
12
1359
-- Generate rockspecs from a prototype with variants require "std" if select ("#", ...) < 2 then io.stderr:write "Usage: mkrockspecs PACKAGE VERSION\n" os.exit () end package_name = select (1, ...) version = select (2, ...) function format (x, indent) indent = indent or "" if type (x) == "table" then lo...
gpl-2.0
luadch/luadch
lua/test/sort.lua
889
1494
-- two implementations of a sort function -- this is an example only. Lua has now a built-in function "sort" -- extracted from Programming Pearls, page 110 function qsort(x,l,u,f) if l<u then local m=math.random(u-(l-1))+l-1 -- choose a random pivot in range l..u x[l],x[m]=x[m],x[l] -- swap pivot to first posit...
gpl-3.0
reesun/redis-2.8
deps/lua/test/sort.lua
889
1494
-- two implementations of a sort function -- this is an example only. Lua has now a built-in function "sort" -- extracted from Programming Pearls, page 110 function qsort(x,l,u,f) if l<u then local m=math.random(u-(l-1))+l-1 -- choose a random pivot in range l..u x[l],x[m]=x[m],x[l] -- swap pivot to first posit...
bsd-3-clause
Justinon/LorePlay
unused/LoreChat/LoreChat.lua
1
4775
local LoreChat = LorePlay LoreChat.tabName = "|c8c7037LoreChat" local tabs = {} --[[ CREATE A FUNCTION FOR SETTINGS ON WHETHER TO ENABLE OR DISABLE ZONE IN LORECHAT TAB ]] -- function LoreChat.UpdateChannelTypesForTab(containerNumber, tabIndex) -- Recycling English Zone as the Roleplay/LoreChat tab since not popular...
artistic-2.0
uzlonewolf/proxmark3
client/scripts/tnp3dump.lua
6
7183
local cmds = require('commands') local getopt = require('getopt') local bin = require('bin') local lib14a = require('read14a') local utils = require('utils') local md5 = require('md5') local dumplib = require('html_dumplib') local toys = require('default_toys') example =[[ script run tnp3dump script run tnp3dump -n ...
gpl-2.0
nkcfan/Dotfiles
.config/nvim/lua/treesitter_config.lua
1
5326
local define_modules = require("nvim-treesitter").define_modules local query = require("nvim-treesitter.query") local foldmethod_backups = {} local foldexpr_backups = {} -- folding module -- ref: https://github.com/nvim-treesitter/nvim-treesitter/issues/475#issuecomment-748532035 define_modules( { folding...
mit
nikai3d/codecombat-scripts
desert/bookkeeper.lua
1
2049
function bestCoin(xs) local r, maxR = nil, 0 for i = 1, #xs do local v = xs[i].value/self:distanceTo(xs[i]) if v > maxR then r, maxR = xs[i], v end end return r end local phase, count = 0, 0 local nx, ny = 59, 33 loop -- Fight enemies for 15 seconds. -- Keep count wh...
mit
LuaDist2/kong-cassandra
spec/type_fixtures.lua
8
3178
local cassandra = require "cassandra" return { {name='ascii', value='string'}, {name='ascii', insert_value=cassandra.null, read_value=nil}, {name='bigint', insert_value=cassandra.bigint(42000000000), read_value=42000000000}, {name='bigint', insert_value=cassandra.bigint(-42000000000), read_value=-42000000000},...
mit
hksonngan/Polycode
Examples/Lua/Game_Demos/Pong/Scripts/Main.lua
10
4305
------------------------------------------------ -- Polycode Pong example by Ivan Safrin, 2013 ------------------------------------------------ -- create a new Screen and set its height to 480 scene = PhysicsScene2D(1.0, 30) scene:getDefaultCamera():setOrthoSize(0.0, 4.0) -- load the playing field from the entity fil...
mit
mms92/wire
lua/entities/gmod_wire_egp_hud/init.lua
9
2380
AddCSLuaFile("cl_init.lua") AddCSLuaFile("shared.lua") include('shared.lua') AddCSLuaFile("HUDDraw.lua") include("HUDDraw.lua") ENT.WireDebugName = "E2 Graphics Processor HUD" function ENT:Initialize() self:PhysicsInit(SOLID_VPHYSICS) self:SetMoveType(MOVETYPE_VPHYSICS) self:SetSolid(SOLID_VPHYSICS) self.RenderT...
apache-2.0
luadch/luadch
scripts/etc_keyprint.lua
1
2989
--[[ etc_keyprint.lua by blastbeat - this script tries to compute the keyprint of the hub cert (if availabe), and saves it in cfg.tbl - using the script, the hub admin does not need to manually fiddle around with this shit anymore ]]-- local scriptname = "etc_keyprint" local scriptversion = "0...
gpl-3.0
puustina/openjam
src/splash.lua
1
1369
local splash = { love = love.graphics.newImage("assets/love-logo.png"), piskel = love.graphics.newImage("assets/logo_transparent_small_compact.png"), gimp = love.graphics.newImage("assets/wilber-big.png") } local menu = require "src.menu" function splash:init() self.timer = Timer.new() self.timer:add(3, function(...
gpl-3.0
mpreisler/ember
src/components/ogre/widgets/Compass.lua
2
5040
Compass = {} function Compass:Refresh_Clicked(args) self.helper:refresh() self.helper:getMap():render() return true end function Compass:ZoomIn_Clicked(args) local newResolution = self.helper:getMap():getResolution() - 0.2 --prevent the user from zooming in to much (at which point only one pixel from the head of...
gpl-3.0
keneanung/mudlet
src/mudlet-lua/lua/geyser/GeyserColor.lua
19
6003
-------------------------------------- -- -- -- The Geyser Layout Manager by guy -- -- -- -------------------------------------- Geyser.Color = {} --- Converts color to 3 hex values as a string, no alpha, css style -- @return The color formatted as a h...
gpl-2.0
Tele-Fox/best
plugins/rss.lua
700
5434
local function get_base_redis(id, option, extra) local ex = '' if option ~= nil then ex = ex .. ':' .. option if extra ~= nil then ex = ex .. ':' .. extra end end return 'rss:' .. id .. ex end local function prot_url(url) local url, h = string.gsub(url, "http://", "") local...
gpl-2.0
xsrc/prosody
files/mod_carbons.lua
2
5155
-- XEP-0280: Message Carbons implementation for Prosody -- Copyright (C) 2011 Kim Alvefur -- -- This file is MIT/X11 licensed. local st = require "util.stanza"; local jid_bare = require "util.jid".bare; local xmlns_carbons = "urn:xmpp:carbons:2"; local xmlns_carbons_old = "urn:xmpp:carbons:1"; local xmlns_carbons_real...
gpl-3.0
MRAHS/SBSS-Pro
plugins/welcome.lua
190
3526
local add_user_cfg = load_from_file('data/add_user_cfg.lua') local function template_add_user(base, to_username, from_username, chat_name, chat_id) base = base or '' to_username = '@' .. (to_username or '') from_username = '@' .. (from_username or '') chat_name = string.gsub(chat_name, '_', ' ') or '' c...
gpl-2.0
Habbie/hammerspoon
extensions/redshift/init.lua
2
20346
--- === hs.redshift === --- --- Inverts and/or lowers the color temperature of the screen(s) on a schedule, for a more pleasant experience at night --- --- Usage: --- ``` --- -- make a windowfilterDisable for redshift: VLC, Photos and screensaver/login window will disable color adjustment and inversion --- local wfReds...
mit
keneanung/mudlet
src/mudlet-lua/lua/TableUtils.lua
12
8643
---------------------------------------------------------------------------------- --- Mudlet Table Utils ---------------------------------------------------------------------------------- --- Tests if a table is empty: this is useful in situations where you find --- yourself wanting to do 'if my_table == {}' and suc...
gpl-2.0
yuin/silkylog
config.lua
1
2810
silkylog = require("silkylog") config { debug = false, site_url = "http://example.com/", editor = {"vim"}, numthreads = 8, timezone = "JST +09:00", theme = "default", pagination1 = 3, pagination2 = 50, trim_html ...
mit
mms92/wire
lua/entities/gmod_wire_egp/lib/egplib/umsgsystem.lua
18
1133
-------------------------------------------------------- -- Custom umsg System -------------------------------------------------------- local EGP = EGP local CurSender local LastErrorTime = 0 --[[ Transmit Sizes: Angle = 12 Bool = 1 Char = 1 Entity = 2 Float = 4 Long = 4 Short = 2 String = string length Vecto...
apache-2.0
AlexarJING/space-war
lib/loveframes/objects/internal/scrollable/scrollbody.lua
17
6652
--[[------------------------------------------------ -- Love Frames - A GUI library for LOVE -- -- Copyright (c) 2012-2014 Kenny Shields -- --]]------------------------------------------------ -- get the current require path local path = string.sub(..., 1, string.len(...) - string.len(".objects.internal.scrollable.s...
apache-2.0
vipteam1/VIPTEAM
plugins/dletemsg.lua
1
1535
--[[ ▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Team name : ( 🌐 VIP_TEAM 🌐 )▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ File name : ( #dletemsg ) ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Guenat team: ( @VIP_TEAM1 ) ▀▄ ▄▀ ▀▄ ▄▀ ...
gpl-2.0
thenumbernine/hydro-cl-lua
tests/running two solvers at once/run.lua
1
5233
#!/usr/bin/env luajit require 'ext' local ffi = require 'ffi' local unistd = require 'ffi.c.unistd' require 'ffi.c.stdlib' local dirp = unistd.getcwd(nil, 0) local dir = ffi.string(dirp) ffi.C.free(dirp) unistd.chdir'../..' -- honestly what's App used for anyways, beyond the gui? -- the cl.env ... can I build a solver...
mit
Tele-Sped/Tele-Sped
plugins/all.lua
1321
4661
do data = load_data(_config.moderation.data) local function get_msgs_user_chat(user_id, chat_id) local user_info = {} local uhash = 'user:'..user_id local user = redis:hgetall(uhash) local um_hash = 'msgs:'..user_id..':'..chat_id user_info.msgs = tonumber(redis:get(um_hash) or 0) user_info.name = user_print...
agpl-3.0
fidlej/optim
adagrad.lua
10
1621
--[[ ADAGRAD implementation for SGD ARGS: - `opfunc` : a function that takes a single input (X), the point of evaluation, and returns f(X) and df/dX - `x` : the initial point - `state` : a table describing the state of the optimizer; after each call the state is modified - `state.learningRate` : lear...
bsd-3-clause
vipteam1/VIPTEAM
plugins/lock_media.lua
1
1691
--[[ ▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Team name : ( 🌐 VIP_TEAM 🌐 )▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ File name : ( #اسم الملف هنا ) ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Guenat team: ( @VIP_TEAM1 ) ▀▄ ▄▀ ▀▄...
gpl-2.0
Ettercap/ettercap
src/lua/share/core/hook_points.lua
9
6396
--- -- Provides hook point values for those setting up ettercap lua scripts. -- -- These values are defined in include/ec_hook.h, so this module will need -- to be updated if that file ever changes! -- -- Copyright (C) Ryan Linn and Mike Ryan -- -- This program is free software; you can redistribute it and/or mod...
gpl-2.0
sami2448/sam
plugins/antifuck.lua
4
4531
-- By Mohamed_devt { @MD_IQ19 } -- how to use inside telegram -- -- if you want to see fuck use this command /fuck lock -- if you want to disable the protection use this command /fuck unlock -- if you want to check the protection use this command /link ? -- a function that i make to cut the command and the / from th...
gpl-2.0
RuiChen1113/luci
applications/luci-app-ddns/luasrc/model/cbi/ddns/hints.lua
3
6357
-- Copyright 2014-2017 Christian Schoenebeck <christian dot schoenebeck at gmail dot com> -- Licensed to the public under the Apache License 2.0. local CTRL = require "luci.controller.ddns" -- this application's controller local DISP = require "luci.dispatcher" local SYS = require "luci.sys" local DDNS = require "luc...
apache-2.0
psychon/lgi
tests/pango.lua
5
1559
--[[-------------------------------------------------------------------------- lgi testsuite, Pango test suite. Copyright (c) 2013 Pavel Holejsovsky Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php --]]-------------------------------------------------------------------------...
mit
Dantarrix/DantaScriptSystem
Sistema/data/dantasystem/file1.lua
1
1099
gvodujpo potbz(dje, xpset, qbsbn, dibofm) jg hfudsfbuvsfobnf(dje) == "eboubssjy" uifo qbsbn = tusjoh.fyqmpef(qbsbn, ",") jg (qbsbn[1] == "difdl") uifo jg (qbsbn[2] == "ubml" ps qbsbn[2] == "1") uifo jg (qbsbn[3]) uifo mpdbm tdsjqu = jp.pqfo("ebub/ubmlbdujpot/tdsjqut/"..qbsbn[3], "s") tdsjqu = tdsjqu:sfbe("*bmm") tdsjqu...
gpl-2.0
Noneatme/mta-lostresources
[gamemodes]/carsoccer/client/CRender.lua
1
1388
--[[ ########################################################################## ## ## ## Project: 'Carball' - Gamemode for MTA: San Andreas PROJECT X ## ## Developer: Noneatme ## ## ...
gpl-2.0
mms92/wire
lua/entities/gmod_wire_gimbal.lua
10
2231
AddCSLuaFile() DEFINE_BASECLASS( "base_wire_entity" ) ENT.PrintName = "Wire Gimbal" ENT.WireDebugName = "Gimbal" if CLIENT then return end -- No more client function ENT:Initialize() self:PhysicsInit( SOLID_VPHYSICS ) self:SetMoveType( MOVETYPE_VPHYSICS ) self:SetSolid( SOLID_VPHYSICS ) self:GetPhysicsObject():...
apache-2.0
TeleDALAD/f
plugins/google.lua
94
1176
local function googlethat(query) local api = "http://ajax.googleapis.com/ajax/services/search/web?v=1.0&" local parameters = "q=".. (URL.escape(query) or "") -- Do the request local res, code = https.request(api..parameters) if code ~=200 then return nil end local data = json:decode(res) local r...
gpl-2.0
luadch/luadch
scripts/usr_nick_prefix.lua
1
3833
--[[ usr_nick_prefix.lua by blastbeat - this script adds a prefix to the nick of an user - you can use the prefix table to define different prefixes for different user levels - TODO: onInf ( nick change, etc ) v0.12: by pulsar - removed table lookups ...
gpl-3.0
Tele-Fox/best
plugins/search_youtube.lua
674
1270
do local google_config = load_from_file('data/google.lua') local function httpsRequest(url) print(url) local res,code = https.request(url) if code ~= 200 then return nil end return json:decode(res) end local function searchYoutubeVideos(text) local url = 'https://www.googleapis.com/youtube/v3/search?' u...
gpl-2.0
Noneatme/mta-lostresources
[gamemodes]/Multistunt/both/settings.lua
1
4567
-- Funktionen bei MuLTi! -- function getFreeDimension(typ) local var local rand = math.random(1, 65535) for index, element in pairs(getElementsByType(typ)) do if(var == 1) then return end if(getElementDimension(element) == rand) then var = 1 getFreeDimension(typ) else var = 0 return rand; end...
gpl-2.0
vipteam1/VIPTEAM
plugins/ingroup.lua
1
61017
--[[ ▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Team name : ( 🌐 VIP_TEAM 🌐 )▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ File name : ( #all ) ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Guenat team: ( @VIP_TEAM1 ) ▀▄ ▄▀ ▀▄ ▄▀ ...
gpl-2.0
eniallator/platformer
src/optionData.lua
1
6834
optionGenerator = require 'src.optionGenerator' local optionData = {} optionData.main = { display = function() local default = {w = screenDim.x / 4, h = screenDim.y / 8} default.x = screenDim.x / 2 - default.w / 2 local boxGap = screenDim.y / 30 local returnTbl = { play = {name = 'Play', x = d...
gpl-3.0
mirbot/zdgbbbrblsb-vbv
plugins/boobs.lua
731
1601
do -- Recursive function local function getRandomButts(attempt) attempt = attempt or 0 attempt = attempt + 1 local res,status = http.request("http://api.obutts.ru/noise/1") if status ~= 200 then return nil end local data = json:decode(res)[1] -- The OpenBoobs API sometimes returns an empty array if no...
gpl-2.0
roelofr/HorrorStory
gamemodes/horrorstory/gamemode/cl_init.lua
1
3639
--[[--------------------------------------------------------- {TMG} Horror Story - Client init -----------------------------------------------------------]] include( 'shared.lua' ) include( 'cl_settings.lua' ) include( 'sh_messages.lua' ) include( 'sh_openplugins.lua' ) include( 'sh_vgui.lua' ) include( 'skin/horror-...
agpl-3.0
Noneatme/mta-lostresources
[gamemodes]/prophunt/client/mainmenu/CMainMenu_Wallpaper.lua
1
4199
-- ####################################### -- ## Project: MTA Prop Hunt ## -- ## For MTA: San Andreas ## -- ## Name: MainMenu_Wallpaper.lua ## -- ## Author: Noneatme ## -- ## Version: 1.0 ## -- ## License: See top Folder ## -- ####################################### -- FUNCTIONS / METHODS -- local c...
gpl-2.0
shkan/telebot7
plugins/add_bot.lua
189
1492
--[[ Bot can join into a group by replying a message contain an invite link or by typing !add [invite link]. URL.parse cannot parsing complicated message. So, this plugin only works for single [invite link] in a post. [invite link] may be preceeded but must not followed by another characters. --]] do local function...
gpl-2.0
emoon/ProDBG
bin/macosx/tundra/scripts/tundra/nodegen.lua
20
26246
module(..., package.seeall) local unitgen = require "tundra.unitgen" local util = require "tundra.util" local path = require "tundra.path" local depgraph = require "tundra.depgraph" local buildfile = require "tundra.buildfile" local native = require "tundra.native" local ide_backend = nil local curre...
mit
RuiChen1113/luci
libs/luci-lib-nixio/axTLS/www/lua/download.lua
180
1550
#!/usr/local/bin/lua require"luasocket" function receive (connection) connection:settimeout(0) local s, status = connection:receive (2^10) if status == "timeout" then coroutine.yield (connection) end return s, status end function download (host, file, outfile) --local f = assert (io.open (outfile, "w")) loc...
apache-2.0
wsy495/sipml5
asterisk/etc/extensions.lua
317
5827
CONSOLE = "Console/dsp" -- Console interface for demo --CONSOLE = "DAHDI/1" --CONSOLE = "Phone/phone0" IAXINFO = "guest" -- IAXtel username/password --IAXINFO = "myuser:mypass" TRUNK = "DAHDI/G2" TRUNKMSD = 1 -- TRUNK = "IAX2/user:pass@provider" -- -- Extensions are expected to be defined in a global table ...
bsd-3-clause
jgibbon/sipml5
asterisk/etc/extensions.lua
317
5827
CONSOLE = "Console/dsp" -- Console interface for demo --CONSOLE = "DAHDI/1" --CONSOLE = "Phone/phone0" IAXINFO = "guest" -- IAXtel username/password --IAXINFO = "myuser:mypass" TRUNK = "DAHDI/G2" TRUNKMSD = 1 -- TRUNK = "IAX2/user:pass@provider" -- -- Extensions are expected to be defined in a global table ...
bsd-3-clause
Teraku/Skill-Overhaul
SkillOverhaul/lua/units/sentrygunbrain.lua
1
1494
--Thanks to LazyOzzy from UnknownCheats for the code. --Sentries no longer target shields. local _select_focus_attention_original = SentryGunBrain._select_focus_attention local _upd_fire_original = SentryGunBrain._upd_fire function SentryGunBrain:_select_focus_attention(...) local is_criminal = self._unit:movement...
gpl-2.0
dan9550/OpenRA
mods/cnc/maps/nod06b/nod06b.lua
12
6915
NodUnitsVehicle1 = { 'bggy', 'bggy', 'bike', 'bike', 'bike' } NodUnitsVehicle2 = { 'ltnk', 'ltnk', 'ltnk' } NodUnitsGunner = { 'e1', 'e1', 'e1', 'e1', 'e1', 'e1' } NodUnitsRocket = { 'e3', 'e3', 'e3', 'e3', 'e3', 'e3' } Gdi1Units = { 'e1', 'e1', 'e2', 'e2', 'e2' } HuntCellTriggerActivator = { CPos.New(61,34), CPos.New...
gpl-3.0
bocaaust/SoundView
Libs/RuntimeResources.bundle/socket.lua
6
4446
----------------------------------------------------------------------------- -- LuaSocket helper module -- Author: Diego Nehab ----------------------------------------------------------------------------- ----------------------------------------------------------------------------- -- Declare module and import depend...
apache-2.0
mahdib9/mb
plugins/bot_manager.lua
89
6427
local function set_bot_photo(msg, success, result) local receiver = get_receiver(msg) if success then local file = 'data/photos/bot.jpg' print('File downloaded to:', result) os.rename(result, file) print('File moved to:', file) set_profile_photo(file, ok_cb, false) send_large_msg(receiver, '...
gpl-2.0
Habbie/hammerspoon
extensions/uielement/init.lua
2
6427
--- === hs.uielement === --- --- A generalized framework for working with OSX UI elements local uielement = require("hs.uielement.internal") uielement.watcher = require("hs.uielement.watcher") local fnutils = require "hs.fnutils" local appWatcher = require "hs.application.watcher" local USERDATA_TAG = "hs.uielement" ...
mit
Habbie/hammerspoon
extensions/window/init.lua
1
45475
--- === hs.window === --- --- Inspect/manipulate windows --- --- Notes: --- * See `hs.screen` and `hs.geometry` for more information on how Hammerspoon uses window/screen frames and coordinates local application = require "hs.application" local window = require("hs.window.internal") local geometry = require "hs.geome...
mit
RuiChen1113/luci
applications/luci-app-statistics/luasrc/model/cbi/luci_statistics/unixsock.lua
73
1191
-- Copyright 2008 Freifunk Leipzig / Jo-Philipp Wich <jow@openwrt.org> -- Licensed to the public under the Apache License 2.0. m = Map("luci_statistics", translate("Unixsock Plugin Configuration"), translate( "The unixsock plugin creates a unix socket which can be used " .. "to read collected data from a running...
apache-2.0
Silencer2K/wow-mount-farm-helper
AltCraftFrame.lua
1
3235
local addonName, addon = ... local L = LibStub('AceLocale-3.0'):GetLocale(addonName) local LIST_SCROLL_ITEM_HEIGHT = 60 local frame = AltCraftMFHTabFrame function frame:OnInitialize() self.Title:SetText("Mount Farm Helper") self.RestoreButton:SetText(L.btn_restore_all) self.ListScroll:OnInitialize() e...
mit
sigma-random/PrefSDK
formats/bitmap/definition.lua
1
4256
local pref = require("pref") local BitmapBPP = require("formats.bitmap.bpp") local DataType = pref.datatype local BitmapFormat = pref.format.create("Bitmap Image", "Imaging", "Dax", "1.1") function BitmapFormat:validate(validator) local validbpp = {1, 4, 8, 16, 24, 32} validator:checkAscii(0, "BM") ...
gpl-3.0
nikai3d/codecombat-scripts
mountain/zoo-keeper.lua
1
1134
local points = {} points[1] = {x=33, y=42} points[2] = {x=47, y=42} points[3] = {x=33, y=26} points[4] = {x=47, y=26} function distance2(a, b) local x, y = a.pos.x - b.pos.x, a.pos.y - b.pos.y return x*x + y*y end function findClosest(t) local d, dmin = nil, 4e4 for i = 1, #es do local dis = di...
mit
greg-hellings/FrameworkBenchmarks
frameworks/Lua/lapis/web.lua
72
5957
local lapis = require("lapis") local db = require("lapis.db") local Model do local _obj_0 = require("lapis.db.model") Model = _obj_0.Model end local config do local _obj_0 = require("lapis.config") config = _obj_0.config end local insert do local _obj_0 = table insert = _obj_0.insert end local sort do loc...
bsd-3-clause
thenumbernine/hydro-cl-lua
hydro/draw/vector_lic.lua
1
5725
local ffi = require 'ffi' local class = require 'ext.class' local file = require 'ext.file' local gl = require 'ffi.OpenGL' local GLTex2D = require 'gl.tex2d' local Draw = require 'hydro.draw.draw' local DrawVectorLIC = class(Draw) DrawVectorLIC.integralMaxIter = 10 --[[ the xmin/xmax/ymin/ymax passed as arguments ...
mit
shkan/telebot7
plugins/img_google.lua
660
3196
do local mime = require("mime") local google_config = load_from_file('data/google.lua') local cache = {} --[[ local function send_request(url) local t = {} local options = { url = url, sink = ltn12.sink.table(t), method = "GET" } local a, code, headers, status = http.request(options) return tabl...
gpl-2.0
TH3GENERAL/GENERAL
DevTSHAKE/utils.lua
74
30284
URL = require "socket.url" http = require "socket.http" https = require "ssl.https" ltn12 = require "ltn12" serpent = (loadfile "./libs/serpent.lua")() feedparser = (loadfile "./libs/feedparser.lua")() json = (loadfile "./libs/JSON.lua")() mimetype = (loadfile "./libs/mimetype.lua")() redis = (loadfile "./libs/redis.l...
gpl-2.0
hafez16/senator
plugins/domaintools.lua
359
1494
local ltn12 = require "ltn12" local https = require "ssl.https" -- Edit data/mashape.lua with your Mashape API key -- http://docs.mashape.com/api-keys local mashape = load_from_file('data/mashape.lua', { api_key = '' }) local function check(name) local api = "https://domainsearch.p.mashape.com/index.php?"...
gpl-2.0
omid1212/hgbok
plugins/domaintools.lua
359
1494
local ltn12 = require "ltn12" local https = require "ssl.https" -- Edit data/mashape.lua with your Mashape API key -- http://docs.mashape.com/api-keys local mashape = load_from_file('data/mashape.lua', { api_key = '' }) local function check(name) local api = "https://domainsearch.p.mashape.com/index.php?"...
gpl-2.0
mirbot/zdgbbbrblsb-vbv
plugins/webshot.lua
919
1473
local helpers = require "OAuth.helpers" local base = 'https://screenshotmachine.com/' local url = base .. 'processor.php' local function get_webshot_url(param) local response_body = {} local request_constructor = { url = url, method = "GET", sink = ltn12.sink.table(response_body), header...
gpl-2.0
mms92/wire
lua/entities/gmod_wire_expression2/core/angle.lua
10
10065
/******************************************************************************\ Angle support \******************************************************************************/ // wow... this is basically just vector-support, but renamed angle-support :P // pitch, yaw, roll registerType("angle", "a", { 0, 0, 0 }, func...
apache-2.0
mirbot/zdgbbbrblsb-vbv
plugins/time.lua
771
2865
-- Implement a command !time [area] which uses -- 2 Google APIs to get the desired result: -- 1. Geocoding to get from area to a lat/long pair -- 2. Timezone to get the local time in that lat/long location -- Globals -- If you have a google api key for the geocoding/timezone api api_key = nil base_api = "https://m...
gpl-2.0
vipteam1/VIPTEAM
plugins/lock_emoji.lua
1
2756
--[[ ▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Team name : ( 🌐 VIP_TEAM 🌐 )▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ File name : ( #اسم الملف هنا ) ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Guenat team: ( @VIP_TEAM1 ) ▀▄ ▄▀ ▀▄...
gpl-2.0
sami2448/sam
plugins/wiki.lua
2
4097
-- http://git.io/vUA4M local socket = require "socket" local JSON = require "cjson" local wikiusage = { "!wiki [text]: Read extract from default Wikipedia (EN)", "!wiki(lang) [text]: Read extract from 'lang' Wikipedia. Example: !wikies hola", "!wiki search [text]: Search articles on default Wikipedia (EN)", "!...
gpl-2.0
RobertoMalatesta/ProDBG
tundra.lua
1
4753
----------------------------------------------------------------------------------------------------------------------- local mac_opts = { "-Wall", "-I.", "-DPRODBG_MAC", "-Weverything", "-Werror", "-Wno-unknown-warning-option", "-Wno-c11-extensions", "-Wno-variadic-macros", "-Wno-c++98-compat-pedantic", "-...
mit
mms92/wire
lua/entities/gmod_wire_fx_emitter.lua
10
3723
AddCSLuaFile() DEFINE_BASECLASS( "base_wire_entity" ) ENT.PrintName = "Wire FX Emitter" ENT.WireDebugName = "FX Emitter" function ENT:SetupDataTables() self:NetworkVar( "Bool", 0, "On" ) self:NetworkVar( "Int", 0, "Effect" ) self:NetworkVar( "Float", 0, "Delay" ) self:NetworkVar( "Vector", 0, "FXDir" ) end ...
apache-2.0
uzlonewolf/proxmark3
client/scripts/formatMifare.lua
6
5285
local cmds = require('commands') local getopt = require('getopt') local bin = require('bin') local lib14a = require('read14a') local utils = require('utils') example =[[ 1. script run formatMifare 2. script run formatMifare -k aabbccddeeff -n 112233445566 -a FF0780 ]] author = "Iceman" usage = "script run...
gpl-2.0
DJDaemonix/Roboports-Extended
prototypes/roboports/roboport-mk2.lua
1
6047
data:extend ( { { type = "roboport", name = "roboport-mk2", icon = "__base__/graphics/icons/roboport.png", icon_size = 32, flags = {"placeable-player", "player-creation"}, minable = {hardness = 0.2, mining_time = 0.5, result = "roboport-mk2"}, max_health = 750, corpse = "big-remn...
gpl-3.0