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
nikai3d/codecombat-scripts
desert/harrowland.lua
1
2514
-- using "bash", "move", "power-up" function notYak(xs) local r = {} for i = 1, #xs do if xs[i].type ~= "sand-yak" then r[#r+1] = xs[i] end end return r end mini = 1 function summonMinion() if mini == 1 and self.gold >= self:costOf("soldier") then self:summon("so...
mit
uhvhugvhhbbh545hhhyg/rekjx
plugins/stats.lua
2
4014
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
thenumbernine/hydro-cl-lua
hydro/eqn/bssnok-fd.lua
1
11177
local class = require 'ext.class' local table = require 'ext.table' local file = require 'ext.file' local EinsteinEqn = require 'hydro.eqn.einstein' local common = require 'hydro.common' local xNames = common.xNames local BSSNOKFiniteDifferenceEquationBase = class(EinsteinEqn) -- seems all the hyperbolic formalisms...
mit
RuiChen1113/luci
libs/luci-lib-nixio/docsrc/nixio.TLSSocket.lua
173
2926
--- TLS Socket Object. -- TLS Sockets contain the underlying socket and context in the fields -- "socket" and "context". -- @cstyle instance module "nixio.TLSSocket" --- Initiate the TLS handshake as client with the server. -- @class function -- @name TLSSocket.connect -- @usage This function calls SSL_connect(). -- @...
apache-2.0
zackp30/cuberite
MCServer/Plugins/APIDump/Classes/Plugins.lua
5
22645
return { cPlugin = { Desc = [[cPlugin describes a Lua plugin. This page is dedicated to new-style plugins and contain their functions. Each plugin has its own Plugin object. ]], Functions = { GetDirectory = { Return = "string", Notes = "<b>OBSOLETE</b>, use GetFolderName() instead!" }, GetFolderName = { P...
apache-2.0
mirbot/zdgbbbrblsb-vbv
plugins/steam.lua
645
2117
-- See https://wiki.teamfortress.com/wiki/User:RJackson/StorefrontAPI do local BASE_URL = 'http://store.steampowered.com/api/appdetails/' local DESC_LENTH = 200 local function unescape(str) str = string.gsub( str, '&lt;', '<' ) str = string.gsub( str, '&gt;', '>' ) str = string.gsub( str, '&quot;', '"' ) str...
gpl-2.0
SammyJames/Rave
Modules/ModulePrototype.lua
1
1198
local ZO_Object = ZO_Object local Rave = Rave local ModulePrototype = ZO_Object:Subclass() function ModulePrototype:New( identity, version ) local result = ZO_Object.New( self ) result:Initialize( identity, version ) return result end function ModulePrototype:Initialize( identity, v...
mit
stevelord/PR30
feeds/xwrt/webif-iw-lua/files/usr/lib/lua/lua-xwrt/xwrt/cgi_env.lua
8
2315
require("lua-xwrt.addon.string") function get_env() local t = {} local myenv = io.popen("env") for line in myenv:lines() do _, _, key, value = string.find(line, "([A-Z_0-9a-z]+)[%=]+(.*)") --print(line, key, value) t[key] = value end --print("-------------------------------------------------------") return...
gpl-2.0
botiiing/BDReborn
bot/utils.lua
1
18257
--Begin Utils.lua By #BeyondTeam :) function serialize_to_file(data, file, uglify) file = io.open(file, 'w+') local serialized if not uglify then serialized = serpent.block(data, { comment = false, name = '_' }) else serialized = serpent.dump(data) end file:write(serialized) ...
gpl-3.0
Dr0virus/k
plugins/settings.lua
40
41643
-------------------------------------------------- -- ____ ____ _____ -- -- | \| _ )_ _|___ ____ __ __ -- -- | |_ ) _ \ | |/ ·__| _ \_| \/ | -- -- |____/|____/ |_|\____/\_____|_/\/\_| -- -- -- --------------...
gpl-2.0
luadch/luadch
luasocket/src/mime.lua
149
2487
----------------------------------------------------------------------------- -- MIME support for the Lua language. -- Author: Diego Nehab -- Conforming to RFCs 2045-2049 ----------------------------------------------------------------------------- ----------------------------------------------------------------------...
gpl-3.0
Armin041/RADDY
libs/mimetype.lua
3662
2922
-- Thanks to https://github.com/catwell/lua-toolbox/blob/master/mime.types do local mimetype = {} -- TODO: Add more? local types = { ["text/html"] = "html", ["text/css"] = "css", ["text/xml"] = "xml", ["image/gif"] = "gif", ["image/jpeg"] = "jpg", ["application/x-javascript"] = "js", ["application/atom...
gpl-2.0
mahdib9/mb
libs/mimetype.lua
3662
2922
-- Thanks to https://github.com/catwell/lua-toolbox/blob/master/mime.types do local mimetype = {} -- TODO: Add more? local types = { ["text/html"] = "html", ["text/css"] = "css", ["text/xml"] = "xml", ["image/gif"] = "gif", ["image/jpeg"] = "jpg", ["application/x-javascript"] = "js", ["application/atom...
gpl-2.0
botiiing/BDReborn
libs/mimetype.lua
3662
2922
-- Thanks to https://github.com/catwell/lua-toolbox/blob/master/mime.types do local mimetype = {} -- TODO: Add more? local types = { ["text/html"] = "html", ["text/css"] = "css", ["text/xml"] = "xml", ["image/gif"] = "gif", ["image/jpeg"] = "jpg", ["application/x-javascript"] = "js", ["application/atom...
gpl-3.0
RuiChen1113/luci
modules/luci-base/luasrc/ccache.lua
81
1651
-- Copyright 2008 Steven Barth <steven@midlink.org> -- Copyright 2008 Jo-Philipp Wich <jow@openwrt.org> -- Licensed to the public under the Apache License 2.0. local io = require "io" local fs = require "nixio.fs" local util = require "luci.util" local nixio = require "nixio" local debug = require "debug" local string...
apache-2.0
Tele-Fox/best
plugins/sudo.lua
359
1878
function run_sh(msg) name = get_name(msg) text = '' -- if config.sh_enabled == false then -- text = '!sh command is disabled' -- else -- if is_sudo(msg) then -- bash = msg.text:sub(4,-1) -- text = run_bash(bash) -- else -- text = name .. ' yo...
gpl-2.0
Noneatme/mta-lostresources
[gamemodes]/prophunt/server/CLobby.lua
1
2895
-- ####################################### -- ## Project: MTA Prop Hunt ## -- ## For MTA: San Andreas ## -- ## Name: Lobby.lua ## -- ## Author: Noneatme ## -- ## Version: 1.0 ## -- ## License: See top Folder ## -- ####################################### -- FUNCTIONS / METHODS -- local cFunc = {};...
gpl-2.0
psychon/lgi
samples/gtk-demo/demo-paned.lua
6
3705
return function(parent, dir) local lgi = require 'lgi' local Gtk = lgi.Gtk local window = Gtk.Window { title = "Panes", Gtk.Box { orientation = 'VERTICAL', Gtk.Paned { orientation = 'VERTICAL', Gtk.Paned { id = 'paned_top', orientation = 'HORIZONTAL', Gtk.Frame { id = 'pan...
mit
Noneatme/mta-lostresources
[gamemodes]/Multistunt/shaders/shader_carpaint/c_car_paint.lua
1
1085
addEventHandler( "onClientResourceStart", resourceRoot, function() -- Version check local ver = getVersion ().sortable local type = string.sub( ver, 7, 7 ) local build = string.sub( ver, 9, 13 ) if build < "02888" and type ~= "1" or ver < "1.1.0" then outputChatBox( "Resource is not compatible with this ...
gpl-2.0
liddiard/google-diff-match-patch
lua/diff_match_patch_test.lua
264
39109
--[[ * Test Harness for Diff Match and Patch * * Copyright 2006 Google Inc. * http://code.google.com/p/google-diff-match-patch/ * * Based on the JavaScript implementation by Neil Fraser * Ported to Lua by Duncan Cross * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except...
apache-2.0
akopytov/sysbench
src/lua/internal/sysbench.lua
2
5463
-- Copyright (C) 2016-2018 Alexey Kopytov <akopytov@gmail.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. -- ...
gpl-2.0
SammyJames/Rave
Libs/LibAnimation-1.0/LibAnimation.lua
4
8242
---------------------------------------------------- -- Lib Animation - for all your animation needs -- -- @classmod LibAnimation -- @author Pawkette ( pawkette.heals@gmail.com ) -- @copyright 2014 Pawkette --[[ The MIT License (MIT) Copyright (c) <year> <copyright holders> Permission is hereby granted, free of charg...
mit
pinkysnowman/homedecor_modpack
computer/tetris.lua
3
6551
local shapes = { { { x = {0, 1, 0, 1}, y = {0, 0, 1, 1} } }, { { x = {1, 1, 1, 1}, y = {0, 1, 2, 3} }, { x = {0, 1, 2, 3}, y = {1, 1, 1, 1} } }, { { x = {0, 0, 1, 1}, y = {0, 1, 1, 2} }, { x = {1, 2, 0, 1}, y = {0, 0, 1, 1} } }, { { x = {1, 0, 1, 0}, y = {0, 1, 1, 2} }, { x = {...
lgpl-3.0
Jfalcon1387/RollForLoot
Libs/AceDB-3.0/AceDB-3.0.lua
4
25375
--- **AceDB-3.0** manages the SavedVariables of your addon. -- It offers profile management, smart defaults and namespaces for modules.\\ -- Data can be saved in different data-types, depending on its intended usage. -- The most common data-type is the `profile` type, which allows the user to choose -- the active p...
lgpl-3.0
pinkysnowman/homedecor_modpack
homedecor_3d_extras/init.lua
4
2498
minetest.override_item("default:bookshelf", { drawtype = "mesh", mesh = "3dbookshelf.obj", tiles = { "default_wood.png", "default_wood.png^3dbookshelf_inside_back.png", "3dbookshelf_books.png", }, paramtype = "light", paramtype2 = "facedir", }) if minetest.get_modpath("vessels") and minetest.registered_no...
lgpl-3.0
RoyZeng/wax
examples/States/scripts/StatesTable.lua
34
1447
waxClass{"StatesTable", UITableViewController, protocols = {"UITableViewDataSource", "UITableViewDelegate"}} function init(self) self.super:init() -- Loads plist from bundle self.states = NSArray:arrayWithContentsOfFile("states.plist") self:setTitle("States") return self end function viewDidLoad(self) ...
mit
kingmiladee/bot-man
plugins/webshot.lua
7
1433
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
luadch/luadch
scripts/etc_dummy_warning.lua
1
1269
--[[ etc_dummy_warning.lua by blastbeat - this script warns any level 100 user at login, if the default "dummy" account is still in the user.tbl v0.02: by pulsar - fix #103 - add lang support ]]-- local scriptname = "etc_dummy_warning" local scriptversio...
gpl-3.0
FivePente/Dijkstra
device.lua
1
9202
require('consts') JSON = cjson local inited = false; mqttClient = mqtt brokerConfs = {addr="192.168.199.120" , port=1883 , userName="" , password=""} IO_LED = 4 propUpdateInterval = 1000; pbPath = nil; protocol = 1; deviceID = "device_200" msgClient = msgClient or nil; msgOpt = nil; device = {test1=100 , test2=true}...
mit
psychon/lgi
lgi/override/Gdk.lua
2
4251
------------------------------------------------------------------------------ -- -- LGI Gdk3 override module. -- -- Copyright (c) 2011, 2014 Pavel Holejsovsky -- Licensed under the MIT license: -- http://www.opensource.org/licenses/mit-license.php -- ----------------------------------------------------------------...
mit
AlexarJING/space-war
scr/ui/gameMenu.lua
1
1573
local ui={} function ui:init() ui.frame=loveframes.Create("frame") :SetPos(w/2,150,true) :SetSize(350,450) :SetName("Game Menu") :SetState("menu") :ShowCloseButton(false) ui.list=loveframes.Create("list",ui.frame) :SetPos(0,25) :SetSize(350,425) :SetPadding(80) :SetSpacing(20) :SetDisp...
apache-2.0
RuiChen1113/luci
modules/luci-base/luasrc/model/network.lua
30
33786
-- Copyright 2009-2015 Jo-Philipp Wich <jow@openwrt.org> -- Licensed to the public under the Apache License 2.0. local type, next, pairs, ipairs, loadfile, table = type, next, pairs, ipairs, loadfile, table local tonumber, tostring, math = tonumber, tostring, math local require = require local nxo = require "nixio...
apache-2.0
RailTracker/OpenRA
mods/d2k/maps/atreides-03a/atreides03a-AI.lua
6
3789
IdlingUnits = { } AttackGroupSize = { easy = 6, normal = 8, hard = 10 } AttackDelays = { easy = { DateTime.Seconds(4), DateTime.Seconds(9) }, normal = { DateTime.Seconds(2), DateTime.Seconds(7) }, hard = { DateTime.Seconds(1), DateTime.Seconds(5) } } OrdosInfantryTypes = { "light_inf", "light_inf", "light_inf",...
gpl-3.0
zhukunqian/slua-1
build/luajit-2.0.4/src/host/genminilua.lua
127
11962
---------------------------------------------------------------------------- -- Lua script to generate a customized, minified version of Lua. -- The resulting 'minilua' is used for the build process of LuaJIT. ---------------------------------------------------------------------------- -- Copyright (C) 2005-2015 Mike P...
mit
mms92/wire
lua/wire/stools/consolescreen.lua
8
1038
WireToolSetup.setCategory( "Visuals/Screens" ) WireToolSetup.open( "consolescreen", "Console Screen", "gmod_wire_consolescreen", nil, "Screens" ) if CLIENT then language.Add( "tool.wire_consolescreen.name", "Console Screen Tool (Wire)" ) language.Add( "tool.wire_consolescreen.desc", "Spawns a console screen" ) lan...
apache-2.0
cryovat/lord-evil-game
src/assets/level7.lua
1
3018
return { version = "1.1", luaversion = "5.1", orientation = "orthogonal", width = 20, height = 13, tilewidth = 16, tileheight = 16, properties = { ["east"] = "level8", ["north"] = "", ["south"] = "", ["west"] = "level6" }, tilesets = { { name = "objects", firstgid = 1, tilewidth = 16, tileheight = 16, spacing = 0, marg...
mit
adib1380/fu2
plugins/google.lua
1
1171
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
torch/optim
test/rosenbrock.lua
14
1390
require 'torch' -- rosenbrock.m This function returns the function value, partial derivatives -- and Hessian of the (general dimension) rosenbrock function, given by: -- -- f(x) = sum_{i=1:D-1} 100*(x(i+1) - x(i)^2)^2 + (1-x(i))^2 -- -- where D is the dimension of x. The true minimum is 0 at x = (1 1 ... 1). -- ...
bsd-3-clause
FliPPeh/Gibbous
scheme/special_forms.lua
1
21994
local special_forms = {} local util = require "scheme.util" local err = util.err local ensure = util.ensure local expect = util.expect local expect_argc = util.expect_argc local expect_argc_min = util.expect_argc_min local expect_argc_max = util.expect_argc_max local is_true = util.is_true local unpack = table.unpac...
bsd-2-clause
q-gears/q-gears-reversing-data
reversing/ffvii/ffvii_battle/model/animation/data/dump_guard_scorpion.lua
1
4684
01001100B004602260222C01F2F9A8F8 C6F3020000000000090E021202272400 001B0000EC010000F0010000F4010000 F8010000FC0100000002000004020000 080200008002800180020000A92539EC E50B00001FFF6BFE9309B9FDA01F0000 1FFD000044020000 E8000000 0 EC000000 1 F0000000 2 F4000000 3 14010000 4 34010000 5 44010000 6 50010000 ...
gpl-2.0
Habbie/hammerspoon
extensions/logger/init.lua
6
11674
--- === hs.logger === --- --- Simple logger for debugging purposes --- --- Note: "methods" in this module are actually "static" functions - see `hs.logger.new()` local date,time = os.date,os.time local min,max,tmove=math.min,math.max,table.move local sformat,ssub,slower,srep,sfind=string.format,string.sub,string.lower,...
mit
shkan/telebot7
plugins/inrealm.lua
287
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
RuiChen1113/luci
applications/luci-app-openvpn/luasrc/model/cbi/openvpn-basic.lua
40
3094
-- Copyright 2008 Steven Barth <steven@midlink.org> -- Licensed to the public under the Apache License 2.0. require("luci.ip") require("luci.model.uci") local basicParams = { -- -- Widget, Name, Default(s), Description -- { ListValue, "verb", { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 }, translate("Set...
apache-2.0
cogwerkz/DiabolicUI
locale/locale-zhCN.lua
2
11221
local _, Engine = ... local L = Engine:NewLocale("zhCN") if not L then return end --------------------------------------------------------------------- -- System Messages --------------------------------------------------------------------- -- Core Engine L["Bad argument #%d to '%s': %s expected, got %s"] ...
mit
stevelord/PR30
feeds/xwrt/webif-iw-lua/files/usr/lib/lua/lua-xwrt/xwrt/util.lua
1
3551
require("lua-xwrt.addon.string") require("lua-xwrt.xwrt.translator") local string = string local io = io local os = os local pairs, ipairs = pairs, ipairs local table = table local type = type local print = print local tostring, tonumber = tostring, tonumber local __TOCHECK = __TOCHECK local __UCI_CMD = __UCI_CMD loc...
gpl-2.0
Ettercap/ettercap
src/lua/share/third-party/stdlib/src/set.lua
12
3663
local list = require "list" -- Primitive methods (know about representation) -- The representation is a table whose tags are the elements, and -- whose values are true. --- Say whether an element is in a set -- @param s set -- @param e element -- @return <code>true</code> if e is in set, <code>false</code> -- otherw...
gpl-2.0
mms92/wire
lua/wire/stools/latch.lua
9
3065
WireToolSetup.setCategory( "Physics/Constraints" ) WireToolSetup.open( "latch", "Weld/Constraint Latch", "gmod_wire_latch", nil, "Constraint Latches" ) TOOL.ClientConVar[ "model" ] = "models/jaanus/wiretool/wiretool_siren.mdl" if CLIENT then language.Add( "Tool.wire_latch.name", "Latch Tool (Wire)" ) language...
apache-2.0
akopytov/sysbench
src/lua/select_random_ranges.lua
1
2154
#!/usr/bin/env sysbench -- This test is designed for testing MariaDB's key_cache_segments for MyISAM, -- and should work with other storage engines as well. -- -- For details about key_cache_segments please refer to: -- http://kb.askmonty.org/v/segmented-key-cache -- require("oltp_common") -- Add --number-of-ranges a...
gpl-2.0
q-gears/q-gears-reversing-data
utilities/ffvii_battle_scene_dumper/output/76_enemy_attacks.lua
1
1598
-- Machine Gun (272) MachineGun = { mp_cost = 0, power = 1, hit = 100, formula = "0x11", target = "0x03", additional_effect = "0xff", additional_effect_modifier = "0xff", special = "0xffff", elements = { Shoot, }, target_hurt_script_id = 0, sound_id_normal = 1...
gpl-2.0
moreginger/spalg2017
hump/vector.lua
2
5978
--[[ Copyright (c) 2010-2013 Matthias Richter 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, merge, publish, dis...
mit
sk89q/PlayX
src/PlayX/lua/playx/providers/filetypes.lua
2
4850
-- 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 v...
lgpl-3.0
hbl0307106015/packages
utils/yunbridge/files/usr/lib/lua/luci/controller/arduino/index.lua
103
12089
--[[ This file is part of YunWebUI. YunWebUI 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 i...
gpl-2.0
RoyZeng/wax
lib/stdlib/helpers/WaxServer.lua
19
1137
-- I don't know where the proper place for this file is. It's not really a helper waxClass{"WaxServer"} -- Class Method --------------- function start(self) self.server = wax.class['wax_server']:init() local err = self.server and self.server:startOnPort(9000) if err then puts("Failed creating server: %s", e...
mit
jonathantompson/optim
fista.lua
12
6084
--[[ FISTA with backtracking line search - `f` : smooth function - `g` : non-smooth function - `pl` : minimizer of intermediate problem Q(x,y) - `xinit` : initial point - `params` : table of parameters (**optional**) - `params.L` : 1/(step size) for ISTA/FISTA iteration (0.1) - `params.L...
bsd-3-clause
Noneatme/mta-lostresources
[gamemodes]/twd/client/CGRegisterBox.lua
1
13764
-- ############################### -- ## Project: MTA:Speedrace ## -- ## Name: RegisterBoxGUI ## -- ## Author: Noneatme ## -- ## Version: 1.0 ## -- ## License: See top Folder ## -- ############################### -- FUNCTIONS / METHODS -- local cFunc = {}; -- Local Functions local cSetting = {}; -- Local Sett...
gpl-2.0
luadch/luadch
core/types.lua
2
3688
--[[ types.lua by blastbeat - provides some type checking ]]-- ----------------------------------// DECLARATION //-- --// lua functions //-- local type = use "type" local next = use "next" local pairs = use "pairs" local error = use "error" --// extern libs //-- local adclib =...
gpl-3.0
mms92/wire
lua/entities/gmod_wire_egp/lib/objects/roundedboxoutline.lua
12
2179
-- Author: sk8 (& Divran) local Obj = EGP:NewObject( "RoundedBoxOutline" ) Obj.angle = 0 Obj.radius = 16 Obj.size = 1 Obj.CanTopLeft = true Obj.fidelity = 36 Obj.Draw = function( self ) local xs,ys , sx,sy = self.x,self.y , self.w, self.h local polys = {} local source = { {x=-1,y=-1} , {x=1,y=-1} , {x=1,y=1} ,...
apache-2.0
pinkysnowman/homedecor_modpack
homedecor/misc-nodes.lua
1
17388
local S = homedecor.gettext homedecor.register("ceiling_paint", { description = S("Textured Ceiling Paint"), drawtype = 'signlike', tiles = { 'homedecor_ceiling_paint.png' }, inventory_image = 'homedecor_ceiling_paint_roller.png', wield_image = 'homedecor_ceiling_paint_roller.png', walkable = false, groups = { ...
lgpl-3.0
AbolDalton/king
plugins/inkie.lua
1
1280
local abol = 368305537 local function action_by_reply(extra, success, result) local hash = 'rank:variables' local text = '' local value = redis:hget(hash, result.from.id) if not value then if result.from.id == tonumber(abol) then text = text..'این مدیر کل رباته \n\n' elseif is_...
gpl-2.0
psychon/lgi
samples/gtk-demo/demo-ofw-mirror.lua
6
8169
return function(parent, dir) local math = require 'math' local lgi = require 'lgi' local GObject = lgi.GObject local Gtk = lgi.Gtk local Gdk = lgi.Gdk local cairo = lgi.cairo local GtkDemo = lgi.GtkDemo local log = lgi.log.domain 'gtk-demo' GtkDemo:class('MirrorBin', Gtk.Bin) function GtkDemo.MirrorBin:_init() s...
mit
parsagachkardev/AutoBotS
bot/utils.lua
309
23029
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")() JSON = (loadfile "./libs/...
gpl-2.0
hksonngan/Polycode
Examples/Lua/3D_Physics/3DPhysics_RayTest/Scripts/Main.lua
10
1523
hud = Scene(Scene.SCENE_2D) label = SceneLabel("Click on a shape to select it.", 16) label:setPosition(-640/ 2 + 120, 480 / 2 - 10) hud:addChild(label) scene = CollisionScene(Vector3(2000, 2000, 2000), false, false) local ground = ScenePrimitive(ScenePrimitive.TYPE_PLANE, 10, 10) ground:loadTexture("Resources/green...
mit
asanosoyokaze/skynet
lualib/skynet/inject.lua
61
1373
local function getupvaluetable(u, func, unique) local i = 1 while true do local name, value = debug.getupvalue(func, i) if name == nil then return end local t = type(value) if t == "table" then u[name] = value elseif t == "function" then if not unique[value] then unique[value] = true getu...
mit
thenumbernine/hydro-cl-lua
hydro/op/viscous-explicit.lua
1
3433
local class = require 'ext.class' local table = require 'ext.table' local ViscousExplicit = class() ViscousExplicit.name = 'ViscousExplicit' function ViscousExplicit:init(args) self.solver = assert(args.solver) require 'hydro.code.symbols'(self, self:getSymbolFields()) end function ViscousExplicit:getSymbolFiel...
mit
robotology/funny-things
app/scripts/lua/gaze.lua
1
4215
#!/usr/bin/lua -- Copyright: (C) 2016 iCub Facility - Istituto Italiano di Tecnologia (IIT) -- Authors: Ugo Pattacini <ugo.pattacini@iit.it> -- Ali Paikan <ali.paikan@iit.it> -- Copy Policy: Released under the terms of the LGPLv2.1 or later, see LGPL.TXT -- Dependencies -- -- To install posix.signal do: -- s...
gpl-2.0
psychon/lgi
lgi/override/GooCanvas.lua
2
1175
------------------------------------------------------------------------------ -- -- lgi GooCanvas override module. -- -- Copyright (c) 2017 Pavel Holejsovsky -- Licensed under the MIT license: -- http://www.opensource.org/licenses/mit-license.php -- -----------------------------------------------------------------...
mit
AlexarJING/space-war
lib/gamera.lua
15
5829
-- gamera.lua v1.0.1 -- Copyright (c) 2012 Enrique García Cota -- 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,...
apache-2.0
sk89q/PlayX
src/PlayX/lua/playx/providers/justin.tv.lua
2
1717
-- 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 v...
lgpl-3.0
pakozm/stdml-april
stdml/classification_utils.lua
1
1235
--[[ Copyright (c) 2014 Francisco Zamora-Martinez (pakozm@gmail.com) The STDML is an extension for APRIL-ANN toolkit, and both are free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 3 as published by the Free Software Foundation This library i...
gpl-3.0
mahdib9/mb
plugins/lock_badword.lua
5
1225
local function run(msg, matches) if msg.to.type == 'chat' then if is_owner(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']['lock_badw'...
gpl-2.0
DJDaemonix/Roboports-Extended
prototypes/items.lua
1
1600
data:extend ( { { --roboport-mk2 type = "item", name = "roboport-mk2", icon = "__base__/graphics/icons/roboport.png", icon_size = 32, subgroup = "logistic-network", order = "c[signal]-b[roboport]2", place_result = "roboport-mk2", stack_size = 5 }, { --robopor...
gpl-3.0
keneanung/mudlet
src/mudlet-lua/lua/geyser/GeyserLabel.lua
13
3769
-------------------------------------- -- -- -- The Geyser Layout Manager by guy -- -- -- -------------------------------------- --- Represents a label like we all know and love. -- @class table -- @name Geyser.Label -- @field fillBg 1 if the background...
gpl-2.0
uhvhugvhhbbh545hhhyg/rekjx
plugins/value.lua
2
2621
local function get_variables_hash(msg) if msg.to.type == 'chat' or msg.to.type == 'channel' then return 'chat:bot'..msg.to.id..':variables' end end local function get_value(msg, var_name) local hash = get_variables_hash(msg) if hash then local value = redis:hget(hash, var_name) if not value then ...
gpl-2.0
q-gears/q-gears-reversing-data
output/data/maps/ffvii/field/md1_1.lua
1
19711
EntityContainer = {} EntityContainer[ "Director" ] = { on_start = function( self ) background2d:play_animation_looped( "Light1" ) background2d:play_animation_looped( "Light2" ) background2d:play_animation_looped( "Fan" ) background2d:autoscroll_to_entity( entity_manager...
gpl-2.0
Noneatme/mta-lostresources
[gamemodes]/twd/client/CExplosion.lua
1
5203
--------------------------------- -- COPYRIGHT[C], NOVEMBER 2012 -- ------- MADE BY NONEATME -------- --------------------------------- -- ####################################### -- ## Project: MTA:The Walking Death ## -- ## Name: Custom Explosions ## -- ## Author: Noneatme ## -- ## Version: 1.0 ## -- ## Lic...
gpl-2.0
RailTracker/OpenRA
mods/cnc/maps/nod04a/nod04a.lua
25
10956
NodUnitsBuggy = { 'bggy', 'bggy', 'bggy', 'bggy', 'bggy' } NodUnitsBikes = { 'bike', 'bike', 'bike' } NodUnitsGunner = { 'e1', 'e1', 'e1', 'e1', 'e1', 'e1' } NodUnitsRocket = { 'e3', 'e3', 'e3', 'e3', 'e3', 'e3' } Atk6Units = { 'c1', 'c2', 'c3' } Atk5Units = { 'e1', 'e1', 'e2', 'e2' } Atk1Units = { 'e1', 'e1' } XxxxUn...
gpl-3.0
emoon/ProDBG
bin/macosx/tundra/scripts/tundra/tools/msvc6.lua
22
3214
-- msvc6.lua - Visual Studio 6 module(..., package.seeall) local native = require "tundra.native" local os = require "os" function path_combine(path, path_to_append) if path == nil then return path_to_append end if path:find("\\$") then return path .. path_to_append end return path .. "\\" .. path_...
mit
thenumbernine/hydro-cl-lua
hydro/mesh/mesh.lua
1
16613
--[[ parent class of meshes used by hydro/solver/meshsolver --]] local ffi = require 'ffi' local class = require 'ext.class' local math = require 'ext.math' local table = require 'ext.table' local range = require 'ext.range' local vec2i = require 'vec-ffi.vec2i' local vector = require 'ffi.cpp.vector' -- one of these i...
mit
AlexarJING/space-war
lib/loveframes/objects/internal/multichoice/multichoicelist.lua
12
10407
--[[------------------------------------------------ -- 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.multichoice....
apache-2.0
mehrpouya81/y
plugins/yoda.lua
642
1199
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 request(text) local api = "https://yoda.p.mashape.com/yoda?" text = ...
gpl-2.0
luadch/luadch
scripts/cmd_setpass.lua
1
13123
--[[ cmd_setpas.lua by blastbeat - this script adds a command "setpas" to set or change the password of your own or an user by nick - usage: [+!#]setpass nick <nick> <password> - [+!#]setpass myself <password> sets your own pasword v0.20: by pulsar - rightcli...
gpl-3.0
asanosoyokaze/skynet
lualib/snax/msgserver.lua
58
7383
local skynet = require "skynet" local gateserver = require "snax.gateserver" local netpack = require "netpack" local crypt = require "crypt" local socketdriver = require "socketdriver" local assert = assert local b64encode = crypt.base64encode local b64decode = crypt.base64decode --[[ Protocol: All the number type ...
mit
adityaramesh/lantern
lt/tty_logger.lua
1
1593
local F = lt.F local io = lt.io local tty_logger = torch.class('lt.tty_logger') function tty_logger:log(resource, data) local make_prefix = function(msg) local caller_info = debug.getinfo(3) local file = lt.path.relpath(caller_info.short_src) local line = caller_info.currentline local func = caller_info.nam...
bsd-3-clause
RailTracker/OpenRA
mods/ra/maps/soviet-06b/soviet06b.lua
12
4263
IntroAttackers = { IntroEnemy1, IntroEnemy2, IntroEnemy3 } Trucks = { Truck1, Truck2 } InfAttack = { } ArmorAttack = { } AttackPaths = { { AttackWaypoint1 }, { AttackWaypoint2 } } AlliedInfantryTypes = { "e1", "e1", "e3" } AlliedArmorTypes = { "jeep", "jeep", "1tnk", "1tnk", "2tnk", "2tnk", "arty" } SovietReinforceme...
gpl-3.0
CapsAdmin/fishingmod2
lua/fishing/server/spawning.lua
2
3544
do -- spots fishing.SampledSpots = fishing.SampledSpots or {} fishing.SearchedSpots = fishing.SearchedSpots or {{{}}} fishing.FishSpots = --[[fishing.FishSpots or]] {{{}}} function fishing.SampleSpots() for key, ent in pairs(ents.FindByClass("weapon_fishing")) do if ent.Owner:IsValid() and ent.dt.hook:IsVal...
gpl-3.0
zackp30/cuberite
MCServer/Plugins/APIDump/Classes/Network.lua
24
20083
-- Network.lua -- Defines the documentation for the cNetwork-related classes return { cNetwork = { Desc = [[ This is the namespace for high-level network-related operations. Allows plugins to make TCP connections to the outside world using a callback-based API.</p> <p> All functions in this nam...
apache-2.0
AbolDalton/king
plugins/megagroup.lua
1
98478
--Begin supergrpup.lua --Check members #Add supergroup local function check_member_super(cb_extra, success, result) local receiver = cb_extra.receiver local data = cb_extra.data local msg = cb_extra.msg if success == 0 then send_large_msg(receiver, "Promote me to admin first!") end for k,v in pairs(result)...
gpl-2.0
pinkysnowman/homedecor_modpack
lrfurn/init.lua
11
2132
lrfurn = {} screwdriver = screwdriver or {} lrfurn.fdir_to_fwd = { { 0, 1 }, { 1, 0 }, { 0, -1 }, { -1, 0 }, } lrfurn.colors = { -- mod changed to use colorize feature of minetest engine (cg72) { "black", "#000000:230" }, { "brown", "#251005:225" }, { "blue", "#0000d0:225" }, { "cyan...
lgpl-3.0
johhnybritain/ettercap-with-ping
src/lua/share/scripts/get_imap_demo.lua
12
1671
--- -- Copyright (C) Ryan Linn and Mike Ryan -- -- 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. -- --...
gpl-2.0
vipteam1/VIPTEAM
plugins/l1.lua
1
2879
--[[ ▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Team name : ( 🌐 VIP_TEAM 🌐 )▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ File name : ( #all ) ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ ▀▄ ▄▀ Guenat team: ( @VIP_TEAM1 ) ▀▄ ▄▀ ▀▄ ▄▀ ...
gpl-2.0
luadch/luadch
core/scripts.lua
1
6960
--[[ scripts.lua by blastbeat - this script manages custom user scripts ]]-- ----------------------------------// DECLARATION //-- --// lua functions //-- local type = use "type" local error = use "error" local pairs = use "pairs" local pcall = use "pcall" local ipairs = use "ipair...
gpl-3.0
Armin041/RADDY
plugins/moderation.lua
25
30112
-------------------------------------------------- -- ____ ____ _____ -- -- | \| _ )_ _|___ ____ __ __ -- -- | |_ ) _ \ | |/ ·__| _ \_| \/ | -- -- |____/|____/ |_|\____/\_____|_/\/\_| -- -- -- --------------...
gpl-2.0
RuiChen1113/luci
applications/luci-app-privoxy/luasrc/model/cbi/privoxy.lua
35
37916
-- Copyright 2014-2015 Christian Schoenebeck <christian dot schoenebeck at gmail dot com> -- Licensed under the Apache License, Version 2.0 local NXFS = require "nixio.fs" local SYS = require "luci.sys" local UTIL = require "luci.util" local DISP = require "luci.dispatcher" local DTYP = require "luci.cbi.datatypes" l...
apache-2.0
thenumbernine/hydro-cl-lua
hydro/coord/cylinder.lua
1
3218
--[[ exact volume: int(φ=φ1,φ2 int(r=r1,r2 r dr) dφ) = 1/2 (φ2-φ1) (r2^2 - r1^2) volume element: r dr dφ = r (r2 - r1) (φ2 - φ1) = (r2+r1)/2 (r2 - r1) (φ2 - φ1) = 1/2 (r2^2 - r1^2) (φ2 - φ1) same thing, good thing --]] local class = require 'ext.class' local table = require 'ext.table' local symmath = require 'sym...
mit
roelofr/HorrorStory
gamemodes/horrorstory/gamemode/player_class/player_horrorstory.lua
1
5589
AddCSLuaFile() DEFINE_BASECLASS( "player_default" ) local PLAYER = {} PLAYER.DisplayName = "Horror Story player" PLAYER.WalkSpeed = 200 -- How fast to move when not running PLAYER.RunSpeed = 400 -- How fast to move when running PLAYER.CrouchedWalkSpeed = 0.3 -- Multiply move speed by this when crouchin...
agpl-3.0
zhukunqian/slua-1
build/luajit-2.1.0/dynasm/dasm_x86.lua
116
58970
------------------------------------------------------------------------------ -- DynASM x86/x64 module. -- -- Copyright (C) 2005-2015 Mike Pall. All rights reserved. -- See dynasm.lua for full copyright notice. ------------------------------------------------------------------------------ local x64 = x64 -- Module i...
mit
drcoms/drcom-generic
tests/drcom_d.lua
2
4150
#!/usr/bin/env lua -- drcom lua version with dhcp -- depend lua with double int32, luasocket, lua-md5 -- author: fuyumi -- dirty and unfinished local socket = require('socket') local md5 = require('md5') local udp = socket.udp() local server = '119.39.30.18' local port = 61440 udp:settimeout(5) udp:setsockname('*', p...
agpl-3.0
RobertoMalatesta/ProDBG
bin/win32/scripts/tundra/syntax/pkgconfig.lua
6
1228
module(..., package.seeall) function ConfigureRaw(cmdline, name, constructor) local fh = assert(io.popen(cmdline)) local data = fh:read("*all") fh:close() local cpppath = {} local libpath = {} local libs = {} local defines = {} local frameworks = {} for kind, value in data:gmatch("-([ILlD])([^ \n\r...
mit
asanosoyokaze/skynet
lualib/skynet/injectcode.lua
108
2610
local debug = debug local table = table local FUNC_TEMP=[[ local $ARGS return function(...) $SOURCE end, function() return {$LOCALS} end ]] local temp = {} local function wrap_locals(co, source, level, ext_funcs) if co == coroutine.running() then level = level + 3 end local f = debug.getinfo(co, level,"f").func ...
mit
Habbie/hammerspoon
extensions/serial/test_serial.lua
5
2084
function testAvailablePortNames() local availablePortNames = hs.serial.availablePortNames() assertTrue(type(availablePortNames) == "table") return success() end function testAvailablePortPaths() local availablePortPaths = hs.serial.availablePortPaths() assertTrue(type(availablePortPaths) == "table") retur...
mit