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 |
|---|---|---|---|---|---|
mahdisudo/best | plugins/inrealm.lua | 850 | 25085 | -- 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_g... | gpl-2.0 |
taeasy/packages | net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/interface.lua | 28 | 9746 | -- ------ extra functions ------ --
function interfaceCheck() -- find issues with too many interfaces, reliability and metric
uci.cursor():foreach("mwan3", "interface",
function (section)
local interfaceName = section[".name"]
interfaceNumber = interfaceNumber+1 -- count number of mwan interfaces configured
... | gpl-2.0 |
luvit/luvit | tests/test-ffi.lua | 14 | 1511 | --[[
Copyright 2015 The Luvit Authors. All Rights Reserved.
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
Unless required by applicable law or agr... | apache-2.0 |
haider1984/-1 | plugins/ar-plugins.lua | 13 | 7118 | --[[
▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀
▀▄ ▄▀ ▀▄ ▄▀
▀▄ ▄▀ BY SAJJAD NOORI ▀▄ ▄▀
▀▄ ▄▀ BY SAJAD NOORI (@SAJJADNOORI) ▀▄ ▄▀
▀▄ ▄▀ JUST WRITED BY SAJJAD NOORI ▀▄ ▄▀
▀▄ ▄▀ plugins : تفعيل الملفات ▀▄ ▄▀
▀▄▀... | gpl-2.0 |
xdel/snabbswitch | src/lib/protocol/ipv4.lua | 4 | 5232 | module(..., package.seeall)
local ffi = require("ffi")
local C = ffi.C
local lib = require("core.lib")
local header = require("lib.protocol.header")
local ipsum = require("lib.checksum").ipsum
-- TODO: generalize
local AF_INET = 2
local INET_ADDRSTRLEN = 16
local ipv4hdr_t = ffi.typeof[[
struct {
uint16_t... | apache-2.0 |
zturtleman/quakeconstruct | code/debug/lua/tests/vampiric.lua | 2 | 2650 | downloader.add("lua/tests/cl_vampiric.lua")
local function PlayerDamaged(self,inflictor,attacker,damage,meansOfDeath)
local force = nil
if(self != nil and attacker != nil) then
local targ_tab = GetEntityTable(self);
if(targ_tab) then
targ_tab.wait = 0
end
local hp2 = self:GetInfo()["health"]
if((... | gpl-2.0 |
githubtelebot/Telebot | plugins/media.lua | 376 | 1679 | do
local function run(msg, matches)
local receiver = get_receiver(msg)
local url = matches[1]
local ext = matches[2]
local file = download_to_file(url)
local cb_extra = {file_path=file}
local mime_type = mimetype.get_content_type_no_sub(ext)
if ext == 'gif' then
print('send_file')
send_docum... | gpl-2.0 |
wcjscm/JackGame | src/cocos/cocos2d/DeprecatedOpenglEnum.lua | 148 | 11934 | -- This is the DeprecatedEnum
DeprecatedClass = {} or DeprecatedClass
_G.GL_RENDERBUFFER_INTERNAL_FORMAT = gl.RENDERBUFFER_INTERNAL_FORMAT
_G.GL_LINE_WIDTH = gl.LINE_WIDTH
_G.GL_CONSTANT_ALPHA = gl.CONSTANT_ALPHA
_G.GL_BLEND_SRC_ALPHA = gl.BLEND_SRC_ALPHA
_G.GL_GREEN_BITS = gl.GREEN_BITS
_G.GL_STENCIL_REF = gl.STENCI... | gpl-3.0 |
xing634325131/Luci-0.11.1 | modules/niu/luasrc/model/cbi/niu/wireless/bridge.lua | 51 | 2481 | local uci = require "luci.model.uci"
local cursor = uci.cursor()
if not cursor:get("wireless", "bridge") then
cursor:section("wireless", "wifi-iface", "bridge",
{device = "_", doth = "1", _niu = "1", mode = "sta", wds = "1"})
cursor:save("wireless")
end
local function deviceroute(self)
cursor:unload("wireless")
... | apache-2.0 |
pm234md/pm233 | plugins/ingroup.lua | 371 | 44212 | do
-- Check Member
local function check_member_autorealm(cb_extra, success, result)
local receiver = cb_extra.receiver
local data = cb_extra.data
local msg = cb_extra.msg
for k,v in pairs(result.members) do
local member_id = v.id
if member_id ~= our_id then
-- Group configuration
data[tostr... | gpl-2.0 |
T3hArco/skeyler-gamemodes | Sassilization/entities/effects/cast_heal/init.lua | 1 | 1275 | function EFFECT:Init( data )
self.Position = data:GetStart()
self.WeaponEnt = data:GetEntity()
self.Scale = data:GetScale()
self.Magnitude = data:GetMagnitude()
self.LifeSpan = CurTime() + self.Magnitude
self.MaxLifeSpan = CurTime() + self.Magnitude
self.StartAlpha = 255
self.Emitter = ParticleEmit... | bsd-3-clause |
MrCerealGuy/Stonecraft | games/stonecraft_game/mods/ethereal/extra.lua | 1 | 8418 |
local S = ethereal.intllib
-- Etherium Dust
minetest.register_craftitem("ethereal:etherium_dust", {
description = S("Etherium Dust"),
inventory_image = "ethereal_etherium_dust.png",
wield_image = "ethereal_etherium_dust.png",
})
-- Ethereium Ore
minetest.register_node("ethereal:etherium_ore", {
description = S("... | gpl-3.0 |
wcjscm/JackGame | frameworks/cocos2d-x/cocos/scripting/lua-bindings/auto/api/PositionFrame.lua | 18 | 1745 |
--------------------------------
-- @module PositionFrame
-- @extend Frame
-- @parent_module ccs
--------------------------------
--
-- @function [parent=#PositionFrame] getX
-- @param self
-- @return float#float ret (return value: float)
--------------------------------
--
-- @function [parent=#PositionF... | gpl-3.0 |
wcjscm/JackGame | frameworks/cocos2d-x/cocos/scripting/lua-bindings/auto/api/MenuItemSprite.lua | 5 | 2889 |
--------------------------------
-- @module MenuItemSprite
-- @extend MenuItem
-- @parent_module cc
--------------------------------
-- Enables or disables the item.
-- @function [parent=#MenuItemSprite] setEnabled
-- @param self
-- @param #bool bEnabled
-- @return MenuItemSprite#MenuItemSprite self (return value:... | gpl-3.0 |
MrCerealGuy/Stonecraft | games/stonecraft_game/mods/ethereal/ores.lua | 1 | 2208 |
-- Baked Clay
minetest.register_ore({
ore_type = "blob",
ore = "bakedclay:red",
wherein = {"bakedclay:orange"},
clust_scarcity = 4 * 4 * 4,
clust_num_ores = 8,
clust_size = 6,
y_min = -10,
y_max = 71,
noise_params = {
offset = 0.35,
scale = ... | gpl-3.0 |
MrCerealGuy/Stonecraft | games/stonecraft_game/mods/plantlife_modpack/woodsoils/init.lua | 1 | 1369 | -----------------------------------------------------------------------------------------------
local title = "Wood Soils" -- former "Forest Soils"
local version = "0.0.9"
local mname = "woodsoils" -- former "forestsoils"
-----------------------------------------------------------------------------------------------
... | gpl-3.0 |
tonicbupt/flynn | cli/Tupfile.lua | 6 | 1517 | tup.export("GOPATH")
tup.export("GIT_COMMIT")
tup.export("GIT_BRANCH")
tup.export("GIT_TAG")
tup.export("GIT_DIRTY")
tup.rule({"../util/rubyassetbuilder/*", "../util/cedarish/<docker>"},
"^ docker build installer-builder^ cat ../log/docker-cedarish.log > /dev/null && ../util/rubyassetbuilder/build.sh image i... | bsd-3-clause |
SLAPaper/MCGC | MCGC/c84130857.lua | 3 | 1072 | -- 来自植吧的使者
function c84130857.initial_effect(c)
local e1 = Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DRAW + CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(c84130857.sptarget)
e1:SetOperation(c84130857.operation)
c:RegisterEffect(e1)
... | mit |
xing634325131/Luci-0.11.1 | applications/luci-commands/luasrc/controller/commands.lua | 76 | 5959 | --[[
LuCI - Lua Configuration Interface
Copyright 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
]]--
module("... | apache-2.0 |
payday-restoration/restoration-mod | lua/managers/hud/HUDDodge.lua | 1 | 3716 | HUDDodgeMeter = HUDDodgeMeter or class()
function HUDDodgeMeter:init(hud)
self._hud_panel = hud.panel
self._dodge_meter_panel = managers.hud:script(PlayerBase.PLAYER_INFO_HUD_PD2).panel:panel({
name = "dodge_meter_init",
layer = 0,
visible = true,
valign = "center",
y = 0
})
self._dodge_panel = self._do... | agpl-3.0 |
heysion/prosody-modules | mod_statistics_statsd/mod_statistics_statsd.lua | 32 | 1307 | local statsmanager = require "core.statsmanager";
local udp = require "socket".udp();
local server = module:get_option_string("statsd_server_ip", "127.0.0.1");
local server_port = module:get_option_number("statsd_server_port", 8124);
local max_datagram_size = module:get_option_number("statds_packet_size", 512);
funct... | mit |
T3hArco/skeyler-gamemodes | ssbase/entities/entities/ent_smokegrenade/init.lua | 1 | 1039 | ----------------------------
-- SSBase --
-- Created by Skeyler.com --
----------------------------
AddCSLuaFile( "cl_init.lua" )
AddCSLuaFile( "shared.lua" )
include('shared.lua')
function ENT:Initialize()
self.Entity:SetModel("models/weapons/w_eq_smokegrenade.mdl")
self.Entity:... | bsd-3-clause |
pirate/snabbswitch | src/program/packetblaster/packetblaster.lua | 6 | 2365 | module(..., package.seeall)
local engine = require("core.app")
local config = require("core.config")
local timer = require("core.timer")
local pci = require("lib.hardware.pci")
local intel10g = require("apps.intel.intel10g")
local intel_app = require("apps.intel.intel_app")
local basic_apps = require(... | apache-2.0 |
QuiQiJingFeng/skynet | service/clusterd.lua | 5 | 5193 | local skynet = require "skynet"
local sc = require "skynet.socketchannel"
local socket = require "skynet.socket"
local cluster = require "skynet.cluster.core"
local config_name = skynet.getenv "cluster"
local node_address = {}
local node_session = {}
local command = {}
local function read_response(sock)
local sz = s... | mit |
emoon/sico | bin/win32/scripts/tundra/syntax/bison.lua | 8 | 1220 | module(..., package.seeall)
local nodegen = require "tundra.nodegen"
local path = require "tundra.path"
local depgraph = require "tundra.depgraph"
local _bison_mt = nodegen.create_eval_subclass {}
local bison_blueprint = {
Source = { Required = true, Type = "string" },
OutputFile = { Required = false, Type = "st... | mit |
emoon/sico | bin/macosx/tundra/scripts/tundra/syntax/bison.lua | 8 | 1220 | module(..., package.seeall)
local nodegen = require "tundra.nodegen"
local path = require "tundra.path"
local depgraph = require "tundra.depgraph"
local _bison_mt = nodegen.create_eval_subclass {}
local bison_blueprint = {
Source = { Required = true, Type = "string" },
OutputFile = { Required = false, Type = "st... | mit |
dmccuskey/dmc-gestures | examples/gesture-memtest/dmc_corona/dmc_gestures/tap_gesture.lua | 10 | 7687 | --====================================================================--
-- dmc_corona/dmc_gesture/tap_gesture.lua
--
-- Documentation: http://docs.davidmccuskey.com/dmc-gestures
--====================================================================--
--[[
The MIT License (MIT)
Copyright (c) 2015 David McCuskey
Per... | mit |
dieg0vb/sysdig | userspace/sysdig/chisels/v_procs_cpu.lua | 8 | 2785 | --[[
Copyright (C) 2013-2015 Draios inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License version 2 as
published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without... | gpl-2.0 |
T3hArco/skeyler-gamemodes | Sassilization/entities/entities/building_city/cl_init.lua | 1 | 4908 | ----------------------------------------
-- Sassilization
-- http://sassilization.com
-- By Sassafrass / Spacetech / LuaPineapple
----------------------------------------
include("shared.lua")
TerritoryWhite = CreateMaterial( "TerritoryWhite1", "UnLitGeneric", {
["$basetexture"] = "color/white",
["$ve... | bsd-3-clause |
wcjscm/JackGame | frameworks/cocos2d-x/cocos/scripting/lua-bindings/auto/api/Terrain.lua | 6 | 6015 |
--------------------------------
-- @module Terrain
-- @extend Node
-- @parent_module cc
--------------------------------
-- initialize heightMap data
-- @function [parent=#Terrain] initHeightMap
-- @param self
-- @param #string heightMap
-- @return bool#bool ret (return value: bool)
----------------------... | gpl-3.0 |
dmccuskey/dmc-gestures | examples/gesture-tap-basic/dmc_corona/dmc_gestures/gesture_manager.lua | 10 | 12537 | --====================================================================--
-- dmc_corona/dmc_gesture/gesture_manager.lua
--
-- Documentation: http://docs.davidmccuskey.com/dmc-gestures
--====================================================================--
--[[
The MIT License (MIT)
Copyright (c) 2015 David McCuskey
... | mit |
wcjscm/JackGame | frameworks/cocos2d-x/cocos/scripting/lua-bindings/auto/api/MenuItemFont.lua | 11 | 2660 |
--------------------------------
-- @module MenuItemFont
-- @extend MenuItemLabel
-- @parent_module cc
--------------------------------
-- Returns the name of the Font.<br>
-- js getFontNameObj<br>
-- js NA
-- @function [parent=#MenuItemFont] getFontNameObj
-- @param self
-- @return string#string ret (return value:... | gpl-3.0 |
MrCerealGuy/Stonecraft | games/stonecraft_game/mods/unified_inventory/internal.lua | 1 | 13659 | local S = minetest.get_translator("unified_inventory")
local F = minetest.formspec_escape
local ui = unified_inventory
-- This pair of encoding functions is used where variable text must go in
-- button names, where the text might contain formspec metacharacters.
-- We can escape button names for the formspec, to avoi... | gpl-3.0 |
spixi/wesnoth | data/ai/micro_ais/cas/ca_messenger_move.lua | 2 | 5409 | local AH = wesnoth.require "ai/lua/ai_helper.lua"
local messenger_next_waypoint = wesnoth.require "ai/micro_ais/cas/ca_messenger_f_next_waypoint.lua"
local ca_messenger_move = {}
function ca_messenger_move:evaluation(cfg)
-- Move the messenger toward goal, potentially attack adjacent unit
local messenger = ... | gpl-2.0 |
shahabsaf1/copy | plugins/inpm.lua | 1114 | 3008 | 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 |
pm234md/pm233 | plugins/inpm.lua | 1114 | 3008 | 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 |
payday-restoration/restoration-mod | lua/sc/states/missionendstate.lua | 1 | 18274 | function MissionEndState:at_enter(old_state, params)
managers.environment_effects:stop_all()
local is_safe_house = managers.job:current_job_data() and managers.job:current_job_id() == "safehouse"
managers.platform:set_presence("Mission_end")
if not is_safe_house then
local rp_state = nil
if table.contains({... | agpl-3.0 |
o-jasper/alt_require.lua | alt_require/alt_require.lua | 1 | 2161 | local already_found = {}
-- Wonder why lua doesnt expose something like this already.
local function findfile(package_str)
if already_found[package_str] then return already_found[package_str] end
local pos = string.gsub(package_str, "[.]", "/")
for at in string.gmatch(package.path, "[^;]+") do
local cur... | mit |
logzero/ValyriaTear | dat/maps/layna_village/layna_village_bronanns_home_map.lua | 3 | 30491 | map_data = {}
-- The number of rows, and columns that compose the map
map_data.num_tile_cols = 32
map_data.num_tile_rows = 24
-- The tilesets definition files used.
map_data.tileset_filenames = {}
map_data.tileset_filenames[1] = "dat/tilesets/building_interior_objects_01.lua"
map_data.tileset_filenames[2] = "dat/tile... | gpl-2.0 |
haider1984/-1 | plugins/en-robot.lua | 7 | 2245 | --[[
▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀
▀▄ ▄▀ ▀▄ ▄▀
▀▄ ▄▀ BY SAJJAD NOORI ▀▄ ▄▀
▀▄ ▄▀ BY SAJAD NOORI (@SAJJADNOORI) ▀▄ ▄▀
▀▄ ▄▀ JUST WRITED BY SAJJAD NOORI ▀▄ ▄▀
▀▄ ▄▀ bot was disabled on specific chat ▀▄ ▄▀
▀▄▀... | gpl-2.0 |
spixi/wesnoth | data/campaigns/Eastern_Invasion/lua/bandits.lua | 4 | 3403 | -- Used for the bandit villages in S5. Much more specific than the village spawn implementations elsewhere,
-- since there are a lot more specific things needed (mostly the boss mechanics and village spreading)
local helper = wesnoth.require "helper"
local wml_actions = wesnoth.wml_actions
local _ = wesnoth.textdomain... | gpl-2.0 |
Djabbz/nn | VolumetricConvolution.lua | 39 | 1702 | local VolumetricConvolution, parent = torch.class('nn.VolumetricConvolution', 'nn.Module')
function VolumetricConvolution:__init(nInputPlane, nOutputPlane, kT, kW, kH, dT, dW, dH)
parent.__init(self)
dT = dT or 1
dW = dW or 1
dH = dH or 1
self.nInputPlane = nInputPlane
self.nOutputPlane = nOutputPl... | bsd-3-clause |
payday-restoration/restoration-mod | lua/sc/units/props/drill.lua | 1 | 6070 | Drill.on_hit_autorepair_chance = 0.75
Hooks:PostHook(Drill, "start", "res_start", function(self)
managers.groupai:state():set_area_min_police_force(self._unit:key(), 3, self._unit:position())
end)
Hooks:PostHook(Drill, "done", "res_done", function(self)
managers.groupai:state():set_area_min_police_force(self._unit:... | agpl-3.0 |
luvit/luvit | examples/app/libs/stack.lua | 8 | 2993 | --[[
Copyright 2012 The Luvit Authors. All Rights Reserved.
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
Unless required by applicable law or agr... | apache-2.0 |
ahmadreza5251/terojanbot | plugins/google.lua | 722 | 1037 | local function googlethat(query)
local api = "http://ajax.googleapis.com/ajax/services/search/web?v=1.0&"
local parameters = "q=".. (URL.escape(query) or "")
-- Do the request
local res, code = https.request(api..parameters)
if code ~=200 then return nil end
local data = json:decode(res)
local r... | gpl-2.0 |
amirkingred/telejian | plugins/google.lua | 722 | 1037 | local function googlethat(query)
local api = "http://ajax.googleapis.com/ajax/services/search/web?v=1.0&"
local parameters = "q=".. (URL.escape(query) or "")
-- Do the request
local res, code = https.request(api..parameters)
if code ~=200 then return nil end
local data = json:decode(res)
local r... | gpl-2.0 |
kroepke/luna | luna-tests/src/test/resources/benchmarksgame/meteor.lua | 1 | 5605 | -- The Computer Language Benchmarks Game
-- http://benchmarksgame.alioth.debian.org/
-- contributed by Mike Pall
-- Generate a decision tree based solver for the meteor puzzle.
local function generatesolver(countinit)
local pairs, ipairs, format = pairs, ipairs, string.format
local byte, min, sort = string.byt... | apache-2.0 |
dmccuskey/dmc-gestures | dmc_corona/dmc_gestures/longpress_gesture.lua | 10 | 10296 | --====================================================================--
-- dmc_corona/dmc_gesture/longpress_gesture.lua
--
-- Documentation: http://docs.davidmccuskey.com/dmc-gestures
--====================================================================--
--[[
The MIT License (MIT)
Copyright (c) 2015 David McCuske... | mit |
MrCerealGuy/Stonecraft | games/stonecraft_game/mods/default/mapgen.lua | 2 | 58698 | --
-- Aliases for map generators
--
-- All mapgens
minetest.register_alias("mapgen_stone", "default:stone")
minetest.register_alias("mapgen_water_source", "default:water_source")
minetest.register_alias("mapgen_river_water_source", "default:river_water_source")
-- Additional aliases needed for mapgen v6
minetest.re... | gpl-3.0 |
pydsigner/naev | dat/missions/neutral/reynir.lua | 5 | 5171 | --[[
MISSION: Hot dogs from space
DESCRIPTION: An old man who owns a hot dog factory wants to go to space
The old man has elevated pressure in his cochlea so he can't go to space.
He's getting old and wants to go to space before he dies. He owns a hot dog
factory and will pay you in hot dogs (food). Be... | gpl-3.0 |
wcjscm/JackGame | frameworks/cocos2d-x/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua | 2 | 7899 |
--------------------------------
-- @module TMXLayer
-- @extend Node
-- @parent_module ccexp
--------------------------------
-- Returns the position in points of a given tile coordinate.<br>
-- param tileCoordinate The tile Coordinate.<br>
-- return The position in points of a given tile coordinate.
-- @function [p... | gpl-3.0 |
rbavishi/vlc-2.2.1 | share/lua/playlist/pinkbike.lua | 97 | 2080 | --[[
$Id$
Copyright © 2009 the VideoLAN team
Authors: Konstantin Pavlov (thresh@videolan.org)
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your opt... | lgpl-2.1 |
T3hArco/skeyler-gamemodes | ssbase/gamemode/__backup/storeitems/hats/fedora.lua | 2 | 2599 | ----------------------------
-- SSBase --
-- Created by Skeyler.com --
----------------------------
ITEM.ID = "fedora" -- Should be a unique string that identifies the item
ITEM.Name = "Fedora" -- The name the item should display
ITEM.Price = 2000
ITEM.Model = "models/captain... | bsd-3-clause |
panozzaj/ufo2000 | extensions/weapons-galactic/galactic weapons.lua | 2 | 36062 | AddXcomItem {
cost = 50,
name = "ZAP PISTOL",
pInv = png_image("$(extension)/galactic/pInv/zp.png" ),
pMap = png_image("$(extension)/galactic/pMap/zp.png" ),
health = 100,
importance = 5,
width = 1,
height = 2,
ammo = {"ZAP PISTOL CHARGE"},
pHeld = {
png_image("$(extension)/g... | gpl-2.0 |
wcjscm/JackGame | frameworks/cocos2d-x/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua | 18 | 3117 |
--------------------------------
-- @module RelativeLayoutParameter
-- @extend LayoutParameter
-- @parent_module ccui
--------------------------------
-- Sets RelativeAlign parameter for LayoutParameter.<br>
-- see RelativeAlign<br>
-- param align Relative align in `RelativeAlign`.
-- @function [parent=#RelativeLayo... | gpl-3.0 |
wcjscm/JackGame | frameworks/cocos2d-x/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua | 6 | 4516 |
--------------------------------
-- @module LoadingBar
-- @extend Widget
-- @parent_module ccui
--------------------------------
-- Changes the progress value of LoadingBar.<br>
-- param percent Percent value from 1 to 100.
-- @function [parent=#LoadingBar] setPercent
-- @param self
-- @param #float percent
-- @re... | gpl-3.0 |
McGlaspie/mvm | lua/mvm/ArmsLab.lua | 1 | 6505 |
Script.Load("lua/mvm/LiveMixin.lua")
Script.Load("lua/mvm/TeamMixin.lua")
Script.Load("lua/mvm/SelectableMixin.lua")
Script.Load("lua/mvm/LOSMixin.lua")
Script.Load("lua/mvm/ConstructMixin.lua")
Script.Load("lua/mvm/GhostStructureMixin.lua")
Script.Load("lua/mvm/FireMixin.lua")
Script.Load("lua/mvm/WeldableMixin.lua")... | gpl-3.0 |
drdownload/prosody-modules | mod_motd_sequential/mod_motd_sequential.lua | 32 | 1482 | -- Prosody IM
-- Copyright (C) 2008-2010 Matthew Wild
-- Copyright (C) 2008-2010 Waqas Hussain
-- Copyright (C) 2010 Jeff Mitchell
--
-- This project is MIT/X11 licensed. Please see the
-- COPYING file in the source package for more information.
--
local host = module:get_host();
local motd_jid = module:get_option("mo... | mit |
KateAdams/lua-autoyield | example.lua | 1 | 1235 | #!/usr/bin/env lua
coroutine.autoyield = require("autoyield").autoyield
local socket = require("socket")
local server = socket.bind("*", 5555)
local function send_data(threadid)
while true do
local cl
while not cl do
server:settimeout(0)
cl = server:accept() -- TODO: make all C calls "auto yield until the... | gpl-3.0 |
MrCerealGuy/Stonecraft | games/stonecraft_game/mods/technic/technic/machines/MV/wind_mill.lua | 1 | 2911 |
local S = technic.getter
minetest.register_craft({
output = 'technic:wind_mill_frame 5',
recipe = {
{'technic:carbon_steel_ingot', '', 'technic:carbon_steel_ingot'},
{'', 'technic:carbon_steel_ingot', ''},
{'technic:carbon_steel_ingot', '', ... | gpl-3.0 |
salorium/awesome | lib/gears/debug.lua | 4 | 2547 | ---------------------------------------------------------------------------
-- @author Uli Schlachter
-- @copyright 2010 Uli Schlachter
-- @release @AWESOME_VERSION@
-- @module gears.debug
---------------------------------------------------------------------------
local tostring = tostring
local print = print
local ty... | gpl-2.0 |
OpenRA/OpenRA | mods/ra/scripts/campaign.lua | 7 | 2229 | --[[
Copyright 2007-2022 The OpenRA Developers (see AUTHORS)
This file is part of OpenRA, which is free software. It is made
available to you 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 vers... | gpl-3.0 |
fucksooN/tabchi | libs/fakeredis.lua | 650 | 40405 | local unpack = table.unpack or unpack
--- Bit operations
local ok,bit
if _VERSION == "Lua 5.3" then
bit = (load [[ return {
band = function(x, y) return x & y end,
bor = function(x, y) return x | y end,
bxor = function(x, y) return x ~ y end,
bnot = function(x) return ~x end,
rshift = function(x... | unlicense |
dgf/pgx-rest | rest.lua | 1 | 4076 | -- calls the generic SQL route function and renders the result
-- requirements
local misc = require("misc")
local cjson = require("cjson.safe")
local rparser = require("rds.parser")
-- get uri, headers, method, ...
local body = "{}" -- default body is empty
local ctype = ngx.req.get_headers().content_type
local metho... | mit |
Djabbz/nn | Jacobian.lua | 33 | 13475 | nn.Jacobian = {}
function nn.Jacobian.backward(module, input, param, dparam)
local doparam = 0
if param then
doparam = 1
end
param = param or input
-- output deriv
module:forward(input)
local dout = module.output.new():resizeAs(module.output)
-- 1D view
local sdout = module.output.new(... | bsd-3-clause |
panozzaj/ufo2000 | init-scripts/standard-maps.lua | 2 | 16592 | ------------------------------------------------------------------------------
-- A place for standard x-com maps initialization. --
-- Editing this file is not recommended, better add new *.lua map init --
-- files into 'newmaps' subdirectory along with your *.map files --
-- ... | gpl-2.0 |
wcjscm/JackGame | frameworks/cocos2d-x/cocos/scripting/lua-bindings/auto/api/Physics3DShape.lua | 8 | 3047 |
--------------------------------
-- @module Physics3DShape
-- @extend Ref
-- @parent_module cc
--------------------------------
--
-- @function [parent=#Physics3DShape] getbtShape
-- @param self
-- @return btCollisionShape#btCollisionShape ret (return value: btCollisionShape)
------------------------------... | gpl-3.0 |
Djabbz/nn | SpatialAveragePooling.lua | 37 | 1063 | local SpatialAveragePooling, parent = torch.class('nn.SpatialAveragePooling', 'nn.Module')
function SpatialAveragePooling:__init(kW, kH, dW, dH)
parent.__init(self)
self.kW = kW
self.kH = kH
self.dW = dW or 1
self.dH = dH or 1
self.divide = true
end
function SpatialAveragePooling:updateOutput(input... | bsd-3-clause |
emoon/sico | bin/win32/scripts/tundra/syntax/install.lua | 28 | 1133 | -- install.lua - Express file copying in unit form.
module(..., package.seeall)
local nodegen = require "tundra.nodegen"
local files = require "tundra.syntax.files"
local path = require "tundra.path"
local util = require "tundra.util"
local depgraph = require "tundra.depgraph"
local _mt = nodegen.create_... | mit |
m2fan/ss | plugins/stats.lua | 168 | 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 |
salorium/awesome | lib/wibox/drawable.lua | 1 | 14137 | ---------------------------------------------------------------------------
--- Handling of drawables. A drawable is something that can be drawn to.
--
-- @author Uli Schlachter
-- @copyright 2012 Uli Schlachter
-- @release @AWESOME_VERSION@
-- @classmod wibox.drawable
--------------------------------------------------... | gpl-2.0 |
rbavishi/vlc-2.2.1 | share/lua/modules/dkjson.lua | 95 | 25741 | --[==[
David Kolf's JSON module for Lua 5.1/5.2
========================================
*Version 2.1*
This module writes no global values, not even the module table.
Import it using
json = require ("dkjson")
Exported functions and values:
`json.encode (object [, state])`
--------------------------------
... | lgpl-2.1 |
TgHelperTM/tghelper | libs/JSON.lua | 3765 | 34843 | -- -*- coding: utf-8 -*-
--
-- Simple JSON encoding and decoding in pure Lua.
--
-- Copyright 2010-2014 Jeffrey Friedl
-- http://regex.info/blog/
--
-- Latest version: http://regex.info/blog/lua/json
--
-- This code is released under a Creative Commons CC-BY "Attribution" License:
-- http://creativecommons.org/licenses... | gpl-3.0 |
logzero/ValyriaTear | dat/effects/status.lua | 3 | 22766 | ------------------------------------------------------------------------------[[
-- Filename: status.lua
--
-- Description: This file contains the implementations of all status effects.
-- The list of different types of status effects and their
-- corresponding names may be found in src/modes/common/global/global_effec... | gpl-2.0 |
hadirahimi1380/speedbot | plugins/ingroup.lua | 527 | 44020 | do
-- Check Member
local function check_member_autorealm(cb_extra, success, result)
local receiver = cb_extra.receiver
local data = cb_extra.data
local msg = cb_extra.msg
for k,v in pairs(result.members) do
local member_id = v.id
if member_id ~= our_id then
-- Group configuration
data[tostr... | gpl-2.0 |
ahmadreza5251/terojanbot | bot/bot.lua | 1 | 7107 | 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 |
m2fan/ss | plugins/google.lua | 336 | 1323 | do
local function googlethat(query)
local url = 'http://ajax.googleapis.com/ajax/services/search/web?v=1.0&safe=active&&rsz=5&'
local parameters = 'q='..(URL.escape(query) or '')
-- Do the request
local res, code = https.request(url..parameters)
if code ~=200 then return nil end
loca... | gpl-2.0 |
haider1984/-1 | plugins/owners.lua | 55 | 23720 | local function lock_group_namemod(msg, data, target)
local group_name_set = data[tostring(target)]['settings']['set_name']
local group_name_lock = data[tostring(target)]['settings']['lock_name']
if group_name_lock == 'yes' then
return 'Group name is already locked'
else
data[tostring(target)]['settings'... | gpl-2.0 |
SLAPaper/MCGC | MCGC/c84130811.lua | 2 | 2922 | -- MC群的战神 无情
function c84130811.initial_effect(c)
-- 不能特殊召唤
local e1 = Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE + EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
c:RegisterEffect(e1)
-- 攻击守备上升
local e2 = Effect.Create... | mit |
payday-restoration/restoration-mod | lua/sc/units/player/playerbipod.lua | 1 | 11080 | function PlayerBipod:_enter(enter_data)
local player = managers.player:player_unit()
if player and self._unit:base().is_local_player then
self._bipod = true
local tweak_data = self._equipped_unit:base():weapon_tweak_data()
local speed_multiplier = self._equipped_unit:base():get_property("bipod_deploy_multiplie... | agpl-3.0 |
emoon/sico | bin/win32/scripts/tundra/debugger.lua | 28 | 38532 |
--{{{ history
--15/03/06 DCN Created based on RemDebug
--28/04/06 DCN Update for Lua 5.1
--01/06/06 DCN Fix command argument parsing
-- Add step/over N facility
-- Add trace lines facility
--05/06/06 DCN Add trace call/return facility
--06/06/06 DCN Make it behave when stepping through the cr... | mit |
dieg0vb/sysdig | userspace/sysdig/chisels/v_errors.lua | 8 | 1879 | --[[
Copyright (C) 2013-2015 Draios inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License version 2 as
published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without... | gpl-2.0 |
upsoft/nginx-openresty-windows | LuaJIT-2.1-20150622/src/jit/dump.lua | 8 | 19845 | ----------------------------------------------------------------------------
-- LuaJIT compiler dump module.
--
-- Copyright (C) 2005-2015 Mike Pall. All rights reserved.
-- Released under the MIT license. See Copyright Notice in luajit.h
----------------------------------------------------------------------------
--
-... | bsd-2-clause |
MrCerealGuy/Stonecraft | games/stonecraft_game/mods/mesecons/mesecons_lamp/init.lua | 1 | 2266 | --[[
2017-01-06 modified by MrCerealGuy <mrcerealguy@gmx.de>
exit if mod is deactivated
--]]
if core.skip_mod("mesecons") then return end
-- MESELAMPS
-- A lamp is "is an electrical device used to create artificial light" (wikipedia)
-- guess what?
local mesecon_lamp_box = {
type = "wallmounted",
wall_top = {-0... | gpl-3.0 |
OpenRA/OpenRA | mods/d2k/maps/harkonnen-04/harkonnen04.lua | 7 | 7502 | --[[
Copyright 2007-2022 The OpenRA Developers (see AUTHORS)
This file is part of OpenRA, which is free software. It is made
available to you 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 vers... | gpl-3.0 |
QuiQiJingFeng/skynet | lualib/snax/interface.lua | 19 | 2153 | local skynet = require "skynet"
local function dft_loader(path, name, G)
local errlist = {}
for pat in string.gmatch(path,"[^;]+") do
local filename = string.gsub(pat, "?", name)
local f , err = loadfile(filename, "bt", G)
if f then
return f, pat
else
ta... | mit |
heysion/prosody-modules | mod_broadcast/mod_broadcast.lua | 32 | 1043 | local is_admin = require "core.usermanager".is_admin;
local allowed_senders = module:get_option_set("broadcast_senders", {});
local from_address = module:get_option_string("broadcast_from");
local jid_bare = require "util.jid".bare;
function send_to_online(message)
local c = 0;
for hostname, host_session in pairs(h... | mit |
MrCerealGuy/Stonecraft | games/stonecraft_game/mods/binoculars/init.lua | 1 | 1666 | -- binoculars/init.lua
-- Mod global namespace
binoculars = {}
-- Load support for MT game translation.
local S = minetest.get_translator("binoculars")
-- Update player property
-- Global to allow overriding
function binoculars.update_player_property(player)
local new_zoom_fov = 0
if player:get_inventory():con... | gpl-3.0 |
heysion/prosody-modules | mod_firewall/mod_firewall.lua | 31 | 13709 |
local resolve_relative_path = require "core.configmanager".resolve_relative_path;
local logger = require "util.logger".init;
local set = require "util.set";
local it = require "util.iterators";
local add_filter = require "util.filters".add_filter;
local definitions = module:shared("definitions");
local active_definit... | mit |
gajop/Zero-K | LuaUI/Widgets/camera_smoothcam.lua | 11 | 1846 | local versionNumber = "0.5"
function widget:GetInfo()
return {
name = "SmoothCam",
desc = "[v" .. string.format("%s", versionNumber ) .. "] Moves camera smoothly",
author = "very_bad_soldier",
date = "August, 8, 2010",
license = "GNU GPL, v2 or later",
layer = 0,
handler = true... | gpl-2.0 |
DustinMorado/tomoauto | src/lib/tomoauto/settings/tomoauto.lua | 1 | 1791 | --[[
Copyright (c) 2015 Dustin Reed Morado
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, publi... | mit |
KayMD/Illarion-Content | craft/gathering/honeygathering.lua | 1 | 8891 | --[[
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 |
jayman39tx/naev | dat/factions/equip/soromid.lua | 8 | 5453 | -- Generic equipping routines, helper functions and outfit definitions.
include("dat/factions/equip/generic.lua")
--[[
TODO PROPERLY FILL OUT!!!
Right now just using empire stuff as a temporary placeholder.
--]]
--[[
-- @brief Does soromid pilot equipping
--
-- @param p Pilot to equip
--]]
function equip( ... | gpl-3.0 |
hussian1997/bot-of-iraq | plugins/rdod.lua | 5 | 2376 | --[[
▀▄ ▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀▄▀▄▄▀▀▄▄▀▀▄▄▀▀▄▄▀▀
▀▄ ▄▀ ▀▄ ▄▀
▀▄ ▄▀ BY(@AHMED_ALOBIDE) ▀▄ ▄▀
▀▄ ▄▀ BY(@hussian_9) ▀▄ ▄▀
▀▄ ▄▀ ▀▄ ▄▀
▀▄ ▄▀ ملف الردود ▀▄ ▄▀
... | agpl-3.0 |
davidBelanger/nn | init.lua | 11 | 3390 | require('torch')
require('libnn')
include('utils.lua')
include('ErrorMessages.lua')
include('Module.lua')
include('Container.lua')
include('Concat.lua')
include('Parallel.lua')
include('Sequential.lua')
include('DepthConcat.lua')
include('Linear.lua')
include('SparseLinear.lua')
include('Reshape.lua')
include('View... | bsd-3-clause |
casseveritt/premake | src/actions/vstudio/vs2013.lua | 4 | 1490 | --
-- vs2013.lua
-- Baseline support for Visual Studio 2013.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
premake.vstudio.vc2013 = {}
local vc2013 = premake.vstudio.vc2013
local vstudio = premake.vstudio
---
-- Register a command-line action for Visual Studio 2013.
---
newaction
{
trigger... | bsd-3-clause |
jayman39tx/naev | dat/missions/neutral/drunkard.lua | 2 | 9087 | --[[
Drunkard
Author: geekt
A drunkard at the bar has gambled his ship into hock, and needs you to do a mission for him.
]]--
include "dat/scripts/numstring.lua"
-- Bar Description
bar_desc = _("You see a drunkard at the bar mumbling about how he was so close to getting his break.")
-- Mission Details
misn_... | gpl-3.0 |
kpkhxlgy0/SublimeText3 | Packages/FormatLua/metalua/compiler/parser.lua | 11 | 1512 | --------------------------------------------------------------------------------
-- Copyright (c) 2006-2013 Fabien Fleutot and others.
--
-- All rights reserved.
--
-- This program and the accompanying materials are made available
-- under the terms of the Eclipse Public License v1.0 which
-- accompanies this distribut... | mit |
Mutos/NAEV-StarsOfCall | dat/factions/equip/nasin.lua | 13 | 5011 | --more of a dummy file to avoid errors.
-- Generic equipping routines, helper functions and outfit definitions.
include("dat/factions/equip/generic.lua")
--[[
-- @brief Does sirius pilot equipping
--
-- @param p Pilot to equip
--]]
function equip( p )
-- Start with an empty ship
p:rmOutfit("all")
p:rmOutf... | gpl-3.0 |
wxguidesigner/wxGUIDesigner | build/premake/solution.lua | 1 | 1608 | -----------------------------------------------------------------------------
-- Name: solution.lua
-- Purpose: Generic Premake 4 solution defining common configurations
-- for all projects it contains.
-- Author: Andrea Zanellato
-- Modified by:
-- Created: 19/10/2011
-- Revision: ... | gpl-3.0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.