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 |
|---|---|---|---|---|---|
Unrepentant-Atheist/mame | scripts/src/emu.lua | 2 | 10016 | -- license:BSD-3-Clause
-- copyright-holders:MAMEdev Team
---------------------------------------------------------------------------
--
-- emu.lua
--
-- Rules for building emu cores
--
---------------------------------------------------------------------------
project ("emu")
uuid ("e6fa15e4-a354-4526-acef-13c8e... | gpl-2.0 |
EliHar/Pattern_recognition | torch1/extra/nn/Replicate.lua | 18 | 1682 | local Replicate, parent = torch.class('nn.Replicate','nn.Module')
function Replicate:__init(nf, dim, ndim)
parent.__init(self)
self.nfeatures = nf
self.dim = dim or 1
self.ndim = ndim
assert(self.dim > 0, "Can only replicate across positive integer dimensions.")
end
function Replicate:updateOutput(inpu... | mit |
EliHar/Pattern_recognition | torch1/install/share/lua/5.1/nn/Replicate.lua | 18 | 1682 | local Replicate, parent = torch.class('nn.Replicate','nn.Module')
function Replicate:__init(nf, dim, ndim)
parent.__init(self)
self.nfeatures = nf
self.dim = dim or 1
self.ndim = ndim
assert(self.dim > 0, "Can only replicate across positive integer dimensions.")
end
function Replicate:updateOutput(inpu... | mit |
paulu/deepfeatinterp | models/facemodel/datasets/transforms.lua | 1 | 7154 | --
-- Copyright (c) 2016, Facebook, Inc.
-- All rights reserved.
--
-- This source code is licensed under the BSD-style license found in the
-- LICENSE file in the root directory of this source tree. An additional grant
-- of patent rights can be found in the PATENTS file in the same directory.
--
-- Image transf... | gpl-3.0 |
dhakust/galvera | backup/config/rc.lua | 1 | 22850 | -- FILE: rc.lua
-- PATH: ~/.config/awesome
-- DATE: 2018-06-26
-- AUTH: David Hannon <dhakust@gmail.com>
-- TYPE: Configuration File - Awesome WM (Lua)
--[[ NOTES & TO-DO LIST:
--]]
-- Standard awesome library
local gears = require("gears")
local awful = require("awful")
require("awful.autofocus")
-- Widget and la... | gpl-3.0 |
EliHar/Pattern_recognition | torch1/install/share/lua/5.1/fftw3/defines.lua | 4 | 1484 | local ffi=require 'ffi'
local defines = {}
function defines.register_hashdefs(fftw, C)
fftw.MEASURE = 0
fftw.DESTROY_INPUT = 1
fftw.UNALIGNED = 2
fftw.CONSERVE_MEMORY = 4
fftw.EXHAUSTIVE = 8 -- /* NO_EXHAUSTIVE is default */
fftw.PRESERVE_INPUT = 16 -- /* cancels DESTROY_INPUT */
fftw.PATIENT =32 ... | mit |
notcake/glib | lua/glib/resources/resourcecache.lua | 1 | 4847 | local self = {}
GLib.Resources.ResourceCache = GLib.MakeConstructor (self)
function self:ctor ()
self.LastAccessTimes = {}
self.NeedsSaving = false
self:LoadLastAccessTimes ()
timer.Create ("GLib.Resources.ResourceCache.PruneCache", 300, 1,
function ()
self:PruneCache ()
end
)
concomm... | gpl-3.0 |
rlcevg/Zero-K | effects/paris.lua | 12 | 4272 | -- paris_glow
-- paris
-- paris_gflash
-- paris_sphere
return {
["paris_glow"] = {
glow = {
air = true,
class = [[CSimpleParticleSystem]],
count = 2,
ground = true,
water = true,
properties = {
airdrag ... | gpl-2.0 |
lynx-seu/skynet | lualib/redis.lua | 47 | 4975 | local skynet = require "skynet"
local socket = require "socket"
local socketchannel = require "socketchannel"
local table = table
local string = string
local redis = {}
local command = {}
local meta = {
__index = command,
-- DO NOT close channel in __gc
}
---------- redis response
local redcmd = {}
redcmd[36] = f... | mit |
ViolyS/RayUI_VS | Interface/AddOns/RayUI/libs/oUF/elements/raidroleindicator.lua | 3 | 2598 | --[[
# Element: Raid Role Indicator
Handles the visibility and updating of an indicator based on the unit's raid assignment (main tank or main assist).
## Widget
RaidRoleIndicator - A `Texture` representing the unit's raid assignment.
## Notes
This element updates by changing the texture.
## Examples
-- Posi... | mit |
SneakyB/iceball | pkg/iceball/halp/texts.lua | 4 | 3463 | texts = {}
texts.main = tparse([==[
$cFFFFFF55Welcome to Iceball!
Seeing as people don't know what
reading is, we're moving a quick
tutorial to here.
Use your up/down arrow keys to
scroll through the text.
Please read this whole document
carefully, as it contains
important information, and we
don't want to have to t... | gpl-3.0 |
joaocc/ta3d-git | src/ta3d/src/luajit/src/jit/bcsave.lua | 20 | 18123 | ----------------------------------------------------------------------------
-- LuaJIT module to save/list bytecode.
--
-- Copyright (C) 2005-2013 Mike Pall. All rights reserved.
-- Released under the MIT license. See Copyright Notice in luajit.h
-------------------------------------------------------------------------... | gpl-2.0 |
blueluna/tempserv | modules/radio.lua | 1 | 3945 | -- Radio package handling
--
-- (C) 2014 Erik Svensson <erik.public@gmail.com>
-- Licensed under MIT
local nrf24 = require("nrf24")
local decode = require("decode")
local time = require("time")
local string = require("string")
local Radio = { nrf = nil }
function Radio:open(spi_master, spi_device, ce_pin... | mit |
TeleBang/bangtg | plugins/filterfa.lua | 8 | 2538 | local function addword(msg, name)
local hash = 'chat:'..msg.to.id..':badword'
redis:hset(hash, name, 'newword')
return "کلمه جدید به فیلتر کلمات اضافه شد\n>"..name
end
local function get_variables_hash(msg)
return 'chat:'..msg.to.id..':badword'
end
local function list_variablesbad(msg)
local hash... | agpl-3.0 |
rlcevg/Zero-K | gamedata/modularcomms/weapons/rocketlauncher.lua | 6 | 1244 | local name = "commweapon_rocketlauncher"
local weaponDef = {
name = [[Rocket Launcher]],
areaOfEffect = 75,
cegTag = [[missiletrailred]],
craterBoost = 0,
craterMult = 0,
customParams = {
slot = [[5]],
muzzleEffectFire = [[cus... | gpl-2.0 |
abdllhbyrktr/Urho3D | Source/ThirdParty/toluapp/src/bin/lua/basic.lua | 24 | 9103 | -- tolua: basic utility functions
-- Written by Waldemar Celes
-- TeCGraf/PUC-Rio
-- Jul 1998
-- Last update: Apr 2003
-- $Id: $
-- 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 obligation to provide maintenance... | mit |
jacklanchantin/sclm | evaluate.lua | 1 | 1883 | require 'torch'
require 'nn'
require 'optim'
include('auRoc.lua')
torch.setdefaulttensortype('torch.FloatTensor')
local utils = require 'util.utils'
local unpack = unpack or table.unpack
local cmd = torch.CmdLine()
cmd:option('-file', './global_results.t7')
local opt = cmd:parse(arg)
results = torch.load(opt.f... | mit |
SonyWWS/SLED | tool/SledSyntaxEditor/Intellisense/Lua/StandardLibrary/basic.lua | 1 | 10155 | --[[
-- lua standard library -- Basic Functions
--]]
--[[
Issues an error when the value of its argument <em>v</em> is false (i.e., nil or false); otherwise, returns all its arguments.
<em>message</em> is an error message; when absent, it defaults to "assertion failed!"
--]]
function assert( v, message ) end
--[[... | apache-2.0 |
rlcevg/Zero-K | LuaRules/Gadgets/weapon_timed_replace.lua | 7 | 3216 | function gadget:GetInfo()
return {
name = "Weapon Timed Replace",
desc = "Replaces a projectile with another projectile a certain time after firing.",
author = "Google Frog",
date = "10 June 2014",
license = "GNU GPL, v2 or later",
layer = 0,
enabled = true,
}
e... | gpl-2.0 |
Jennal/cocos2dx-3.2-qt | cocos/scripting/lua-bindings/auto/api/ComAttribute.lua | 7 | 2283 |
--------------------------------
-- @module ComAttribute
-- @extend Component
-- @parent_module ccs
--------------------------------
-- @function [parent=#ComAttribute] getFloat
-- @param self
-- @param #string str
-- @param #float float
-- @return float#float ret (return value: float)
---------------------... | mit |
rlcevg/Zero-K | units/armaak.lua | 2 | 6778 | unitDef = {
unitname = [[armaak]],
name = [[Archangel]],
description = [[Heavy Anti-Air Jumper]],
acceleration = 0.18,
brakeRate = 0.2,
buildCostEnergy = 550,
buildCostMetal = 550,
buildPic = [[ARMAAK.png]],
buildTime = 5... | gpl-2.0 |
ViolyS/RayUI_VS | Interface/AddOns/Skada/modules/Enemies.lua | 1 | 12234 | Skada:AddLoadableModule("Enemies", nil, function(Skada, L)
if Skada.db.profile.modulesBlocked.Enemies then return end
local done = Skada:NewModule(L["Enemy damage done"])
local taken = Skada:NewModule(L["Enemy damage taken"])
local hdone = Skada:NewModule(L["Enemy healing done"])
local htaken = Skada:NewModule(L[... | mit |
SneakyB/iceball | pkg/iceball/pmfedit/main_client.lua | 4 | 7945 | --[[
This file is part of Ice Lua Components.
Ice Lua Components 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.
... | gpl-3.0 |
ikstream/Minstrel-Blues | measurement/minstrel-measurement/tests/tshark.lua | 2 | 1753 | require ('misc')
local tshark_bin = "/usr/bin/tshark"
--local fname = "/home/denis/data-udp-07.04.2017-HT40-40-far-all.bak/tp4300/tp4300-14-4-10-10M-1.pcap"
--local fname = "/home/denis/data-udp-27.04.2017-C13-HT20-noani-ldpc/tp3600/tp3600-7-10-d10-10M-1.pcap"
local fname = "/home/denis/data-udp-27.04.2017-C13-HT20-an... | gpl-2.0 |
SonyWWS/SLED | src/sledluaplugin/libsce_sledluaplugin-5.1.4.lua | 1 | 1209 | -- Copyright (C) Sony Computer Entertainment America LLC.
-- All Rights Reserved.
--
-- Dependencies
--
include "../../wws_lua/lua-5.1.4/src/lua-5.1.4.lua"
--
-- Premake build script for the libsce_sledluaplugin-5.1.4 library
--
sdk_project "libsce_sledluaplugin-5.1.4"
sdk_location "."
sdk_kind "Library"
targ... | apache-2.0 |
rlcevg/Zero-K | LuaRules/Gadgets/CustomUnitShaders/UnitMaterials/1_normalmapping.lua | 17 | 4460 | -- $Id$
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
local materials = {
normalMappedS3o = {
shaderDefinitions = {
"#define use_perspective_correct_shadows",
"#define use_nor... | gpl-2.0 |
EliHar/Pattern_recognition | torch1/extra/cudnn/SpatialSoftMax.lua | 1 | 3323 | local SpatialSoftMax, parent = torch.class('cudnn.SpatialSoftMax', 'nn.Module')
local errcheck = cudnn.errcheck
function SpatialSoftMax:__init(fast)
parent.__init(self)
if fast then
self.algorithm = 'CUDNN_SOFTMAX_FAST'
else
self.algorithm = 'CUDNN_SOFTMAX_ACCURATE'
end
end
function SpatialSof... | mit |
EliHar/Pattern_recognition | torch1/install/share/lua/5.1/optim/adadelta.lua | 6 | 2125 | --[[ ADADELTA implementation for SGD http://arxiv.org/abs/1212.5701
ARGS:
- `opfunc` : a function that takes a single input (X), the point of
evaluation, and returns f(X) and df/dX
- `x` : the initial point
- `config` : a table of hyper-parameters
- `config.rho` : interpolation parameter
- `config.eps` : f... | mit |
Satoshi-t/Re-SBS | lua/ai/bgm-ai.lua | 1 | 46165 | sgs.ai_skill_invoke.chongzhen = function(self, data)
local target = data:toPlayer()
if self:isFriend(target) then
if hasManjuanEffect(self.player) then return false end
if self:needKongcheng(target) and target:getHandcardNum() == 1 then return true end
if self:getOverflow(target) > 2 then return true end
retu... | gpl-3.0 |
TeleBang/bangtg | plugins/fun.lua | 7 | 31685 |
do
--------------------------
local function savefile(extra, success, result)
local msg = extra.msg
local name = extra.name
local adress = extra.adress
local receiver = get_receiver(msg)
if success then
local file = './'..adress..'/'..name..''
print('File saving to:', result)
os.rename... | agpl-3.0 |
zhuhangyu/ABTestingGateway | lib/abtesting/error/errcode.lua | 22 | 1583 | local modulename = 'abtestingErrorInfo'
local _M = {}
_M._VERSION = '0.0.1'
_M.info = {
-- index code desc
-- SUCCESS
["SUCCESS"] = { 200, 'success '},
-- System Level ERROR
['REDIS_ERROR'] = { 40101, 'redis error for '},
['POLICY_DB_ERROR'] = { 40102, 'policy in db error '... | mit |
rlcevg/Zero-K | LuaRules/Configs/StartBoxes/Terra.lua | 1 | 2335 | local layout = {
[0] = {{
{Game.mapSizeX / 2, 1},
{0, 1},
{0, 2233.623046875},
{59.700881958008, 2221.083984375},
{151.52703857422, 2230.8056640625},
{261.55853271484, 2215.4636230469},
{426.48919677734, 2209.6975097656},
{575.38916015625, 2204.8198242188},
{710.96252441406, 2178.3088378906}... | gpl-2.0 |
joaocc/ta3d-git | src/ta3d/src/luajit/src/host/genminilua.lua | 73 | 11943 | ----------------------------------------------------------------------------
-- Lua script to generate a customized, minified version of Lua.
-- The resulting 'minilua' is used for the build process of LuaJIT.
----------------------------------------------------------------------------
-- Copyright (C) 2005-2013 Mike P... | gpl-2.0 |
soniccol/OpenRedAlert_TW | mods/common/lua/supportpowers.lua | 3 | 1963 | SupportPowers = { }
SupportPowers.Airstrike = function(owner, planeName, enterLocation, bombLocation)
local facing = { Map.GetFacing(CPos.op_Subtraction(bombLocation, enterLocation), 0), "Int32" }
local center = WPos.op_Addition(Map.CenterOfCell(enterLocation), WVec.New(0, 0, Rules.InitialAltitude(planeName)))
loca... | gpl-3.0 |
VladimirTyrin/wireshark | epan/wslua/dtd_gen.lua | 38 | 8369 | -- dtd_gen.lua
--
-- a DTD generator for wireshark
--
-- (c) 2006 Luis E. Garcia Ontanon <luis@ontanon.org>
--
-- Wireshark - Network traffic analyzer
-- By Gerald Combs <gerald@wireshark.org>
-- Copyright 1998 Gerald Combs
--
-- This program is free software; you can redistribute it and/or
-- modify it under the terms... | gpl-2.0 |
Satoshi-t/Re-SBS | lua/ai/wind-ai.lua | 1 | 34230 | sgs.ai_skill_use["@@shensu1"]=function(self,prompt)
self:updatePlayers()
self:sort(self.enemies,"defense")
if self.player:containsTrick("lightning") and self.player:getCards("j"):length()==1
and self:hasWizard(self.friends) and not self:hasWizard(self.enemies, true) then
return "."
end
if self:needBear() the... | gpl-3.0 |
rlcevg/Zero-K | LuaUI/Widgets/tipdispenser.lua | 6 | 15941 | local widgetName = "Automatic Tip Dispenser"
local playerID = Spring.GetMyPlayerID()
local rank = playerID and select(9, Spring.GetPlayerInfo(playerID))
function widget:GetInfo()
return {
name = widgetName,
desc = "v0.4 Teach you to play the game, one tip at a time",
author = "KingRaptor; original by zwzsg",
... | gpl-2.0 |
rlcevg/Zero-K | gamedata/modularcomms/weapons/disintegrator.lua | 1 | 1066 | local name = "commweapon_disintegrator"
local weaponDef = {
name = [[Disintegrator]],
areaOfEffect = 48,
avoidFeature = false,
avoidFriendly = false,
avoidNeutral = false,
commandfire = true,
craterBoost = 1,
craterMult ... | gpl-2.0 |
ViolyS/RayUI_VS | Interface/AddOns/RayUI_Options/libs/AceGUI-3.0-SharedMediaWidgets/Libs/AceGUI-3.0/widgets/AceGUIWidget-Button.lua | 1 | 2459 | --[[-----------------------------------------------------------------------------
Button Widget
Graphical Button.
-------------------------------------------------------------------------------]]
local Type, Version = "Button", 21
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidget... | mit |
weirdouncle/QSanguosha-For-Hegemony-personal | lang/zh_CN/Audio/StandardWeiLines.lua | 7 | 3764 | --[[********************************************************************
Copyright (c) 2013-2015 Mogara
This file is part of QSanguosha-Hegemony.
This game 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... | gpl-3.0 |
juefeix/lbcnn.torch | RandomBinaryConvolution.lua | 1 | 1187 | -- RandomBinaryConvolution.lua
local THNN = require 'nn.THNN'
local RandomBinaryConvolution, parent = torch.class('cudnn.RandomBinaryConvolution', 'cudnn.SpatialConvolution')
function RandomBinaryConvolution:__init(nInputPlane, nOutputPlane, kW, kH, dW, dH, padW, padH)
parent.__init(self, nInputPlane, nOutputPlane... | mit |
rlcevg/Zero-K | units/factorygunship.lua | 5 | 4568 | unitDef = {
unitname = [[factorygunship]],
name = [[Gunship Plant]],
description = [[Produces Gunships, Builds at 10 m/s]],
acceleration = 0,
brakeRate = 0,
buildCostEnergy = 600,
buildCostMe... | gpl-2.0 |
yangboz/bugfree-bugfixes | CocosJSGame/frameworks/js-bindings/cocos2d-x/external/lua/luasocket/ltn12.lua | 71 | 8331 | -----------------------------------------------------------------------------
-- LTN12 - Filters, sources, sinks and pumps.
-- LuaSocket toolkit.
-- Author: Diego Nehab
-----------------------------------------------------------------------------
------------------------------------------------------------------------... | mit |
Amadiro/obtuse-tanuki | libs/material-love/init.lua | 2 | 2257 | local material = {
_VERSION = 'material-love v1.0.0',
_DESCRIPTION = 'Implementation of parts of the Material-Design spec, for LOVE',
_URL = 'https://www.github.com/Positive07/material-love',
_LICENSE = [[
The Material Design Icon font is Licensed under SIL Open Font License 1.1
https://github.c... | mit |
EliHar/Pattern_recognition | torch1/install/share/lua/5.1/pl/dir.lua | 5 | 15858 | --
-- Dependencies: `pl.utils`, `pl.path`, `pl.tablex`
--
-- Soft Dependencies: `alien`, `ffi` (either are used on Windows for copying/moving files)
-- @module pl.dir
local utils = require 'pl.utils'
local path = require 'pl.path'
local is_windows = path.is_windows
local tablex = require 'pl.tablex'
local ldir = path.... | mit |
medialab-prado/Interactivos-15-Ego | minetest-ego/games/adventuretest/mods/mobs/monsters/yeti.lua | 1 | 1152 | mobs:register_mob("mobs:snow_monster", {
type = "monster",
hp_min = 10,
hp_max = 35,
exp_min = 3,
exp_max = 35,
collisionbox = {-0.35,-1.0,-0.35, 0.35,0.8,0.35},
visual = "mesh",
mesh = "character.x",
textures = {"mobs_snow_monster.png"},
visual_size = {x=1, y=1},
makes_footstep_sound = true,
view_range = 1... | mit |
anholt/ValyriaTear | dat/effects/particles/shield_big_sprites.lua | 3 | 2438 | --defensive stance particle effect, big sprites version
-- Author: Bertram
systems = {}
systems[0] =
{
enabled = true,
emitter =
{
x = 0,
y = -128,
x2 = 0, --useless when using a circle shape
y2 = 0, --useless when using a circle shape
center_x = 0, --useless when... | gpl-2.0 |
Jigoku/boxclip | src/entities/enemies/spike_timer.lua | 1 | 2999 | --[[
* Copyright (C) 2015 - 2022 Ricky K. Thomson
*
* 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 3 of the License, or
* (at your option) any later version.
* This progr... | gpl-3.0 |
drmingdrmer/mysql-proxy-xp | lib/ro-balance.lua | 40 | 6646 | --[[ $%BEGINLICENSE%$
Copyright (c) 2007, 2009, Oracle and/or its affiliates. All rights reserved.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; version 2 of the
License.
This program is dis... | gpl-2.0 |
cailyoung/CommandPost | src/plugins/finalcutpro/watchers/version.lua | 1 | 3621 | --------------------------------------------------------------------------------
--------------------------------------------------------------------------------
-- F I N A L C U T P R O V E R S I O N --
-----------------------------------------------------------------------------... | mit |
notcake/glib | lua/glib/garrysmod/net/layer1/pinnednetinbuffer.lua | 2 | 1148 | local self = {}
GLib.Net.Layer1.PinnedNetInBuffer = GLib.MakeConstructor (self, GLib.Net.InBuffer)
function self:ctor (netInBuffer, position, data)
self.PositionOffset = position - 1
self.InBuffer = GLib.StringInBuffer (data)
end
function self:GetBytesRemaining ()
return self.InBuffer:GetBytesRemaining ()
end
fun... | gpl-3.0 |
rlcevg/Zero-K | LuaUI/Widgets/unit_auto_set_retreat60.lua | 6 | 5109 | local versionNumber = "1.3"
function widget:GetInfo()
return {
name = "Auto Set Retreat @60",
desc = "[v" .. string.format("%s", versionNumber ) .. "] Automatically set units when built to 'Retreat at 60% health', support /luaui reload (re-set retreat for every unit). Based on 'Auto Retreat' by CarRepairer",
aut... | gpl-2.0 |
pielover88888/denice | lua/greeting.lua | 2 | 1117 | -- callback for user joining a channel
function greeting_join_callback(event, origin, params)
local nick = sql_escape(origin)
local t = sql_query_fetch("SELECT `Greeting` FROM `greeting` WHERE `Nick` = '" .. nick .. "'")
if #t > 0 and t[1].Greeting ~= nil and t[1].Greeting:len() > 0 then
irc_msg(params[1], t[1].Gr... | mit |
naserteam/hextor | plugins/invite.lua | 2 | 1202 | do
local function callbackres(extra, success, result) -- Callback for res_user in line 27
local user = 'user#id'..result.id
local chat = 'chat#id'..extra.chatid
if is_banned(result.id, extra.chatid) then -- Ignore bans
send_large_msg(chat, 'این کاربر بن است')
elseif is_gbanned(result.id) then -- ... | gpl-2.0 |
ViolyS/RayUI_VS | Interface/AddOns/WorldQuestTab/libs/LibStub/LibStub.lua | 184 | 1367 | -- LibStub is a simple versioning stub meant for use in Libraries. http://www.wowace.com/wiki/LibStub for more info
-- LibStub is hereby placed in the Public Domain Credits: Kaelten, Cladhaire, ckknight, Mikk, Ammo, Nevcairiel, joshborke
local LIBSTUB_MAJOR, LIBSTUB_MINOR = "LibStub", 2 -- NEVER MAKE THIS AN SVN REVI... | mit |
cailyoung/CommandPost | src/extensions/cp/strings/init.lua | 1 | 4388 | --- === cp.strings ===
---
--- Provides strings from (potentially) multiple sources, with support for loading from multiple languages.
---
--- ```lua
--- local strs = require("cp.strings").new():fromPlist("/Path/To/Resources/${language}.lproj/MYLocalization.strings")
--- local value = strs:find("en", "AKey")
--- ```
--... | mit |
rlcevg/Zero-K | scripts/cruisemissile.lua | 7 | 1222 | include "constants.lua"
local base = piece 'base'
function script.AimWeapon1(heading, pitch) return true end
local function RemoveMissile()
Spring.SetUnitNoSelect(unitID, true)
Spring.SetUnitNoDraw(unitID, true)
Spring.SetUnitNoMinimap(unitID, true)
Spring.SetUnitHealth(unitID, {paralyze=99999999})
Spring.SetU... | gpl-2.0 |
ViolyS/RayUI_VS | Interface/AddOns/GnomishVendorShrinker/GnomishVendorShrinker.lua | 1 | 14155 |
local myname, ns = ...
local ItemSearch = LibStub('LibItemSearch-1.0')
local NUMROWS, ICONSIZE, GAP, SCROLLSTEP = 14, 17, 4, 5
for _,f in pairs{MerchantNextPageButton, MerchantPrevPageButton, MerchantPageText} do
f:Hide()
f.Show = f.Hide
end
local GVS = CreateFrame("frame", nil, MerchantFrame)
GVS:SetWidth(31... | mit |
ViolyS/RayUI_VS | Interface/AddOns/RayUI/mini/BonusRollPreview/encounters/Legion.lua | 1 | 6176 | local _, ns = ...
ns.encounterInfo = ns.encounterInfo or {}
ns.itemBlacklist = ns.itemBlacklist or {}
-- http://www.wowhead.com/spells/uncategorized/name:Bonus?filter=84:109:16;1:6:7;::
for spellID, encounterInfo in next, {
--- World
[227128] = {1790, 822, 14}, -- Ana-Mouz
[227129] = {1774, 822, 14}, -- Ca... | mit |
avatani83/teleseed | plugins/invite.lua | 1 | 1192 | do
local function callbackres(extra, success, result) -- Callback for res_user in line 27
local user = 'user#id'..result.id
local chat = 'chat#id'..extra.chatid
if is_banned(result.id, extra.chatid) then -- Ignore bans
send_large_msg(chat, 'User is banned.')
elseif is_gbanned(result.id) then -- I... | gpl-2.0 |
cxiao/chdkptp-old | lua/extras/msgtest.lua | 5 | 4789 | --[[
Copyright (C) 2010-2014 <reyalp (at) gmail dot com>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License version 2 as
published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
bu... | gpl-2.0 |
cailyoung/CommandPost | src/plugins/finalcutpro/notifications/pushover.lua | 1 | 14601 | --------------------------------------------------------------------------------
--------------------------------------------------------------------------------
-- P U S H O V E R N O T I F I C A T I O N S --
-----------------------------------------------------------------------------... | mit |
VladimirTyrin/wireshark | test/lua/pcre_sets.lua | 35 | 6911 | -- See Copyright Notice in the file lrexlib.h
local luatest = require "luatest"
local N = luatest.NT
local function norm(a) return a==nil and N or a end
local function fill (n, m)
local t = {}
for i = n, m, -1 do table.insert (t, i) end
return t
end
local function set_named_subpatterns (lib, flg)
return {
... | gpl-2.0 |
SneakyB/iceball | pkg/base/plug_pmfedit.lua | 4 | 5869 | --[[
This file is part of Ice Lua Components.
Ice Lua Components 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.
... | gpl-3.0 |
cloudkick/ck-agent | src/lua/remote/test_util.lua | 1 | 4890 | -- -- Copyright 2012 Rackspace
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compli... | apache-2.0 |
avdimdv/proxmark3 | client/scripts/dumptoemul.lua | 10 | 2939 | -- The getopt-functionality is loaded from pm3/getopt.lua
-- Have a look there for further details
getopt = require('getopt')
bin = require('bin')
example = "script run dumptoemul -i dumpdata-foobar.bin"
author = "Martin Holst Swende"
usage = "script run dumptoemul [-i <file>] [-o <file>]"
desc =[[
This script takes a... | gpl-2.0 |
rlcevg/Zero-K | LuaRules/Gadgets/mod_stats.lua | 7 | 7701 | -- $Id: unit_noselfpwn.lua 3171 2008-11-06 09:06:29Z det $
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
function gadget:GetInfo()
return {
name = "Mod statistics",
desc = "Gathers mo... | gpl-2.0 |
stas2z/openwrt-witi | package/luci/protocols/luci-proto-vpnc/luasrc/model/cbi/admin_network/proto_vpnc.lua | 7 | 3343 | -- Copyright 2015 Daniel Dickinson <openwrt@daniel.thecshore.com>
-- Licensed to the public under the Apache License 2.0.
local map, section, net = ...
local server, username, password, hexpassword
local authgroup, interface, passgroup, hexpassgroup
local domain, vendor, natt_mode, dh_group
local pfs, enable_single_d... | gpl-2.0 |
doorxp/ccjson | cocos2d/plugin/luabindings/auto/api/lua_cocos2dx_pluginx_auto_api.lua | 146 | 1793 | --------------------------------
-- @module plugin
--------------------------------------------------------
-- the plugin PluginProtocol
-- @field [parent=#plugin] PluginProtocol#PluginProtocol PluginProtocol preloaded module
--------------------------------------------------------
-- the plugin PluginManager
-- @fi... | gpl-3.0 |
imashkan/ashifire | bot/seedbot.lua | 1 | 9427 | 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 |
Jennal/cocos2dx-3.2-qt | cocos/scripting/lua-bindings/auto/api/Animate.lua | 6 | 1297 |
--------------------------------
-- @module Animate
-- @extend ActionInterval
-- @parent_module cc
--------------------------------
-- @overload self
-- @overload self
-- @function [parent=#Animate] getAnimation
-- @param self
-- @return Animation#Animation ret (retunr value: cc.Animation)
--------... | mit |
stas2z/openwrt-witi | package/luci/applications/luci-app-qos/luasrc/model/cbi/qos/qos.lua | 17 | 2481 | -- Copyright 2008 Steven Barth <steven@midlink.org>
-- Licensed to the public under the Apache License 2.0.
local wa = require "luci.tools.webadmin"
local fs = require "nixio.fs"
m = Map("qos", translate("Quality of Service"),
translate("With <abbr title=\"Quality of Service\">QoS</abbr> you " ..
"can prioritize n... | gpl-2.0 |
stas2z/openwrt-witi | package/luci/applications/luci-app-diag-devinfo/luasrc/model/cbi/luci_diag/smap_devinfo_mini.lua | 141 | 1031 | --[[
smap_devinfo - SIP Device Information
(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.i18n")
re... | gpl-2.0 |
Amadiro/obtuse-tanuki | libs/winapi/wglext.lua | 2 | 23164 |
--proc/wglext: opengl WGL API from wglext.h
--Written by Cosmin Apreutesei. Public Domain.
setfenv(1, require'winapi')
require'winapi.winuser'
require'gl_types'
WGL_WGLEXT_VERSION = 24
-- WGL_ARB_buffer_region
WGL_FRONT_COLOR_BUFFER_BIT_ARB = 0x00000001
WGL_BACK_COLOR_BUFFER_BIT_ARB = 0x00000002
WGL_DEPTH_BUFFER_B... | mit |
cloudkick/ck-agent | src/lua/remote/check_disk.lua | 1 | 4247 | -- -- Copyright 2012 Rackspace
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compli... | apache-2.0 |
Amadiro/obtuse-tanuki | systems/render.lua | 2 | 3518 | local tiny = require "tiny"
local cpml = require "cpml"
local utils = require "utils"
return function(camera)
local render_system = tiny.system()
render_system.filter = tiny.requireAll("model_matrix", "mesh", tiny.rejectAny("needs_reload"))
render_system.camera = camera
Signal.register('client-network-id', func... | mit |
rlcevg/Zero-K | units/tele_beacon.lua | 3 | 2252 | unitDef = {
unitname = [[tele_beacon]],
name = [[Lamp]],
description = [[Teleport Bridge Entry Beacon, right click to teleport.]],
acceleration = 0,
brakeRate = 0,
buildAngle = 4096,
bui... | gpl-2.0 |
joole/private-pkgs | luci/applications/luci-app-shadowsocksR/files/usr/lib/lua/luci/model/cbi/shadowsocksr/gfwlist.lua | 1 | 3675 |
local fs = require "nixio.fs"
local china_file = "/etc/ssrr/china_route"
local user_local_file = "/etc/ssrr/user_local_ip"
local user_remote_file = "/etc/ssrr/user_remote_ip"
function sync_value_to_file(value, file)
value = value:gsub("\r\n?", "\n")
local old_value = nixio.fs.readfile(file)
if value ~= old_value ... | gpl-2.0 |
anholt/ValyriaTear | dat/maps/mt_elbrus/mt_elbrus_cave1_map.lua | 1 | 63501 | map_data = {}
-- The number of rows, and columns that compose the map
map_data.num_tile_cols = 50
map_data.num_tile_rows = 40
-- The tilesets definition files used.
map_data.tileset_filenames = {}
map_data.tileset_filenames[1] = "dat/tilesets/desert_cave_ground.lua"
-- The map grid to indicate walkability. 0 is walk... | gpl-2.0 |
ViolyS/RayUI_VS | Interface/AddOns/RayUI/modules/skins/blizzard/bags.lua | 1 | 1411 | ----------------------------------------------------------
-- Load RayUI Environment
----------------------------------------------------------
RayUI:LoadEnv("Skins")
local S = _Skins
local function LoadSkin()
local r, g, b = _r, _g, _b
S:ReskinCheck(TokenFramePopupInactiveCheckBox)
S:ReskinCheck(TokenFramePopupB... | mit |
ploxiln/janus-gateway | plugins/lua/janus-sdp.lua | 2 | 11922 | -- Set of utilities for parsing, processing and managing Janus SDPs in Lua,
-- as the C Janus SDP utils that Janus provides are unavailable otherwise
local JANUSSDP = {}
function JANUSSDP.parse(text)
if text == nil then
return nil
end
local lines = {}
local s = nil
for s in text:gmatch("[^\r\n]+") do
table.i... | gpl-3.0 |
rlcevg/Zero-K | scripts/fighter.lua | 6 | 3987 | include "constants.lua"
--pieces
local base, flare1, flare2, nozzle1, nozzle2, missile, rgun, lgun, rwing, lwing, rjet, ljet, body
= piece("base", "flare1", "flare2", "nozzle1", "nozzle2", "missile", "rgun", "lgun", "rwing", "lwing", "rjet", "ljet", "body")
local smokePiece = {base, rwing, lwing}
--variables
local... | gpl-2.0 |
EliHar/Pattern_recognition | torch1/extra/penlight/lua/pl/utils.lua | 6 | 14946 | --- Generally useful routines.
-- See @{01-introduction.md.Generally_useful_functions|the Guide}.
-- @module pl.utils
local format,gsub,byte = string.format,string.gsub,string.byte
local compat = require 'pl.compat'
local clock = os.clock
local stdout = io.stdout
local append = table.insert
local unpack = rawget(_G,'u... | mit |
Amadiro/obtuse-tanuki | libs/iqm/init.lua | 2 | 5774 | local base = (...):gsub('%.init$', '') .. "."
local c = require(base .. "iqm-ffi")
local ffi = require "ffi"
local iqm = {}
iqm.lookup = {}
function iqm.load(file)
assert(love.filesystem.isFile(file))
-- Make sure it's a valid IQM file first
local magic = love.filesystem.read(file, 16)
assert(magic == "INTERQUA... | mit |
rlcevg/Zero-K | LuaUI/Widgets/chili/Controls/font.lua | 17 | 6639 | --//=============================================================================
Font = Object:Inherit{
classname = 'font',
font = "FreeSansBold.otf",
size = 12,
outlineWidth = 3,
outlineWeight = 3,
shadow = false,
outline = false,
color = {1,1,1,1},
out... | gpl-2.0 |
ViolyS/RayUI_VS | Interface/AddOns/Skada/Skada.lua | 1 | 84710 | local Skada = LibStub("AceAddon-3.0"):NewAddon("Skada", "AceTimer-3.0", "LibNotify-1.0")
_G.Skada = Skada
local L = LibStub("AceLocale-3.0"):GetLocale("Skada", false)
local ldb = LibStub:GetLibrary("LibDataBroker-1.1")
local icon = LibStub("LibDBIcon-1.0", true)
local media = LibStub("LibSharedMedia-3.0")
local boss =... | mit |
mightymadTV/gcraft | gcraft/gamemode/cl_hudpickup.lua | 3 | 6359 |
GM.PickupHistory = {}
GM.PickupHistoryLast = 0
GM.PickupHistoryTop = ScrH() / 2
GM.PickupHistoryWide = 300
GM.PickupHistoryCorner = surface.GetTextureID( "gui/corner8" )
--[[---------------------------------------------------------
Name: gamemode:HUDWeaponPickedUp( wep )
Desc: The game wants you to draw on the H... | gpl-2.0 |
medialab-prado/Interactivos-15-Ego | minetest-ego/games/minetest_game/mods/beds/functions.lua | 1 | 5209 | local pi = math.pi
local player_in_bed = 0
local is_sp = minetest.is_singleplayer()
local enable_respawn = minetest.setting_getbool("enable_bed_respawn")
if enable_respawn == nil then
enable_respawn = true
end
-- helper functions
local function get_look_yaw(pos)
local n = minetest.get_node(pos)
if n.param2 == 1 t... | mit |
Jeffyrao/nn | CMul.lua | 24 | 3600 | local CMul, parent = torch.class('nn.CMul', 'nn.Module')
function CMul:__init(...)
parent.__init(self)
local arg = {...}
self.size = torch.LongStorage()
local n = #arg
if n == 1 and torch.type(arg[1]) == 'torch.LongStorage' then
self.size:resize(#arg[1]):copy(arg[1])
else
self.size:r... | bsd-3-clause |
kindy/ltp | ltp/template.lua | 3 | 5946 | --
-- Copyright 2007-2008 Savarese Software Research Corporation.
--
-- 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.savarese.com/software/ApacheLicense-2.0
--
-- Unless... | apache-2.0 |
premake/premake-eclipse | eclipse_project.lua | 1 | 3769 | --
-- Name: eclipse/eclipse_project.lua
-- Purpose: Generate a Eclipse .project file.
-- Author: Manu Evans
-- Created: 2014/12/22
-- Copyright: (c) 2008-2014 Jason Perkins and the Premake project
--
local p = premake
local eclipse = p.modules.eclipse
local tree = p.tree
local project = p.p... | bsd-3-clause |
rlcevg/Zero-K | units/corhlt.lua | 4 | 6799 | unitDef = {
unitname = [[corhlt]],
name = [[Stinger]],
description = [[High-Energy Laser Tower]],
acceleration = 0,
brakeRate = 0,
buildAngle = 4096,
buildCostEnergy = 420,... | gpl-2.0 |
naserteam/hextor | bot/utils.lua | 2 | 23606 | 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 |
samyk/proxmark3 | client/luascripts/data_mf_eml2html.lua | 1 | 2299 | -- The getopt-functionality is loaded from pm3/getopt.lua
-- Have a look there for further details
getopt = require('getopt')
bin = require('bin')
dumplib = require('html_dumplib')
local ansicolors = require('ansicolors')
copyright = ''
author = 'Martin Holst Swende'
version = 'v1.0.2'
desc = [[
This script takes a d... | gpl-2.0 |
joole/private-pkgs | luci/applications/luci-app-vpnbypass/luasrc/model/cbi/vpnbypass.lua | 6 | 2362 | readmeURL = "https://github.com/openwrt/packages/blob/master/net/vpnbypass/files/README.md"
m = Map("vpnbypass", translate("VPN Bypass Settings"))
s = m:section(NamedSection, "config", "vpnbypass")
-- General options
e = s:option(Flag, "enabled", translate("Enable/start service"))
e.rmempty = false
function e.cfgval... | gpl-2.0 |
Amadiro/obtuse-tanuki | states/login.lua | 2 | 4490 | local tiny = require "tiny"
local gui = require "quickie"
local avatar = require "avatar"
local material = require "material-love"
-- This state is active from username entry until we get account and realm info
return function()
local gs = tiny.system()
gs.name = "login"
function gs:enter(from, world)
... | mit |
Satoshi-t/Re-SBS | lang/zh_CN/Mini.lua | 3 | 1973 | return {
["MiniScene"]= "小型场景",
["_mini_1"] = "狭路相逢",
["_mini_2"] = "谁与争锋",
["_mini_3"] = "青梅煮酒",
["_mini_4"] = "遗命与天运",
["_mini_5"] = "直刺咽喉",
["_mini_6"] = "围追堵截",
["_mini_7"] = "铁与血与火",
["_mini_8"] = "天下无双",
["_mini_9"] = "你死我活",
["_mini_10"] = "步步惊心",
["_mini_11"] = "措手不及",
["_mini_12"] = "翻云覆雨",
["_mi... | gpl-3.0 |
Satoshi-t/Re-SBS | lang/zh_CN/Package/YJCMPackage.lua | 1 | 7677 | -- translation for YJCM Package
return {
["YJCM"] = "一将成名",
["#caozhi"] = "八斗之才",
["caozhi"] = "曹植",
["designer:caozhi"] = "Foxear",
["illustrator:caozhi"] = "木美人",
["luoying"] = "落英",
[":luoying"] = "其他角色的牌因判定或弃置而置入弃牌堆时,你可以获得其中至少一张梅花牌。",
["jiushi"] = "酒诗",
[":jiushi"] = "若你的武将牌正面朝上,你可以将武将牌翻面,视为你使用了一张【酒】。每当你... | gpl-3.0 |
avataronline/avatarclient | modules/game_hotkeys/hotkeys_manager.lua | 5 | 17268 | HOTKEY_MANAGER_USE = nil
HOTKEY_MANAGER_USEONSELF = 1
HOTKEY_MANAGER_USEONTARGET = 2
HOTKEY_MANAGER_USEWITH = 3
HotkeyColors = {
text = '#888888',
textAutoSend = '#FFFFFF',
itemUse = '#8888FF',
itemUseSelf = '#00FF00',
itemUseTarget = '#FF0000',
itemUseWith = '#F5B325',
}
hotkeysManagerLoaded = false
hotk... | mit |
AlexMili/torch-dataframe | specs/dataframe/column_spec.lua | 1 | 9692 | require 'lfs'
-- Ensure the test is launched within the specs/ folder
assert(string.match(lfs.currentdir(), "specs")~=nil, "You must run this test in specs folder")
local initial_dir = lfs.currentdir()
-- Go to specs folder
while (not string.match(lfs.currentdir(), "/specs$")) do
lfs.chdir("..")
end
local specs_d... | mit |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.