repo_name
stringlengths
6
78
path
stringlengths
4
206
copies
stringclasses
281 values
size
stringlengths
4
7
content
stringlengths
625
1.05M
license
stringclasses
15 values
dafei2015/IntWars
BinWars/Scripts/Heroes/Karthus.lua
4
4297
--[[ NotSingleTargetSpell = true DoesntBreakShields = true DoesntTriggerSpellCasts = false CastingBreaksStealth = true IsDamagingSpell = true local R1 = {Function = BBPreloadParticle} R1["Params"] = {Name = 'laywaste_point.troy'} --R2 = {} / R2["Name"] = "laywaste_point.troy" / R1["Params"] = R2 local R2 = {Function ...
gpl-3.0
pixeltailgames/gm-mediaplayer
lua/mediaplayer/services/twitchstream/init.lua
1
1286
AddCSLuaFile "shared.lua" include "shared.lua" local urllib = url local APIKey = MediaPlayer.GetConfigValue('twitch.client_id') local MetadataUrl = "https://api.twitch.tv/kraken/streams/%s?client_id=%s" local function OnReceiveMetadata( self, callback, body ) local metadata = {} local response = util.JSONToTable...
mit
mahdib77/bot
utilities.lua
1
21286
-- utilities.lua -- Functions shared among plugins. function get_word(s, i) -- get the indexed word in a string s = s or '' i = i or 1 local t = {} for w in s:gmatch('%g+') do table.insert(t, w) end return t[i] or false end function string:input() -- Returns the string after the first space. if not self:...
gpl-2.0
Enfernuz/quik-lua-rpc
curve_keypair_generator.lua
1
1027
package.path = "?.lua;" .. package.path local scriptPath = getScriptPath() local zmq = require("lzmq") local utils = require("utils.utils") local function localize (str) return utils.Utf8ToCp1251(str) end function main () local pub, sec = zmq.curve_keypair() if pub == nil then local msg = string.format...
apache-2.0
LuigiLazzari/Lua
test.lua
1
5211
package.cpath = package.cpath..";./?.dll;./?.so;../lib/?.so;../lib/vc_dll/?.dll;../lib/bcc_dll/?.dll;../lib/mingw_dll/?.dll;" require("wx") frame = nil editor = 1 --the editor page function LoadFile(filePath, editor, file_exists) local file_text = "" local handle = io.open(filePath, "rb") if handle then ...
mit
gajop/Zero-K
LuaUI/Widgets/chili/Skins/Robocracy/skin.lua
2
5807
--//============================================================================= --// Skin local skin = { info = { name = "Robocracy", version = "0.3", author = "jK", } } --//============================================================================= --// skin.general = { focusColor = {1.0,...
gpl-2.0
CodeAnxiety/premake-core
tests/actions/vstudio/vc200x/test_files.lua
6
12963
-- -- tests/actions/vstudio/vc200x/test_files.lua -- Validate generation of <files/> block in Visual Studio 200x projects. -- Copyright (c) 2009-2014 Jason Perkins and the Premake project -- local suite = test.declare("vstudio_vs200x_files") local vc200x = premake.vstudio.vc200x -- -- Setup -- loca...
bsd-3-clause
Sweet-kid/Algorithm-Implementations
Memoization/Lua/Yonaba/memoize_test.lua
26
1080
-- Tests for memoize.lua local memoize = require 'memoize' local total, pass = 0, 0 local function dec(str, len) return #str < len and str .. (('.'):rep(len-#str)) or str:sub(1,len) end local function run(message, f) total = total + 1 local ok, err = pcall(f) if ok then pass = pass + 1 end local...
mit
starius/toposort
spec/toposort_spec.lua
1
12770
-- toposort, Topological sorting -- Copyright (c) 2015 Boris Nagaev -- See the LICENSE file for terms of use. describe("Topological sorting module", function() it("loads 'toposort' module", function() require 'toposort' end) end) describe("Function toposort.transpose", function() it("transpose...
mit
N3X15/spacebuild
lua/entities/other_spotlight/init.lua
5
3048
AddCSLuaFile("cl_init.lua") AddCSLuaFile("shared.lua") util.PrecacheSound("Buttons.snd17") include('shared.lua') local Energy_Increment = 4 function ENT:Initialize() self.BaseClass.Initialize(self) self.Active = 0 self.damaged = 0 self.flashlight = nil if not (WireAddon == nil) then self...
apache-2.0
KayMD/Illarion-Content
craft/final/finesmithing.lua
2
13140
--[[ Illarion Server This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it wi...
agpl-3.0
trappi-stone/Factorio-Stdlib
spec/area/surface_spec.lua
1
1515
require 'spec/setup/defines' local Surface = require 'stdlib/area/surface' describe('Surface Spec', function() describe('Surface lookups', function() it('should work with no parameters', function() assert.same({ }, Surface.lookup()) end) it('should work with string parameters',...
isc
gajop/Zero-K
LuaUI/Widgets/chili/Controls/button.lua
17
1147
--//============================================================================= Button = Control:Inherit{ classname= "button", caption = 'button', defaultWidth = 70, defaultHeight = 20, } local this = Button local inherited = this.inherited --//============================================================...
gpl-2.0
KayMD/Illarion-Content
monster/race_114_akaltut/id_1142_akaltut.lua
2
3238
--[[ Illarion Server This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it wi...
agpl-3.0
gajop/Zero-K
units/corraid.lua
2
6946
unitDef = { unitname = [[corraid]], name = [[Ravager]], description = [[Assault Vehicle]], acceleration = 0.027, brakeRate = 0.0385, buildCostEnergy = 250, buildCostMetal = 250, builder = false, buildPic ...
gpl-2.0
gajop/Zero-K
LuaUI/Widgets/chili/simple examples/Widgets/gui_chiligui.lua
18
2737
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- function widget:GetInfo() return { name = "chiliGUI", desc = "hot GUI Framework", author = "jK & quantum", date = "WIP", ...
gpl-2.0
Sweet-kid/Algorithm-Implementations
Fibonacci_series/Lua/Yonaba/fib_test.lua
27
1042
-- Tests for fib.lua local fib = (require 'fib').fib local fib_iter = (require 'fib').fib_iter local total, pass = 0, 0 local function dec(str, len) return #str < len and str .. (('.'):rep(len-#str)) or str:sub(1,len) end local function run(message, f) total = total + 1 local ok, err = pcall(f) if o...
mit
KayMD/Illarion-Content
npc/base/tools.lua
3
1558
--[[ Illarion Server This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it wi...
agpl-3.0
MOSAVI17/videobot
plugins/hackernews.lua
16
1401
local command = 'hackernews' local doc = [[``` Returns four (if group) or eight (if private message) top stories from Hacker News. Alias: /hn ```]] local triggers = { '^/hackernews[@'..bot.username..']*', '^/hn[@'..bot.username..']*' } local action = function(msg) sendChatAction(msg.chat.id, 'typing') local jst...
gpl-2.0
abasshacker/abbas3
plugins/meme.lua
637
5791
local helpers = require "OAuth.helpers" local _file_memes = './data/memes.lua' local _cache = {} local function post_petition(url, arguments) local response_body = {} local request_constructor = { url = url, method = "POST", sink = ltn12.sink.table(response_body), headers = {}, red...
gpl-2.0
gajop/Zero-K
LuaUI/Widgets/snd_music.lua
2
11637
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -- -- file: gui_music.lua -- brief: yay music -- author: cake -- -- Copyright (C) 2007. -- Licensed under the terms of the GNU GPL, v2 or later. -- ---------...
gpl-2.0
thomas-schultz/sdn-cert
test-cases/config/filter.lua
1
1738
--[[ Test: matching on all given fields of an UDP/TCP packet possible matches are macs, ips, proto, ports Result: throughput and latency ]] require "testcase_lib" local Test = {} Test.require = "match_inport match_ethertype match_l2addr match_ipv4 match_l4proto match_l4port" Test.loadGen = "moo...
gpl-2.0
Mutos/NAEV-StarsOfCall
dat/missions/shark/sh01_corvette.lua
4
5664
--[[ This is the second mission of the Shark's teeth campaign. The player has to take part to a fake battle. Stages : 0) Way to Toaxis 1) Battle 2) Going to Darkshed --]] include "numstring.lua" lang = naev.lang() if lang == "es" then else -- default english title = {} text = {} ...
gpl-3.0
cecile/Cecile_QuickLaunch
src/Cecile_QuickLaunch/locales/modules/search_enUS.lua
1
2424
---------------------------------------------------------------------------------------------------- -- localized English (search module) strings -- --get the add-on engine local AddOnName = ...; --prepare locale local L = LibStub("AceLocale-3.0"):NewLocale(AddOnName, "enUS", true); if not L then return; end --searc...
artistic-2.0
CodeAnxiety/premake-core
src/actions/vstudio/vs2010_rules_xml.lua
5
8487
--- -- vs2010_rules_xml.lua -- Generate a Visual Studio 201x custom rules XML file. -- Copyright (c) 2014 Jason Perkins and the Premake project -- premake.vstudio.vs2010.rules.xml = {} local m = premake.vstudio.vs2010.rules.xml m.elements = {} local p = premake --- -- Entry point; generate the root <ProjectSch...
bsd-3-clause
adib1380/create-your-anti-spam-group
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
aadddjj/testbotantispam
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
gajop/Zero-K
LuaUI/Widgets/map_external_grid.lua
7
9297
--related thread: http://springrts.com/phpbb/viewtopic.php?f=13&t=26732&start=22 function widget:GetInfo() return { name = "External VR Grid", desc = "VR grid around map", author = "knorke, tweaked by KR", date = "Sep 2011", license = "PD", layer = -3, enabled = f...
gpl-2.0
danteinforno/wesnoth
data/ai/micro_ais/micro_ai_wml_tag.lua
6
26045
local H = wesnoth.require "lua/helper.lua" local W = H.set_wml_action_metatable {} local MAIH = wesnoth.require("ai/micro_ais/micro_ai_helper.lua") function wesnoth.wml_actions.micro_ai(cfg) local CA_path = 'ai/micro_ais/cas/' cfg = cfg.__parsed -- Add translation for old-syntax animal MAIs to new syntax...
gpl-2.0
danteinforno/wesnoth
data/ai/micro_ais/cas/ca_zone_guardian.lua
26
5275
local H = wesnoth.require "lua/helper.lua" local AH = wesnoth.require "ai/lua/ai_helper.lua" local LS = wesnoth.require "lua/location_set.lua" local function get_guardian(cfg) local filter = cfg.filter or { id = cfg.id } local guardian = AH.get_units_with_moves { side = wesnoth.current.side, { ...
gpl-2.0
dhotson/prosody-modules
mod_post_msg/mod_post_msg.lua
32
2623
module:depends"http" local jid_split = require "util.jid".split; local jid_prep = require "util.jid".prep; local msg = require "util.stanza".message; local test_password = require "core.usermanager".test_password; local b64_decode = require "util.encodings".base64.decode; local formdecode = require "net.http".formdeco...
mit
adel8268adelad/Bot-thebest
plugins/inrealm.lua
2
36501
-- 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_admin1(msg) then local group_creator = msg.from.print_name create_group_chat (group_creator, group_na...
agpl-3.0
wangtianhang/UnityLuaTest
toluaSnapshotTest/toluaUnityProject/Assets/ToLua/Lua/jit/vmdef.lua
11
7381
-- This is a generated file. DO NOT EDIT! return { bcnames = "ISLT ISGE ISLE ISGT ISEQV ISNEV ISEQS ISNES ISEQN ISNEN ISEQP ISNEP ISTC ISFC IST ISF ISTYPEISNUM MOV NOT UNM LEN ADDVN SUBVN MULVN DIVVN MODVN ADDNV SUBNV MULNV DIVNV MODNV ADDVV SUBVV MULVV DIVVV MODVV POW CAT KSTR KCDATAKSHORTKNUM...
mit
theasp/awesome-config
lib/crappy/misc.lua
1
1313
local misc = {} -- http://snippets.luacode.org/snippets/Simple_Table_Dump_7 function misc.dump(o) if type(o) == 'table' then local s = '{ ' for k, v in pairs(o) do if type(k) ~= 'number' then k = '"'..k..'"' end s = s .. '['..k..'] = ' .. misc.dump(v) .. ',' end return s .....
gpl-2.0
supertgteam/teamsofttelegram
plugins/inpm.lua
5
2991
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
gajop/Zero-K
gamedata/weapondefs_post.lua
1
13070
-- $Id: weapondefs_post.lua 3171 2008-11-06 09:06:29Z det $ -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -- -- file: weapondefs_post.lua -- brief: weaponDef post processing -- author: Dave Rodge...
gpl-2.0
litnimax/luci
applications/luci-diag-devinfo/luasrc/controller/luci_diag/luci_diag_devinfo.lua
76
2144
--[[ Luci diag - Diagnostics controller module (c) 2009 Daniel Dickinson 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 ]]-- module("luci.cont...
apache-2.0
torhve/ivar2
core/control.lua
2
2080
local ivar2 = ... local nixio = require'nixio' local ev = require'ev' local stripExtension = function(path) local i = path:match( ".+()%.%w+$" ) if ( i ) then return path:sub(1, i-1) end return path end -- Use the config file name as a base local fileName = stripExtension(nixio.fs.basename(ivar2.config.configFil...
mit
gajop/Zero-K
gamedata/modularcomms/weapons/heatray.lua
2
1395
local name = "commweapon_heatray" local weaponDef = { name = [[Heat Ray]], accuracy = 512, areaOfEffect = 20, cegTag = [[HEATRAY_CEG]], coreThickness = 0.5, craterBoost = 0, craterMult = 0, customParams ...
gpl-2.0
wangtianhang/UnityLuaTest
protoBufTest/UnityLuaTest2018/Assets/ToLua/Lua/UnityEngine/Plane.lua
6
1862
-------------------------------------------------------------------------------- -- Copyright (c) 2015 - 2016 , 蒙占志(topameng) topameng@gmail.com -- All rights reserved. -- Use, modification and distribution are subject to the "MIT License" -----------------------------------------------------------------...
mit
Shayan123456/botttttt1
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
Sweet-kid/Algorithm-Implementations
Linear_Search/Lua/Yonaba/linear_search_test.lua
26
2059
-- Tests for linear_search.lua local search = require 'linear_search' local total, pass = 0, 0 local function dec(str, len) return #str < len and str .. (('.'):rep(len-#str)) or str:sub(1,len) end local function run(message, f) total = total + 1 local ok, err = pcall(f) if ok then pass = pass + 1 ...
mit
cecile/Cecile_QuickLaunch
src/Cecile_QuickLaunch/libs/AceGUI-3.0-SharedMediaWidgets/SoundWidget.lua
7
7693
-- Widget is based on the AceGUIWidget-DropDown.lua supplied with AceGUI-3.0 -- Widget created by Yssaril local AceGUI = LibStub("AceGUI-3.0") local Media = LibStub("LibSharedMedia-3.0") local AGSMW = LibStub("AceGUISharedMediaWidgets-1.0") do local widgetType = "LSM30_Sound" local widgetVersion = 13 local conte...
artistic-2.0
KayMD/Illarion-Content
quest/alberto_dicker_674_runewick.lua
4
6867
--[[ Illarion Server This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it wi...
agpl-3.0
MOSAVI17/Anchor
plugins/get.lua
613
1067
local function get_variables_hash(msg) if msg.to.type == 'chat' then return 'chat:'..msg.to.id..':variables' end if msg.to.type == 'user' then return 'user:'..msg.from.id..':variables' end end local function list_variables(msg) local hash = get_variables_hash(msg) if hash then local names =...
gpl-2.0
arya5123/tell
plugins/spammer.lua
42
75166
local function run(msg) if msg.text == "[!/]spam" then return "".. [[ ...
gpl-2.0
safavi1381/Mr_bot
vir/Spammer.lua
42
75166
local function run(msg) if msg.text == "[!/]spam" then return "".. [[ ...
gpl-2.0
Tgfire/tgFire
tg/tdcli.lua
102
88571
--[[ 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. This program is distributed in the hope that it will be use...
gpl-3.0
Sweet-kid/Algorithm-Implementations
Knuth_Morris_Pratt/Lua/Yonaba/kmp.lua
26
1219
-- Knuth-Morris-Pratt string searching algorithm implementation -- See: http://en.wikipedia.org/wiki/Knuth%E2%80%93Morris%E2%80%93Pratt_algorithm local function kmp_table(pattern) local result = {} for i = 1, #pattern+1,1 do local j = i while true do if j == 1 then result[#result + 1] = 1 ...
mit
gajop/Zero-K
units/factorycloak.lua
7
3927
unitDef = { unitname = [[factorycloak]], name = [[Cloaky Bot Factory]], description = [[Produces Cloaky Robots, Builds at 10 m/s]], buildCostEnergy = 600, buildCostMetal = 600, builder = true, ...
gpl-2.0
gajop/Zero-K
LuaRules/Gadgets/unit_jumpjet_pilot_2.lua
11
4195
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- if (not gadgetHandler:IsSyncedCode()) then return false end function gadget:GetInfo() return { name = "Jumpjet Pilot 2014", desc = "St...
gpl-2.0
litnimax/luci
applications/luci-asterisk/luasrc/model/cbi/asterisk-mod-app.lua
137
15546
cbimap = Map("asterisk", "asterisk", "") module = cbimap:section(TypedSection, "module", "Modules", "") module.anonymous = true app_alarmreceiver = module:option(ListValue, "app_alarmreceiver", "Alarm Receiver Application", "") app_alarmreceiver:value("yes", "Load") app_alarmreceiver:value("no", "Do Not Load") app_al...
apache-2.0
litnimax/luci
applications/luci-radvd/luasrc/model/cbi/radvd/prefix.lua
74
3766
--[[ LuCI - Lua Configuration Interface Copyright 2010 Jo-Philipp Wich <xm@subsignal.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.apache.org/licenses/LICENSE-2.0 $Id$ ]]-- lo...
apache-2.0
jinq0123/grpc-lua
src/lua/grpc_lua/client/async/ClientAsyncWriter.lua
1
2950
--- Client async writer class. -- @classmod grpc_lua.client.async.ClientAsyncWriter local ClientAsyncWriter = {} local c = require("grpc_lua.c") -- from grpc_lua.so local pb = require("luapbintf") ------------------------------------------------------------------------------- --- Public functions. -- @section publi...
bsd-3-clause
c0mb1ne/dota2-training-polygon
training_polygon/scripts/vscripts/test.lua
1
1092
function TargetTest( event ) local caster = event.caster local target = event.target local unit = event.unit local attacker = event.attacker local ability = event.ability -- Tables local target_points = event.target_points local target_entities = event.target_entities -- Extra par...
mit
CodeAnxiety/premake-core
src/actions/make/make_csharp.lua
7
7768
-- -- make_csharp.lua -- Generate a C# project makefile. -- Copyright (c) 2002-2013 Jason Perkins and the Premake project -- premake.make.cs = {} local make = premake.make local cs = premake.make.cs local project = premake.project local config = premake.config local fileconfig = premake.fileconfig -- -- Add na...
bsd-3-clause
nobie/sesame_fw
feeds/luci/applications/luci-asterisk/dist/usr/lib/lua/luci/model/cbi/asterisk/dialzones.lua
91
3529
--[[ LuCI - Lua Configuration Interface Copyright 2008 Jo-Philipp Wich <xm@subsignal.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.apache.org/licenses/LICENSE-2.0 $Id: trunks.l...
gpl-2.0
mardraze/prosody-modules
mod_pubsub_hub/mod_pubsub_hub.lua
32
6808
-- Copyright (C) 2011 - 2012 Kim Alvefur -- -- This file is MIT/X11 licensed. local http = require "net.http"; local formdecode = http.formdecode; local formencode = http.formencode; local http_request = http.request; local uuid = require "util.uuid".generate; local hmac_sha1 = require "util.hmac".sha1; local json_enc...
mit
N3X15/spacebuild
lua/weapons/gmod_tool/stools/rd3_dev_link2.lua
3
5383
--load our other stools first --include( "RD2/tool_manifest.lua" ) --dev link stool --TOOL = ToolObj:Create() TOOL.Mode = "rd3_dev_link2" TOOL.Category = 'Resource Distribution' TOOL.Name = '#Smart Link Tool' TOOL.Command = nil TOOL.ConfigName = '' if (CLIENT and GetConVarNumber("CAF_UseTab") == 1) then TOOL.Tab =...
apache-2.0
KayMD/Illarion-Content
item/id_313_glassmeltoven.lua
4
1704
--[[ Illarion Server This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it wi...
agpl-3.0
gajop/Zero-K
effects/mary_sue.lua
25
5718
-- mary_sue_fireball1 -- mary_sue_fireball3 -- mary_sue -- mary_sue_fireball2 return { ["mary_sue_fireball1"] = { wezels = { air = true, class = [[CSimpleParticleSystem]], count = 1, ground = true, water = true, ...
gpl-2.0
danteinforno/wesnoth
data/ai/micro_ais/cas/ca_fast_combat.lua
6
5874
local H = wesnoth.require "lua/helper.lua" local AH = wesnoth.require "ai/lua/ai_helper.lua" local FAU = wesnoth.require "ai/micro_ais/cas/ca_fast_attack_utils.lua" local LS = wesnoth.require "lua/location_set.lua" local ca_fast_combat = {} function ca_fast_combat:evaluation(ai, cfg, self) self.data.move_cache = ...
gpl-2.0
mua/BlockingBad
game.lua
1
5921
---------------------------- -- Author: M. Utku Altinkaya -- utkualtinkaya@gmail.com ---------------------------- require "well" require "shapes" -- Actual game play happens in this scene GameScene = Class(Scene) function GameScene:init() self.activeShape = nil self.well = Well:create() -- Main data structure for ...
bsd-3-clause
ld-test/lua-nucleo
test/cases/0460-diagnostics.lua
2
2735
-------------------------------------------------------------------------------- -- 0460-diagnostics.lua: Tests code diagnostics utilities -- This file is a part of lua-nucleo library -- Copyright (c) lua-nucleo authors (see file `COPYRIGHT` for the license) -------------------------------------------------------------...
mit
hussian1997/bot-of-iraq
plugins/help.lua
3
1732
--[[ ▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ BY(@AHMED_ALOBIDE) ▀▄ ▄▀ ▀▄ ▄▀ BY(@hussian_9) ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ (ملف الهيلب انكلش) ▀▄ ▄▀...
agpl-3.0
AnsonSmith/kong
kong/plugins/request_transformer/access.lua
17
3899
local utils = require "kong.tools.utils" local stringy = require "stringy" local Multipart = require "multipart" local _M = {} local CONTENT_LENGTH = "content-length" local FORM_URLENCODED = "application/x-www-form-urlencoded" local MULTIPART_DATA = "multipart/form-data" local CONTENT_TYPE = "content-type" local fun...
apache-2.0
KayMD/Illarion-Content
craft/base/crafts.lua
1
31402
--[[ Illarion Server This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it wi...
agpl-3.0
mardraze/prosody-modules
mod_s2s_auth_fingerprint/mod_s2s_auth_fingerprint.lua
31
1380
-- Copyright (C) 2013-2014 Kim Alvefur -- This file is MIT/X11 licensed. module:set_global(); local digest_algo = module:get_option_string(module:get_name().."_digest", "sha1"); local fingerprints = {}; local function hashprep(h) return tostring(h):gsub(":",""):lower(); end local function hashfmt(h) return h:gsu...
mit
miralireza2/gpf
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
iainmerrick/Urho3D
bin/Data/LuaScripts/41_DatabaseDemo.lua
26
7819
-- Database demo. This sample demonstrates how to use database subsystem to connect to a database and execute adhoc SQL statements. require "LuaScripts/Utilities/Sample" local connection local row local maxRows = 50 function Start() -- Execute the common startup for samples SampleStart() -- Disable defa...
mit
duk3luk3/MoonGen
lua/include/device.lua
1
24157
--------------------------------- --- @file device.lua --- @brief Device ... --- @todo TODO docu --------------------------------- local mod = {} local ffi = require "ffi" local dpdkc = require "dpdkc" local dpdk = require "dpdk" local memory = require "memory" local serpent = require "Serpent" local errors = re...
mit
danteinforno/wesnoth
data/ai/micro_ais/cas/ca_healer_move.lua
26
5637
local H = wesnoth.require "lua/helper.lua" local LS = wesnoth.require "lua/location_set.lua" local AH = wesnoth.require "ai/lua/ai_helper.lua" local BC = wesnoth.require "ai/lua/battle_calcs.lua" local ca_healer_move = {} function ca_healer_move:evaluation(ai, cfg, self) -- Should happen with higher priority than...
gpl-2.0
safavi1381/Mr_bot
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
kiarash14/BumperTG
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
abasshacker/abbas3
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
KayMD/Illarion-Content
quest/numila_irunnleh_624_runewick.lua
3
2879
--[[ Illarion Server This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it wi...
agpl-3.0
safavi1381/Mr_bot
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
indexTM/index
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
adib1380/create-your-anti-spam-group
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
safavi1381/Mr_bot
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
abasshacker/abbas3
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
lifesfun/ShineExtensions
output/lua/Balance/Damage.lua
1
7681
kDamageVelocityScalar = 2.5 kMelee1DamageScalar = 1.1 kMelee2DamageScalar = 1.2 kMelee3DamageScalar = 1.3 local kDamagePerUpgradeScalar = 0.1 kWeapons1DamageScalar = 1 + kDamagePerUpgradeScalar kWeapons2DamageScalar = 1 + kDamagePerUpgradeScalar * 2 kWeapons3DamageScalar = 1 + kDamagePerUpgradeScalar * 3 //...
mit
tryller/crystalserver
data/npc/lib/npcsystem/keywordhandler.lua
2
7158
-- Advanced NPC System (Created by Jiddo), -- Modified by TheForgottenServer Team. if(KeywordHandler == nil) then BEHAVIOR_SIMPLE = 1 -- Does not support nested keywords. If you choose this setting you must use a variable such as 'talkState' to keep track of how to handle keywords. BEHAVIOR_NORMAL = 2 -- Default beh...
gpl-3.0
gajop/Zero-K
LuaUI/Widgets/chili/Skins/default/skin.lua
8
17618
--//============================================================================= --// default local skin = { info = { name = "default", version = "0.1", author = "jK", } } --//============================================================================= --// Render Helpers local function _DrawBo...
gpl-2.0
indexTM/index
plugins/anti-spam.lua
8
2355
local NUM_MSG_MAX = 3 local TIME_CHECK = 4 local function kick_user(user_id, chat_id) local chat = 'channel#id'..chat_id local user = 'user#id'..user_id channel_kick_user(chat, user, function (data, success, result) if success ~= 1 then local text = 'I can\'t kick '..data.user..' but should be kicked' ...
gpl-2.0
gajop/Zero-K
LuaRules/Configs/StartBoxes/Conquest_of_Paradise_v1.lua
11
13079
return { [0] = { boxes = { { {1337, 4200}, {1835.4140625, 3731.3166503906}, {1781.3040771484, 3796.2602539063}, {1766.8371582031, 3928.3518066406}, {1770.8837890625, 4173.1723632813}, {1672.4652099609, 4296.7426757813}, {1602.6494140625, 4462.306640625}, {1630.5236816406, 4583.8208...
gpl-2.0
MOSAVI17/videobot
plugins/librefm.lua
8
2666
local command = 'librefm' local doc = [[``` /lnp [username] Returns what you are or were last listening to. If you specify a username, info will be returned for that username. /lfmset <username> Sets your libre.fm username. Otherwise, /np will use your Telegram username. Use "/fmset -" to delete it. ```]] local trigg...
gpl-2.0
Proxmark/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
jayman39tx/naev
dat/missions/empire/collective/ec04.lua
2
9013
--[[ Collective Extraction Author: bobbens minor edits by Infiltrator Fifth mission in the collective mini campaign. You must go rescue a team of commandos after being attacked by collective forces on a surveillance mission. ]]-- include "dat/scripts/nextjump.lua" include "proximity.lua" mi...
gpl-3.0
jayman39tx/naev
dat/ai/civilian.lua
4
1544
include("dat/ai/tpl/generic.lua") include("dat/ai/personality/civilian.lua") -- Sends a distress signal which causes faction loss function sos () msg = { _("Mayday! We are under attack!"), _("Requesting assistance. We are under attack!"), _("Civilian vessel under attack! Requesting help!"), ...
gpl-3.0
dhotson/prosody-modules
mod_storage_ldap/ldap/vcard.lib.lua
40
5035
-- vim:sts=4 sw=4 -- Prosody IM -- Copyright (C) 2008-2010 Matthew Wild -- Copyright (C) 2008-2010 Waqas Hussain -- Copyright (C) 2012 Rob Hoelz -- -- This project is MIT/X11 licensed. Please see the -- COPYING file in the source package for more information. -- local st = require 'util.stanza'; local VCARD_NS = 'vc...
mit
N3X15/spacebuild
lua/caf/stools/ls3_receptacles.lua
1
26556
TOOL.Category = "Life Support" TOOL.Name = "#Storage Devices" TOOL.DeviceName = "Storage Device" TOOL.DeviceNamePlural = "Storage Devices" TOOL.ClassName = "ls3_receptacles" TOOL.DevSelect = true TOOL.CCVar_type = "storage_gas_o2" TOOL.CCVar_sub_type = "Small (Phx)" TOOL.CCVar_model = "models/props_phx/life_support/c...
apache-2.0
flike/Atlas
lib/xtab.lua
40
13591
--[[ $%BEGINLICENSE%$ Copyright (c) 2007, 2008, Oracle and/or its affiliates. All rights reserved. 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; version 2 of the License. This program is dis...
gpl-2.0
gajop/Zero-K
LuaRules/Configs/stealth_defs.lua
4
1103
-- $Id: stealth_defs.lua 3496 2008-12-21 20:33:13Z licho $ -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- local passiveStealth = { draw = false, init = false, energy = 0, delay = 0, tie...
gpl-2.0
ld-test/lua-nucleo
lua-nucleo/ensure.lua
2
11414
-------------------------------------------------------------------------------- --- Tools to ensure correct code behaviour -- @module lua-nucleo.ensure -- This file is a part of lua-nucleo library -- @copyright lua-nucleo authors (see file `COPYRIGHT` for the license) --------------------------------------------------...
mit
theasp/awesome-config
lib/crappy/crappy-plugins/crappy.functions.signals.lua
1
4688
local lgi = require('lgi') local misc = require('crappy.misc') local plugin = { id = 'crappy.functions.signals', name = 'Signal Functions', description = 'Functions that handle signals', author = 'Andrew Phillips <theasp@gmail.com>', requires = {"crappy.shared.settings.titlebar", "crappy.shared.settings...
gpl-2.0
gajop/Zero-K
LuaRules/Configs/customcmds.h.lua
2
3094
-------------------------------------------------------------------------------- -- -- Proposed Command ID Ranges: -- -- all negative: Engine (build commands) -- 0 - 999: Engine -- 1000 - 9999: Group AI -- 10000 - 19999: LuaUI -- 20000 - 29999: LuaCob -- 30000 - 39999: LuaRules -- -- if you...
gpl-2.0
jzbontar/nn
Max.lua
27
1520
local Max, parent = torch.class('nn.Max', 'nn.Module') function Max:__init(dimension) parent.__init(self) dimension = dimension or 1 self.dimension = dimension end function Max:_lazyInit() self._output = self._output or self.output.new() self._indices = self._indices or (torch.type(self.output) =...
bsd-3-clause
mcastron/BBRL
scripts/lua_scripts/data/agents.lua
2
11077
-- ============================================================================ -- This script describes the agents which have to be considered in the -- experiments. -- -- An agent is described as follows: -- -- ... -- { -- -- Name of the agent class -- name = "<agent class name>", -- -- ...
gpl-2.0
mt246/mt246
plugins/moderation.lua
336
9979
do local function check_member(cb_extra, success, result) local receiver = cb_extra.receiver local data = cb_extra.data local msg = cb_extra.msg for k,v in pairs(result.members) do local member_id = v.id if member_id ~= our_id then local username = v.username data[tostring(m...
gpl-2.0