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 |
|---|---|---|---|---|---|
FastTM/Fast-Unique | plugins/welcome.lua | 1 | 6696 | local plugin = {}
local function is_locked(chat_id, thing)
local hash = 'chat:'..chat_id..':settings'
local current = db:hget(hash, thing)
if current == 'off' then
return true
else
return false
end
end
local function get_welcome(msg)
if is_locked(msg.chat.id, 'Welcome') then
return false
en... | gpl-2.0 |
dismantl/luci-0.12 | applications/luci-p910nd/luasrc/model/cbi/p910nd.lua | 74 | 1512 | --[[
LuCI p910nd
(c) 2008 Yanira <forum-2008@email.de>
(c) 2012 Jo-Philipp Wich <jow@openwrt.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... | apache-2.0 |
ashkanpj/seedfire | bot/seedbot.lua | 1 | 9684 | 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 = '2'
-- This function is called when tg receive a msg
function on_msg_receive (msg)
if not started then
return... | gpl-2.0 |
jason9263/JasonAI | torch/A_datasets/svhn.lua | 1 | 2342 | ----------------------------------------------------------------------
-- This script downloads and loads the (SVHN) House Numbers dataset
-- http://ufldl.stanford.edu/housenumbers/
----------------------------------------------------------------------
print '==> downloading dataset'
-- Here we download dataset files.... | apache-2.0 |
qq779089973/ramod | 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... | mit |
vladimir-kotikov/clink-completions | dotnet.lua | 1 | 5725 | local matchers = require('matchers')
local parser = clink.arg.new_parser
local runtime_parser = parser({
-- Windows
"win-x64", "win-x86", "win-arm", "win-arm64", "win7-x64", "win7-x86",
"win81-x64", "win81-x86", "win81-arm", "win10-x64", "win10-x86", "win10-arm",
"win10-arm64",
-- Linux
"linu... | mit |
Ali-2h/wwefucker | plugins/img_google.lua | 660 | 3196 | do
local mime = require("mime")
local google_config = load_from_file('data/google.lua')
local cache = {}
--[[
local function send_request(url)
local t = {}
local options = {
url = url,
sink = ltn12.sink.table(t),
method = "GET"
}
local a, code, headers, status = http.request(options)
return tabl... | gpl-2.0 |
bsmr-games/lipsofsuna | data/lipsofsuna/building/building.lua | 1 | 2712 | --- Building subgame.
--
-- Lips of Suna is free software: you can redistribute it and/or modify
-- it under the terms of the GNU Lesser General Public License as
-- published by the Free Software Foundation, either version 3 of the
-- License, or (at your option) any later version.
--
-- @module building.building
-- @... | gpl-3.0 |
bsmr-games/lipsofsuna | data/lipsofsuna/core/ai/state/combat.lua | 1 | 1466 | local AiStateSpec = require("core/specs/aistate")
AiStateSpec{
name = "combat",
calculate = function(self)
-- Check for enemies.
for k,v in pairs(self.enemies) do return 1 end
end,
enter = function(self, prev)
self:calculate_combat_ratings()
self.target = self.best_enemy
if prev ~= "combat" then
local... | gpl-3.0 |
LaFamiglia/Illarion-Content | quest/nimbur_goldhand_313_noobia.lua | 1 | 3747 | --[[
Illarion Server
This program is free software: you can redistribute it and/or modify it under
the terms of the GNU Affero General Public License as published by the Free
Software Foundation, either version 3 of the License, or (at your option) any
later version.
This program is distributed in the hope that it wi... | agpl-3.0 |
facebokiii/arman | 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 |
FastTM/Fast-Unique | plugins/realms.lua | 1 | 29054 | local plugin = {}
----these functions should be globals
local function is_realm(chat_id)
if db:sismember('bot:realms', chat_id) then
return true
else
return false
end
end
local function is_paired(chat_id)
--realm_id: the chat has a realm associated and the chat_id appears in the subgroups of the... | gpl-2.0 |
chegenipapi/sajadchegen | plugins/rae.lua | 616 | 1312 | do
function getDulcinea( text )
-- Powered by https://github.com/javierhonduco/dulcinea
local api = "http://dulcinea.herokuapp.com/api/?query="
local query_url = api..text
local b, code = http.request(query_url)
if code ~= 200 then
return "Error: HTTP Connection"
end
dulcinea = json:decode(b)
... | gpl-2.0 |
hnyman/luci | applications/luci-app-vpn-policy-routing/luasrc/controller/vpn-policy-routing.lua | 3 | 1213 | module("luci.controller.vpn-policy-routing", package.seeall)
function index()
if nixio.fs.access("/etc/config/vpn-policy-routing") then
local e = entry({"admin", "vpn"}, firstchild(), _("VPN"), 60)
e.dependent = false
e.acl_depends = { "luci-app-vpn-policy-routing" }
entry({"admin", "vpn", "vpn-policy-routing"... | apache-2.0 |
Choumiko/SmallFixes | config.lua | 1 | 1714 | config =
{
-- make construction bots not go to the quickbar, default on
fix_bots = true,
-- make construction bots unminable, default on
unminable_bots = true,
-- make logistic bots unminable, default off
unminable_logistic_bots = false,
-- mining bots returns the mater... | mit |
sepehrpk/firebot | 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 |
Hzj-jie/koreader-base | ffi/linux_input_h.lua | 3 | 1320 | local ffi = require("ffi")
ffi.cdef[[
struct input_event {
struct timeval time;
short unsigned int type;
short unsigned int code;
int value;
};
static const int EVIOCGRAB = 1074021776;
static const int EV_SYN = 0;
static const int EV_KEY = 1;
static const int EV_REL = 2;
static const int EV_ABS = 3;
static con... | agpl-3.0 |
qq779089973/ramod | 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... | mit |
clandmeter/luadbi | DBI.lua | 3 | 2061 | #!/usr/bin/lua
local _M = {}
-- Driver to module mapping
local name_to_module = {
MySQL = 'dbdmysql',
PostgreSQL = 'dbdpostgresql',
SQLite3 = 'dbdsqlite3',
DB2 = 'dbddb2',
Oracle = 'dbdoracle',
}
local string = require('string')
-- Returns a list of available drivers
-- based on run time loading... | mit |
xpqz/lua-cloudant | cloudant.lua | 1 | 3386 |
local request = require 'http.request'
local json = require 'cjson'
local mime = require 'mime'
local URI = require 'uri'
local Cloudant = { baseuri = nil }
local function urlencode(str)
if (str) then
str = string.gsub (str, "\n", "\r\n")
str = string.gsub (str, "([^%w ])",
function (c) retur... | apache-2.0 |
openwayne/chaos_theory | mods/moreblocks/stairsplus/init.lua | 1 | 3379 | --[[
More Blocks: Stairs+
Copyright (c) 2011-2017 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
-- Nodes will be called <modname>:{stair,slab,panel,micro}_<subname>
local modpath = minetest.get_modpath("moreblocks").. "/stairsplus"
stairsplus = {}
stairsp... | lgpl-2.1 |
justathoughtor2/atomicApe | cygwin/bin/texlive/texmf-dist/scripts/oberdiek/oberdiek.luacolor-pre065.lua | 6 | 5752 | --
-- This is file `oberdiek.luacolor-pre065.lua',
-- generated with the docstrip utility.
--
-- The original source files were:
--
-- luacolor.dtx (with options: `lua,pre065')
--
-- This is a generated file.
--
-- Project: luacolor
-- Version: 2011/11/01 v1.8
--
-- Copyright (C) 2007, 2009-2011 by
--... | gpl-3.0 |
openwayne/chaos_theory | mods/farming_plus/carrots.lua | 2 | 2430 | -- main `S` code in init.lua
local S
S = farming.S
minetest.register_craftitem("farming_plus:carrot_seed", {
description = S("Carrot Seeds"),
inventory_image = "farming_carrot_seed.png",
on_place = function(itemstack, placer, pointed_thing)
return farming.place_seed(itemstack, placer, pointed_thing, "farming_plus... | lgpl-2.1 |
Cyumus/Plugins | crafting/entities/weapons/hl2_m_hammer.lua | 2 | 2158 | if (SERVER) then
SWEP.Weight = 10
SWEP.AutoSwitchTo = false
SWEP.AutoSwitchFrom = false
end
if ( CLIENT ) then
SWEP.PrintName = "Hammer"
SWEP.Author = "Black Tea"
SWEP.Instructions = "Left click to attack."
SWEP.ShowWorldModel = false
SWEP.ViewModelBoneMods = {
["v_weapon.Knife_Handle"] = { s... | gpl-3.0 |
obsy/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 |
openwayne/chaos_theory | mods/mesecons/mesecons_doors/init.lua | 5 | 3586 | -- Modified, from minetest_game/mods/doors/init.lua
local function on_rightclick(pos, dir, check_name, replace, replace_dir, params)
pos.y = pos.y + dir
if not minetest.get_node(pos).name == check_name then
return
end
local p2 = minetest.get_node(pos).param2
p2 = params[p2 + 1]
minetest.swap_node(pos, {name = ... | lgpl-2.1 |
lixiantai/barrier_breaker | feeds/luci/contrib/luasrcdiet/lua/optlex.lua | 125 | 31588 | --[[--------------------------------------------------------------------
optlex.lua: does lexer-based optimizations
This file is part of LuaSrcDiet.
Copyright (c) 2008 Kein-Hong Man <khman@users.sf.net>
The COPYRIGHT file describes the conditions
under which this software may be distributed.
See the Chan... | gpl-2.0 |
obsy/luci | applications/luci-app-privoxy/luasrc/controller/privoxy.lua | 33 | 4608 | -- Copyright 2014 Christian Schoenebeck <christian dot schoenebeck at gmail dot com>
-- Licensed under the Apache License, Version 2.0
module("luci.controller.privoxy", package.seeall)
local NX = require "nixio"
local NXFS = require "nixio.fs"
local HTTP = require "luci.http"
local UCI = require "luci.model.uci"
l... | apache-2.0 |
LuaAV/LuaAV4 | examples/alife/evo_agentfield.lua | 1 | 4552 | local field2D = require "field2D"
local vec2 = require "vec2"
local draw2D = require "draw2D"
math.randomseed(os.time())
win = Window(nil, 400, 400)
-- number of genes in a genome:
local genome_size = 8
-- number of different values a gene can take:
local gene_range = 9
local mutation_rate = 0.01
local generation_... | mit |
jyggen/lua-parser | tests/Fixtures/b6/18/ed/3c2b5cc24a68434cea78ca395ad8e6d76fb4a8ab411ba1e254c505c651.lua | 1 | 12176 |
Overachiever_CharVars = {
["Version"] = "0.84",
}
Overachiever_CharVars_Consumed = {
["PandaEats2"] = {
[74649] = 0,
[74651] = 0,
[74653] = 0,
[74655] = 0,
[86069] = 0,
[75037] = 0,
[74636] = 0,
[74642] = 0,
[74644] = 0,
[74646] = 0,
[74648] = 0,
[74650] = 0,
[74652] = 0,
[75026] = 0,
[... | mit |
shingenko/darkstar | scripts/globals/spells/kurayami_san.lua | 18 | 1142 | -----------------------------------------
-- Spell: Kurayami: San
-----------------------------------------
require("scripts/globals/status");
require("scripts/globals/magic");
-----------------------------------------
-- OnSpellCast
-----------------------------------------
function onMagicCastingCheck(caster,targe... | gpl-3.0 |
wagonrepairer/Zero-K | LuaRules/Gadgets/game_over.lua | 2 | 15728 | --------------------------------------------------------------------------------
--------------------------------------------------------------------------------
if not gadgetHandler:IsSyncedCode() then
return
end
--------------------------------------------------------------------------------
------------------------... | gpl-2.0 |
QuetzalQatl/RustPluginManual | SnapshotAllPlugins/event.lua | 1 | 18482 | PLUGIN.Name = "Running"
PLUGIN.Title = "Running"
PLUGIN.Version = V(1, 0, 0)
PLUGIN.Description = "Бегущий человек"
PLUGIN.Author = "Mizantop"
PLUGIN.ResourceId = 777
PLUGIN.HasConfig = true
local runningman = nil
local eventstart = nil
local eventpause = nil
local time1 = nil
local time2 = nil
local API = nil
functi... | gpl-2.0 |
shingenko/darkstar | scripts/zones/Tavnazian_Safehold/npcs/Migran.lua | 37 | 1542 | -----------------------------------
-- Area: Tavnasian Safehold
-- NPC: Migran
-- Standard Merchant NPC
-----------------------------------
require("scripts/globals/shop");
package.loaded["scripts/zones/Tavnazian_Safehold/TextIDs"] = nil;
require("scripts/zones/Tavnazian_Safehold/TextIDs");
----------------... | gpl-3.0 |
kveratis/GameCode4 | Source/GCC4/3rdParty/luaplus51-all/Src/Modules/wsapi/src/wsapi/util.lua | 1 | 6012 | module("wsapi.util", package.seeall)
----------------------------------------------------------------------------
-- Decode an URL-encoded string (see RFC 2396)
----------------------------------------------------------------------------
function url_decode(str)
if not str then return nil end
str = string.g... | lgpl-3.0 |
matinJ/skynet | examples/login/gated.lua | 57 | 2201 | local msgserver = require "snax.msgserver"
local crypt = require "crypt"
local skynet = require "skynet"
local loginservice = tonumber(...)
local server = {}
local users = {}
local username_map = {}
local internal_id = 0
-- login server disallow multi login, so login_handler never be reentry
-- call by login server
... | mit |
openwayne/chaos_theory | mods/castle_gates/gate_functions.lua | 1 | 14648 | local MP = minetest.get_modpath(minetest.get_current_modname())
dofile(MP.."/class_pointset.lua")
-- Given a facedir, returns a set of all the corresponding directions
local get_dirs = function(facedir)
local dirs = {}
local top = {[0]={x=0, y=1, z=0},
{x=0, y=0, z=1},
{x=0, y=0, z=-1},
{x=1, y=0, z=0},
{x=-... | lgpl-2.1 |
fzimmermann89/texlive.js | texlive/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/energybased/SpringEmbedderFRExact.lua | 1 | 2152 | -- Copyright 2013 by Till Tantau
--
-- This file may be distributed an/or modified
--
-- 1. under the LaTeX Project Public License and/or
-- 2. under the GNU Public License
--
-- See the file doc/generic/pgf/licenses/LICENSE for more information
-- @release $Header$
local key = require 'pgf.gd.doc'.key
loc... | gpl-2.0 |
shingenko/darkstar | scripts/zones/Lower_Jeuno/npcs/Muckvix.lua | 19 | 1439 | -----------------------------------
-- Area: Lower Jeuno
-- NPC: Muckvix
-- Involved in Mission: Magicite
-- @zone 245
-- @pos -26.824 3.601 -137.082
-----------------------------------
package.loaded["scripts/zones/Lower_Jeuno/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/keyitems");
... | gpl-3.0 |
ArcherSys/ArcherSys | Lua/lua/socket/ftp.lua | 144 | 9120 | -----------------------------------------------------------------------------
-- FTP support for the Lua language
-- LuaSocket toolkit.
-- Author: Diego Nehab
-- RCS ID: $Id: ftp.lua,v 1.45 2007/07/11 19:25:47 diego Exp $
-----------------------------------------------------------------------------
-------------------... | mit |
pacerom/external_skia | tools/lua/scrape.lua | 145 | 2246 | function tostr(t)
local str = ""
for k, v in next, t do
if #str > 0 then
str = str .. ", "
end
if type(k) == "number" then
str = str .. "[" .. k .. "] = "
else
str = str .. tostring(k) .. " = "
end
if type(v) == "table" then
... | bsd-3-clause |
shingenko/darkstar | scripts/zones/Southern_San_dOria/npcs/Blendare.lua | 13 | 1767 | -----------------------------------
-- Area: Southern San d'Oria
-- NPC: Blendare
-- Type: Standard NPC
-- @zone: 230
-- @pos 33.033 0.999 -30.119
--
-- Auto-Script: Requires Verification (Verified by Brawndo)
-----------------------------------
package.loaded["scripts/zones/Southern_San_dOria/TextIDs"]... | gpl-3.0 |
apaszke/nn | THNN.lua | 7 | 3681 | local ffi = require 'ffi'
local THNN = {}
local generic_THNN_h = require 'nn.THNN_h'
-- strip all lines starting with #
-- to remove preprocessor directives originally present
-- in THNN.h
generic_THNN_h = generic_THNN_h:gsub("\n#[^\n]*", "")
generic_THNN_h = generic_THNN_h:gsub("^#[^\n]*\n", "")
-- THGenerator str... | bsd-3-clause |
holocronweaver/accidental-noise-library-stable | lua/noisemoduletree.lua | 1 | 31946 | require 'class'
require 'tablesaveload'
MaxSources=20
NoiseModuleTree=class(function(a,declaration)
a.moduletable={}
a.libraries={}
a.seedablemodules={}
if declaration~=nil then
a:parseDeclaration(declaration)
end
end)
function NoiseModuleTree:getFunction(name)
return self.moduletable[name]
e... | mit |
shingenko/darkstar | scripts/globals/mobskills/Polar_Blast.lua | 7 | 1066 | ---------------------------------------------
-- Polar Blast
--
-- Description: Deals Ice damage to enemies within a fan-shaped area. Additional effect: Paralyze
-- Type: Breath
-- Ignores Shadows
-- Range: Unknown Cone
---------------------------------------------
require("scripts/globals/settings");
require("sc... | gpl-3.0 |
shingenko/darkstar | scripts/zones/Northern_San_dOria/npcs/Beadurinc.lua | 53 | 1875 | -----------------------------------
-- Area: Northern San d'Oria
-- NPC: Beadurinc
-- Type: Smithing Synthesis Image Support
-- @pos -182.300 10.999 146.650 231
-----------------------------------
package.loaded["scripts/zones/Northern_San_dOria/TextIDs"] = nil;
-----------------------------------
require("scripts/gl... | gpl-3.0 |
AleksCore/Mr.Green-MTA-Resources | resources/[gameplay]/mrgreen-settings/c_bloom.lua | 4 | 5773 | --
-- c_bloom.lua
--
local scx, scy = guiGetScreenSize()
-----------------------------------------------------------------------------------
-- Le settings
-----------------------------------------------------------------------------------
Settings = {}
Settings.var = {}
Settings.var.cutoff = 0.1
Settings.var.power =... | mit |
henry4k/LDoc | ldoc/builtin/math.lua | 7 | 3657 | --- standard mathematical functions.
-- @module math
local math = {}
---
-- Returns the absolute value of `x`.
function math.abs(x) end
---
-- Returns the arc cosine of `x` (in radians).
function math.acos(x) end
---
-- Returns the arc sine of `x` (in radians).
function math.asin(x) end
---
-- Re... | mit |
truefitness/vlc | share/lua/intf/cli.lua | 35 | 31833 | --[==========================================================================[
cli.lua: CLI module for VLC
--[==========================================================================[
Copyright (C) 2007-2011 the VideoLAN team
$Id$
Authors: Antoine Cellerier <dionoea at videolan dot org>
Pierre Ynard
... | gpl-2.0 |
jyggen/lua-parser | tests/Fixtures/de/c5/fe/642a77cc78a4f8b8c5fbdaa011068f534abe59dc1dfd242667a938c7b6.lua | 1 | 4072 |
EmoteSplitterSaved = {
["char"] = {
["Flöyd - Argent Dawn"] = {
["undo_history"] = {
{
["history"] = {
{
["cursor"] = 47,
["text"] = "I think the reasons for the brig was disobeying",
}, -- [1]
{
["cursor"] = 67,
["text"] = "I think the reasons ... | mit |
wagonrepairer/Zero-K | LuaRules/Utilities/base64.lua | 12 | 3111 | -- $Id: api_base64.lua 3171 2008-11-06 09:06:29Z det $
-- Author: Alex Kloss
-- Contact: http://www.it-rfc.de
-- Date: 2006-2008
-- License: LGPL2
-- Public functions:
-- * Spring.Utilities.Base64Encode(string data) -> string
-- * Spring.Utilities.Base64Decode(string data) -> string
-- bitshift functions (<<, >> eq... | gpl-2.0 |
shingenko/darkstar | scripts/zones/Southern_San_dOria/npcs/Diary.lua | 17 | 2122 | -----------------------------------
-- Area: Northern San d'Oria
-- NPC: Diary
-- Involved in Quest: To Cure a Cough
-- @zone 230
-- @pos -75 -12 65
-----------------------------------
package.loaded["scripts/zones/Southern_San_dOria/TextIDs"] = nil;
-----------------------------------
require("scripts/glob... | gpl-3.0 |
shingenko/darkstar | scripts/zones/Northern_San_dOria/npcs/Doggomehr.lua | 17 | 1232 | -----------------------------------
-- Area: Northern San d'Oria
-- NPC: Doggomehr
-- Guild Merchant NPC: Blacksmithing Guild
-- @pos -193.920 3.999 162.027 231
-----------------------------------
package.loaded["scripts/zones/Northern_San_dOria/TextIDs"] = nil;
-----------------------------------
requir... | gpl-3.0 |
Illarion-eV/Illarion-Content | quest/decius_cerasus_160_runewick.lua | 1 | 10745 | --[[
Illarion Server
This program is free software: you can redistribute it and/or modify it under
the terms of the GNU Affero General Public License as published by the Free
Software Foundation, either version 3 of the License, or (at your option) any
later version.
This program is distributed in the hope that it wi... | agpl-3.0 |
shingenko/darkstar | scripts/zones/Windurst_Waters_[S]/npcs/Pihra_Rhebenslo.lua | 36 | 4463 | -----------------------------------
-- Area: Windurst Waters [S]
-- NPC: Pihra_Rhebenslo
-- Armor Storage NPC
-----------------------------------
package.loaded["scripts/zones/Windurst_Waters_[S]/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/quests");
require("scripts/globals/a... | gpl-3.0 |
Illarion-eV/Illarion-Content | triggerfield/evilrock.lua | 1 | 22420 | --[[
Illarion Server
This program is free software: you can redistribute it and/or modify it under
the terms of the GNU Affero General Public License as published by the Free
Software Foundation, either version 3 of the License, or (at your option) any
later version.
This program is distributed in the hope that it wi... | agpl-3.0 |
hfjgjfg/mehdi5 | plugins/inpm.lua | 243 | 3007 | do
local function pairsByKeys (t, f)
local a = {}
for n in pairs(t) do table.insert(a, n) end
table.sort(a, f)
local i = 0 -- iterator variable
local iter = function () -- iterator function
i = i + 1
if a[i] == nil then return nil
else return a[i], t[a[i]]
... | gpl-2.0 |
fzimmermann89/texlive.js | texlive/texmf-dist/tex/luatex/luaotfload/fontloader-l-lpeg.lua | 4 | 38440 | if not modules then modules = { } end modules ['l-lpeg'] = {
version = 1.001,
comment = "companion to luat-lib.mkiv",
author = "Hans Hagen, PRAGMA-ADE, Hasselt NL",
copyright = "PRAGMA ADE / ConTeXt Development Team",
license = "see context related readme files"
}
-- we can get too many ca... | gpl-2.0 |
shingenko/darkstar | scripts/zones/The_Eldieme_Necropolis/npcs/qm1.lua | 17 | 1641 | -----------------------------------
-- Area: The Eldieme Necropolis
-- NPC: ???
-- Involved in Quests: Acting in Good Faith
-- @zone 195
-- @pos -17 0 59 (I-10)
-- @pos
-- @pos
-- @pos
-----------------------------------
package.loaded["scripts/zones/The_Eldieme_Necropolis/TextIDs"] = nil;
--------------... | gpl-3.0 |
shingenko/darkstar | scripts/globals/items/broiled_pipira.lua | 35 | 1371 | -----------------------------------------
-- ID: 4585
-- Item: Broiled Pipira
-- Food Effect: 60Min, All Races
-----------------------------------------
-- Dexterity 4
-- Mind -1
-- Attack % 14
-- Ranged ATT % 14
-----------------------------------------
require("scripts/globals/status");
---------------... | gpl-3.0 |
PhilMo6/Lua_pi_pan | obj/Buzzer.lua | 1 | 2520 | local Cloneable = require("obj.Common")
local Buzzer = Cloneable:clone()
--[[
piezo buzzer! who doesen't love buzzers. whatever your need if you want to make some noise this is the module for you!
working on making a better variety of noises.
]]
Buzzer.location = 'buzzers'
function Buzzer:setup(options)
local... | mit |
fzimmermann89/texlive.js | texlive/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/CoarseGraph.lua | 1 | 14370 | -- Copyright 2011 by Jannis Pohlmann
-- Copyright 2012 by Till Tantau
--
-- This file may be distributed an/or modified
--
-- 1. under the LaTeX Project Public License and/or
-- 2. under the GNU Public License
--
-- See the file doc/generic/pgf/licenses/LICENSE for more information
-- @release $Header$
--- A class f... | gpl-2.0 |
shingenko/darkstar | scripts/zones/Port_Windurst/npcs/Hakkuru-Rinkuru.lua | 17 | 7052 | -----------------------------------
-- Area: Port Windurst
-- NPC: Hakkuru-Rinkuru
-- Involved In Quest: Making Amends
-- Starts and Ends Quest: Wonder Wands
-- @pos -111 -4 101 240
-----------------------------------
package.loaded["scripts/zones/Port_Windurst/TextIDs"] = nil;
package.loaded["scripts/globals/... | gpl-3.0 |
TheAncientGoat/GodheadLips | data/system/widgets/menuitem.lua | 1 | 1249 | require "system/widgets/label"
Widgets.MenuItem = Class(Widgets.Label)
Widgets.MenuItem.class_name = "Widgets.MenuItem"
Widgets.MenuItem.new = function(clss, args)
local self = Widgets.Label.new(clss, args)
self.color = args.color or {1,1,1,1}
self.color_focus = args.color_focus or {1,1,0,1}
return self
end
Widg... | gpl-3.0 |
wagonrepairer/Zero-K | LuaUI/Widgets/dbg_startbox_editor.lua | 6 | 3011 | function widget:GetInfo() return {
name = "Startbox Editor",
desc = "cruder than yo momma",
author = "git blame",
date = "git log",
license = "PD",
layer = math.huge,
enabled = false,
} end
--[[ tl;dr
LMB to draw (either clicks or drag)
RMB to accept a polygon
D to remove last polygon
S to echo curr... | gpl-2.0 |
wagonrepairer/Zero-K | scripts/corshad.lua | 2 | 6741 | local base = piece 'base'
local fuselage = piece 'fuselage'
local wingl1 = piece 'wingl1'
local wingr1 = piece 'wingr1'
local wingl2 = piece 'wingl2'
local wingr2 = piece 'wingr2'
local engines = piece 'engines'
local fins = piece 'fins'
local rflap = piece 'rflap'
local lflap = piece 'lflap'
local predrop = p... | gpl-2.0 |
shingenko/darkstar | scripts/globals/items/bowl_of_adoulin_soup_+1.lua | 36 | 1507 | -----------------------------------------
-- ID: 5999
-- Item: Bowl of Adoulin Soup +1
-- Food Effect: 240 Min, All Races
-----------------------------------------
-- HP % 4 Cap 45
-- Vitality 4
-- Defense % 16 Cap 75
-- HP Healing 7
-----------------------------------------
require("scripts/globals/status");
-------... | gpl-3.0 |
shingenko/darkstar | scripts/zones/West_Sarutabaruta/npcs/Ipupu.lua | 17 | 1415 | -----------------------------------
-- Area: West Sarutabaruta
-- NPC: Ipupu
-- Involved in Quest: Glyph Hanger
-- @pos 251.745 -5.5 35.539 115
-----------------------------------
package.loaded["scripts/zones/West_Sarutabaruta/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/... | gpl-3.0 |
cjmay/thrift | lib/lua/TCompactProtocol.lua | 30 | 13135 | --
-- 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 ma... | apache-2.0 |
shingenko/darkstar | scripts/zones/Ranguemont_Pass/npcs/Waters_of_Oblivion.lua | 17 | 2199 | -----------------------------------
-- Area: Ranguemont Pass
-- NPC: Waters of Oblivion
-- Finish Quest: Painful Memory (BARD AF1)
-- @pos -284 -45 210 166
-----------------------------------
package.loaded["scripts/zones/Ranguemont_Pass/TextIDs"] = nil;
package.loaded["scripts/globals/settings"] = nil;
------... | gpl-3.0 |
sshadowart/oxscripts | src/007-ini.lua | 1 | 13254 | Ini = (function()
-- Imports
local split = Core.split
local trim = Core.trim
local countPairs = Core.countPairs
local indexTable = Core.indexTable
local setTimeout = Core.setTimeout
local getSelfName = Core.getSelfName
local debug = Core.debug
local error = Console.error
local log = Console.log
local prompt ... | gpl-2.0 |
yuin/gopher-lua | _lua5.1-tests/attrib.lua | 10 | 8357 | do --[
print "testing require"
assert(require"string" == string)
assert(require"math" == math)
assert(require"table" == table)
assert(require"io" == io)
assert(require"os" == os)
assert(require"debug" == debug)
assert(require"coroutine" == coroutine)
assert(type(package.path) == "string")
assert(type(package.cpath) ... | mit |
Antokolos/NLB | NLBW/res/vnstead/modules/vn.lua | 1 | 85303 | -- vn module
require 'timer'
require 'theme'
require 'sprites'
require 'modules/fonts'
require 'modules/gobj'
require 'modules/gr'
require 'modules/vnspr'
require 'modules/log'
require 'modules/nlb'
game.timer = stead.hook(game.timer, function(f, s, cmd, ...)
return vntimer(f, s, cmd, ...);
end)
game.fading = ste... | agpl-3.0 |
openwayne/chaos_theory | mods/moretrees/node_defs.lua | 2 | 19065 | local S = moretrees.intllib
moretrees.avoidnodes = {}
moretrees.treelist = {
{"beech", "Beech Tree"},
{"apple_tree", "Apple Tree"},
{"oak", "Oak Tree", "acorn", "Acorn", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
{"sequoia", "Giant Sequoia"},
{"birch", "Birch Tree"},
{"palm", "Palm Tree", "palm_fruit_t... | lgpl-2.1 |
wagonrepairer/Zero-K | units/armjeth.lua | 2 | 6650 | unitDef = {
unitname = [[armjeth]],
name = [[Gremlin]],
description = [[Cloaked Anti-Air Bot]],
acceleration = 0.5,
brakeRate = 0.32,
buildCostEnergy = 150,
buildCostMetal = 150,
buildPic = [[ARMJETH.png]],
... | gpl-2.0 |
jyggen/lua-parser | tests/Fixtures/a3/83/62/da4697d218e31fde3e7d4ba6dc2033bff53cb93e6c64b5aeff707ac73e.lua | 1 | 12176 |
Overachiever_CharVars = {
["Version"] = "0.81",
}
Overachiever_CharVars_Consumed = {
["PandaEats2"] = {
[74649] = 0,
[74651] = 0,
[74653] = 0,
[74655] = 0,
[86069] = 0,
[75037] = 0,
[74636] = 0,
[74642] = 0,
[74644] = 0,
[74646] = 0,
[74648] = 0,
[74650] = 0,
[74652] = 0,
[75026] = 0,
[... | mit |
TheAncientGoat/GodheadLips | data/godhead/scripts/client/objects/creature.lua | 1 | 8623 | Creature = Class(Object)
Creature.new = function(clss, args)
local self = Object.new(clss, args)
Object.dict_active[self] = 1.0
return self
end
Creature.detach = function(self)
-- Hide equipment.
if self.slots then
for k,v in pairs(self.slots.slots) do
v:detach()
end
self.slots = nil
end
-- Call base.... | gpl-3.0 |
mmusial/prosody-modules | mod_s2s_idle_timeout/mod_s2s_idle_timeout.lua | 32 | 1590 | local now = os.time;
local s2smanager = require "core.s2smanager";
local timer = require "util.timer";
local s2s_sessions = setmetatable({}, { __mode = "kv" });
local idle_timeout = module:get_option("s2s_idle_timeout") or 300;
local check_interval = math.ceil(idle_timeout * 0.75);
local function install_checks(ses... | mit |
medoo313m/bmo-bot2 | plugins/admin.lua | 95 | 10643 | 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(rec... | gpl-2.0 |
shadobaker/TeleBeyond | plugins/plugmanager.lua | 22 | 3691 | do
local function run(msg, matches)
if not is_sudo(msg) then
return "you have not accsess to filemanager"
end
local receiver = get_receiver(msg)
if matches[1] == 'بفرس' then
local file = matches[3]
if matches[2] == 'sticker' and not matches[4] then
send_document(receiver, "./media/"... | gpl-2.0 |
ubaldus/eja | eja.lua | 1 | 1467 | -- Copyright (C) 2007-2016 by Ubaldo Porcheddu <ubaldo@eja.it>
if not eja then
eja={}
eja.opt={}
eja.lib={}
eja.pid={}
eja.help={}
eja.mime={}
eja.mimeApp={}
eja.path=_eja_path or '/opt/eja.it/'
if eja.path == '/' or not ejaFileStat(eja.path) then
eja.path='/'
eja.pathBin=eja.path..'/usr/bin/'
eja.p... | gpl-3.0 |
shingenko/darkstar | scripts/globals/effects/super_buff.lua | 35 | 1143 | -----------------------------------
--
-- EFFECT_SUPER_BUFF
--
-----------------------------------
require("scripts/globals/status");
-----------------------------------
-- onEffectGain Action
-----------------------------------
function onEffectGain(target,effect)
local power = effect:getPower();
... | gpl-3.0 |
shingenko/darkstar | scripts/zones/Upper_Jeuno/npcs/Renik.lua | 34 | 1376 | -----------------------------------
-- Area: Upper Jeuno
-- NPC: Renik
-- Standard Info NPC
-----------------------------------
package.loaded["scripts/zones/Upper_Jeuno/TextIDs"] = nil;
-----------------------------------
require("scripts/zones/Upper_Jeuno/TextIDs");
require("scripts/globals/quests");
---... | gpl-3.0 |
shingenko/darkstar | scripts/zones/Norg/npcs/Oruga.lua | 34 | 3022 | -----------------------------------
-- Area: Norg
-- NPC: Oruga
-- Standard Info NPC
-----------------------------------
require("scripts/globals/pathfind");
local path = {
-0.016294, -1.251156, -30.703135,
1.135162, -1.295192, -30.737705,
2.267773, -1.620833, -30.756174,
3.344393, -1.879029, -30.778761,
... | gpl-3.0 |
wagonrepairer/Zero-K | LuaUI/Widgets/chili/Handlers/texturehandler.lua | 25 | 3354 | --//=============================================================================
--//
TextureHandler = {}
--//=============================================================================
--//TWEAKING
local timeLimit = 0.2/15 --//time per second / desiredFPS
--//==================================================... | gpl-2.0 |
shingenko/darkstar | scripts/zones/Bibiki_Bay/npcs/Fheli_Lapatzuo.lua | 19 | 4842 | -----------------------------------
-- Area: Bibiki Bay
-- NPC: Fheli Lapatzuo
-- Type: Manaclipper
-- @pos 488.793 -4.003 709.473 4
-----------------------------------
package.loaded["scripts/zones/Bibiki_Bay/TextIDs"] = nil;
require("scripts/zones/Bibiki_Bay/TextIDs");
-----------------------------------
-- o... | gpl-3.0 |
kaspter/ftk | script_binding/lua/demo_button.lua | 9 | 1478 | function OnQuit(button)
print("OnQuit: " .. button:GetText())
Ftk.Quit()
return RET_OK
end
function OnHide(button)
print("OnHide: " .. button:GetText())
button:Toplevel():Lookup(100):Show(0)
return RET_OK
end
function OnShow(button)
print("OnShow: " .. button:GetText())
button:Toplevel():Lookup(100):Show(1)
... | lgpl-3.0 |
shingenko/darkstar | scripts/zones/Kazham/npcs/Cha_Tigunalhgo.lua | 15 | 1101 | -----------------------------------
-- Area: Kazham
-- NPC: Cha Tigunalhgo
-- Standard Info NPC
-----------------------------------
package.loaded["scripts/zones/Kazham/TextIDs"] = nil;
require("scripts/zones/Kazham/TextIDs");
-----------------------------------
-- onTrade Action
--------------------------... | gpl-3.0 |
shingenko/darkstar | scripts/zones/Ranguemont_Pass/npcs/Myffore.lua | 19 | 1073 | -----------------------------------
-- Area: Ranguemont Pass
-- NPC: Myffore
-- Type: NPC
-- @pos -179.951 4 -172.234 166
-----------------------------------
package.loaded["scripts/zones/Ranguemont_Pass/TextIDs"] = nil;
-----------------------------------
-----------------------------------
-- onTrade Action
---... | gpl-3.0 |
ashkanpj/uzzfire | plugins/gnuplot.lua | 622 | 1813 | --[[
* Gnuplot plugin by psykomantis
* dependencies:
* - gnuplot 5.00
* - libgd2-xpm-dev (on Debian distr) for more info visit: https://libgd.github.io/pages/faq.html
*
]]
-- Gnuplot needs absolute path for the plot, so i run some commands to find where we are
local outputFile = io.popen("pwd","r")
io.input(outputFile... | gpl-2.0 |
shingenko/darkstar | scripts/zones/Throne_Room/npcs/_4l4.lua | 51 | 1172 | -----------------------------------
-- Area: Throne Room
-- NPC: Ore Door
-------------------------------------
require("scripts/globals/bcnm");
-----------------------------------
-- onTrade Action
-----------------------------------
function onTrade(player,npc,trade)
if (TradeBCNM(player,player:ge... | gpl-3.0 |
wagonrepairer/Zero-K | units/amphcon.lua | 4 | 2830 | unitDef = {
unitname = [[amphcon]],
name = [[Conch]],
description = [[Amphibious Construction Bot, Builds at 7.5 m/s]],
acceleration = 0.4,
activateWhenBuilt = true,
brakeRate = 0.25,
buildCostEnergy = 180,
buildCostMetal = 180,
buildDistan... | gpl-2.0 |
fridolin2/morethings_modpack | morethings_nature/flower_powder.lua | 1 | 2803 |
-- flower_powder, bonemeal recipes
minetest.register_craft({
type = "shapeless",
output = 'ethereal:bonemeal 2',
recipe = {"morethings_items:bone"},
})
minetest.register_craft({
type = "shapeless",
output = 'morethings_nature:flower_powder 4',
recipe = {"ethereal:bone","group:dye" },
})
minetest.register_c... | gpl-3.0 |
ArcherSys/ArcherSys | Lua/examples/luacom/wmi/wmi_obj.lua | 4 | 4292 | --[[
Example Lua Object for using Windows Managment and Instrumentation via LuaCom
This object is meant to be used as a class to create other objects.
Contributed by Michael Cumming
--]]
require("luacom")
cWMI = {
New = function (self)
o = {}
setmetatable (o,self)
self.__index = self
return o
end,... | mit |
shingenko/darkstar | scripts/zones/Bastok_Mines/npcs/Tibelda.lua | 36 | 1405 | -----------------------------------
-- Area: Bastok Mines
-- NPC: Tibelda
-- Only sells when Bastok controlls Valdeaunia Region
-----------------------------------
require("scripts/globals/shop");
require("scripts/globals/conquest");
package.loaded["scripts/zones/Bastok_Mines/TextIDs"] = nil;
require("scripts... | gpl-3.0 |
diz-vara/nn | BCECriterion.lua | 12 | 2712 | local BCECriterion, parent = torch.class('nn.BCECriterion', 'nn.Criterion')
local eps = 1e-12
function BCECriterion:__init(weights, sizeAverage)
parent.__init(self)
if sizeAverage ~= nil then
self.sizeAverage = sizeAverage
else
self.sizeAverage = true
end
if weights ~= nil then
... | bsd-3-clause |
shingenko/darkstar | scripts/zones/Port_San_dOria/npcs/Diraulate.lua | 36 | 1375 | -----------------------------------
-- Area: Port San d'Oria
-- NPC: Diraulate
-- Standard Info NPC
-----------------------------------
package.loaded["scripts/zones/Port_San_dOria/TextIDs"] = nil;
-----------------------------------
require("scripts/globals/quests");
require("scripts/zones/Port_San_dOria/Tex... | gpl-3.0 |
sirinsidiator/ESO-AetheriusBadgeFilter | src/data/TheNobleMerchants.lua | 1 | 6313 | AetheriusBadgeFilter:RegisterGuild(
AetheriusBadgeFilter.SERVER_EU,
"The Noble Merchants",
{
{
name = "Special",
badges = {
{
name = "Partisan",
description = "Awarded to a very select individual who has been |cB45F04inc... | artistic-2.0 |
jyggen/lua-parser | tests/Fixtures/4d/23/27/acf663761d1688b91f8c65bfb1c2f900e69ea401277ac8f1d133c2e5a6.lua | 1 | 2095 |
AmrDb = {
["Talents"] = {
},
["LastCharacterImportDate"] = "",
["SendSettings"] = {
["SendTo"] = "",
["SendGems"] = true,
["SendEnchants"] = true,
["SendEnchantMaterials"] = true,
["SendToType"] = "a friend",
},
["CharacterName"] = "Zealotry",
["Race"] = "BloodElf",
["ActiveSpec"] = 1,
["Level"] = 5... | mit |
kveratis/GameCode4 | Assets/Scripts/TeapotStates.lua | 44 | 13650 | --========================================================================
-- ActorManager.lua : Defines all the states for an AI controlled teapot
--
-- Part of the GameCode4 Application
--
-- GameCode4 is the sample application that encapsulates much of the source code
-- discussed in "Game Coding Complete - 4t... | lgpl-3.0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.