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
AMIRUJK/teleujk
plugins/ssssss.lua
3
3657
local add_user_cfg = load_from_file('data/add_user_cfg.lua') local function template_add_user(base, to_username, from_username, chat_name, chat_id) base = base or '' to_username = '@' .. (to_username or '') from_username = '@' .. (from_username or '') chat_name = string.gsub(chat_name, '_', ' ') or '' c...
gpl-2.0
Enignite/darkstar
scripts/zones/La_Theine_Plateau/npcs/qm3.lua
28
2035
----------------------------------- -- Area: La Theine Plateau -- NPC:??? (qm3) -- Involved in Quest: I Can Hear A Rainbow ----------------------------------- package.loaded["scripts/zones/La_Theine_Plateau/TextIDs"] = nil; ----------------------------------- require("scripts/zones/La_Theine_Plateau/TextIDs")...
gpl-3.0
Enignite/darkstar
scripts/zones/West_Sarutabaruta/npcs/Cavernous_Maw.lua
29
1519
----------------------------------- -- Area: West Sarutabaruta -- NPC: Cavernous Maw -- Teleports Players to West Sarutabaruta [S] -- @pos -2.229 0.001 -162.715 115 ----------------------------------- package.loaded["scripts/zones/West_Sarutabaruta/TextIDs"] = nil; ----------------------------------- require...
gpl-3.0
fcpxhacks/fcpxhacks
src/plugins/finalcutpro/inspector/info.lua
2
1397
--- === plugins.finalcutpro.inspector.info === --- --- Final Cut Pro Info Inspector Additions. local require = require --local log = require "hs.logger".new "videoInspector" local fcp = require "cp.apple.finalcutpro" local i18n = require "cp.i18n" local plugin = ...
mit
Enignite/darkstar
scripts/zones/The_Boyahda_Tree/npcs/Grounds_Tome.lua
34
1137
----------------------------------- -- Area: The Boyahda Tree -- NPC: Grounds Tome ----------------------------------- require("scripts/globals/settings"); require("scripts/globals/groundsofvalor"); ----------------------------------- -- onTrade Action ----------------------------------- function onTrad...
gpl-3.0
mys007/cudnn.torch
test/test_groups.lua
7
1261
require 'ccn2' require 'cudnn' bs = 32 ni = 96 no = 128 imsize = 55 groups = 2 kW = 7 stride = 3 ccn2_conv = ccn2.SpatialConvolution(ni,no,kW,stride,0,groups):cuda() cudnn_conv = cudnn.SpatialConvolution(ni,no,kW,kW,stride,stride,0,0,groups):cuda() input = torch.randn(bs,ni,imsize,imsize):cuda() input_tr = input:tra...
bsd-2-clause
joaofvieira/luci
applications/luci-app-upnp/luasrc/model/cbi/upnp/upnp.lua
56
3828
-- Copyright 2008 Steven Barth <steven@midlink.org> -- Copyright 2008-2011 Jo-Philipp Wich <jow@openwrt.org> -- Licensed to the public under the Apache License 2.0. m = Map("upnpd", luci.util.pcdata(translate("Universal Plug & Play")), translate("UPnP allows clients in the local network to automatically configure the...
apache-2.0
yetsky/luci
modules/admin-full/luasrc/controller/admin/index.lua
79
1245
--[[ LuCI - Lua Configuration Interface 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 http://www.apache.org/licenses/LICENSE-2.0 $Id$ ]]-- mod...
apache-2.0
philsiff/Red-Vs-Blue
Very Basic TDM [Gamemode]/gamemodes/vbtdm/gamemode/hitmarker/cl_hitdamagenumbers.lua
1
4238
local hit_txts = {} local hit_lastcurtime = 0 local dmg_cols = { gen = Color(255, 230, 210), -- Generic/Bullet damage crit = Color(255, 40, 40), -- Critical hit fire = Color(255, 120, 0), -- Fire damage expl = Color(240,240,50), -- Explosion damage acid = Color(140, 255, 75), -- Toxic damage elec = Color(100, 16...
mit
githabbot/server22
bot/utils.lua
11
26466
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
google/flatbuffers
samples/sample_binary.lua
17
3431
-- need to update the Lua path to point to the local flatbuffers implementation package.path = string.format("../lua/?.lua;%s",package.path) package.path = string.format("./lua/?.lua;%s",package.path) -- require the library local flatbuffers = require("flatbuffers") local binaryArray = flatbuffers.binaryArray-- for h...
apache-2.0
daniel-slaney/demirogue
src/texture.lua
3
4984
texture = {} local function _clamp( x, xmin, xmax ) if x < xmin then return xmin elseif x > xmax then return xmax end return x end local function _smootherstep( x, xmin, xmax ) local t = _clamp((x - xmin)/(xmax - xmin), 0, 1); return t*t*t*(t*(t*6 - 15) + 10) end -- bands = { -- [percentage] =...
bsd-3-clause
yetsky/luci
applications/luci-asterisk/luasrc/model/cbi/asterisk-iax-connections.lua
80
2000
--[[ 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 h...
apache-2.0
philsiff/Red-Vs-Blue
Red Vs. Blue Files/lua/vgui/spawnicon.lua
1
7520
local matHover = Material( "vgui/spawnmenu/hover" ) local PANEL = {} AccessorFunc( PANEL, "m_strModelName", "ModelName" ) AccessorFunc( PANEL, "m_iSkin", "SkinID" ) AccessorFunc( PANEL, "m_strBodyGroups", "BodyGroup" ) AccessorFunc( PANEL, "m_strIconName", "IconName" ) --[[---------------------------------...
mit
dijkstracula/libinjection
lua/luatest.lua
7
2497
require 'libinjection' -- dofile('sqlifingerprints.lua') -- silly callback that just calls back into C -- identical to libinjection_is_sqli(sql_state, string_input, nil) -- function check_pattern_c(sqlstate) return(libinjection.sqli_blacklist(sqlstate) and libinjection.sqli_not_whitelist(sqlstate)) e...
bsd-3-clause
NatWeiss/RGP
src/cocos2d-js/frameworks/js-bindings/cocos2d-x/cocos/scripting/lua-bindings/script/framework/components/event.lua
62
4752
local Event = class("Event") local EXPORTED_METHODS = { "addEventListener", "dispatchEvent", "removeEventListener", "removeEventListenersByTag", "removeEventListenersByEvent", "removeAllEventListeners", "hasEventListener", "dumpAllEventListeners", } function Event:init_() self.tar...
mit
mjarco/sysdig
userspace/sysdig/chisels/iobytes_file.lua
18
1602
--[[ Copyright (C) 2013-2014 Draios inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without...
gpl-2.0
yetsky/luci
applications/luci-n2n_v2/luasrc/model/cbi/n2n_v2.lua
13
1657
--[[ --N2N VPN(V2) configuration page. Made by 981213 -- ]]-- local fs = require "nixio.fs" m = Map("n2n_v2", translate("N2N VPN(V2)"), translatef("n2n is a layer-two peer-to-peer virtual private network (VPN) which allows users to exploit features typical of P2P applications at network instead of application...
apache-2.0
bradchesney79/2015BeastRouterProject
openwrt/unsquash/squashfs-root/usr/lib/lua/luci/model/cbi/admin_network/proto_static.lua
60
2460
-- Copyright 2011 Jo-Philipp Wich <jow@openwrt.org> -- Licensed to the public under the Apache License 2.0. local map, section, net = ... local ifc = net:get_interface() local ipaddr, netmask, gateway, broadcast, dns, accept_ra, send_rs, ip6addr, ip6gw local mtu, metric ipaddr = section:taboption("general", Value, ...
cc0-1.0
NonVolatileComputing/arrow
c_glib/example/lua/read-batch.lua
9
1557
-- Licensed to the Apache Software Foundation (ASF) under one -- or more contributor license agreements. See the NOTICE file -- distributed with this work for additional information -- regarding copyright ownership. The ASF licenses this file -- to you under the Apache License, Version 2.0 (the -- "License"); you may...
apache-2.0
pazos/koreader
frontend/ui/widget/buttontable.lua
3
4976
local Blitbuffer = require("ffi/blitbuffer") local Button = require("ui/widget/button") local Device = require("device") local FocusManager = require("ui/widget/focusmanager") local HorizontalGroup = require("ui/widget/horizontalgroup") local LineWidget = require("ui/widget/linewidget") local Size = require("ui/size") ...
agpl-3.0
philsiff/Red-Vs-Blue
Red Vs. Blue Files/lua/menu/progressbar.lua
1
2746
--=============================================================================-- -- ___ ___ _ _ _ __ _ ___ ___ __ __ -- |_ _|| __| / \ | \_/ | / _| / \ | o \ o \\ V / -- | | | _| | o || \_/ | ( |_n| o || / / \ / -- |_| |___||_n_||_| |_| \__/|_n_||_|\\_|\\ |_| 2009 -- --=============...
mit
yetsky/luci
applications/luci-firewall/luasrc/model/cbi/firewall/forwards.lua
85
3942
--[[ LuCI - Lua Configuration Interface Copyright 2008 Steven Barth <steven@midlink.org> Copyright 2010-2012 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 htt...
apache-2.0
cjtallman/luasocket
test/testclnt.lua
20
22799
local socket = require"socket" host = host or "localhost" port = port or "8383" function printf(...) io.stderr:write(string.format(...)) end function pass(...) printf(...) io.stderr:write("\n") end function fail(...) io.stderr:write("ERROR: ") printf(...) io.stderr:write("!\n") os.exit()...
mit
persianstar/AdvanSource
system/libs/serpent.lua
656
7877
local n, v = "serpent", 0.28 -- (C) 2012-15 Paul Kulchenko; MIT License local c, d = "Paul Kulchenko", "Lua serializer and pretty printer" local snum = {[tostring(1/0)]='1/0 --[[math.huge]]',[tostring(-1/0)]='-1/0 --[[-math.huge]]',[tostring(0/0)]='0/0'} local badtype = {thread = true, userdata = true, cdata = true} lo...
gpl-2.0
LilyEssence/neuralart
costs.lua
13
2661
-- -- Cost functions -- -- compute the Gramian matrix for input function gram(input) local k = input:size(2) local flat = input:view(k, -1) local gram = torch.mm(flat, flat:t()) return gram end function collect_activations(model, activation_layers, gram_layers) local activations, grams = {}, {} ...
mit
joaofvieira/luci
applications/luci-app-ddns/luasrc/model/cbi/ddns/overview.lua
33
9247
-- Copyright 2014 Christian Schoenebeck <christian dot schoenebeck at gmail dot com> -- Licensed to the public under the Apache License 2.0. local NXFS = require "nixio.fs" local CTRL = require "luci.controller.ddns" -- this application's controller local DISP = require "luci.dispatcher" local HTTP = require "luci.htt...
apache-2.0
mys007/cudnn.torch
Pointwise.lua
4
2063
local Pointwise, parent = torch.class('cudnn._Pointwise','nn.Module') local errcheck = cudnn.errcheck function Pointwise:__init(inplace) parent.__init(self) self.inplace = inplace or false end function Pointwise:createIODescriptors(input) assert(self.mode, 'mode is not set. (trying to use base class?)'); ...
bsd-2-clause
drmingdrmer/lua-paxos
lib/acid/paxos/acceptor.lua
2
7395
local _M = { _VERSION = require("acid.paxos._ver") } local tableutil = require( "acid.tableutil" ) local base = require( "acid.paxos.base" ) local round = require( "acid.paxos.round" ) local errors = base.errors local _meth = { _VERSION = _M._VERSION } local _mt = { __index = _meth } tableutil.merge( _meth, base ) ...
mit
pazos/koreader
frontend/ui/size.lua
2
3263
--[[-- This module provides a standardized set of sizes for use in widgets. There are values for borders, margins, paddings, radii, and lines. Have a look at the code for full details. If you are considering to deviate from one of the defaults, please take a second to consider: 1. Why you want to differ in the first ...
agpl-3.0
derElektrobesen/tntlua
list_mailer.lua
5
1347
-- space 0: -- tuple : (listid, email) -- space 1: -- tuple : (listid, subj_prefix) -- function returns list of mailer function list_mailer_get(listid) listid = box.unpack('i', listid) local result = { } local tuples = { box.select(0, 0, listid) } if tuples == nil then return else for _, tuple in ...
bsd-2-clause
theonlywild/copy
plugins/welcome.lua
114
3529
local add_user_cfg = load_from_file('data/add_user_cfg.lua') local function template_add_user(base, to_username, from_username, chat_name, chat_id) base = base or '' to_username = '@' .. (to_username or '') from_username = '@' .. (from_username or '') chat_name = string.gsub(chat_name, '_', ' ') or '' c...
gpl-2.0
rmtew/demirogue
src/mode/ForceDrawMode.lua
3
6595
-- -- mode/ForceDrawMode.lua -- -- Test bed and debugging tool for the force drawing algorithm. -- require 'Graph' local AABB = require 'lib/AABB' require 'Vector' require 'geometry' require 'graph2D' local graphDraw = require 'lib/graphDraw' local schema, ForceDrawMode = require 'lib/mode' { 'ForceDrawMode' } local...
bsd-3-clause
philsiff/Red-Vs-Blue
Red Vs. Blue Files/lua/autorun/server/sensorbones/tf2_heavy.lua
2
5282
-- -- These are the physics bone numbers -- local PLVS = 0; local RTHY = 1; local RCLF = 2; local LTHY = 3; local LCLF = 4; local LFOT = 5; local SPNE = 6; local SPN2 = 7; local RSLD = 8; local LSLD = 9; local LARM = 10; local LHND = 11; local RARM = 12; local RHND = 13; local HEAD = 14; local RFOT = 15...
mit
NatWeiss/RGP
src/cocos2d-js/frameworks/js-bindings/cocos2d-x/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua
7
29398
-------------------------------- -- @module ParticleSystem -- @extend Node,TextureProtocol -- @parent_module cc -------------------------------- -- Gets the start size variance in pixels of each particle.<br> -- return The start size variance in pixels of each particle. -- @function [parent=#ParticleSystem] getStart...
mit
IntelligentBot/IntelligentBot
libs/lua-redis.lua
580
35599
local redis = { _VERSION = 'redis-lua 2.0.4', _DESCRIPTION = 'A Lua client library for the redis key value storage system.', _COPYRIGHT = 'Copyright (C) 2009-2012 Daniele Alessandri', } -- The following line is used for backwards compatibility in order to keep the `Redis` -- global module name. Using...
gpl-2.0
siktirmirza/dt
plugins/setbotphoto.lua
18
1162
local function set_bot_photo(msg, success, result) local receiver = get_receiver(msg) if success then local file = 'data/photos/bot.jpg' print('File downloaded to:', result) os.rename(result, file) print('File moved to:', file) set_profile_photo(file, ok_cb, false) send_large_msg(receiver, '...
gpl-2.0
eggBOY91/Arctic-Core
src/scripts/lua/Lua/Stable Scripts/Azeroth/Karazhan/BOSS_Karazhan_Dorothee.lua
30
1308
-- TODO:Timer (3 seconds before goes into combat) ,enrage when tito is killed,check video when tito is summoned. function Dorothee_Water_Bolt(Unit, event, miscunit, misc) Unit:ClearThreatList() Unit:FullCastSpellOnTarget(31012,Unit:GetRandomPlayer()) end function Dorothee_Summon_Tito(Unit, event, miscunit, misc) pr...
agpl-3.0
rstudio/redx
lua/src/lib/plugins/weighted_score.lua
1
3179
local M = { } M.balance = function(request, session, param) local servers = session['servers'] if param ~= 'least' and param ~= 'most' then library.log_err("Weighted score requires a parameter or 'least' or 'most") return servers end if M.same_scores(servers) then return servers end if #servers ...
bsd-2-clause
yetsky/luci
applications/luci-asterisk/luasrc/controller/asterisk.lua
69
7498
--[[ 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 h...
apache-2.0
xiaowa183/Atlas
examples/tutorial-states.lua
40
2935
--[[ $%BEGINLICENSE%$ Copyright (c) 2007, 2009, 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
mp4saeed/energy28
msg-checks.lua
1
10698
local TIME_CHECK = 2 local function pre_process(msg) local data = load_data(_config.moderation.data) local chat = msg.chat_id_ local user = msg.sender_user_id_ local is_channel = gp_type(chat) == "channel" local is_chat = gp_type(chat) == "chat" local auto_leave = 'auto_leave_bot' local data = load_data(_config.moderat...
gpl-3.0
philsiff/Red-Vs-Blue
Red Vs. Blue Files/lua/weapons/weapon_medkit.lua
1
3082
AddCSLuaFile() SWEP.Author = "robotboy655 & MaxOfS2D" SWEP.Purpose = "Heal people with your primary attack, or yourself with the secondary." SWEP.Spawnable = true SWEP.UseHands = true SWEP.ViewModel = "models/weapons/c_medkit.mdl" SWEP.WorldModel = "models/weapons/w_medkit.mdl" SWEP.ViewModelFOV = 5...
mit
yetsky/luci
applications/luci-qos_gargoyle/luasrc/model/cbi/qos_gargoyle/download.lua
5
4558
--[[ ]]-- local wa = require "luci.tools.webadmin" local fs = require "nixio.fs" m = Map("qos_gargoyle", translate("Download"),translate("Download set")) s = m:section(TypedSection, "download_class", translate("download_class")) s.addremove = true s.template = "cbi/tblsection" name = s:option(Value, "name", trans...
apache-2.0
blankoworld/PorteAil
categ/display.lua
1
2007
#!/usr/bin/env lua -- display.lua -- Display content of a file and attempt to match some specific words -- author: Olivier DOSSMANN (olivier+lua@dossmann.net) --[[ requirement ]]-- require 'lfs' -- apt-get install liblua5.1-filesystem0 || luarocks install luafilesystem function process(filepath) -- parse given fil...
gpl-3.0
ARPA-SIMC/meteo-vm2
doc/examples/source.lua
1
1149
return { stations={ [1]={lon=1207738,lat=4460016,rep="locali"}, [2]={lon=1128402,lat=4483906,rep="locali"}, [3]={lon=1166134,lat=4485799,rep="locali"}, [4]={lon=1226798,lat=4416614,rep="locali"}, [5]={lon=1115610,lat=4426852,rep="locali"}, [6]={lon=1189605,lat=4438166,rep="locali"}, [7]={lon=1162264,lat=...
gpl-2.0
8day/aegisub-auto4-scripts
reformat-selected-collisions.lua
1
6840
--[[ Description Auto4 script written in Lua for subtitle editor Aegisub. Purpose is stated in the "script_description" variable. If you wonder why all the hassle with alignment etc., then the answer for you is this: because this way subs look more professional, as well as easier to read, at least for those accustom...
bsd-3-clause
Tarfand-pro/csgroup
plugins/info.lua
1
21821
local function callback_reply(extra, success, result) --icon & rank ------------------------------------------------------------------------------------------------ userrank = "Member" if is_vip(msg) then userrank = "VIP ⭐⭐⭐⭐" send_document(org_chat_id,"./icons/7.webp", ok_cb, false) elseif is_sudo(result) then...
gpl-2.0
joaofvieira/luci
applications/luci-app-asterisk/luasrc/model/cbi/asterisk-mod-codec.lua
68
1959
-- 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. cbimap = Map("asterisk", "asterisk", "") module = cbimap:section(TypedSection, "module", "Modules", "") module.anonymous = true codec_a_mu = module:option(Li...
apache-2.0
blankoworld/PorteAil
create_homepage.lua
1
10385
#!/usr/bin/env lua -- porteail.lua --[[ Requirements ]]-- require 'lfs' --[[ Variables ]]-- -- Mandatories files local configFile = './' .. 'configrc' -- Default directories values local currentpath = os.getenv('CURDIR') or '.' local default_dir_category = 'categ' local default_dir_component = 'composants' local d...
gpl-3.0
xiaowa183/Atlas
lib/proxy/tokenizer.lua
41
6215
--[[ $%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
pazos/koreader
frontend/ui/message/messagequeue.lua
11
2268
local ffi = require("ffi") local Event = require("ui/event") local logger = require("logger") local _ = require("ffi/zeromq_h") local czmq = ffi.load("libs/libczmq.so.1") local MessageQueue = {} function MessageQueue:new(o) o = o or {} setmetatable(o, self) self.__index = self if o.init then o:init()...
agpl-3.0
gnuser/gocServer
d_3rd/LuaJIT-2.0.1/dynasm/dasm_arm.lua
74
34483
------------------------------------------------------------------------------ -- DynASM ARM module. -- -- Copyright (C) 2005-2013 Mike Pall. All rights reserved. -- See dynasm.lua for full copyright notice. ------------------------------------------------------------------------------ -- Module information: local _in...
gpl-2.0
MathieuDuponchelle/gdx
demos/pax-britannica/pax-britannica-android/assets/data/scripts/fighter_ai.lua
11
2352
local v2 = require 'dokidoki.v2' -- shot range local shot_range = 200 -- try to stay this far away when you're out of ammo local run_distance = 200 -- true when we've shot everything and want to make a distance, false means -- we're approaching to attack local running = false local target = false local on_screen = t...
apache-2.0
joaofvieira/luci
applications/luci-app-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
soumith/nn
Concat.lua
1
4564
local Concat, parent = torch.class('nn.Concat', 'nn.Module') function Concat:__init(dimension) parent.__init(self) self.modules = {} self.size = torch.LongStorage() self.dimension = dimension end function Concat:add(module) table.insert(self.modules, module) return self end function Concat:get(inde...
bsd-3-clause
dfst/deepforge
test/unit/test-cases/code/alexnetowt.lua
2
1656
require 'nn' -- thanks to https://github.com/soumith/imagenet-multiGPU.torch for this example nGPU = 4 nClasses = 5 -- from https://code.google.com/p/cuda-convnet2/source/browse/layers/layers-imagenet-1gpu.cfg -- this is AlexNet that was presented in the One Weird Trick paper. http://arxiv.org/abs/1404.5997 local featu...
apache-2.0
zaeem55/meme
bot/utils.lua
473
24167
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
mrmetti/teleum-new-open
plugins/savefile.lua
9
1266
--Created by: @janlou & @Alirezame --Powered by: @SUDO_TM & @AdvanTM --⚠️CopyRight all right reserved⚠️ local function savefile(extra, success, result) local msg = extra.msg local name = extra.name local adress = extra.adress local receiver = get_receiver(msg) if success then local file = './'..adress..'...
gpl-2.0
philsiff/Red-Vs-Blue
Red Vs. Blue Files/lua/vgui/dmenuoptioncvar.lua
2
1320
--[[ _ ( ) _| | __ _ __ ___ ___ _ _ /'_` | /'__`\( '__)/' _ ` _ `\ /'_` ) ( (_| |( ___/| | | ( ) ( ) |( (_| | `\__,_)`\____)(_) (_) (_) (_)`\__,_) DMenuOption --]] PANEL = {} DEFINE_BASECLASS( "DMenuOption" ) AccessorFunc( P...
mit
Samake/Minecraft
Minecraft/client/classes/BlockCursorC.lua
1
3805
--[[ Name: Minecraft Filename: BlockCursorC.lua Authors: Sam@ke --]] BlockCursorC = {} function BlockCursorC:constructor(parent) mainOutput("BlockCursorC was loaded.") self.mainClass = parent self.x = nil self.y = nil self.z = nil self.blockOffset = 0.5 self.cursorColor = tocolor(0, 0, 0, 255) self.cur...
gpl-3.0
yetsky/luci
libs/httpclient/luasrc/httpclient/receiver.lua
93
6049
--[[ LuCI - Lua Development Framework Copyright 2009 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.apache.org/licenses/LICENSE-2.0 $Id$ ]]-- requ...
apache-2.0
pazos/koreader
spec/unit/background_runner_spec.lua
2
10752
describe("BackgroundRunner widget tests", function() local Device, PluginShare, MockTime, UIManager setup(function() require("commonrequire") package.unloadAll() require("document/canvascontext"):init(require("device")) -- Device needs to be loaded before UIManager. Devi...
agpl-3.0
philsiff/Red-Vs-Blue
Red Vs. Blue Files/gamemodes/sandbox/entities/weapons/gmod_tool/stools/inflator.lua
1
4566
TOOL.Category = "Poser" TOOL.Name = "#tool.inflator.name" TOOL.Command = nil TOOL.ConfigName = "" TOOL.LeftClickAutomatic = true TOOL.RightClickAutomatic = true TOOL.RequiresTraceHit = true if ( CLIENT ) then language.Add( "Tool_inflator_name", "Ragdoll Inflator" ) language.Add( "Tool_inflator_desc", "Inflat...
mit
philsiff/Red-Vs-Blue
Red Vs. Blue Files/lua/vgui/dcategorylist.lua
2
1530
--[[ _ ( ) _| | __ _ __ ___ ___ _ _ /'_` | /'__`\( '__)/' _ ` _ `\ /'_` ) ( (_| |( ___/| | | ( ) ( ) |( (_| | `\__,_)`\____)(_) (_) (_) (_)`\__,_) DPanelList A window. --]] local PANEL = {} --[[--------------------------------...
mit
eggBOY91/Arctic-Core
src/scripts/lua/Lua/0Misc/0LCF_Includes/LCF_Player.lua
18
2613
--[[ * ArcEmu MMORPG Server * Copyright (C) 2005-2007 Ascent Team <http://www.ascentemu.com/> * Copyright (C) 2008-2010 <http://www.ArcEmu.org/> * * 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 Softwa...
agpl-3.0
pazos/koreader
tools/wbuilder.lua
4
15107
-- widget test utility -- usage: ./luajit tools/wtest.lua require "defaults" print(package.path) package.path = "common/?.lua;rocks/share/lua/5.1/?.lua;frontend/?.lua;" .. package.path package.cpath = "common/?.so;common/?.dll;/usr/lib/lua/?.so;rocks/lib/lua/5.1/?.so;" .. package.cpath local DataStorage = require("da...
agpl-3.0
Aminkavari/-xXD4RKXx-
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
disslove2-bot/Mr.Mj-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
ZerothAngel/FtDScripts
control/airplane.lua
1
6385
--@ commons propulsionapi requestcontrol pid lookuptable normalizebearing getvectorangle sign clamp -- Airplane module (Yaw, Pitch, Throttle) Airplane_AltitudePID = PID.new(AirplanePIDConfig.Altitude, -10, 10) Airplane_YawPID = PID.new(AirplanePIDConfig.Yaw, -1, 1) Airplane_PitchPID = PID.new(AirplanePIDConfig.Pitch, -...
mit
Tarfand-pro/csgroup
plugins/tools.lua
1
38730
--Start tools.lua by @P9999 --[[Plugins: savefile saveplug tosticker tophoto note onservice setteam setsudo (Default: local sudo_id = 123456789) addsudo clean deleted (Thanks to @Blackwolf_admin) filter hyper & bold & italic & code addplug delplug rmsg version setwlc setbye rate start ]] --Functions: ------------------...
gpl-2.0
NatWeiss/RGP
src/cocos2d-js/frameworks/js-bindings/cocos2d-x/cocos/scripting/lua-bindings/script/cocostudio/DeprecatedCocoStudioFunc.lua
61
3456
if nil == ccs then return end --tip local function deprecatedTip(old_name,new_name) print("\n********** \n"..old_name.." was deprecated please use ".. new_name .. " instead.\n**********") end --functions of GUIReader will be deprecated begin local GUIReaderDeprecated = { } function GUIReaderDeprecated.shareRe...
mit
Humbedooh/papersplease
index.lua
1
7291
-- CREATE DATABASE `cfp` CHARACTER SET utf8 COLLATE utf8_general_ci; local rootFolder = "/www/CFP/" local template = "" local output = "" function print(...) output = output .. table.concat({...}, "") end function parseymd(txt) local y,m,d = txt:match("(%d+)-(%d+)-(%d+)") if y and m and d then re...
apache-2.0
pazos/koreader
frontend/ui/widget/imagewidget.lua
1
22063
--[[-- ImageWidget shows an image from a file or memory Show image from file example: UIManager:show(ImageWidget:new{ file = "resources/koreader.png", -- Make sure alpha is set to true if png has transparent background -- alpha = true, }) Show image from memory ex...
agpl-3.0
hummelchen/unikeylog
src/keysym2text.lua
1
1235
local utf8 = require 'utf8' -- Lua 5.3 or luarocks install utf8 local function binaryToInt(n) local a, b, c, d = n:byte(1, 4) return d * 256^3 + c * 256^2 + b * 256 + a end local keysym_map = {} for line in io.lines('keysyms.txt') do if line:sub(1, 1) ~= '#' then -- example: 0x0020 U0020 . ...
mit
Aminkavari/-xXD4RKXx-
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
dangersuperbot/super_boomrange
plugins/status.lua
3
3989
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
philsiff/Red-Vs-Blue
Red Vs. Blue Files/addons/ulib/lua/ulib/server/util.lua
2
8396
--[[ Title: Utilities Has some useful server utilities ]] --[[ Function: clientRPC Think of this function as if you're calling a client function directly from the server. You state who should run it, what the name of the function is, and then a list of parameters to pass to that function on the client. ULib ha...
mit
bradchesney79/2015BeastRouterProject
openwrt/unsquash/squashfs-root/usr/lib/lua/luci/ltn12.lua
84
8954
--[[ LuaSocket 2.0.2 license Copyright � 2004-2007 Diego Nehab 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, me...
cc0-1.0
pazos/koreader
plugins/autofrontlight.koplugin/main.lua
4
4441
local Device = require("device") if not Device:isKindle() or (Device.model ~= "KindleVoyage" and Device.model ~= "KindleOasis") then return { disabled = true, } end local ConfirmBox = require("ui/widget/confirmbox") local DataStorage = require("datastorage") local LuaSettings = require("luasettings") local Plu...
agpl-3.0
kahluamods/konferpug
KPG-Utility.lua
1
4158
--[[ KahLua KonferPUG - an open roll loot distribution helper for PUGs. WWW: http://kahluamod.com/kpug SVN: http://kahluamod.com/svn/konferpug IRC: #KahLua on irc.freenode.net E-mail: cruciformer@gmail.com Please refer to the file LICENSE.txt for the Apache License, Version 2.0. Co...
apache-2.0
cuberite/transapi
main.lua
7
1934
-- This plugin copyright Alexander Harkness 2013, licensed under the MIT license. -- Configuration g_ServerLang = "en" g_ConsoleLang = "en" -- Global Variables g_Plugin = nil g_PluginDir = "" g_DataLoc = "" g_UserData = nil -- START WITH DA AWESOME! function Initialize( Plugin ) -- Set u...
mit
philsiff/Red-Vs-Blue
Red Vs. Blue Files/lua/vgui/dlabelurl.lua
2
2140
--[[ _ ( ) _| | __ _ __ ___ ___ _ _ /'_` | /'__`\( '__)/' _ ` _ `\ /'_` ) ( (_| |( ___/| | | ( ) ( ) |( (_| | `\__,_)`\____)(_) (_) (_) (_)`\__,_) DLabelURL --]] PANEL = {} AccessorFunc( PANEL, "m_colText", "TextColor" ) A...
mit
klyone/wishbone-gen
cgen_doc_texinfo.lua
1
4641
#!/usr/bin/lua -- wbgen2, (c) 2010 Tomasz Wlostowski/CERN BE-Co-HT -- LICENSED UNDER GPL v2 -- File: cgen_c_headers.lua -- -- Texinfo documentation generator. -- --function has_any_ports(reg) -- local has = false; -- if(reg.ports ~= nil) then return true; end -- foreach_subfield(reg, function(field) if (field....
gpl-2.0
NatWeiss/RGP
src/cocos2d-js/frameworks/js-bindings/cocos2d-x/cocos/scripting/lua-bindings/auto/api/JumpBy.lua
7
1299
-------------------------------- -- @module JumpBy -- @extend ActionInterval -- @parent_module cc -------------------------------- -- Creates the action.<br> -- param duration Duration time, in seconds.<br> -- param position The jumping distance.<br> -- param height The jumping height.<br> -- param jumps The jumping ...
mit
xiaowa183/Atlas
lib/histogram.lua
40
5165
--[[ $%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
philsiff/Red-Vs-Blue
Red Vs. Blue Files/gamemodes/sandbox/gamemode/player_class/player_sandbox.lua
1
4018
AddCSLuaFile() DEFINE_BASECLASS( "player_default" ) if ( CLIENT ) then CreateConVar( "cl_playercolor", "0.24 0.34 0.41", { FCVAR_ARCHIVE, FCVAR_USERINFO, FCVAR_DONTRECORD }, "The value is a Vector - so between 0-1 - not between 0-255" ) CreateConVar( "cl_weaponcolor", "0.30 1.80 2.10", { FCVAR_ARCHIVE, FCVAR_USERI...
mit
ld-test/lua-curl
examples/lcurl/post.lua
4
1451
local cURL = require("lcurl") local post = cURL.form() -- post file from filesystem :add_file ("name", "post.lua", "text/plain") -- post file from data variable :add_buffer("name2", "dummy.html", "<html><bold>bold</bold></html>", "text/html") cURL.easy() :setopt_url("http://localhost") :setopt_httppost(p...
mit
thess/OpenWrt-packages
utils/prometheus-node-exporter-lua/files/usr/lib/lua/prometheus-collectors/bmx7.lua
76
2091
#!/usr/bin/lua local json = require "cjson" local function interpret_suffix(rate) if rate ~= nil then local value = string.sub(rate, 1, -2) local suffix = string.sub(rate, -1) if suffix == "K" then return tonumber(value) * 10^3 end if suffix == "M" then return tonumber(value) * 10^6 end if suffi...
gpl-2.0
LuaDist2/zipwriter
utils/mkarch.lua
3
2280
local IS_WINDOWS = package.config:sub(1,1) == '\\' local ZipWriter = require "ZipWriter" local PATH = require "path" local TEXT_EXT = {".lua", ".txt", ".c", ".cpp", ".h", ".hpp", ".pas", ".cxx", ".me"} local function isin(s, t) local s = s:lower() for _, v in ipairs(t) do if s == v then return true...
mit
ld-test/luatexts
src/lua/luatexts/lua.lua
1
9090
-------------------------------------------------------------------------------- -- luatexts/lua.lua: plain Lua implementation of luatexts -------------------------------------------------------------------------------- -- Copyright (c) 2011-2012, luatexts authors -- See license in the file named COPYRIGHT ------------...
mit
pazos/koreader
frontend/ui/network/wpa_supplicant.lua
4
5241
--[[-- WPA client helper for Kobo. ]] local FFIUtil = require("ffi/util") local InfoMessage = require("ui/widget/infomessage") local WpaClient = require('lj-wpaclient/wpaclient') local UIManager = require("ui/uimanager") local _ = require("gettext") local T = FFIUtil.template local CLIENT_INIT_ERR_MSG = _("Failed to ...
agpl-3.0
lopezloo/mta-csrw
csrw/server/nominate.lua
1
5103
local playerNominations = { } local nominations = {} local nominateLimit = 5 -- lista map w obecnym głosowaniu local currentVoteOptions = {} function nominateMap(mapName) if not client or client ~= source then return end if #currentVoteOptions > 0 then outputText("msg_ArleadyVoting", 255, 102, 102, client) ...
gpl-3.0
githabbot/server22
libs/redis.lua
14
2985
local Redis = require 'redis' local FakeRedis = require 'fakeredis' local params = { host = '127.0.0.1', port = 6379, } -- Overwrite HGETALL Redis.commands.hgetall = Redis.command('hgetall', { response = function(reply, command, ...) local new_reply = { } for i = 1, #reply, 2 do new_reply[reply[i]] = re...
gpl-2.0
pazos/koreader
frontend/device.lua
4
1535
local isAndroid, _ = pcall(require, "android") local util = require("ffi/util") local function probeDevice() if util.isSDL() then return require("device/sdl/device") end if isAndroid then return require("device/android/device") end local kindle_sn = io.open("/proc/usid", "r") ...
agpl-3.0
pecio/RBP-Broker
core.lua
1
6623
-- LDB-Broker ------------- local ldb = LibStub:GetLibrary("LibDataBroker-1.1") local AceConfig = LibStub("AceConfig-3.0") local AceConfigReg = LibStub("AceConfigRegistry-3.0") local L = LibStub("AceLocale-3.0"):GetLocale("RBPBroker") local UPDATEPERIOD, elapsed = 0.5, 0 local RBPSPELL = 125439 local dataobj = ldb:N...
gpl-3.0
anonymous12212020/sbss
plugins/boobs.lua
1
1605
do -- Recursive function local function getRandomButts(attempt) attempt = attempt or 0 attempt = attempt + 1 local res,status = http.request("http://api.obutts.ru/noise/1") if status ~= 200 then return nil end local data = json:decode(res)[1] -- The OpenBoobs API sometimes returns an empty array if no...
gpl-2.0
amirmrbad/flashbot
bot/utils.lua
646
23489
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
fegimanam/bib
bot/utils.lua
646
23489
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
gnuser/gocServer
d_3rd/LuaJIT-2.0.1/src/host/genminilua.lua
73
11943
---------------------------------------------------------------------------- -- Lua script to generate a customized, minified version of Lua. -- The resulting 'minilua' is used for the build process of LuaJIT. ---------------------------------------------------------------------------- -- Copyright (C) 2005-2013 Mike P...
gpl-2.0