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 |
|---|---|---|---|---|---|
JulianVolodia/awesome | spec/awful/util_spec.lua | 12 | 2693 | ---------------------------------------------------------------------------
-- @author Uli Schlachter
-- @copyright 2015 Uli Schlachter
---------------------------------------------------------------------------
local util = require("awful.util")
local say = require("say")
describe("awful.util", function()
it("ta... | gpl-2.0 |
teahouse/FWServer | script/script.lua | 1 | 2723 | require "include"
local util = require "util.function"
local script = {}
function script.serverStart(watchdoghandler, sendfunc, closeFunc) --起服
assert(watchdoghandler, "watchdoghandler must not nil!")
assert(sendfunc, "sendfunc must not nil!")
assert(closeFunc, "closeAllFunc must not nil!")
g_protoco... | mit |
sjznxd/lc-20130127 | applications/luci-diag-devinfo/luasrc/model/cbi/luci_diag/netdiscover_devinfo_config_mini.lua | 80 | 1150 | --[[
LuCI - Lua Configuration Interface
(c) 2009 Daniel Dickinson
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
$Id$
]]--
require("luci.controller.l... | apache-2.0 |
JulianVolodia/awesome | spec/wibox/test_utils.lua | 2 | 3233 | ---------------------------------------------------------------------------
-- @author Uli Schlachter
-- @copyright 2014 Uli Schlachter
---------------------------------------------------------------------------
local object = require("gears.object")
local cache = require("gears.cache")
local matrix_equals = require("... | gpl-2.0 |
hnyman/packages | utils/prometheus-node-exporter-lua/files/usr/lib/lua/prometheus-collectors/netclass.lua | 21 | 3068 | local ubus = require "ubus"
-- reference/further reading:
-- - node_exporter netclass_linux (upstream metrics): https://github.com/prometheus/node_exporter/blob/master/collector/netclass_linux.go
-- - relevant sysfs files: https://github.com/prometheus/procfs/blob/5f46783c017ef6a934fc8cfa6d1a2206db21401b/sysfs/net_cla... | gpl-2.0 |
lordporya1/lord | plugins/plugins.lua | 23 | 4992 | do
-- Returns 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 |
FFXIOrgins/FFXIOrgins | scripts/zones/Norg/npcs/Aeka.lua | 18 | 3050 | -----------------------------------
-- Area: Norg
-- NPC: Aeka
-- Involved in Quest: Forge Your Destiny
-- @zone 252
-- @pos 4 0 -4
-----------------------------------
package.loaded["scripts/zones/Norg/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/settings");
require("script... | gpl-3.0 |
msburgess3200/PERP | gamemodes/perp/gamemode/items/drug_beer_box_full.lua | 1 | 1288 |
local ITEM = {};
ITEM.ID = 65;
ITEM.Reference = "drug_beer_box_full";
ITEM.Name = "Box o' Beer (6 Beers)";
ITEM.Description = "Allows your guests to grab beers at their leisure.\n\nLeft click to spawn as prop.";
ITEM.Weight = 10;
ITEM.Cost = 200;
ITEM.MaxStack = 10;
ITEM.Invento... | mit |
sjznxd/luci-0.11-aa | libs/lucid-http/luasrc/lucid/http/LuciWebPublisher.lua | 52 | 1651 | --[[
LuCId HTTP-Slave
(c) 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$
]]--
local ipairs, pcall, ... | apache-2.0 |
unknownssassss/sudo_meti | plugins/banhammer.lua | 5 | 36375 | local function pre_process(msg)
if msg.to.type ~= 'pv' then
chat = msg.to.id
user = msg.from.id
local function check_newmember(arg, data)
test = load_data(_config.moderation.data)
lock_bots = test[arg.chat_id]['settings']['lock_bots']
local hash = "gp_lang:"..arg.chat_id
local lang = redis:get(hash)
if data... | gpl-3.0 |
hb9cwp/snabbswitch | src/lib/index_set.lua | 15 | 2518 | --- index set object: keeps a set of indexed values
local NDX_mt = {}
NDX_mt.__index = NDX_mt
-- trivial constructor
function NDX_mt:new (max, name)
return setmetatable({
__nxt = 0,
__max = max,
__name = name,
}, self)
end
-- search a specific index
function NDX_mt:search(ndx)
if type(ndx)... | apache-2.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Upper_Jeuno/npcs/Champalpieu.lua | 36 | 1244 | -----------------------------------
-- Area: Upper Jeuno
-- NPC: Champalpieu
-- Standard Merchant NPC
-----------------------------------
require("scripts/globals/shop");
package.loaded["scripts/zones/Upper_Jeuno/TextIDs"] = nil;
require("scripts/zones/Upper_Jeuno/TextIDs");
--------------------------------... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Windurst_Woods/npcs/Retto-Marutto.lua | 19 | 1168 | -----------------------------------
-- Area: Windurst Woods
-- NPC: Retto-Marutto
-- Guild Merchant NPC: Bonecrafting Guild
-- @pos -6.142 -6.55 -132.639 241
-----------------------------------
package.loaded["scripts/zones/Windurst_Woods/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/s... | gpl-3.0 |
arman022/spamer- | plugins/plugins.lua | 6 | 6068 | do
-- Returns 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 |
jonm/lxUnit | src/test/lxUnit/framework/test_test_failure.lua | 1 | 1688 | require("assert")
require("test_failure")
tests = {}
function tests.failedTestReturnsTest()
o = {}
tf = TestFailure:new(o, nil)
Assert.assertEquals(o, tf:failedTest())
end
function tests.thrownErrorReturnsError()
o = {}
tf = TestFailure:new(nil, o)
Assert.assertEquals(o, tf:thrownError())
end
func... | apache-2.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Aht_Urhgan_Whitegate/npcs/Ironbound_Gate.lua | 17 | 1497 | -----------------------------------
-- Area: Aht Urhgan Whitegate
-- NPC: Ironbound Gate
-----------------------------------
package.loaded["scripts/zones/Aht_Urhgan_Whitegate/TextIDs"] = nil;
-----------------------------------
require("scripts/zones/Aht_Urhgan_Whitegate/TextIDs");
------------------------... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Upper_Jeuno/npcs/Finnela.lua | 38 | 1027 | -----------------------------------
-- Area: Upper Jeuno
-- NPC: Finnela
-- Type: Standard NPC
-- @zone: 244
-- @pos -51.880 -1 106.486
--
-- Auto-Script: Requires Verification (Verfied by Brawndo)
-----------------------------------
package.loaded["scripts/zones/Upper_Jeuno/TextIDs"] = nil;
----------------------... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Dynamis-Xarcabard/mobs/Animated_Gun.lua | 17 | 1468 | -----------------------------------
-- Area: Dynamis Xarcabard
-- NPC: Animated Gun
-----------------------------------
require("scripts/globals/status");
require("scripts/zones/Dynamis-Xarcabard/TextIDs");
-----------------------------------
-- onMobEngaged
-----------------------------------
function ... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Chateau_dOraguille/npcs/Curilla.lua | 15 | 5129 | -----------------------------------
-- Area: Chateau d'Oraguille
-- NPC: Curilla
-- Starts and Finishes Quest: The General's Secret, Enveloped in Darkness, Peace for the Spirit, Lure of the Wildcat (San d'Oria)
-- @pos 27 0.1 0.1 233
-----------------------------------
package.loaded["scripts/zones/Chateau_dOrag... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Cloister_of_Tremors/Zone.lua | 32 | 1667 | -----------------------------------
--
-- Zone: Cloister_of_Tremors (209)
--
-----------------------------------
package.loaded["scripts/zones/Cloister_of_Tremors/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/settings");
require("scripts/zones/Cloister_of_Tremors/TextIDs");
... | gpl-3.0 |
wilbefast/you-ordered-a-pizza | src/assets/lson/endings.lua | 1 | 1701 | return {
{
name = "alone",
trigger = 50,
text = "FOREVER ALONE !",
sound = "FinRien",
stickerImg = "stickers_alone",
stickerX = 740,
stickerY = 485
},
{
name = "robot",
trigger = 50,
text = "ROBOT INVASION !",
sound = "FinRobot",
stickerImg = "stickers_robot",
stickerX = 600,
... | mit |
FFXIOrgins/FFXIOrgins | scripts/zones/Temenos/bcnms/Central_Temenos_Basement.lua | 8 | 1136 | -----------------------------------
-- Area: Temenos
-- Name:
-----------------------------------
-- After registering the BCNM via bcnmRegister(bcnmid)
function OnBcnmRegister(player,instance)
SetServerVariable("[C_Temenos_Base]UniqueID",GenerateLimbusKey());
HideArmouryCrates(GetInstanceRegion(1301),TEMENOS); ... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/South_Gustaberg/npcs/qm1.lua | 19 | 1347 | -----------------------------------
-- Area: South Gustaberg
-- NPC: qm1 (???)
-- Involved in Quest: The Cold Light of Day
-- @pos 744 0 -671 107
-----------------------------------
package.loaded["scripts/zones/South_Gustaberg/TextIDs"] = nil;
-----------------------------------
require("scripts/zones/South_Gustabe... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Dynamis-Buburimu/mobs/Serjeant_Tombstone.lua | 17 | 2476 | -----------------------------------
-- Area: Dynamis Buburimu
-- NPC: Serjeant_Tombstone
-----------------------------------
package.loaded["scripts/zones/Dynamis-Buburimu/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/dynamis");
require("scripts/zones/Dynamis-Buburimu/TextIDs... | gpl-3.0 |
subzrk/BadRotations | Rotations/Death Knight/Unholy/THUnholy.lua | 1 | 56038 | local rotationName = "THUnholy" -- Change to name of profile listed in options drop down
---------------
--- Toggles ---
---------------
local function createToggles() -- Define custom toggles
-- Rotation Button
RotationModes = {
[1] = { mode = "Auto", value = 1 , overlay = "Automatic Rotation", tip = "Swa... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Temenos/mobs/Water_Elemental.lua | 17 | 1709 | -----------------------------------
-- Area: Temenos E T
-- NPC: Water_Elemental
-----------------------------------
package.loaded["scripts/zones/Temenos/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/limbus");
require("scripts/zones/Temenos/TextIDs");
----------------------... | gpl-3.0 |
pax2you4now/wesnoth | data/ai/micro_ais/cas/ca_big_animals.lua | 25 | 4308 | local H = wesnoth.require "lua/helper.lua"
local AH = wesnoth.require "ai/lua/ai_helper.lua"
local LS = wesnoth.require "lua/location_set.lua"
local MAIUV = wesnoth.require "ai/micro_ais/micro_ai_unit_variables.lua"
local function get_big_animals(cfg)
local big_animals = AH.get_units_with_moves {
side = we... | gpl-2.0 |
sjznxd/lc-20130127 | applications/luci-asterisk/luasrc/model/cbi/asterisk/voicemail.lua | 80 | 1684 | --[[
LuCI - Lua Configuration Interface
Copyright 2009 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 |
FFXIOrgins/FFXIOrgins | scripts/globals/items/wild_cookie.lua | 35 | 1337 | -----------------------------------------
-- ID: 4577
-- Item: wild_cookie
-- Food Effect: 5Min, All Races
-----------------------------------------
-- MP Recovered While Healing 3
-- Aquan Killer 5
-- Resist Sleep 5
-----------------------------------------
require("scripts/globals/status");
------------... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Windurst_Waters/npcs/Pechiru-Mashiru.lua | 36 | 1776 | -----------------------------------
-- Area: Windurst Waters
-- NPC: Pechiru-Mashiru
-- Involved in Quests: Hat in Hand
-- Working 100%
-- @zone = 238
-- @pos = 162 -2 159
-----------------------------------
package.loaded["scripts/zones/Windurst_Walls/TextIDs"] = nil;
-----------------------------------
... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/globals/items/dish_of_spaghetti_melanzane_+1.lua | 35 | 1389 | -----------------------------------------
-- ID: 5214
-- Item: dish_of_spaghetti_melanzane_+1
-- Food Effect: 1Hr, All Races
-----------------------------------------
-- HP % 25 (cap 105)
-- Vitality 2
-- Store TP 4
-----------------------------------------
require("scripts/globals/status");
-------------... | gpl-3.0 |
JulianVolodia/awesome | lib/wibox/layout/flex.lua | 2 | 4614 | ---------------------------------------------------------------------------
-- @author Uli Schlachter
-- @copyright 2010 Uli Schlachter
-- @release @AWESOME_VERSION@
-- @classmod wibox.layout.flex
---------------------------------------------------------------------------
local base = require("wibox.widget.base")
loca... | gpl-2.0 |
peval/Atlas | lib/admin.lua | 28 | 9387 | --[[ $%BEGINLICENSE%$
Copyright (c) 2008, 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 |
maximilianofaccone/puppy-siberian | root/.conky/.scripts_orange/bargraph.lua | 1 | 21875 | --[[ BARGRAPH WIDGET
v2.1 by wlourf (07 Jan. 2011)
this widget draws a bargraph with different effects
http://u-scripts.blogspot.com/2010/07/bargraph-widget.html
To call the script in a conky, use, before TEXT
lua_load /path/to/the/script/bargraph.lua
lua_draw_hook_pre main_rings
and add one line (blank or not)... | gpl-3.0 |
nehz/busted | busted/status.lua | 12 | 1142 | local function get_status(status)
local smap = {
['success'] = 'success',
['pending'] = 'pending',
['failure'] = 'failure',
['error'] = 'error',
['true'] = 'success',
['false'] = 'failure',
['nil'] = 'error',
}
return smap[tostring(status)] or 'error'
end
return function(inital_status... | mit |
TRIEXTEAM/TaylortTG | plugins/feedback.lua | 2 | 2760 |
do
function run(msg, matches)
local fuse = 'پیام پشتیبانی جدید دریافت شد\n\n آیدی ' .. msg.from.id .. '\n\n نام ' .. msg.from.print_name ..'\n\n یوزر آیدی @' .. msg.from.username .. '\n\n پیام :' .. matches[1]
local fuses = '!printf user#id' .. msg.from.id
local text = matches[1]
local chat = "chat#id"... | gpl-2.0 |
xToken/CompMod | lua/CompMod/Balance/Balance_Movement.lua | 1 | 1293 | -- Natural Selection 2 Competitive Mod
-- Source located at - https://github.com/xToken/CompMod
-- lua\CompMod\Balance\Balance_Movement.lua
-- - Dragon
-- SKULK
kSkulkMaxGroundSpeed = 7.75 -- Increased from 7.25
kSkulkMaxWallJumpSpeed = 11 -- Increased from 11
kSkulkWallJumpSpeed = 1.5
-- GORGE
kGorgeMaxGroun... | mit |
hacker44-h44/1104 | plugins/giphy.lua | 633 | 1796 | -- Idea by https://github.com/asdofindia/telegram-bot/
-- See http://api.giphy.com/
do
local BASE_URL = 'http://api.giphy.com/v1'
local API_KEY = 'dc6zaTOxFJmzC' -- public beta key
local function get_image(response)
local images = json:decode(response).data
if #images == 0 then return nil end -- No images
loca... | gpl-2.0 |
sadegh1996/sword_antispam | plugins/echoset.lua | 11 | 2498 | do
local function save_file(name, text)
local file = io.open("./data/echo/"..name, "w") --save file to echo folder !
file:write(text)
file:flush()
file:close()
end
function run(msg, matches)
if matches[1] == "echo>" and is_sudo(msg) then --Sudo only !
local name = matches[2]
loc... | gpl-2.0 |
nehz/busted | spec/core_spec.lua | 1 | 9449 | --ensure environment is set up
assert(type(file) == 'nil')
assert(type(describe) == 'function')
assert(type(context) == 'function')
assert(type(it) == 'function')
assert(type(spec) == 'function')
assert(type(test) == 'function')
assert(type(before_each) == 'function')
assert(type(after_each) == 'function')
assert(type(... | mit |
joshimoo/Algorithm-Implementations | Best_First_Search/Lua/Yonaba/handlers/point_graph_handler.lua | 182 | 2492 | -- A point graph handler
-- This handler is devised for waypoints graphs.
-- Waypoints are locations represented via labelled nodes
-- and are connected with edges having a positive weight.
-- It assumes edges are symmetric, that is if an edge exists
-- between a and b, weight(a -> b) == weight(b -> a)
local PATH = ... | mit |
joshimoo/Algorithm-Implementations | Depth_First_Search/Lua/Yonaba/handlers/point_graph_handler.lua | 182 | 2492 | -- A point graph handler
-- This handler is devised for waypoints graphs.
-- Waypoints are locations represented via labelled nodes
-- and are connected with edges having a positive weight.
-- It assumes edges are symmetric, that is if an edge exists
-- between a and b, weight(a -> b) == weight(b -> a)
local PATH = ... | mit |
joshimoo/Algorithm-Implementations | Breadth_First_Search/Lua/Yonaba/handlers/point_graph_handler.lua | 182 | 2492 | -- A point graph handler
-- This handler is devised for waypoints graphs.
-- Waypoints are locations represented via labelled nodes
-- and are connected with edges having a positive weight.
-- It assumes edges are symmetric, that is if an edge exists
-- between a and b, weight(a -> b) == weight(b -> a)
local PATH = ... | mit |
FFXIOrgins/FFXIOrgins | scripts/zones/Al_Zahbi/npcs/Dabigo.lua | 38 | 1030 | -----------------------------------
-- Area: Al Zahbi
-- NPC: Dabigo
-- Type: Delivery Box Manager
-- @zone: 48
-- @pos -34.289 -1 -129.141
--
-- Auto-Script: Requires Verification (Verified by Brawndo)
-----------------------------------
package.loaded["scripts/zones/Al_Zahbi/TextIDs"] = nil;
-------------------... | gpl-3.0 |
hnyman/packages | utils/prometheus-node-exporter-lua/files/usr/lib/lua/prometheus-collectors/realtek-poe.lua | 16 | 2602 | require "ubus"
local METRIC_NAMESPACE = "realtek_poe"
-- possible poe modes for a port
-- realtek-poe/src/main.c
-- static int poe_reply_port_ext_config()
local POE_MODES = {
"PoE",
"Legacy",
"pre-PoE+",
"PoE+"
}
-- possible poe states for a port
-- realtek-poe/src/main.c
-- static int poe_re... | gpl-2.0 |
Capster/Metro | lua/metro/ui/dkillicon.lua | 2 | 1083 | --[[ _
( )
_| | __ _ __ ___ ___ _ _
/'_` | /'__`\( '__)/' _ ` _ `\ /'_` )
( (_| |( ___/| | | ( ) ( ) |( (_| |
`\__,_)`\____)(_) (_) (_) (_)`\__,_)
DImage
--]]
PANEL = {}
AccessorFunc( PANEL, "m_Name", "Name" )
--[[------... | apache-2.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Middle_Delkfutts_Tower/npcs/qm1.lua | 9 | 1564 | -----------------------------------
-- Area: Middle Delfutt's Tower
-- NPC: ??? (qm1)
-- Involved In Quest: Blade of Evil
-- @pos 84 -79 77 157
-----------------------------------
package.loaded["scripts/zones/Middle_Delkfutts_Tower/TextIDs"] = nil;
-----------------------------------
require("scripts/global... | gpl-3.0 |
dmcooke/tradecd | LibDataBroker-1.1.lua | 78 | 3139 |
assert(LibStub, "LibDataBroker-1.1 requires LibStub")
assert(LibStub:GetLibrary("CallbackHandler-1.0", true), "LibDataBroker-1.1 requires CallbackHandler-1.0")
local lib, oldminor = LibStub:NewLibrary("LibDataBroker-1.1", 4)
if not lib then return end
oldminor = oldminor or 0
lib.callbacks = lib.callbacks or LibStu... | mit |
FFXIOrgins/FFXIOrgins | scripts/globals/items/witch_kabob.lua | 35 | 1384 | -----------------------------------------
-- ID: 4343
-- Item: witch_kabob
-- Food Effect: 1hour, All Races
-----------------------------------------
-- Magic Points 15
-- Mind 4
-- Enmity -1
-- MP Recovered While Healing 3
-----------------------------------------
require("scripts/globals/status");
----... | gpl-3.0 |
lordporya1/lord | plugins/invite.lua | 24 | 2328 | --[[
Invite other user to the chat group.
Use !invite ********* (where ********* is id_number) to invite a user by id_number.
This is the most reliable method.
Use !invite @username to invite a user by @username.
Less reliable. Some users don't have @username.
Use !invite Type print_name Here to invite a user by pri... | gpl-2.0 |
elyasgalikeshi/renjer | plugins/inrealm.lua | 34 | 22928 | -- 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_grou... | gpl-2.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Temple_of_Uggalepih/npcs/_mf8.lua | 17 | 1401 | -----------------------------------
-- Area: Temple of Uggalepih
-- NPC: _mf8 (Granite Door)
-- Notes: Opens with Prelate Key
-- @pos -11 -8 -99 159
-----------------------------------
package.loaded["scripts/zones/Temple_of_Uggalepih/TextIDs"] = nil;
-----------------------------------
require("scripts/zo... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Mount_Zhayolm/npcs/Bapokk.lua | 17 | 1458 | -----------------------------------
-- Area: Mount Zhayolm
-- NPC: Bapokk
-- Handles access to Alzadaal Ruins
-- @pos -20 -6 276 61
-----------------------------------
package.loaded["scripts/zones/Mount_Zhayolm/TextIDs"] = nil;
-----------------------------------
require("scripts/zones/Mount_Zhayolm/TextIDs... | gpl-3.0 |
elt11bot/seed-sup | plugins/stats.lua | 5 | 2366 | -- Saves the number of messages from a user
-- Can check the number of messages with !stats
do
local socket = require('socket')
local _file_stats = './data/stats.lua'
local _stats
function update_user_stats(msg)
-- Save user to stats table
local from_id = tostring(msg.from.id)
local to_id = tostring(msg.to.i... | gpl-2.0 |
moteus/ZipWriter | test/test.lua | 2 | 14727 | pcall(require, "luacov")
local HAS_RUNNER = not not lunit
local base64 = require "base64"
function DUMP(lvl, res)
res = base64.decode(res)
print(#res)
local out = assert(io.open(lvl, "wb"))
out:write(res)
out:close()
end
function LOAD(fname)
local f = assert(io.open(fname, "rb"))
lo... | mit |
FFXIOrgins/FFXIOrgins | scripts/globals/spells/slow.lua | 4 | 1611 | -----------------------------------------
-- Spell: Slow
-- Spell accuracy is most highly affected by Enfeebling Magic Skill, Magic Accuracy, and MND.
-- Slow's potency is calculated with the formula (150 + dMND*2)/1024, and caps at 300/1024 (~29.3%).
-- And MND of 75 is neccessary to reach the hardcap of Slow.
--... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Metalworks/npcs/Tomasa.lua | 34 | 1476 | -----------------------------------
-- Area: Metalworks
-- NPC: Tomasa
-- Standard Merchant NPC
-----------------------------------
package.loaded["scripts/zones/Metalworks/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/shop");
require("scripts/zones/Metalworks/TextIDs");
--... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Riverne-Site_B01/npcs/_0t2.lua | 19 | 1339 | -----------------------------------
-- Area: Riverne Site #B01
-- NPC: Unstable Displacement
-----------------------------------
package.loaded["scripts/zones/Riverne-Site_B01/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/settings");
require("scripts/zones/Riverne-Site_B01/Text... | gpl-3.0 |
daofeng2015/luci | applications/luci-app-olsr/luasrc/model/cbi/olsr/olsrd.lua | 68 | 17192 | -- Copyright 2008 Steven Barth <steven@midlink.org>
-- Copyright 2010 Jo-Philipp Wich <jow@openwrt.org>
-- Licensed to the public under the Apache License 2.0.
require("luci.tools.webadmin")
local fs = require "nixio.fs"
local util = require "luci.util"
local ip = require "luci.ip"
local has_ipip = fs.glob("/etc/mo... | apache-2.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Northern_San_dOria/npcs/Cauzeriste.lua | 17 | 1262 | -----------------------------------
-- Area: Northern San d'Oria
-- NPC: Cauzeriste
-- Guild Merchant NPC: Woodworking Guild
-- @pos -175.946 3.999 280.301 231
-----------------------------------
package.loaded["scripts/zones/Northern_San_dOria/TextIDs"] = nil;
-----------------------------------
require("sc... | gpl-3.0 |
peval/Atlas | examples/tutorial-routing.lua | 47 | 1829 | --[[ $%BEGINLICENSE%$
Copyright (c) 2009, 2010, 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 |
FFXIOrgins/FFXIOrgins | scripts/zones/Riverne-Site_A01/mobs/Heliodromos.lua | 5 | 1721 | -----------------------------------
-- Area: Riverne Site A01
-- MOB: Heliodromos
-----------------------------------
-----------------------------------
function OnMobRoam(mob)
local Heliodromos_Table =
{
16900110,
16900111,
16900112
};
local Heliodromos_PH_Table =
{
16900107,
16900108,
16900109... | gpl-3.0 |
sjznxd/lc-20130127 | modules/niu/luasrc/model/cbi/niu/wireless/apdevice.lua | 51 | 1625 | --[[
LuCI - Lua Configuration Interface
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$
]]--
loca... | apache-2.0 |
unknownssassss/sudo_meti | plugins/filter.lua | 4 | 2776 | local function addword(msg, name)
local hash = 'chat:'..msg.chat_id_..':badword'
redis:hset(hash, name, 'newword')
return "<code>add filter</code>\n➣ "..name
end
local function get_badword_hash(msg)
return 'chat:'..msg.chat_id_..':badword'
end
local function list_badwords(msg)
local has... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Apollyon/mobs/Gorynich.lua | 17 | 1399 | -----------------------------------
-- Area: Apollyon NW
-- NPC: Kaiser Behemoth
-----------------------------------
package.loaded["scripts/zones/Apollyon/TextIDs"] = nil;
-----------------------------------
require("scripts/zones/Apollyon/TextIDs");
-----------------------------------
-- onMobSpawn Act... | gpl-3.0 |
Gael-de-Sailly/minetest-minetestforfun-server | mods/moretrees/tree_models.lua | 7 | 7150 | moretrees.beech_model={
axiom="FFFFFBFB",
rules_a="[&&&GGF[++^Fd][--&Fd]//Fd[+^Fd][--&Fd]]////[&&&GGF[++^Fd][--&Fd]//Fd[+^Fd][--&Fd]]////[&&&GGF[++^Fd][--&Fd]//Fd[+^Fd][--&Fdd]]",
rules_b="[&&&F[++^Fd][--&d]//d[+^d][--&d]]////[&&&F[++^Fd][--&d]//d[+^d][--&d]]////[&&&F[++^Fd][--&Fd]//d[+^d][--&d]]",
rules_c="/",
ru... | unlicense |
FFXIOrgins/FFXIOrgins | scripts/globals/items/loaf_of_hobgoblin_bread.lua | 35 | 1378 | -----------------------------------------
-- ID: 4328
-- Item: loaf_of_hobgoblin_bread
-- Food Effect: 60Min, All Races
-----------------------------------------
-- Health 10
-- Vitality 3
-- Charisma -7
-- Health Regen While Healing 2
-----------------------------------------
require("scripts/globals/statu... | gpl-3.0 |
subzrk/BadRotations | Libs/DiesalGUI-1.0/Objects/DropDown.lua | 4 | 9663 | -- $Id: DropDown.lua 60 2016-11-04 01:34:23Z diesal2010 $
local DiesalGUI = LibStub('DiesalGUI-1.0')
-- ~~| Libraries |~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
local DiesalTools = LibStub('DiesalTools-1.0')
local Diesa... | gpl-3.0 |
Mogara/QSanguosha | extension-doc/general_config.lua | 15 | 3078 | sgs.ai_keep_value = {
Shit = 6,
Peach = 5,
Analeptic = 4.5,
Jink = 4,
Nullification = 3,
Slash = 2,
ThunderSlash = 2.5,
FireSlash = 2.6,
ExNihilo=4.6,
AmazingGrace=-1,
Lightning=-1,
}
sgs.ai_use_value =
{
--skill cards
XinzhanCard = 4.4,
TianyiCard = 8.5,
XianzhenCard = 9.2,
XianzhenSlashCard = ... | gpl-3.0 |
rohgarg/slurm | contribs/lua/proctrack.lua | 25 | 9930 | --[[
Example lua script demonstrating the SLURM proctrack/lua interface.
This script implements a very simple job step container using CPUSETs.
--]]
require "posix"
--########################################################################--
--
-- SLURM proctrack/lua interface:
--
--############################... | gpl-2.0 |
Gael-de-Sailly/minetest-minetestforfun-server | mods/christmas_craft/mods.lua | 6 | 2610 | print (" ---- mods override is Loading! ---- ")
-- leaves --
--minetest.register_node(":4seasons:leaves_winter", {
-- description = "Leaves",
-- drawtype = "allfaces_optional",
-- visual_scale = 1.3,
-- tiles = {"4seasons_leaves_with_snow.png"},
-- paramtype = "light",
-- groups = {snappy=3, leafdecay=3, flammable=2... | unlicense |
xtria/new_tg | libs/url.lua | 567 | 9183 | --[[
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, merge, publish, distribute,... | agpl-3.0 |
teahouse/FWServer | skynet/examples/login/logind.lua | 25 | 1656 | local login = require "snax.loginserver"
local crypt = require "crypt"
local skynet = require "skynet"
local server = {
host = "127.0.0.1",
port = 8001,
multilogin = false, -- disallow multilogin
name = "login_master",
}
local server_list = {}
local user_online = {}
local user_login = {}
function server.auth_han... | mit |
Gael-de-Sailly/minetest-minetestforfun-server | mods/mesecons/mesecons/util.lua | 9 | 6449 | function mesecon.move_node(pos, newpos)
local node = minetest.get_node(pos)
local meta = minetest.get_meta(pos):to_table()
minetest.remove_node(pos)
minetest.set_node(newpos, node)
minetest.get_meta(pos):from_table(meta)
end
function mesecon.flattenrules(allrules)
--[[
{
{
{xyz},
{xyz},
},
{
{xyz}... | unlicense |
sjznxd/luci-0.11-aa | applications/luci-asterisk/luasrc/model/cbi/asterisk/phone_sip.lua | 11 | 3859 | --[[
LuCI - Lua Configuration Interface
Copyright 2008 Jo-Philipp Wich <xm@subsignal.org>
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
$Id: phone_si... | apache-2.0 |
vietlq/luasocket | etc/check-links.lua | 59 | 3388 | -----------------------------------------------------------------------------
-- Little program that checks links in HTML files, using coroutines and
-- non-blocking I/O via the dispatcher module.
-- LuaSocket sample files
-- Author: Diego Nehab
-- RCS ID: $$
------------------------------------------------------------... | mit |
FFXIOrgins/FFXIOrgins | scripts/globals/items/yagudo_cherry.lua | 35 | 1200 | -----------------------------------------
-- ID: 4445
-- Item: yagudo_cherry
-- Food Effect: 5Min, All Races
-----------------------------------------
-- Agility -3
-- Intelligence 1
-----------------------------------------
require("scripts/globals/status");
-----------------------------------------
-- O... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Maze_of_Shakhrami/npcs/Excavation_Point.lua | 4 | 1623 | -----------------------------------
-- Area: Maze of Shakhrami
-- NPC: Excavation Point
-- Used in Quest: The Holy Crest
-- @pos 234 0.1 -110 198
-----------------------------------
package.loaded["scripts/zones/Maze_of_Shakhrami/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/e... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/globals/mobskills/Dispelling_Wind.lua | 4 | 1038 | ---------------------------------------------
-- Dispelling Wind
--
-- Description: Dispels two effects from targets in an area of effect.
-- Type: Enfeebling
-- Utsusemi/Blink absorb: Ignores shadows
-- Range: 10' radial
-- Notes:
---------------------------------------------
require("/scripts/globals/s... | gpl-3.0 |
Messael/Firewolf | old/firefox 1.4.5.lua | 5 | 53732 |
-- -------- Mozilla Firefox
-- -------- Made by GravityScore and 1lann
-- -------- Original Idea from Rednet Explorer v2.4.1
-- -------- Rednet Explorer made by xXm0dzXx/CCFan11
-- -------- Global Variables
local exitApp = false
local finishExit = false
local exitWebsite = false
-- Encase in function
local ... | mit |
caidongyun/nginx-openresty-windows | lua-resty-core-0.0.3/lib/resty/core/response.lua | 1 | 2843 | -- Copyright (C) 2013 Yichun Zhang (agentzh)
local ffi = require 'ffi'
local base = require "resty.core.base"
local C = ffi.C
local ffi_new = ffi.new
local ffi_cast = ffi.cast
local ffi_str = ffi.string
local FFI_BAD_CONTEXT = base.FFI_BAD_CONTEXT
local FFI_NO_REQ_CTX = base.FFI_NO_REQ_CTX
local FFI_ER... | bsd-2-clause |
JulianVolodia/awesome | lib/awful/mouse/finder.lua | 10 | 5405 | -------------------------------------------------------------------------
--- Mouse finder for awful
--
-- Find the mouse pointer on the screen.
-- Mouse finder highlights the mouse cursor on the screen
-- To enable this feature, a `awful.mouse.finder` object needs to be bound to a
-- key:
--
-- mymousefinder = awf... | gpl-2.0 |
shahabsaf1/DaLTon-bot-test2 | bot/bot.lua | 1 | 7110 | package.path = package.path .. ';.luarocks/share/lua/5.2/?.lua'
..';.luarocks/share/lua/5.2/?/init.lua'
package.cpath = package.cpath .. ';.luarocks/lib/lua/5.2/?.so'
require("./bot/utils")
VERSION = '0.14.6'
-- This function is called when tg receive a msg
function on_msg_receive (msg)
if not started then
r... | gpl-2.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Inner_Horutoto_Ruins/npcs/_5ca.lua | 19 | 2234 | -----------------------------------
-- Area: Inner Horutoto Ruins
-- NPC: Mahogany Door
-- Involved In Quest: Making Headlines
-- Involved in Mission 2-1
-- @pos -11 0 20 192
-----------------------------------
package.loaded["scripts/zones/Inner_Horutoto_Ruins/TextIDs"] = nil;
--------------------------------... | gpl-3.0 |
chinnytp/proxmark3 | client/scripts/mifare_autopwn.lua | 9 | 4830 | local getopt = require('getopt')
local reader = require('read14a')
local cmds = require('commands')
example = "script run mifare_autopwn"
author = "Martin Holst Swende"
desc =
[[
This is a which automates cracking and dumping mifare classic cards. It sets itself into
'listening'-mode, after which it cracks and dump... | gpl-2.0 |
Gael-de-Sailly/minetest-minetestforfun-server | mods/mesecons/mesecons_walllever/init.lua | 12 | 1753 | -- WALL LEVER
-- Basically a switch that can be attached to a wall
-- Powers the block 2 nodes behind (using a receiver)
mesecon.register_node("mesecons_walllever:wall_lever", {
description="Lever",
drawtype = "mesh",
inventory_image = "jeija_wall_lever_inv.png",
wield_image = "jeija_wall_lever_inv.png",
paramtype... | unlicense |
FFXIOrgins/FFXIOrgins | scripts/zones/Ghelsba_Outpost/Zone.lua | 4 | 1608 | -----------------------------------
--
-- Zone: Ghelsba_Outpost (140)
--
-----------------------------------
package.loaded["scripts/zones/Ghelsba_Outpost/TextIDs"] = nil;
require("scripts/globals/settings");
require("scripts/zones/Ghelsba_Outpost/TextIDs");
-----------------------------------
-- onInitial... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Selbina/npcs/Mathilde.lua | 19 | 1804 | -----------------------------------
-- Area: Selbina
-- NPC: Mathilde
-- Involved in Quest: Riding on the Clouds
-- @pos 12.578 -8.287 -7.576 248
-----------------------------------
package.loaded["scripts/zones/Selbina/TextIDs"] = nil;
-----------------------------------
require("scripts/zones/Selbina/TextIDs");
req... | gpl-3.0 |
moonlight-stream/moonlight-android | LuaScripts/NVStreamVideoPacket.lua | 4 | 2408 | -- Nvidia Streaming Video Packet Dissector
-- Version: 1.0
-- Diego Waxemberg
-- video header
local nvHeader_frame = ProtoField.uint32("nv.frame", "Frame", base.HEX) -- 4 bytes
local nvHeader_pindex = ProtoField.uint16("nv.pindex", "Packet Index", base.HEX) -- 2 bytes
local nvHeader_empty = ProtoField.uint16("nv.empty... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/globals/items/nosteau_herring.lua | 17 | 1324 | -----------------------------------------
-- ID: 4482
-- Item: nosteau_herring
-- Food Effect: 5Min, Mithra only
-----------------------------------------
-- Dexterity 2
-- Mind -4
-----------------------------------------
require("scripts/globals/status");
-----------------------------------------
-- OnI... | gpl-3.0 |
subzrk/BadRotations | System/UI/Toggles/Toggles.lua | 4 | 5732 | -- this handles old profiles buttons
function TogglesFrame()
GarbageButtons()
---------------------------
-- Main Button --
---------------------------
-- Default Values
emptyIcon = [[Interface\FrameGeneral\UI-Background-Marble]]
backIconOn = [[Interface\ICONS\Spell_Holy_PowerWordShield]]
backIconOff = [[... | gpl-3.0 |
houst0nn/external_skia | tools/lua/scrape_dashing_full.lua | 159 | 4610 | local canvas -- holds the current canvas (from startcanvas())
--[[
startcanvas() is called at the start of each picture file, passing the
canvas that we will be drawing into, and the name of the file.
Following this call, there will be some number of calls to accumulate(t)
where t is a tabl... | bsd-3-clause |
fartoverflow/naev | dat/missions/sirius/heretic/heretic3.lua | 9 | 10584 | --[[misn title - the assault]]
--[[in this mission, the wringer is assaulted by a full assault fleet
sent in by the threatened sirius. the player attempts to defend,
when is instead ordered back to the wringer to escape sirius controlled
space. thanks to nloewen and viashimo for help!]]
include "dat/scripts/numst... | gpl-3.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Temenos/mobs/Temenos_Aern.lua | 17 | 2349 | -----------------------------------
-- Area: Temenos
-- NPC: Temenos_Aern
-----------------------------------
package.loaded["scripts/zones/Temenos/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/limbus");
require("scripts/zones/Temenos/TextIDs");
-------------------------------... | gpl-3.0 |
msburgess3200/PERP | gamemodes/perp/gamemode/npcs/job_fireman.lua | 1 | 5116 |
local NPC = {};
NPC.Name = "Fire Department";
NPC.ID = 12;
NPC.Model = Model("models/players/perp2/fire_02.mdl");
NPC.Invisible = false; // Used for ATM Machines, Casino Tables, etc.
NPC.Location = Vector(-3788.1167, -6982.7051, 198.0313);
NPC.Angles = Angle(0, 180, 0);
NPC.ShowChatBubble = "Normal";
NPC.Sequenc... | mit |
realtime-framework/RealtimeMessaging-Lua | app/OrtcClient.lua | 1 | 26911 | #!/usr/bin/env lua
local base_char,keywords=128,{"and","break","do","else","elseif","end","false","for","function","if","in","local","nil","not","or","repeat","return","then","true","until","while","Strings","find","require","string","_SUPER","isNullOrEmpty","self","error","uri_part_not_allowed","\"uri._util\"","userin... | mit |
Ali-2h/lwl | plugins/kickall.lua | 125 | 1670 | local function kick_user(user_id, chat_id)
local chat = 'chat#id'..chat_id
local user = 'user#id'..user_id
chat_del_user(chat, user, ok_cb, true)
end
local function returnids(cb_extra, success, result)
local receiver = cb_extra.receiver
local chat_id = result.id
local chatname = result.print_name
loc... | gpl-2.0 |
zhouxiaoxiaoxujian/skynet | test/testredis2.lua | 30 | 1053 | local skynet = require "skynet"
local redis = require "skynet.db.redis"
local db
function add1(key, count)
local t = {}
for i = 1, count do
t[2*i -1] = "key" ..i
t[2*i] = "value" .. i
end
db:hmset(key, table.unpack(t))
end
function add2(key, count)
local t = {}
for i = 1, cou... | mit |
cyph84/mpv | player/lua/assdraw.lua | 33 | 2378 | local ass_mt = {}
ass_mt.__index = ass_mt
local function ass_new()
return setmetatable({ scale = 4, text = "" }, ass_mt)
end
function ass_mt.new_event(ass)
-- osd_libass.c adds an event per line
if #ass.text > 0 then
ass.text = ass.text .. "\n"
end
end
function ass_mt.draw_start(ass)
ass.... | gpl-2.0 |
FFXIOrgins/FFXIOrgins | scripts/zones/Northern_San_dOria/npcs/Eugballion.lua | 19 | 1644 | -----------------------------------
-- Area: Northern San d'Oria
-- NPC: Eugballion
-- Only sells when San d'Oria controlls Qufim Region
-----------------------------------
package.loaded["scripts/zones/Northern_San_dOria/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/shop");
re... | gpl-3.0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.