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
ryanplusplus/xlua
exercises/sublist/sublist_spec.lua
3
1610
local is_sublist = require('sublist') describe('sublist', function() it('should consider an empty list to be a sublist of an empty list', function() assert.equal(true, is_sublist({}, {})) end) it('should consider an empty list to be a sublist of a non-empty list', function() assert.equal(true, is_sublis...
mit
Corvass/BorrowedTime
Libs/LibMagicUtil-1.0/Locales/enUS.lua
1
1094
-- Generated by Babelfish script, do not add strings manually, only translate existing strings. -- This is the base locale; values can be "true" so they default to their key, or any string to override that behaviour. local L = LibStub("AceLocale-3.0"):NewLocale("LibMagicUtil-1.0", "enUS", true) L["Background Color"] ...
gpl-3.0
erwincoumans/premake-dev-iphone-xcode4
tests/actions/vstudio/vc2010/test_compile_settings.lua
1
13035
-- -- tests/actions/vstudio/vc2010/test_compile_settings.lua -- Validate compiler settings in Visual Studio 2010 C/C++ projects. -- Copyright (c) 2011-2012 Jason Perkins and the Premake project -- T.vstudio_vs2010_compile_settings = { } local suite = T.vstudio_vs2010_compile_settings local vc2010 = premake....
bsd-3-clause
mixflowtech/logsensor
lib/ljsyscall/test/bsd.lua
18
16048
-- General BSD tests local function init(S) local helpers = require "syscall.helpers" local types = S.types local c = S.c local abi = S.abi local bit = require "syscall.bit" local ffi = require "ffi" local t, pt, s = types.t, types.pt, types.s local assert = helpers.assert local function fork_assert(cond, err, .....
apache-2.0
sinavafa/ERRORTG
bot/utils.lua
239
13499
URL = require "socket.url" http = require "socket.http" https = require "ssl.https" ltn12 = require "ltn12" serpent = require "serpent" feedparser = require "feedparser" json = (loadfile "./libs/JSON.lua")() mimetype = (loadfile "./libs/mimetype.lua")() redis = (loadfile "./libs/redis.lua")() http.TIMEOUT = 10 funct...
gpl-2.0
RedCraneStudio/redcrane-engine
mildly-cold/generator.lua
1
4055
local noise = require("lj_noise") local M = {} local function triangle_fn(x, y) local freq = 5.0 return (8.0 / math.pi) * (math.sin(2 * math.pi * freq * x) - 1.0 / 9.0 * math.sin(6 * math.pi * freq * x) + 1.0 / 25.0 * math.sin(10 * math.pi * freq *x)) end local function noise_fn(x, y) return noise.Simpl...
bsd-3-clause
LuckyGameCn/LHCocosGame
cocos2d/cocos/scripting/lua-bindings/auto/api/PhysicsJointGroove.lua
3
1332
-------------------------------- -- @module PhysicsJointGroove -- @extend PhysicsJoint -------------------------------- -- @function [parent=#PhysicsJointGroove] setAnchr2 -- @param self -- @param #cc.Vec2 vec2 -------------------------------- -- @function [parent=#PhysicsJointGroove] setGrooveA -- @param ...
mit
ArchShaman/Zero-K
scripts/amphraid.lua
5
8630
--linear constant 65536 include "constants.lua" local base, torso, head = piece('base', 'torso', 'head') local rthigh, rshin, rfoot, lthigh, lshin, lfoot = piece('rthigh', 'rshin', 'rfoot', 'lthigh', 'lshin', 'lfoot') local lturret, rturret, lflare, rflare = piece('lturret', 'rturret', 'lflare', 'rflare') local fir...
gpl-2.0
3pehrdev/funny
plugins/inpm.lua
1114
3008
do local function pairsByKeys (t, f) local a = {} for n in pairs(t) do table.insert(a, n) end table.sort(a, f) local i = 0 -- iterator variable local iter = function () -- iterator function i = i + 1 if a[i] == nil then return nil else return a[i], t[a[i]] ...
gpl-2.0
dromozoa/dromozoa-graph
dromozoa/graph/render.lua
1
7466
-- Copyright (C) 2018 Tomoyuki Fujimori <moyu@dromozoa.com> -- -- This file is part of dromozoa-graph. -- -- dromozoa-graph 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 3 of the License, or...
gpl-3.0
SawyerHood/mal
lua/stepA_mal.lua
12
6275
#!/usr/bin/env lua local table = require('table') local readline = require('readline') local utils = require('utils') local types = require('types') local reader = require('reader') local printer = require('printer') local Env = require('env') local core = require('core') local List, Vector, HashMap = types.List, typ...
mpl-2.0
alarouche/premake-core
src/_premake_main.lua
5
7609
-- -- _premake_main.lua -- Script-side entry point for the main program logic. -- Copyright (c) 2002-2015 Jason Perkins and the Premake project -- local shorthelp = "Type 'premake5 --help' for help" local versionhelp = "premake5 (Premake Build Script Generator) %s" -- Load the collection of core scripts, req...
bsd-3-clause
jchuang1977/my_luci
modules/base/luasrc/model/ipkg.lua
82
5778
--[[ LuCI - Lua Configuration Interface (c) 2008-2011 Jo-Philipp Wich <xm@subsignal.org> (c) 2008 Steven Barth <steven@midlink.org> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apach...
apache-2.0
phi-psi/luci
libs/ipkg/luasrc/model/ipkg.lua
82
5778
--[[ LuCI - Lua Configuration Interface (c) 2008-2011 Jo-Philipp Wich <xm@subsignal.org> (c) 2008 Steven Barth <steven@midlink.org> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apach...
apache-2.0
ArchShaman/Zero-K
LuaUI/Widgets/gui_selection_hierarchy.lua
3
10991
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- function widget:GetInfo() return { name = "Selection Hierarchy", desc = "Implements selection heirarchy state.", author = "GoogleF...
gpl-2.0
ArchShaman/Zero-K
LuaRules/Configs/MetalSpots/Grts_Messa_008.lua
17
1312
return { spots = { -- Four metal spots in center {x = 6162, z = 6750, metal = 3}, {x = 5546, z = 6128, metal = 3}, {x = 6138, z = 5562, metal = 3}, {x = 6747, z = 6152, metal = 3}, -- 12 starting spots (2x3 on each side) {x = 1093, z = 9286, metal = 3}, {x = 1174, z = 7125, metal = 3}, {x = 1208, z =...
gpl-2.0
ArchShaman/Zero-K
units/chickenblobber.lua
2
3277
unitDef = { unitname = [[chickenblobber]], name = [[Blobber]], description = [[Heavy Artillery]], acceleration = 0.36, activateWhenBuilt = true, brakeRate = 0.205, buildCostEnergy = 0, buildCostMetal = 0, builder = false, buil...
gpl-2.0
DBReinitialized/PigBot
Source/deps/discordia/voice/sodium.lua
3
1541
return function(filename) local ffi = require("ffi") local success, lib = pcall(ffi.load, filename) if not success then return error(lib) end local new = ffi.new ffi.cdef[[ const char *sodium_version_string(void); size_t crypto_secretbox_keybytes(void); size_t crypto_secretbox_noncebytes(void); size_t crypto_secret...
mit
LuckyGameCn/LHCocosGame
cocos2d/cocos/scripting/lua-bindings/auto/api/Scene.lua
5
1135
-------------------------------- -- @module Scene -- @extend Node -------------------------------- -- @function [parent=#Scene] getPhysicsWorld -- @param self -- @return PhysicsWorld#PhysicsWorld ret (return value: cc.PhysicsWorld) -------------------------------- -- @function [parent=#Scene] create -- @pa...
mit
ArchShaman/Zero-K
units/turretimpulse.lua
3
5292
unitDef = { unitname = [[turretimpulse]], name = [[Newton]], description = [[Gravity Turret]], activateWhenBuilt = true, buildCostMetal = 200, builder = false, buildingGroundDecalDecaySpeed = 3...
gpl-2.0
Paaskehare/SurvivalTD
game/survival_td/scripts/vscripts/abilities/build_tower.lua
1
7555
build_tower = class ({}) function build_tower:PositionCollides(position) local UnitWidth = 128 local UnitWidthHalf = UnitWidth / 2 local BlockingSize = UnitWidthHalf local collided = false local BlockingEntities = Entities:FindAllInSphere(GetGroundPosition(position, nil), Bl...
mit
CoderDojo024/Love2d-Tutorial-Scrolling-Shooter
Shooter/functies.lua
1
2286
function xRechterRand() return love.graphics.getWidth() - speler.plaatje:getWidth() end function yOnderRand() return love.graphics.getHeight() end function xWillekeurig() return math.random(50, love.graphics.getWidth() - 50) end function tekenVijanden(vijanden) for index, vijand in ipairs(vijand...
mit
bbohling/keys
VSCOKeys.lrdevplugin/Init.lua
11
1912
--[[---------------------------------------------------------------------------- VSCO Keys for Adobe Lightroom Copyright (C) 2015 Visual Supply Company Licensed under GNU GPLv2 (or any later version). This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public Lic...
gpl-2.0
gkamal/likwid
src/applications/likwid-powermeter.lua
7
11455
#!<PREFIX>/bin/likwid-lua --[[ * ======================================================================================= * * Filename: likwid-powermeter.lua * * Description: An application to get information about power * consumption on architectures implementing the RAPL interface. * * ...
gpl-3.0
jchuang1977/my_luci
applications/luci-statistics/luasrc/statistics/rrdtool/definitions/interface.lua
69
2769
--[[ Luci statistics - interface plugin diagram definition (c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www....
apache-2.0
ArchShaman/Zero-K
LuaUI/utility_two.lua
17
1410
-- Utility function for ZK -- Will try to read LUA content from target file and create BACKUP if have a successful read (in user's Spring folder) OR DELETE them if have a failure read -- This prevent corrupted file from being used. -- Note: currently only a "table" is considered a valid file function CheckLUAFileAndBa...
gpl-2.0
phi-psi/luci
applications/luci-splash/luasrc/model/cbi/splash/splash.lua
52
3212
--[[ LuCI - Lua Configuration Interface Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 ]]-- require("luci.model.uci") m = Map("luci_splash", translate...
apache-2.0
d9magai/freeciv
dependencies/tolua-5.2/src/bin/lua/enumerate.lua
14
1815
-- tolua: enumerate class -- Written by Waldemar Celes -- TeCGraf/PUC-Rio -- Jul 1998 -- $Id: enumerate.lua,v 1.3 2009/11/24 16:45:13 fabraham Exp $ -- This code is free software; you can redistribute it and/or modify it. -- The software provided hereunder is on an "as is" basis, and -- the author has no obligation to...
gpl-2.0
eigenl/tge
bin/TGE.app/Contents/Resources/scripts/textadventure/logic.lua
2
1635
GameObject = {} -- Some global fields GameObject.MainInput = nil GameObject.MainConsole = nil GameObject.init = function () print("Init GameObject ...") GameObject.MainInput = LuaTextField(UI.createTextField({ y = 24, width = 80, inputPrefix = "> ", mainInput = true })) GameObject.MainConsole = LuaC...
mit
dangersos/fffff
plugins/btc.lua
289
1375
-- See https://bitcoinaverage.com/api local function getBTCX(amount,currency) local base_url = 'https://api.bitcoinaverage.com/ticker/global/' -- Do request on bitcoinaverage, the final / is critical! local res,code = https.request(base_url..currency.."/") if code ~= 200 then return nil end local data = j...
gpl-2.0
ArchShaman/Zero-K
scripts/shieldcon.lua
5
5147
-- original bos animation by Chris Mackey -- converted to lua by psimyn include 'constants.lua' local base, pelvis, torso = piece('base', 'pelvis', 'torso') local shield = piece 'shield' local lathe = piece 'lathe' local emit = piece 'emit' local centerpoint = piece 'centerpoint' local rthigh, ruppercalf, rlowerca...
gpl-2.0
bbohling/keys
VSCOKeys.lrdevplugin/ActivateKeys.lua
11
1463
--[[---------------------------------------------------------------------------- VSCO Keys for Adobe Lightroom Copyright (C) 2015 Visual Supply Company Licensed under GNU GPLv2 (or any later version). This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public Lic...
gpl-2.0
celeron55/buildat
client/sandbox.lua
1
7497
-- Buildat: client/sandbox.lua -- http://www.apache.org/licenses/LICENSE-2.0 -- Copyright 2014 Perttu Ahola <celeron55@gmail.com> local log = buildat.Logger("sandbox") local dump = buildat.dump -- -- Base sandbox environment -- __buildat_sandbox_environment = { assert = assert, -- Safe according to http://lua-users....
apache-2.0
scholzd/MoonGen
lua/crc-ratecontrol.lua
4
2956
local device = require "device" local pkt = require "packet" local memory = require "memory" local ffi = require "ffi" local log = require "log" local txQueue = device.__txQueuePrototype local device = device.__devicePrototype local C = ffi.C ffi.cdef[[ void moongen_send_all_packets_with_delay_bad_crc(uint8...
mit
galnegus/Glaskross
component/input/BulletInputComponent.lua
1
2329
local Class = require "lib.hump.Class" local InputComponent = require "component.input.InputComponent" local Signals = require "constants.Signals" local EntityTypes = require "constants.EntityTypes" local Constants = require "constants.Constants" local BulletInputComponent = Class{} BulletInputComponent:include(InputC...
mit
brahmi2/prosody-modules
mod_motd_sequential/mod_motd_sequential.lua
32
1482
-- Prosody IM -- Copyright (C) 2008-2010 Matthew Wild -- Copyright (C) 2008-2010 Waqas Hussain -- Copyright (C) 2010 Jeff Mitchell -- -- This project is MIT/X11 licensed. Please see the -- COPYING file in the source package for more information. -- local host = module:get_host(); local motd_jid = module:get_option("mo...
mit
bbohling/keys
VSCOKeys.lrdevplugin/Info.lua
11
1580
--[[---------------------------------------------------------------------------- VSCO Keys for Adobe Lightroom Copyright (C) 2015 Visual Supply Company Licensed under GNU GPLv2 (or any later version). This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public Lic...
gpl-2.0
mixflowtech/logsensor
src/apps/lwaftr/ndp.lua
3
16664
module(..., package.seeall) -- NDP address resolution. -- Given a remote IPv6 address, try to find out its MAC address. -- If resolution succeeds: -- All packets coming through the 'south' interface (ie, via the network card) -- are silently forwarded. -- Note that the network card can drop packets; if it does, they w...
apache-2.0
phi-psi/luci
applications/luci-statistics/luasrc/model/cbi/luci_statistics/ping.lua
80
1397
--[[ Luci configuration model for statistics - collectd ping plugin configuration (c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License ...
apache-2.0
lowne/hammerspoon
extensions/fnutils/init.lua
11
20125
--- === hs.fnutils === --- --- Functional programming utility functions local fnutils = {} local pairs,ipairs = pairs,ipairs local floor = math.floor --- hs.fnutils.imap(list, fn) -> list --- Function --- Execute a function across a list-like table in order, and collect the results --- --- Parameters: --- * list - ...
mit
phi-psi/luci
libs/json/luasrc/json.lua
50
13333
--[[ LuCI - Lua Configuration Interface Copyright 2008 Steven Barth <steven@midlink.org> Copyright 2008 Jo-Philipp Wich <xm@leipzig.freifunk.net> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at ht...
apache-2.0
turingbot/BDReborn
libs/fakeredis.lua
650
40405
local unpack = table.unpack or unpack --- Bit operations local ok,bit if _VERSION == "Lua 5.3" then bit = (load [[ return { band = function(x, y) return x & y end, bor = function(x, y) return x | y end, bxor = function(x, y) return x ~ y end, bnot = function(x) return ~x end, rshift = function(x...
gpl-3.0
MarchM4/Milkyway-home-server-expansion
separation/tests/ResultSets.lua
4
3857
oldTestSet = { ["small_test11"] = { file = "astronomy_parameters-11-small.txt", stars = "stars/stars-11.txt", parameters = { 0.571713, 12.312119, -3.305187, 148.010257, 22.453902, 0.42035, -0.468858, 0.760579, -1.361644, 177.884238, 23.882892, 1.210639, ...
gpl-3.0
galnegus/Glaskross
lib/sperm/loveframes/objects/internal/scrollable/scrollarea.lua
3
5549
--[[------------------------------------------------ -- Love Frames - A GUI library for LOVE -- -- Copyright (c) 2013 Kenny Shields -- --]]------------------------------------------------ -- scrollarea class local newobject = loveframes.NewObject("scrollarea", "loveframes_object_scrollarea", true) --[[-------------...
mit
Brusalk/EventHorizon_Continued
EventHorizon_Warrior/config.lua
1
4299
function EventHorizon:InitializeClass() self.config.gcdSpellID = 1680 -- -- Arms -- Colossus Smash + Warbreaker self:newSpell({ cooldown = {167105, 262161}, debuff = {167105, 262161}, requiredTree = 1, }) -- Rend self:newSpell({ debuff = {772, 3}, r...
mit
ArchShaman/Zero-K
LuaUI/Configs/integral_menu_config.lua
5
5927
local buildCmdFactory, buildCmdEconomy, buildCmdDefence, buildCmdSpecial, buildCmdUnits, commandDisplayConfig, hiddenCommands = include("Configs/integral_menu_commands.lua") local function CommandClickFunction() local _,_, meta,_ = Spring.GetModKeyState() if not meta then return false end WG.crude.OpenPath("Hot...
gpl-2.0
sternold/Love2DRL
src/game/classes/Equipment.lua
1
1710
Equipment = class('Equipment') function Equipment:initialize(slot, power_bonus, defense_bonus, max_hp_bonus, equip_function, usage_table) self.slot = slot self.is_equipped = false self.power_bonus = power_bonus self.defense_bonus = defense_bonus self.max_hp_bonus = max_hp_bonus self.equip_functi...
mit
DBReinitialized/PigBot
Source/deps/discordia/client/API.lua
1
21556
local json = require('json') local timer = require('timer') local http = require('coro-http') local package = require('../package') local Mutex = require('../utils/Mutex') local format = string.format local request = http.request local setTimeout = timer.setTimeout local max, random = math.max, math.random local encod...
mit
ArchShaman/Zero-K
effects/sonic.lua
5
4080
Spring = Spring or {} Spring.Utilities = Spring.Utilities or {} VFS.Include("LuaRules/Utilities/tablefunctions.lua") local fx = { ['sonic'] = { groundflash = { air = true, underwater = true, circlealpha = 0.6, circlegrowth = 2, flashalpha = ...
gpl-2.0
Gwinel/likwid
src/applications/likwid-agent.lua
10
13028
#!/home/rrze/unrz/unrz139/Work/likwid/trunk/ext/lua/lua package.path = package.path .. ';' .. string.gsub(debug.getinfo(1).source, "^@(.+/)[^/]+$", "%1") .. '/?.lua' local likwid = require("likwid") dconfig = {} dconfig["groupStrings"] ={} dconfig["groupData"] ={} dconfig["duration"] = 1 dconfig["groupPath"] = "/home...
gpl-3.0
Shayan123456/botttttt8
plugins/stats.lua
168
4001
do -- Returns a table with `name` and `msgs` 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_prin...
gpl-2.0
amirhooo/db
libs/dkjson.lua
63
26559
-- Module options: local always_try_using_lpeg = true local register_global_module_table = false local global_module_name = 'json' --[==[ David Kolf's JSON module for Lua 5.1/5.2 ======================================== *Version 2.4* In the default configuration this module writes no global values...
gpl-2.0
Y33XY/ASD_Falluja
libs/JSON.lua
3765
34843
-- -*- coding: utf-8 -*- -- -- Simple JSON encoding and decoding in pure Lua. -- -- Copyright 2010-2014 Jeffrey Friedl -- http://regex.info/blog/ -- -- Latest version: http://regex.info/blog/lua/json -- -- This code is released under a Creative Commons CC-BY "Attribution" License: -- http://creativecommons.org/licenses...
gpl-2.0
dangersos/fffff
libs/JSON.lua
3765
34843
-- -*- coding: utf-8 -*- -- -- Simple JSON encoding and decoding in pure Lua. -- -- Copyright 2010-2014 Jeffrey Friedl -- http://regex.info/blog/ -- -- Latest version: http://regex.info/blog/lua/json -- -- This code is released under a Creative Commons CC-BY "Attribution" License: -- http://creativecommons.org/licenses...
gpl-2.0
ArchShaman/Zero-K
gamedata/modularcomms/weapons/napalmgrenade.lua
5
1433
local name = "commweapon_napalmgrenade" local weaponDef = { name = [[Hellfire Grenade]], accuracy = 256, areaOfEffect = 256, --cegTag = [[torpedo_trail]], commandFire = true, craterBoost = 0, craterMult = 0, cust...
gpl-2.0
Maxsteam/Test
libs/redis.lua
566
1214
local Redis = require 'redis' local FakeRedis = require 'fakeredis' local params = { host = os.getenv('REDIS_HOST') or '127.0.0.1', port = tonumber(os.getenv('REDIS_PORT') or 6379) } local database = os.getenv('REDIS_DB') local password = os.getenv('REDIS_PASSWORD') -- Overwrite HGETALL Redis.commands.hgetall = ...
gpl-2.0
ArchShaman/Zero-K
gamedata/modularcomms/weapons/sunburst.lua
5
1316
local name = "commweapon_sunburst" local weaponDef = { name = [[Sunburst Cannon]], areaOfEffect = 32, avoidFriendly = true, commandfire = true, craterBoost = 1, craterMult = 6, customParams = { slot = [[3]], muzzleEffect...
gpl-2.0
ArchShaman/Zero-K
units/damagesinkrock.lua
6
1114
unitDef = { unitname = [[rocksink]], name = [[Rocking Damage Sink thing]], description = [[Rocks when you shoot at it.]], acceleration = 0, autoHeal = 500000, buildCostMetal = 10, builder = false, buildingGr...
gpl-2.0
alarouche/premake-core
src/base/table.lua
11
9265
-- -- table.lua -- Additions to Lua's built-in table functions. -- Copyright (c) 2002-2013 Jason Perkins and the Premake project -- -- -- Make a copy of the indexed elements of the table. -- function table.arraycopy(object) local result = {} for i, value in ipairs(object) do result[i] = value end return ...
bsd-3-clause
erwincoumans/premake-dev-iphone-xcode4
tests/actions/xcode/test_xcode_project.lua
2
52909
-- -- tests/actions/xcode/test_xcode_project.lua -- Automated test suite for Xcode project generation. -- Copyright (c) 2009-2011 Jason Perkins and the Premake project -- T.xcode3_project = { } local suite = T.xcode3_project local xcode = premake.xcode -----------------------------------------------------------...
bsd-3-clause
mixflowtech/logsensor
src/program/packetblaster/synth/synth.lua
14
1360
-- Use of this source code is governed by the Apache 2.0 license; see COPYING. module(..., package.seeall) local config = require("core.config") local main = require("core.main") local Synth = require("apps.test.synth").Synth local lib = require("core.lib") local packetblaster = require("program.pa...
apache-2.0
abasshacker/abas0
plugins/google.lua
336
1323
do local function googlethat(query) local url = 'http://ajax.googleapis.com/ajax/services/search/web?v=1.0&safe=active&&rsz=5&' local parameters = 'q='..(URL.escape(query) or '') -- Do the request local res, code = https.request(url..parameters) if code ~=200 then return nil end loca...
gpl-2.0
amirquick/quick
plugins/google.lua
336
1323
do local function googlethat(query) local url = 'http://ajax.googleapis.com/ajax/services/search/web?v=1.0&safe=active&&rsz=5&' local parameters = 'q='..(URL.escape(query) or '') -- Do the request local res, code = https.request(url..parameters) if code ~=200 then return nil end loca...
gpl-2.0
ld-test/concurrentlua
src/concurrent/register.lua
2
1535
-- Submodule for process name registering. module('concurrent._register', package.seeall) names = {} -- Process names and PIDs associative table. -- Registers a PID with the specified name. Returns true if successful or false -- otherwise. function register(name, pid) if whereis(name) then ...
mit
ArchShaman/Zero-K
LuaRules/Gadgets/unit_boolean_disable.lua
3
9726
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- function gadget:GetInfo() return { name = "Boolean Disable", desc = "Handles disables which act in a boolean way (similar to engine defau...
gpl-2.0
ArchShaman/Zero-K
LuaUI/Widgets/gui_chili_minimap.lua
4
32065
function widget:GetInfo() return { name = "Chili Minimap", desc = "v0.895 Chili Minimap", author = "Licho, CarRepairer", date = "@2010", license = "GNU GPL, v2 or later", layer = -100000, enabled = true, } end VFS.Include("LuaRules/Configs/customcmds.h.lua") in...
gpl-2.0
LuckyGameCn/LHCocosGame
cocos2d/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua
3
5365
-------------------------------- -- @module RenderTexture -- @extend Node -------------------------------- -- @function [parent=#RenderTexture] setVirtualViewport -- @param self -- @param #cc.Vec2 vec2 -- @param #rect_table rect -- @param #rect_table rect -------------------------------- -- @function [paren...
mit
brahmi2/prosody-modules
mod_vjud/vcard.lib.lua
32
9198
-- Copyright (C) 2011-2012 Kim Alvefur -- -- This project is MIT/X11 licensed. Please see the -- COPYING file in the source package for more information. -- -- TODO -- Fix folding. local st = require "util.stanza"; local t_insert, t_concat = table.insert, table.concat; local type = type; local next, pairs, ipairs = n...
mit
jchuang1977/my_luci
modules/base/luasrc/sgi/cgi.lua
87
2260
--[[ LuCI - SGI-Module for CGI Description: Server Gateway Interface for CGI FileId: $Id$ License: Copyright 2008 Steven Barth <steven@midlink.org> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at...
apache-2.0
jokerdevv/Joker-Developer
plugins/newgroup.lua
12
35829
--[[ # For More Information ....! # Developer : Aziz < @devss_bot > #Dev # our channel: @help_tele ]] -- data saved to moderation.json -- check moderation plugin do local function create_group(msg) -- superuser and admins only (because sudo are always has privilege) if is_sudo(msg) or is_realm(msg) and...
gpl-2.0
ashemedai/ProDBG
bin/macosx/tundra/scripts/tundra/debugger.lua
28
38532
--{{{ history --15/03/06 DCN Created based on RemDebug --28/04/06 DCN Update for Lua 5.1 --01/06/06 DCN Fix command argument parsing -- Add step/over N facility -- Add trace lines facility --05/06/06 DCN Add trace call/return facility --06/06/06 DCN Make it behave when stepping through the cr...
mit
ArchShaman/Zero-K
effects/beamer.lua
25
2991
-- beamerray return { ["beamerray"] = { usedefaultexplosions = false, groundflash = { circlealpha = 0, circlegrowth = 1, flashalpha = 1.0, flashsize = 26, ttl = 24, color = { [1] = 0, [2] = 0, [3] = 1,...
gpl-2.0
ArchShaman/Zero-K
LuaUI/Widgets/camera_cofc.lua
4
93174
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- function widget:GetInfo() return { name = "Combo Overhead/Free Camera (experimental)", desc = "v0.138 Camera featuring 6 actions", au...
gpl-2.0
eigenl/tge
bin/scripts/mazegame/map.lua
2
4501
Map = {} Map.Width = 20 Map.Height = 20; Map.Data = "" Map.create = function () print("Create map ...") Map.Data = "############### ".. "#.....T.......# ".. "#.###.T.#####.# ".. "#.# #...#,,,#.######".. "#.###.####,##......#".. "#.....#,,,,,#.####.#".. "###.####,####.#...
mit
ArchShaman/Zero-K
units/amphtele.lua
4
2083
unitDef = { unitname = [[amphtele]], name = [[Djinn]], description = [[Amphibious Teleport Bridge]], acceleration = 0.25, activateWhenBuilt = true, brakeRate = 0.75, buildCostMetal = 750, buildPic = [[amphtele.p...
gpl-2.0
amirhooo/db
plugins/membercontrol.lua
16
23892
local function is_spromoted(chat_id, user_id) local hash = 'sprom:'..chat_id..':'..user_id local spromoted = redis:get(hash) return spromoted or false end local function kick_user(user_id, chat_id) local chat = 'chat#id'..chat_id local user = 'user#id'..user_id chat_del_user(chat, user, ok_cb, true) end ...
gpl-2.0
ArchShaman/Zero-K
LuaRules/Gadgets/unit_invincibility.lua
5
1560
function gadget:GetInfo() return { name = "Invincibility", desc = "Implements invicibility and neutrality that persists over luarules reload and save/load (thanks to the unitRulesParam).", author = "GoogleFrog", date = "5 August 2017", license = "GNU GPL, v2 or later", layer = 0, ...
gpl-2.0
lowne/hammerspoon
extensions/webview/init.lua
5
18179
--- === hs.webview === --- --- Display web content in a window from Hammerspoon --- --- This module uses Apple's WebKit WKWebView class to provide web content display with JavaScript injection support. The objective is to provide a functional interface to the WKWebView and WKUserContentController classes. --- --- This...
mit
alarouche/premake-core
tests/base/test_detoken.lua
9
3290
-- -- tests/base/test_detoken.lua -- Test suite for the token expansion API. -- Copyright (c) 2011-2014 Jason Perkins and the Premake project -- local suite = test.declare("detoken") local detoken = premake.detoken -- -- Setup -- local x, action local environ = {} function suite.setup() action = premake.ac...
bsd-3-clause
brahmi2/prosody-modules
mod_statistics/top.lua
32
6810
module("prosodytop", package.seeall); local array = require "util.array"; local it = require "util.iterators"; local curses = require "curses"; local stats = require "stats".stats; local time = require "socket".gettime; local sessions_idle_after = 60; local stanza_names = {"message", "presence", "iq"}; local top = {...
mit
webbuddy/ifalcon
Data/Scripts/mime.lua
118
2433
----------------------------------------------------------------------------- -- MIME support for the Lua language. -- Author: Diego Nehab -- Conforming to RFCs 2045-2049 -- RCS ID: $Id: mime.lua,v 1.29 2007/06/11 23:44:54 diego Exp $ ----------------------------------------------------------------------------- ------...
gpl-3.0
ArchShaman/Zero-K
LuaRules/Gadgets/cmd_transfer_unit.lua
13
1909
function gadget:GetInfo() return { name = "Command Transfer Unit", desc = "Adds a command to transfer units between teams.", author = "GoogleFrog", date = "8 September 2017", license = "GNU GPL, v2 or later", layer = 0, enabled = true, } end include("LuaRules/Configs/customcmds.h.lua") if g...
gpl-2.0
Maxsteam/Test
libs/JSON.lua
3765
34843
-- -*- coding: utf-8 -*- -- -- Simple JSON encoding and decoding in pure Lua. -- -- Copyright 2010-2014 Jeffrey Friedl -- http://regex.info/blog/ -- -- Latest version: http://regex.info/blog/lua/json -- -- This code is released under a Creative Commons CC-BY "Attribution" License: -- http://creativecommons.org/licenses...
gpl-2.0
aqasaeed/sparta1
libs/JSON.lua
3765
34843
-- -*- coding: utf-8 -*- -- -- Simple JSON encoding and decoding in pure Lua. -- -- Copyright 2010-2014 Jeffrey Friedl -- http://regex.info/blog/ -- -- Latest version: http://regex.info/blog/lua/json -- -- This code is released under a Creative Commons CC-BY "Attribution" License: -- http://creativecommons.org/licenses...
gpl-2.0
Arashsezar/Telegram-Bot
libs/JSON.lua
3765
34843
-- -*- coding: utf-8 -*- -- -- Simple JSON encoding and decoding in pure Lua. -- -- Copyright 2010-2014 Jeffrey Friedl -- http://regex.info/blog/ -- -- Latest version: http://regex.info/blog/lua/json -- -- This code is released under a Creative Commons CC-BY "Attribution" License: -- http://creativecommons.org/licenses...
gpl-2.0
MarchM4/Milkyway-home-server-expansion
mwtao/tests/stripe82.lua
4
1415
wedge = 82 start = { background = { q = 0.456, r0 = 19.530 }, streams = { { epsilon = -1.828, mu = 31.361, r = 29.228, theta = 1.696, phi = 0.044, sigma = 2.854 } } } max = { background = { q = 1.000...
gpl-3.0
samijon/anti
plugins/Lyrics.lua
695
2113
do local BASE_LNM_URL = 'http://api.lyricsnmusic.com/songs' local LNM_APIKEY = '1f5ea5cf652d9b2ba5a5118a11dba5' local BASE_LYRICS_URL = 'http://api.chartlyrics.com/apiv1.asmx/SearchLyricDirect' local function getInfo(query) print('Getting info of ' .. query) local url = BASE_LNM_URL..'?api_key='..LNM_APIKEY ...
gpl-2.0
d9magai/freeciv
dependencies/tolua-5.2/src/bin/lua/compat.lua
7
4170
------------------------------------------------------------------- -- Real globals -- _ALERT -- _ERRORMESSAGE -- _VERSION -- _G -- assert -- error -- metatable -- next -- print -- require -- tonumber -- tostring -- type ------------------------------------------------------------------- -- collectgarbage -- gcinfo -...
gpl-2.0
scholzd/MoonGen
test/tests/01-send.lua
8
1672
-- Function to test: Send -- Test against: Network card speed. local luaunit = require "luaunit" local dpdk = require "dpdk" local memory = require "memory" local device = require "device" local timer = require "timer" local log = require "testlog" local testlib = require "testlib" local tconfig = require "tconfig" ...
mit
brahmi2/prosody-modules
mod_stanza_counter/mod_stanza_counter.lua
32
3033
-- (C) 2011, Marco Cirillo (LW.Org) -- General Stanzas' Counter. local jid_bare = require "util.jid".bare -- Setup, Init functions. -- initialize function counter table on the global object on start local function init_counter() prosody.stanza_counter = { iq = { incoming=0, outgoing=0 }, message = { incoming=0, ...
mit
badboyam/mr
plugins/inrealm.lua
71
25005
-- data saved to moderation.json -- check moderation plugin do local function create_group(msg) -- superuser and admins only (because sudo are always has privilege) if is_sudo(msg) or is_realm(msg) and is_admin(msg) then local group_creator = msg.from.print_name create_g...
gpl-2.0
gmorishere/bsoeted
plugins/anti_spam.lua
102
3744
--An empty table for solving multiple kicking problem(thanks to @topkecleon ) kicktable = {} do local TIME_CHECK = 2 -- seconds local data = load_data(_config.moderation.data) -- Save stats, ban user local function pre_process(msg) -- Ignore service msg if msg.service then return msg end if msg.from.id =...
gpl-2.0
Kyominii/Cops_FiveM
police/locales/de.lua
1
7654
i18n.importData("de", { police_station = "Polizeistation", title_notification = "Regierung", now_cuffed = "Dir wurden die Handschellen angelegt !", now_uncuffed = "Freiheit !", info_fine_request_before_amount = "Drücke ~g~Y~s~ um das Strafgeld zu akzeptieren $", info_fine_request_after_amount = " , drücke ~r~R~s~...
mit
eonpatapon/contrail-controller
src/vnsw/agent/contrail/agent_dissector.lua
5
6522
local dprint2 = function() end dprint2 = function(...) print(table.concat({"Lua:", ...}," ")) end ---------------------------------------- -- creates a Proto object, but doesn't register it yet local agent = Proto("agent","agent Protocol") ---------------------------------------- -- multiple ways to do the same th...
apache-2.0
phi-psi/luci
applications/luci-statistics/luasrc/statistics/rrdtool/definitions/iptables.lua
86
1131
--[[ Luci statistics - iptables plugin diagram definition (c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.a...
apache-2.0
Phanx/oUF
elements/ricons.lua
7
2020
--[[ Element: Raid Icon Handles updating and toggles visibility of raid target icons. Widget RaidIcon - A Texture used to display the raid target icon. Notes This element updates by changing the texture. The default raid icons will be used if the UI widget is a texture and doesn't have a texture or color d...
mit
d9magai/freeciv
dependencies/tolua-5.2/src/bin/lua/basic.lua
4
4653
-- tolua: basic utility functions -- Written by Waldemar Celes -- TeCGraf/PUC-Rio -- Jul 1998 -- Last update: Apr 2003 -- $Id: basic.lua,v 1.4 2009/11/24 16:45:13 fabraham Exp $ -- This code is free software; you can redistribute it and/or modify it. -- The software provided hereunder is on an "as is" basis, and -- th...
gpl-2.0
phi-psi/luci
contrib/luadoc/lua/luadoc/lp.lua
175
4389
---------------------------------------------------------------------------- -- Lua Pages Template Preprocessor. -- -- @release $Id: lp.lua,v 1.7 2007/04/18 14:28:39 tomas Exp $ ---------------------------------------------------------------------------- local assert, error, getfenv, loadstring, setfenv = assert, erro...
apache-2.0
lowne/hammerspoon
extensions/httpserver/hsminweb.lua
5
84146
--- === hs.httpserver.hsminweb === --- --- Minimalist Web Server for Hammerspoon --- --- This module aims to be a minimal, but (mostly) standards-compliant web server for use within Hammerspoon. Expanding upon the Hammerspoon module, `hs.httpserver`, this module adds support for serving static pages stored at a speci...
mit
rashed8271/bot
libs/JSON.lua
3765
34843
-- -*- coding: utf-8 -*- -- -- Simple JSON encoding and decoding in pure Lua. -- -- Copyright 2010-2014 Jeffrey Friedl -- http://regex.info/blog/ -- -- Latest version: http://regex.info/blog/lua/json -- -- This code is released under a Creative Commons CC-BY "Attribution" License: -- http://creativecommons.org/licenses...
gpl-2.0