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 |
|---|---|---|---|---|---|
TeoTwawki/darkstar | scripts/zones/East_Ronfaure/Zone.lua | 2 | 1696 | -----------------------------------
--
-- Zone: East_Ronfaure (101)
--
-----------------------------------
local ID = require("scripts/zones/East_Ronfaure/IDs")
require("scripts/globals/icanheararainbow");
require("scripts/globals/chocobo_digging");
require("scripts/globals/conquest");
require("scripts/globals/quests")... | gpl-3.0 |
kesac/libtsl | libtsl/entity.lua | 1 | 1816 | --[[
Copyright (c) 2012 Kevin Sacro
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, distribu... | mit |
MNoya/Warchasers | game/dota_addons/warchasers/scripts/vscripts/statcollection/schema.lua | 1 | 3406 | customSchema = class({})
function customSchema:init()
-- Listen for changes in the current state
ListenToGameEvent('game_rules_state_change', function(keys)
-- Grab the current state
local state = GameRules:State_Get()
if state == DOTA_GAMERULES_STATE_POST_GAME then
... | gpl-3.0 |
jchuang1977/my_luci | applications/luci-wol/luasrc/model/cbi/wol.lua | 37 | 2522 | --[[
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
]]--
local sy... | apache-2.0 |
Kyominii/Cops_FiveM | police/server/server.lua | 1 | 16324 | --[[
Cops_FiveM - A cops script for FiveM RP servers.
Copyright (C) 2018 FiveM-Scripts
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 vers... | mit |
TelTOP/TeleStar22 | plugins/all.lua | 1321 | 4661 | do
data = load_data(_config.moderation.data)
local function get_msgs_user_chat(user_id, chat_id)
local user_info = {}
local uhash = 'user:'..user_id
local user = redis:hgetall(uhash)
local um_hash = 'msgs:'..user_id..':'..chat_id
user_info.msgs = tonumber(redis:get(um_hash) or 0)
user_info.name = user_print... | gpl-2.0 |
amirquick/quick | plugins/all.lua | 1321 | 4661 | do
data = load_data(_config.moderation.data)
local function get_msgs_user_chat(user_id, chat_id)
local user_info = {}
local uhash = 'user:'..user_id
local user = redis:hgetall(uhash)
local um_hash = 'msgs:'..user_id..':'..chat_id
user_info.msgs = tonumber(redis:get(um_hash) or 0)
user_info.name = user_print... | gpl-2.0 |
galnegus/Glaskross | lib/sperm/loveframes/objects/internal/tabbutton.lua | 3 | 5444 | --[[------------------------------------------------
-- Love Frames - A GUI library for LOVE --
-- Copyright (c) 2013 Kenny Shields --
--]]------------------------------------------------
-- tabbutton class
local newobject = loveframes.NewObject("tabbutton", "loveframes_object_tabbutton", true)
--[[----------------... | mit |
rashed8271/bot | bot/permissions.lua | 43 | 1333 | local sudos = {
"plugins",
"rank_admin",
"bot",
"lang_install",
"set_lang",
"tosupergroup",
"gban_installer"
}
local admins = {
"rank_mod",
"gban",
"ungban",
"setrules",
"setphoto",
"creategroup",
"setname",
"addbots",
"setlink",
"rank_guest",
"description",
"export_... | gpl-2.0 |
thisverygoodhhhh/orange | orange/plugins/waf/handler.lua | 3 | 3642 | local pairs = pairs
local ipairs = ipairs
local orange_db = require("orange.store.orange_db")
local judge_util = require("orange.utils.judge")
local extractor_util = require("orange.utils.extractor")
local handle_util = require("orange.utils.handle")
local BasePlugin = require("orange.plugins.base_handler")
local stat ... | mit |
MichaelSp/deutsch_lernen | www/cgi-bin/videos.lua | 1 | 3283 | #!/usr/bin/lua
-- video_dir = '../../videos'
videos_dir = '/www/videos'
url_path= '/videos'
function scandir(directory)
local i, t, popen = 0, {}, io.popen
for filename in popen('ls -a "'..directory..'"'):lines() do
if not(filename == '.' or filename == '..') then
i = i + 1
t[i... | mit |
mixflowtech/logsensor | lib/ljsyscall/syscall/linux/x64/ffi.lua | 25 | 1356 | -- x64 specific definitions
return {
epoll = [[
struct epoll_event {
uint32_t events;
epoll_data_t data;
} __attribute__ ((packed));
]],
ucontext = [[
typedef long long greg_t, gregset_t[23];
typedef struct _fpstate {
unsigned short cwd, swd, ftw, fop;
unsigned long long rip, rdp;
unsigned mxcsr, mxcr_m... | apache-2.0 |
LuckyGameCn/LHCocosGame | cocos2d/cocos/scripting/lua-bindings/auto/api/Control.lua | 3 | 2941 |
--------------------------------
-- @module Control
-- @extend Layer
--------------------------------
-- @function [parent=#Control] setEnabled
-- @param self
-- @param #bool bool
--------------------------------
-- @function [parent=#Control] onTouchMoved
-- @param self
-- @param #cc.Touch touch
-- @param... | mit |
lowne/hammerspoon | extensions/osascript/init.lua | 9 | 2774 | --- === hs.osascript ===
---
--- Execute Open Scripting Architecture (OSA) code - AppleScript and JavaScript
---
local module = require("hs.osascript.internal")
-- private variables and methods -----------------------------------------
local processResults = function(ok, object, rawDescriptor)
local descriptor
... | mit |
ArchShaman/Zero-K | scripts/cloakjammer.lua | 15 | 2991 | local head = piece 'head'
local hips = piece 'hips'
local chest = piece 'chest'
local rthigh = piece 'rthigh'
local lthigh = piece 'lthigh'
local lshin = piece 'lshin'
local rshin = piece 'rshin'
local rfoot = piece 'rfoot'
local lfoot = piece 'lfoot'
local disc = piece 'disc'
local cloaker = piece 'cloaker' ... | gpl-2.0 |
ArchShaman/Zero-K | LuaUI/Widgets/chili/simple examples/Widgets/gui_simplewindow.lua | 17 | 3595 |
function widget:GetInfo()
return {
name = "chilli example",
desc = "example chilli code",
author = "smoth",
date = "8/26/10",
license = "none",
layer = 0,
enabled = false -- loaded by default?
}
end
local windows = {}
local Window
local ScrollPanel
local Chili
local lab
local tx = "Man... | gpl-2.0 |
galnegus/Glaskross | lib/sperm/loveframes/objects/internal/menuoption.lua | 3 | 5958 | --[[------------------------------------------------
-- Love Frames - A GUI library for LOVE --
-- Copyright (c) 2013 Kenny Shields --
--]]------------------------------------------------
-- menuoption object
local newobject = loveframes.NewObject("menuoption", "loveframes_object_menuoption", true)
--[[------------... | mit |
jchuang1977/my_luci | contrib/luadoc/lua/luadoc/init.lua | 172 | 1333 | -------------------------------------------------------------------------------
-- LuaDoc main function.
-- @release $Id: init.lua,v 1.4 2008/02/17 06:42:51 jasonsantos Exp $
-------------------------------------------------------------------------------
local require = require
local util = require "luadoc.util"
log... | apache-2.0 |
ArchShaman/Zero-K | LuaRules/Configs/cloak_shield_defs.lua | 16 | 1373 | -- Cloak Levels
--
-- 0: disabled
-- 1: conditionally enabled, uses energy
-- 2: conditionally enabled, does no use energy
-- 3: enabled, unless stunned
-- 4: always enabled
local uncloakables = {}
for k, v in pairs(UnitDefNames) do
if (v.customParams.cannotcloak) then
uncloakables[k] = true
end
end
l... | gpl-2.0 |
Lerg/plugins-sample-vk | scenes/friends.lua | 1 | 5290 | local composer = require('composer')
local widget = require('widget')
local json = require('json')
local vk = require('plugin.vk')
local _W = display.contentWidth
local _H = display.contentHeight
local _CX, _CY = _W * 0.5, _H * 0.5
local _T, _L = display.screenOriginY, display.screenOriginX -- Top, Left
local _R, _B ... | mit |
sdgdsffdsfff/lua-resty-template | lib/resty/template/html.lua | 10 | 1201 | local template = require "resty.template"
local escape = template.escape
local concat = table.concat
local pairs = pairs
local type = type
local function tag(name, content, attr)
local r, a, content = {}, {}, content or attr
r[#r + 1] = "<"
r[#r + 1] = name
if attr then
for k, v in pairs(attr) ... | bsd-3-clause |
ArchShaman/Zero-K | scripts/hoverraid.lua | 11 | 1979 | include "constants.lua"
local base = piece 'base'
local turret = piece 'turret'
local gun = piece 'gun'
local flare = piece 'flare'
local ground = piece 'ground01'
local wakes = {}
for i = 1, 8 do
wakes[i] = piece('wake0' .. i)
end
local function WobbleUnit()
local wobble = true
while true do
if wobble == true t... | gpl-2.0 |
celeron55/buildat | games/uitest/main/client_lua/init.lua | 1 | 1192 | -- Buildat: uitest/client_lua/init.lua
-- http://www.apache.org/licenses/LICENSE-2.0
-- Copyright 2014 Perttu Ahola <celeron55@gmail.com>
local log = buildat.Logger("uitest")
local magic = require("buildat/extension/urho3d")
local uistack = require("buildat/extension/uistack")
log:info("uitest/init.lua loaded")
local ... | apache-2.0 |
Corvass/BorrowedTime | Libs/AceGUI-3.0-SharedMediaWidgets/Libs/AceGUI-3.0/AceGUI-3.0.lua | 11 | 23422 | --- **AceGUI-3.0** provides access to numerous widgets which can be used to create GUIs.
-- AceGUI is used by AceConfigDialog to create the option GUIs, but you can use it by itself
-- to create any custom GUI. There are more extensive examples in the test suite in the Ace3
-- stand-alone distribution.
--
-- **Note**:... | gpl-3.0 |
Corvass/BorrowedTime | Libs/AceGUI-3.0/AceGUI-3.0.lua | 11 | 23422 | --- **AceGUI-3.0** provides access to numerous widgets which can be used to create GUIs.
-- AceGUI is used by AceConfigDialog to create the option GUIs, but you can use it by itself
-- to create any custom GUI. There are more extensive examples in the test suite in the Ace3
-- stand-alone distribution.
--
-- **Note**:... | gpl-3.0 |
sternold/Love2DRL | src/game/classes/Item.lua | 1 | 7122 | Item = class('Item')
function Item:initialize(use_function)
self.use_function = use_function
self.var = {}
end
function Item:pick_up()
if table.maxn(data.player.inventory) >= 26 then
game.print("Your inventory is full.")
else
table.insert(data.player.inventory, self.owner)
table... | mit |
mixflowtech/logsensor | src/program/lwaftr/loadtest/promise.lua | 2 | 1552 | module(..., package.seeall)
Promise = {}
Promise.__index = Promise
local function is_promise(val)
return type(val) == 'table' and val.and_then
end
local function curry(f, ...)
local curried_args = { ... }
if #curried_args == 0 then return f end
return function(...)
local args = { ... }
for i=... | apache-2.0 |
SawyerHood/mal | lua/core.lua | 7 | 6986 | local utils = require('utils')
local types = require('types')
local reader = require('reader')
local printer = require('printer')
local readline = require('readline')
local socket = require('socket')
local Nil, List, HashMap, _pr_str = types.Nil, types.List, types.HashMap, printer._pr_str
local M = {}
-- string func... | mpl-2.0 |
galnegus/Glaskross | lib/sperm/loveframes/objects/internal/columnlist/columnlistarea.lua | 3 | 9515 | --[[------------------------------------------------
-- Love Frames - A GUI library for LOVE --
-- Copyright (c) 2013 Kenny Shields --
--]]------------------------------------------------
-- columnlistarea class
local newobject = loveframes.NewObject("columnlistarea", "loveframes_object_columnlistarea", true)
--[[-... | mit |
dangersos/fffff | 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 |
mrbangi/t_e_l_e_b_o_t | 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 |
piller187/LeadwerksComponentSystem | LcsSample/scripts/Objects/Physics/Platform.lua | 1 | 2698 | Script.enabled = true --bool "Enabled"
Script.speed = 10 --float "Speed"
Script.target = "" --entity "Target waypoint"
Script.originPosition = nil
Script.targetPosition = nil
Script.currentPosition = nil
Script.currentRotation = nil
Script.moving = nil
Script.oldMass = nil
function Script:Start()
self.or... | gpl-3.0 |
alarouche/premake-core | premake5.lua | 6 | 4133 | ---
-- Premake 5.x build configuration script
-- Use this script to configure the project with Premake5.
---
--
-- Remember my location; I will need it to locate sub-scripts later.
--
local corePath = _SCRIPT_DIR
--
-- Disable deprecation warnings for myself, so that older development
-- versions of Premake can be... | bsd-3-clause |
mixflowtech/logsensor | src/core/memory_posix.lua | 1 | 4874 | -- Use of this source code is governed by the Apache 2.0 license; see COPYING.
-- Call when running in none-root/none-hugepage mode, or runing on windows
module(...,package.seeall)
-- For more information about huge pages checkout:
-- * HugeTLB - Large Page Support in the Linux kernel
-- http://linuxgazette.net/155/... | apache-2.0 |
ArchShaman/Zero-K | effects/goo.lua | 17 | 13999 | -- queen_trail
-- queen_trail_fire
-- large_green_goo
-- green_goo
-- small_green_goo
-- spire_trail
-- blobber_goo
-- lobber_goo
-- small_red_goo
-- red_goo
return {
["queen_trail"] = {
splashes = {
air = true,
class = [[CSimpleParticleSystem]],
count =... | gpl-2.0 |
galnegus/Glaskross | lib/sperm/loveframes/third-party/middleclass.lua | 6 | 5995 | local middleclass = {
_VERSION = 'middleclass v3.0.0',
_DESCRIPTION = 'Object Orientation for Lua',
_LICENSE = [[
MIT LICENSE
Copyright (c) 2011 Enrique García Cota
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation ... | mit |
ArchShaman/Zero-K | LuaUI/cawidgets.lua | 2 | 61871 | -- $Id: cawidgets.lua 4261 2009-03-31 16:34:36Z licho $
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
--
-- file: widgets.lua
-- brief: the widget manager, a call-in router
-- author: Dave Rodger... | gpl-2.0 |
ArchShaman/Zero-K | effects/annabelle.lua | 25 | 4477 | -- annabelle
-- annabelle_smokejet
return {
["annabelle"] = {
boom = {
air = true,
class = [[CExpGenSpawner]],
count = 1,
ground = true,
water = true,
properties = {
delay = [[0 i1]],
... | gpl-2.0 |
Siapran/discord-biobot | deps/pathjoin.lua | 20 | 2808 | --[[lit-meta
name = "creationix/pathjoin"
description = "The path utilities that used to be part of luvi"
version = "2.0.0"
tags = {"path"}
license = "MIT"
author = { name = "Tim Caswell" }
]]
local getPrefix, splitPath, joinParts
local isWindows
if _G.jit then
isWindows = _G.jit.os == "Windows"
else
... | mit |
abasshacker/abas0 | plugins/owners.lua | 284 | 12473 |
local function lock_group_namemod(msg, data, target)
local group_name_set = data[tostring(target)]['settings']['set_name']
local group_name_lock = data[tostring(target)]['settings']['lock_name']
if group_name_lock == 'yes' then
return 'Group name is already locked'
else
data[tostring(target)]['setting... | gpl-2.0 |
MarchM4/Milkyway-home-server-expansion | nbody/tests/persistence.lua | 19 | 5650 | -- Internal persistence library
--[[ Provides ]]
-- persistence.store(path, ...): Stores arbitrary items to the file at the given path
-- persistence.load(path): Loads files that were previously stored with store and returns them
--[[ Limitations ]]
-- Does not export userdata, threads or most function values
-- Func... | gpl-3.0 |
thisverygoodhhhh/orange | orange/utils/stringy.lua | 4 | 1446 | local string_gsub = string.gsub
local string_find = string.find
local table_insert = table.insert
local _M = {}
function _M.trim_all(str)
if not str or str == "" then return "" end
local result = string_gsub(str, " ", "")
return result
end
function _M.strip(str)
if not str or str == "" then return ""... | mit |
jchuang1977/my_luci | libs/nixio/axTLS/www/lua/download.lua | 180 | 1550 | #!/usr/local/bin/lua
require"luasocket"
function receive (connection)
connection:settimeout(0)
local s, status = connection:receive (2^10)
if status == "timeout" then
coroutine.yield (connection)
end
return s, status
end
function download (host, file, outfile)
--local f = assert (io.open (outfile, "w"))
loc... | apache-2.0 |
amirilk22333322/uzzbot | 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 |
LuckyGameCn/LHCocosGame | cocos2d/tests/lua-tests/src/AccelerometerTest/AccelerometerTest.lua | 15 | 2344 | local function AccelerometerMainLayer()
local function title()
return "AccelerometerTest"
end
local layer = cc.Layer:create()
local function onEnter()
layer:setAccelerometerEnabled(true)
local label = cc.Label:createWithTTF(title(), "fonts/arial.ttf", 32)
layer:addChild(l... | mit |
ArchShaman/Zero-K | LuaUI/Widgets/chili_new/core.lua | 9 | 1595 | local includes = {
--"headers/autolocalizer.lua",
"headers/util.lua",
"headers/links.lua",
"headers/backwardcompability.lua",
"headers/unicode.lua",
"handlers/debughandler.lua",
"handlers/taskhandler.lua",
"handlers/skinhandler.lua",
"handlers/themehandler.lua",
"handlers/fonthandler.lua",
"handl... | gpl-2.0 |
nekulin/sipml5 | asterisk/etc/extensions.lua | 317 | 5827 |
CONSOLE = "Console/dsp" -- Console interface for demo
--CONSOLE = "DAHDI/1"
--CONSOLE = "Phone/phone0"
IAXINFO = "guest" -- IAXtel username/password
--IAXINFO = "myuser:mypass"
TRUNK = "DAHDI/G2"
TRUNKMSD = 1
-- TRUNK = "IAX2/user:pass@provider"
--
-- Extensions are expected to be defined in a global table ... | bsd-3-clause |
Phanx/oUF | elements/classicons.lua | 3 | 7420 | --[[ Element: Class Icons
Toggles the visibility of icons depending on the player's class and
specialization.
Widget
ClassIcons - An array consisting of as many UI Textures as the theoretical
maximum return of `UnitPowerMax`.
Notes
All - Combo Points
Mage - Arcane Charges
Monk - Chi Orbs
Paladi... | mit |
jchuang1977/my_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 |
golem1381/golem_b | 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 |
scholzd/MoonGen | examples/lacp.lua | 5 | 3210 | local mg = require "moongen"
local memory = require "memory"
local device = require "device"
local ts = require "timestamping"
local stats = require "stats"
local hist = require "histogram"
local lacp = require "proto.lacp"
local PKT_SIZE = 60
local ETH_DST = "90:E2:BA:C0:EE:8C"
local SRC_IP ... | mit |
LuckyGameCn/LHCocosGame | cocos2d/tests/lua-tests/src/TouchesTest/Ball.lua | 5 | 2841 |
require "extern"
require "src/VisibleRect"
require "src/TouchesTest/Paddle"
Ball = class("Ball", function(texture)
return cc.Sprite:createWithTexture(texture)
end)
Ball.__index = Ball
Ball.m_velocity = cc.p(0,0)
local M_PI = 3.1415926
function Ball:radius()
local size = self:getTexture():getContentSize()... | mit |
focusworld/big | plugins/chats.lua | 1 | 1701 | local function run(msg)
if msg.text == "hi" then
return "Hello bb"
end
if msg.text == "Hi" then
return "Hello honey"
end
if msg.text == "Hello" then
return "Hi bb"
end
if msg.text == "hello" then
return "Hi honey"
end
if msg.text == "Salam" then
return "Salam aleykom"
end
if msg.text == "salam" then
return "va al... | gpl-2.0 |
mixflowtech/logsensor | lib/ljsyscall/examples/event.lua | 23 | 1356 | -- example of event ioctls
local S = require "syscall"
local EV = S.c.EV
local MSC = S.c.MSC
local KEY = S.c.KEY
local kl = {}
for k, v in pairs(KEY) do kl[v] = k end
local oldassert = assert
local function assert(cond, s)
collectgarbage("collect") -- force gc, to test for bugs
return oldassert(cond, tostring(s... | apache-2.0 |
ArchShaman/Zero-K | LuaRules/Gadgets/bank.lua | 5 | 3213 | function gadget:GetInfo()
return {
name = "Bank",
desc = "Handle Debts.",
author = "CarRepairer",
date = "2010-07-24",
license = "GNU GPL, v2 or later",
layer = 1,
enabled = false,
}
end
local echo = Spring.Echo
-------------------------------------------... | gpl-2.0 |
ArchShaman/Zero-K | units/tankassault.lua | 5 | 3337 | unitDef = {
unitname = [[tankassault]],
name = [[Minotaur]],
description = [[Assault Tank]],
acceleration = 0.0237,
brakeRate = 0.04786,
buildCostMetal = 850,
builder = false,
buildPic = [[tankassault.png]],
canGuard ... | gpl-2.0 |
ArchShaman/Zero-K | effects/nota_otaplas.lua | 50 | 48727 | -- miniotaplas_fireball11
-- otaplas_fireball3
-- otaplas_fireball16
-- otaplas_fireball14
-- ota_plas
-- miniotaplas_fireball17
-- otaplas_fireball18
-- otaplas_fireball1
-- otaplas_fireball11
-- miniotaplas_fireball13
-- otaplas_fireball10
-- miniotaplas_fireball16
-- otaplas_fireball13
-- miniotaplas_fireball2
-- ot... | gpl-2.0 |
bbohling/keys | Build/VSCOKeys.lrplugin/halfway_server/socket/tp.lua | 146 | 3608 | -----------------------------------------------------------------------------
-- Unified SMTP/FTP subsystem
-- LuaSocket toolkit.
-- Author: Diego Nehab
-- RCS ID: $Id: tp.lua,v 1.22 2006/03/14 09:04:15 diego Exp $
-----------------------------------------------------------------------------
--------------------------... | gpl-2.0 |
sinavafa/ERRORTG | 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 |
chuckbutler/telegram-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 |
Corvass/BorrowedTime | Libs/LibMagicUtil-1.0/Locales/Locale-ruRU.lua | 1 | 1952 | local L = LibStub("AceLocale-3.0"):NewLocale("LibMagicUtil-1.0", "ruRU")
if not L then return end
-- To help localize LibMagicUtil-1.0 please enter phrase translations on the
-- following URL:
-- http://www.wowace.com/projects/libmagicutil-10/localization/
-- This file should not be edited manually!
L["Background Col... | gpl-3.0 |
Corvass/BorrowedTime | Locales/Babelfish.lua | 1 | 3054 | #!/usr/local/bin/lua
-- CONFIG --
--[[
The name of the AceLocale-3.0 Category, as being used in :NewLocale and :GetLocale
]]
local localeName = "BorrowedTime"
--[[
Prefix to all files if this script is run from a subdir, for example
]]
local filePrefix = "../"
--[[
List of all files to parse
]]
local files = {
... | gpl-3.0 |
Siapran/discord-biobot | deps/discordia/utils/Mutex.lua | 1 | 1266 | local timer = require('timer')
local Deque = require('./Deque')
local setTimeout = timer.setTimeout
local running, yield, resume = coroutine.running, coroutine.yield, coroutine.resume
local Mutex, property, method = class('Mutex', Deque)
Mutex.__description = "Mutual exclusion class for coroutines."
functio... | mit |
lowne/hammerspoon | extensions/notify/init.lua | 3 | 14199 |
--- === hs.notify ===
---
--- This module allows you to create on screen notifications in the User Notification Center located at the right of the users screen.
---
--- Notifications can be sent immediately or scheduled for delivery at a later time, even if that scheduled time occurs when Hammerspoon is not currently ... | mit |
scholzd/MoonGen | examples/l2-load-latency.lua | 4 | 2141 | local mg = require "moongen"
local memory = require "memory"
local device = require "device"
local ts = require "timestamping"
local stats = require "stats"
local hist = require "histogram"
local PKT_SIZE = 60
local ETH_DST = "11:12:13:14:15:16"
local function getRstFile(...)
local args = { ... }
for i, ... | mit |
golem1381/golem_b | plugins/stats.lua | 866 | 4001 | do
-- Returns a table with `name` and `msgs`
local function get_msgs_user_chat(user_id, chat_id)
local user_info = {}
local uhash = 'user:'..user_id
local user = redis:hgetall(uhash)
local um_hash = 'msgs:'..user_id..':'..chat_id
user_info.msgs = tonumber(redis:get(um_hash) or 0)
user_info.name = user_prin... | gpl-2.0 |
phi-psi/luci | modules/rpc/luasrc/controller/rpc.lua | 70 | 4443 | --[[
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 |
piller187/LeadwerksComponentSystem | LcsSample/scripts/GUI/ListBox.lua | 1 | 10049 | Script.hovered=false
Script.offset=0
Script.itemheight=20
Script.sliderwidth=19
Script.sliderrange={}
Script.sliderincrements = Script.itemheight
function Script:UpdateSlider()
local gui = self.widget:GetGUI()
local sz = self.widget:GetSize(true)
local scale = gui:GetScale()
if self.itemheight*scale * s... | gpl-3.0 |
chuckbutler/telegram-bot | plugins/plugins.lua | 4 | 4731 | do
-- Retruns the key (index) in the config.enabled_plugins table
local function plugin_enabled( name )
for k,v in pairs(_config.enabled_plugins) do
if name == v then
return k
end
end
-- If not found
return false
end
-- Returns true if file exists in plugins folder
local function plugin_exists( ... | gpl-2.0 |
d9magai/freeciv | dependencies/tolua-5.2/src/bin/lua/declaration.lua | 13 | 12335 | -- tolua: declaration class
-- Written by Waldemar Celes
-- TeCGraf/PUC-Rio
-- Jul 1998
-- $Id: declaration.lua,v 1.5 2011/01/13 13:43:46 fabraham Exp $
-- This code is free software; you can redistribute it and/or modify it.
-- The software provided hereunder is on an "as is" basis, and
-- the author has no obligatio... | gpl-2.0 |
LinusU/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 |
mrbangi/t_e_l_e_b_o_t | 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 |
zhepama/rosa | src/utils.lua | 1 | 3254 |
--Robust pretty-printing dir() function
function dir(obj, pretty_mode, expand_tables, _indent_level)
pretty_mode = pretty_mode or false
expand_tables = expand_tables or false
--Handle indentation levels
local indent_level = _indent_level or 1
local indent = ""
local prev_indent = ""
... | mit |
jchuang1977/my_luci | applications/luci-qos/luasrc/model/cbi/qos/qos.lua | 41 | 2689 | --[[
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$
]]--
loc... | apache-2.0 |
ArchShaman/Zero-K | LuaRules/Gadgets/unit_impulsefloat_toggle.lua | 4 | 17247 | if (not gadgetHandler:IsSyncedCode()) then
return
end
-------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------
function gadget:GetInfo()
return {
name = "Impulse Float Toggle",
desc ... | gpl-2.0 |
ArchShaman/Zero-K | scripts/vehcapture.lua | 12 | 6694 | include "constants.lua"
local spGetUnitRulesParam = Spring.GetUnitRulesParam
local base, front, bigwheel, rear = piece('base', 'front', 'bigwheel', 'rear')
local turret, arm_1, arm_2, arm_3, dish, panel_a1, panel_b1, panel_a2, panel_b2, flare = piece('turret', 'arm_1', 'arm_2', 'arm_3', 'dish', 'panel_a1', 'panel_b1... | gpl-2.0 |
phi-psi/luci | modules/admin-full/luasrc/model/cbi/admin_system/leds.lua | 83 | 3272 | --[[
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$
]]--
m = ... | apache-2.0 |
KurdyMalloy/packages | net/luci-app-clamav/files/model/cbi/clamav-cbi.lua | 100 | 6776 | --[[
LuCI ClamAV module
Copyright (C) 2015, Itus Networks, Inc.
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
Author: Marko Ratkaj <marko.ratkaj@sar... | gpl-2.0 |
Iamgoofball/tcf-gmod | vietnam/entities/weapons/tfa_m16/shared.lua | 1 | 4052 | -- Variables that are used on both client and server
SWEP.Gun = ("tfa_10mm_pistol") -- must be the name of your swep but NO CAPITALS!
if (GetConVar(SWEP.Gun.."_allowed")) != nil then
if not (GetConVar(SWEP.Gun.."_allowed"):GetBool()) then SWEP.Base = "tfa_blacklisted" SWEP.PrintName = SWEP.Gun return end
end
SWEP.Cate... | agpl-3.0 |
SawyerHood/mal | lua/step2_eval.lua | 12 | 2127 | #!/usr/bin/env lua
local table = require('table')
local readline = require('readline')
local utils = require('utils')
local types = require('types')
local reader = require('reader')
local printer = require('printer')
local List, Vector, HashMap = types.List, types.Vector, types.HashMap
-- read
function READ(str)
... | mpl-2.0 |
LinusU/nn | Threshold.lua | 42 | 1158 | local Threshold, parent = torch.class('nn.Threshold','nn.Module')
function Threshold:__init(th,v,ip)
parent.__init(self)
self.threshold = th or 1e-6
self.val = v or 0
if (th and type(th) ~= 'number') or (v and type(v) ~= 'number') then
error('nn.Threshold(threshold, value)')
end
-- default for ... | bsd-3-clause |
JesseEmond/original-dotfiles-repo-name | awesome/rc.lua | 1 | 28074 | -- Standard awesome library
local gears = require("gears")
local awful = require("awful")
awful.rules = require("awful.rules")
require("awful.autofocus")
-- Widget and layout library
local wibox = require("wibox")
local vicious = require("vicious")
local blingbling = require("blingbling")
-- Theme handling library
loca... | mit |
mrbangi/t_e_l_e_b_o_t | plugins/minecraft.lua | 624 | 2605 | local usage = {
"!mine [ip]: Searches Minecraft server on specified ip and sends info. Default port: 25565",
"!mine [ip] [port]: Searches Minecraft server on specified ip and port and sends info.",
}
local ltn12 = require "ltn12"
local function mineSearch(ip, port, receiver) --25565
local responseText = ""
l... | gpl-2.0 |
Jobq/vlc-mdc | share/lua/playlist/canalplus.lua | 113 | 3501 | --[[
$Id: $
Copyright (c) 2007 the VideoLAN team
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 distr... | gpl-2.0 |
phi-psi/luci | protocols/ipv6/luasrc/model/cbi/admin_network/proto_6rd.lua | 53 | 2242 | --[[
LuCI - Lua Configuration Interface
Copyright 2011-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
http://www.apache.org/licenses/LICENSE-2.0
]]--
loc... | apache-2.0 |
jchuang1977/my_luci | applications/luci-pbx/luasrc/model/cbi/pbx-advanced.lua | 99 | 14473 | --[[
Copyright 2011 Iordan Iordanov <iiordanov (AT) gmail.com>
This file is part of luci-pbx.
luci-pbx is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
... | apache-2.0 |
brahmi2/prosody-modules | mod_muc_log/mod_muc_log.lua | 32 | 4843 | -- Copyright (C) 2009 Thilo Cestonaro
-- Copyright (C) 2009 Waqas Hussain
-- Copyright (C) 2009-2013 Matthew Wild
-- Copyright (C) 2013 Kim Alvefur
-- Copyright (C) 2013 Marco Cirillo
local hosts = prosody.hosts;
local tostring = tostring;
local split_jid = require "util.jid".split;
local datamanager = require"core.st... | mit |
scholzd/MoonGen | rfc2544/benchmarks/backtoback.lua | 9 | 13123 | package.path = package.path .. "rfc2544/?.lua"
local standalone = false
if master == nil then
standalone = true
master = "dummy"
end
local dpdk = require "dpdk"
local memory = require "memory"
local device = require "device"
local ts = require "timestamping"
local filter ... | mit |
ld-test/concurrentlua | src/concurrent/link.lua | 2 | 2700 | --Submodule for process linking.
module('concurrent._link', package.seeall)
links = {} -- Active links between processes.
concurrent._option.options.trapexit = false -- Option to trap exit signals.
-- The calling process is linked with the specified process.
function link(dest)
local t =... | mit |
erwincoumans/premake-dev-iphone-xcode4 | tests/premake4.lua | 1 | 5405 | --
-- tests/premake4.lua
-- Automated test suite for Premake 4.x
-- Copyright (c) 2008-2012 Jason Perkins and the Premake project
--
dofile("testfx.lua")
--
-- Some helper functions
--
test.createsolution = function()
local sln = solution "MySolution"
configurations { "Debug", "Release" }
local prj = projec... | bsd-3-clause |
ArchShaman/Zero-K | LuaUI/Widgets/chili_new/controls/window.lua | 9 | 1852 | --- Window module
--- Window fields.
-- Inherits from Control.
-- @see control.Control
-- @table Window
Window = Control:Inherit{
classname = 'window',
resizable = true,
draggable = true,
minWidth = 50,
minHeight = 50,
defaultWidth = 400,
defaultHeight = 300,
}
local this = Window
local inherited = t... | gpl-2.0 |
erwincoumans/premake-dev-iphone-xcode4 | src/base/api.lua | 1 | 18992 | --
-- api.lua
-- Implementation of the solution, project, and configuration APIs.
-- Copyright (c) 2002-2012 Jason Perkins and the Premake project
--
--
-- Here I define all of the getter/setter functions as metadata. The actual
-- functions are built programmatically below.
--
premake.fields =
{
architecture =... | bsd-3-clause |
qyli/test | lualib/snax.lua | 9 | 3269 | local skynet = require "skynet"
local snax_interface = require "snax.interface"
local snax = {}
local typeclass = {}
local G = { require = function() end }
skynet.register_protocol {
name = "snax",
id = skynet.PTYPE_SNAX,
pack = skynet.pack,
unpack = skynet.unpack,
}
function snax.interface(name)
if typeclass... | mit |
galnegus/Glaskross | lib/sperm/loveframes/objects/columnlist.lua | 3 | 17109 | --[[------------------------------------------------
-- Love Frames - A GUI library for LOVE --
-- Copyright (c) 2013 Kenny Shields --
--]]------------------------------------------------
-- columnlist object
local newobject = loveframes.NewObject("columnlist", "loveframes_object_columnlist", true)
--[[------------... | mit |
chundi/uwsgi | tests/websockets_echo.lua | 27 | 1867 | #!./uwsgi --https :8443,foobar.crt,foobar.key --http-modifier1 6 --http-raw-body --threads 100 --lua tests/websockets_echo.lua
function app(env)
local function html()
coroutine.yield(string.format([[
<html>
<head>
<script language="Javascript">
var s = new WebSocket("%s://%s... | gpl-2.0 |
DigitalCrypto/scite-mql | additions/MoveLines.lua | 3 | 4538 | --[[--------------------------------------------------
MoveLines.lua
Authors: codewarlock1101
Version: 1.1
------------------------------------------------------
Description:
Ïåðåìåùåíèå âûäåëåííûõ ñòðîê (èëè 1 ñòðîêè) ââåðõ, âíèç, âïðàâî, âëåâî
ïåðåìåùåíèå âûäåëåííîãî ñòðèíãà ïî ñòðîêå âïðàâî è âëåâî
---------------... | isc |
DBReinitialized/PigBot | Source/deps/discordia/containers/snowflakes/channels/GuildTextChannel.lua | 1 | 3970 | local Message = require('../Message')
local GuildChannel = require('./GuildChannel')
local TextChannel = require('./TextChannel')
local Webhook = require('../Webhook')
local clamp = math.clamp
local insert = table.insert
local format = string.format
local GuildTextChannel, property, method = class('GuildTextChannel',... | mit |
brahmi2/prosody-modules | mod_roster_command/mod_roster_command.lua | 31 | 5484 | -----------------------------------------------------------
-- mod_roster_command: Manage rosters through prosodyctl
-- version 0.02
-----------------------------------------------------------
-- Copyright (C) 2011 Matthew Wild
-- Copyright (C) 2011 Adam Nielsen
--
-- This project is MIT/X11 licensed. Please see the
--... | mit |
ArchShaman/Zero-K | LuaRules/Gadgets/lups_flame_jitter.lua | 17 | 6545 | -- $Id: lups_flame_jitter.lua 3643 2009-01-03 03:00:52Z jk $
-------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------
function gadget:GetInfo()
return {
name = "Lups Flamethrower Jitter",
d... | gpl-2.0 |
ArchShaman/Zero-K | units/vehcon.lua | 5 | 2197 | unitDef = {
unitname = [[vehcon]],
name = [[Mason]],
description = [[Construction Rover, Builds at 5 m/s]],
acceleration = 0.066,
brakeRate = 1.5,
buildCostMetal = 140,
buildDistance = 180,
builder = true,
... | gpl-2.0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.