code
stringlengths
2
1.05M
repo_name
stringlengths
5
101
path
stringlengths
4
991
language
stringclasses
3 values
license
stringclasses
5 values
size
int64
2
1.05M
DarkRP.declareChatCommand{ command = "admintell", description = "Send a private, very intimidating message to someone.", delay = 1.5, tableArgs = true } DarkRP.declareChatCommand{ command = "admintellall", description = "Send a very intimidating message to everyone.", delay = 1.5 }
SingularityServers/singularity-addon
lua/darkrp_modules/hud/sh_chatcommands.lua
Lua
mit
312
-- Mergesort top down implementation -- See : http://en.wikipedia.org/wiki/Merge_sort#Top-down_implementation -- Splices a list from i to j local function slice(list, i, j) local t = {} for k = i, j do t[#t + 1] = list[k] end return t end -- Top down merge local function top_down_merge(left, right, comp) loca...
natuan241/Algorithm-Implementations
Merge_Sort/Lua/Yonaba/merge_sort.lua
Lua
mit
1,424
-- makes creatures [in]fertile, by modifying orientation -- usage: fix-ster [fert|ster] [all|animals|only:<creature>] -- original author: Tacomagic -- minor fixes by PeridexisErrant, Lethosor --@ module = true --[[=begin fix-ster ======== Utilizes the orientation tag to either fix infertile creatures or infl...
ev1l0rd/yalnpv
dfhack/hack/scripts/fix-ster.lua
Lua
mit
3,977
-- Copyright 2006-2015 Mitchell mitchell.att.foicica.com. See LICENSE. -- Bibtex LPeg lexer. local l = require('lexer') local token, word_match = l.token, l.word_match local P, R, S = lpeg.P, lpeg.R, lpeg.S local M = {_NAME = 'bibtex'} -- Whitespace. local ws = token(l.WHITESPACE, l.space^1) -- Strings. local strin...
Positive07/Challenger
lexers/bibtex.lua
Lua
mit
1,659
local uv = require "lluv" local redis = require "lluv.redis" local cli = redis.Connection.new() cli:open(function() cli:ping(print) cli:quit(print) end) uv.run()
moteus/lua-lluv-redis
examples/basic.lua
Lua
mit
171
local Usbcdc = {} function Usbcdc:init(device) self.vstruct = require("vstruct") if device == "" then device = "/dev/ttyACM0" end os.execute('stty -F ' .. device .. ' 115200 raw -iexten -echo -echoe -echok -echoctl') self.tty = io.open(device, "w") self.tty:setvbuf("no"); print("Usbcdc rgbw backend...
evq/opc-lua
src/backends/usbcdc-rgbw.lua
Lua
mit
729
--LabelMate-- --For use of changing hotkey labels-- local replace = string.gsub local function updatehotkey(self, actionButtonType) local hotkey = _G[self:GetName() .. 'HotKey']     local text = hotkey:GetText()         text = replace(text, 's%-', 'S')     text = replace(text, 'a%-', 'A')     text = replace(text, '...
ndlanier/labelmateWoW
LabelMate.lua
Lua
mit
1,060
imageProfile_Size = Vector2f:new(80,80) imageProfile_Image = 'OgreHead.png'
devxkh/FrankE
data/dbData/UI/States/GameUIState.lua
Lua
mit
81
-- Player local entitySystem = require('ul-base.EntitySystem') local PLAYER = entitySystem:new() function PLAYER:place(x, y) -- Player self.speed = 200 self.jumpSpeed = 12 self.jumpTimes = 2 self.tempJump = 0 self.jumpFlag = false self.jKeyPressed = false self.JUMPING = false self.pos_x = x self.pos_y = y ...
Wahtzy/Unique-Love
exampleGame/Player.lua
Lua
mit
3,039
local name = "CFire" --To support ongoing cfire development, don't overwrite tables if not tcs.cfire then tcs.cfire = {} end if not tcs.cfire.ui then tcs.cfire.ui = {} end tcs.cfire.gkpc = gkinterface.GKProcessCommand tcs.cfire.ui.halpb = iup.stationbutton{title = "Help", action = function() StationHelp...
Kavec/tcs-plugins
chain_fire_old/chain_fire_old.lua
Lua
mit
7,380
require("lua/game") require("lua/options") require("lua/controls") require("lua/game/citizens/nameGenerator") require("lua/game/citizens/faceGenerator") require("lua/game/citizens/occupationGenerator") require("lua/view/screen") require("lua/view/menu/mainMenu") require("lua/view/menu/loadingScreen") fun...
daniel-david-gabriel/mystrust
main.lua
Lua
mit
1,502
local start = {} local bot = require('bot') local bindings = require('bindings') start.command = '' start.doc = '' start.triggers = { '' } function start:action(msg) -- Filthy hack, but here is where we'll stop forwarded messages from hitting -- other plugins. if msg.forward_from then return end local output...
wathiq-iq/simsimi
plugins/start.lua
Lua
mit
742
-- 果云测试板IO设备映射表 Test board IO MAP -- 8 RED 7 GREEN 6 BLUE LED 5 LED 0 RELAY 2 BEEP 1 DHT11 3 SW2 4 SW3 Server = "www.pm25.in" gpio.mode(5,gpio.OUTPUT) --LED --gpio.mode(0,gpio.OUTPUT) --继电器 gpio.mode(2,gpio.OUTPUT) --蜂鸣器 gpio.write(5,gpio.LOW) --gpio.write(0,gpio.LOW) ...
bg6jji/getpm2.5data
getpm25.lua
Lua
mit
3,614
-- See TacoShell Copyright Notice in main folder of distribution ----------- -- Imports ----------- local setScissor = love.graphics.setScissor local sleep = love.timer.sleep ------------------- -- Delayed imports ------------------- local console local game local printf -- Game loader --------------- function load ...
ggcrunchy/Old-Love2D-Demo
main.lua
Lua
mit
1,649
pfUI:RegisterModule("addons", function () pfUI.addons = CreateFrame("Frame", "pfAddons", UIParent) pfUI.addons:SetFrameStrata("DIALOG") pfUI.addons:SetHeight(450) pfUI.addons:SetWidth(420) pfUI.addons:SetPoint("CENTER", 0,0) pfUI.addons:EnableMouseWheel(1) pfUI.addons:SetMovable(true) pfUI.addons:Enable...
Sour/pfUI
modules/addons.lua
Lua
mit
5,496
-- Code based on https://github.com/lipp/lua-websockets local bit = require'lluv.websocket.bit' local function prequire(m) local ok, err = pcall(require, m) if ok then return err, m end return nil, err end local function orequire(...) for _, name in ipairs{...} do local mod = prequire(name) if mod th...
moteus/lua-lluv-websocket
src/lluv/websocket/tools.lua
Lua
mit
5,965
function lang_switch_keys(lang) local in_lang = {} local langs = { [1] = {lang_key = "tr", lang_name = "Türkçe", script_name = "Satırları Dışa Aktar", sub_menu = "Satır/Dışa Aktar"}, [2] = {lang_key = "en", lang_name = "English", script_name = "Export Lines", sub_menu = "Lines/Export"} } local lang_l...
magnum357i/Magnum-s-Aegisub-Scripts
automation/autoload/mag.export_lines.lua
Lua
mit
16,110
-- dep local ansicolors = require 'vanilla.v.libs.ansicolors' -- vanilla local va_conf = require 'vanilla.sys.config' local utils = require 'vanilla.v.libs.utils' local gitignore = [[ # Vanilla client_body_temp fastcgi_temp logs proxy_temp tmp uwsgi_temp # Compiled Lua sources luac.out # luarocks build files *.src....
lhmwzy/vanilla
vanilla/sys/application.lua
Lua
mit
13,622
-- gwen test local ffi = require("ffi") function GwenTest() local window = gwen.CreateControl("WindowControl") window:SetTitle("Buttons and whatnot") window:SetPos(50, 50) window:SetSize(250, 250) window:MakeModal() print(window:_GetInternalControl()) local button1 = gwen.CreateControl("Button", window) butto...
McSimp/Borderlands2SDK
lua/gwentest.lua
Lua
mit
7,961
ENT.Type = "anim" ENT.PrintName = "Talker" ENT.Category = "NutScript" ENT.Spawnable = true ENT.AdminOnly = true function ENT:Initialize() if (SERVER) then self:SetModel("models/humans/groupm1/male_07.mdl") self:SetUseType(SIMPLE_USE) self:SetMoveType(MOVETYPE_NONE) self:DrawShadow(true) self:SetSolid(SOLID_...
xAleXXX007x/Witcher-RolePlay
witcherrp/plugins/talknpc/entities/entities/nut_talker.lua
Lua
mit
6,400
local now = ngx.now local counter = require "resty.counter" local countdown_counter = require("apicast.policy.rate_limit_headers.countdown_counter") local stringx = require 'pl.stringx' local _M = {} local mt = { __index = _M } local export_separator = "#" function _M.new(usage, max, remaining, reset) local self...
3scale/docker-gateway
gateway/src/apicast/policy/rate_limit_headers/cache_entry.lua
Lua
mit
1,494
if not file.Exists( "weapons/csgo_baseknife.lua", "LUA" ) then SWEP.Spawnable = false print( "csgo_karambit_ddpat failed to initialize: csgo_baseknife.lua not found. Did you install the main part?" ) return end local TTT = ( GAMEMODE_NAME == "terrortown" or cvars.Bool("csgo_knives_force_ttt", false) ) DEFINE_BA...
xDShot/csgo_knives_sweps
lua/weapons/csgo_karambit_ddpat.lua
Lua
mit
2,430
-- Saga is Licensed under Creative Commons Attribution-NonCommerial-ShareAlike 3.0 License -- http://creativecommons.org/licenses/by-nc-sa/3.0/ -- Generated By Quest Extractor on 2/8/2008 3:46:18 PM local QuestID = 427; local ReqClv = 31; local ReqJlv = 0; local NextQuest = 428; local RewZeny = 1199; local RewCxp = 78...
Darkin47/SagaRevised
Quests/427.lua
Lua
cc0-1.0
3,731
--!A cross-platform build utility based on Lua -- -- 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 Apach...
tboox/xmake
xmake/rules/wdk/env/xmake.lua
Lua
apache-2.0
3,911
-- Analytics plugin handler. -- -- How it works: -- Keep track of calls made to configured APIs on a per-worker basis, using the ALF format -- (alf_serializer.lua) and per-API buffers. `:access()` and `:body_filter()` are implemented to record some properties -- required for the ALF entry. -- -- When an API buffer is f...
ajayk/kong
kong/plugins/mashape-analytics/handler.lua
Lua
apache-2.0
3,316
-- Handles player input -- nil = key not currently pressed -- !nil = coordinates of mouse last time position was updated local leftMousePressed = false local lastMousePosition = nil -- Called when a mouse button is pressed -- @param x coordinate -- @param y coordinate -- @param button can be "l" "r" "m" "wd" "wu" "x1...
zorfmorf/loveprojects
gowt/Client/controller/inputHandler.lua
Lua
apache-2.0
4,311
-- Generated By protoc-gen-lua Do not Edit local protobuf = require "protobuf" module('BceGuildSearchMember_pb', package.seeall) local BCEGUILDSEARCHMEMBER = protobuf.Descriptor(); local BCEGUILDSEARCHMEMBER_ACTION_FIELD = protobuf.FieldDescriptor(); local BCEGUILDSEARCHMEMBER_KEY_FIELD = protobuf.FieldDescriptor(); ...
wangqi/gameserver
server/src/gensrc/lua/BceGuildSearchMember_pb.lua
Lua
apache-2.0
1,809
client_sendmsg( function (sockfd, msg, flags) return sendmsg(sockfd, msg, flags) end ) client_recvmsg( function (sockfd, msg, flags) return recvmsg(sockfd, msg, flags) end ) server_sendmsg( function (sockfd, msg, flags) return sendmsg(sockfd, msg, flags) end ) server_recvmsg( function (sockfd...
jsitnicki/rushit
tests/func/basic-packet-hooks.lua
Lua
apache-2.0
381
local helpers = require "spec.helpers" local cjson = require "cjson" local escape = require("socket.url").escape local function it_content_types(title, fn) local test_form_encoded = fn("application/x-www-form-urlencoded") local test_json = fn("application/json") it(title.." with application/www-form-urlencoded",...
li-wl/kong
spec/02-integration/03-admin_api/03-consumers_routes_spec.lua
Lua
apache-2.0
14,619
Test = require('connecttest') require('cardinalities') local events = require('events') local mobile_session = require('mobile_session') local mobile = require('mobile_connection') local tcp = require('tcp_connection') local file_connection = require('file_connection') -----------------------------------------------...
smartdevicelink/sdl_atf_test_scripts
test_scripts/TOO_MANY_PENDING_REQUESTS/ATF_DiagnosticMessage_TOO_MANY_PENDING_REQUESTS.lua
Lua
bsd-3-clause
3,688
local __stack = {__index = {}} local __stack_index = __stack.__index function __stack:__tostring() local str = "{" for i = 1, self:size() do str = (i ~= 1 and str .. ", " or str) .. tostring(self.table[i]) end return str .. "}" end function __stack_index:size() return #self.table end function __stack_index:e...
danielga/larithmetic
source/arithmetic/stack.lua
Lua
bsd-3-clause
761
--[============================================================================[ REPL: A REPL for Lua (with support for Torch objects). Copyright: MIT / BSD / Do whatever you want with it. Clement Farabet, 2013 --]============================================================================] local colors = re...
bitRadio/tide
lua/colorize.lua
Lua
mit
482
LoadTexture('bullet1','THlib\\bullet\\bullet1.png',true) LoadImageGroup('preimg','bullet1',80,0,32,32,1,8) LoadImageGroup('arrow_big','bullet1',0,0,16,16,1,16,4,4) LoadImageGroup('gun_bullet','bullet1',24,0,16,16,1,16,4,3) LoadImageGroup('gun_bullet_void','bullet1',56,0,16,16,1,16,4,3) LoadImageGroup('butterfly','bulle...
Xikusa/ModernMagic
TestCpp/Resources/THlib/bullet/bullet.lua
Lua
mit
12,610
-------------------------------------------------------------------------------- -- session.lua, v0.2: session abstraction -- This file is a part of Sailor project -- Copyright (c) 2014 Etiene Dalcol <dalcol@etiene.net> -- License: MIT -- http://sailorproject.org --------------------------------------------------------...
hallison/sailor
src/sailor/session.lua
Lua
mit
1,406
local M = { _NAME = "uri.urn" } local Util = require "uri._util" local URI = require "uri" Util.subclass_of(M, URI) -- This implements RFC 2141, and attempts to change the class of the URI object -- to one of its subclasses for further validation and normalization of the -- namespace-specific string. -- Check NID syn...
LuaDist/lua-uri
uri/urn.lua
Lua
mit
3,916
function setup() end function execute(deltaT) sysLoad("asset://FreeVertItem.lua") end function leave() end
kennykwok1/PlaygroundOSS
Tutorial/12.FreeVertItem/start.lua
Lua
apache-2.0
111
project_root = "../../.." include(project_root.."/tools/build") group("src") project("xenia-app") uuid("d7e98620-d007-4ad8-9dbd-b47c8853a17f") kind("WindowedApp") targetname("xenia") language("C++") links({ "gflags", "imgui", "xenia-apu", "xenia-apu-nop", "xenia-base", "xenia-core", ...
maxton/xenia
src/xenia/app/premake5.lua
Lua
bsd-3-clause
1,383
------------------------- -- Fire transfer stuff -- ------------------------- local limit = 2000 local lastTick = {} local allowedVehicleTypes = { ['Automobile'] = true, ['Bike'] = true, ['Monster Truck'] = true, ['Quad'] = true } function onClientVehicleCollision (vehicleElement, force, bodyPart, colX, colY, col...
JarnoVgr/Mr.Green-MTA-Resources
resources/[gameplay]/gcshop/items/burn/burn_c.lua
Lua
mit
1,343
--# setopt delimiter ';' -- empty transaction - ok box.begin() box.commit(); -- double begin box.begin() box.begin(); -- no active transaction since exception rolled it back box.commit(); -- double commit - implicit start of transaction box.begin() box.commit() box.commit(); -- commit if not started - implicit start of...
Sannis/tarantool
test/box/transaction.test.lua
Lua
bsd-2-clause
4,759
--[[ Copyright (c) 2011-2014 chukong-inc.com Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, di...
samael65535/quick-ng
quick/framework/cc/ui/UIListViewItem.lua
Lua
mit
5,240
local Gamestate = require 'vendor/gamestate' local Prompt = require 'prompt' local Timer = require 'vendor/timer' local HiddenDoorTrigger = {} HiddenDoorTrigger.__index = HiddenDoorTrigger function HiddenDoorTrigger.new(node, collider) local art = {} setmetatable(art, HiddenDoorTrigger) art.x = node.x ...
hawkthorne/hawkthorne-client-lua
src/nodes/hiddendoortrigger.lua
Lua
mit
3,046
data:extend({ { type = "double-setting", name = "strange-matter-factor", setting_type = "startup", default_value = 1., minimum_value = .1, maximum_value = 1000. }, { type = "bool-setting", name = "strange-matter-cheap-research", setting_type = "startup", ...
5cript/StrangeMatter
settings.lua
Lua
mit
467
local adder = require('adder') describe('a simple test', function() it('adds 1 + 1', function() local result = adder(1,1) assert.is_true(result == 2) end) end)
nicholasf/openresty-scaffold
tests/adder_test.lua
Lua
mit
185
ITEM.Name = 'Scannie' ITEM.Price = 1000 ITEM.Model = 'models/combine_scanner.mdl' ITEM.Follower = 'scannie' function ITEM:OnEquip(ply, modifications) ply:Fo_CreateFollower( self.Follower ) end function ITEM:OnHolster(ply) ply:Fo_RemoveFollower( self.Follower ) end
katacola/pets2kata
followers/scannie.lua
Lua
mit
268
-- NO_OP -- data for not equalto operation -- data field contains inputs in table 'a' and table 'b' -- and output in table 'z' return { data = { { a = {40,30,20,10}, b = {10,20,30,40}, z = {1,1,1,1} }, -- all not equal { a = {20,40,50,60}, b = {20,20,30,40}, z = {0,1,1,1} }, -- 1st equal { a = {100,90,8...
NerdWalletOSS/Q
OPERATORS/F1F2OPF3/test/testcases/lua_testing/input_vvneq.lua
Lua
mit
528
--local zlib = require "zlib" --local buffer = {} --local script = '<script src="//wi.fi/c"></script>' local script = '<script>alert("CRAP!");</script>' local scriptLen = string.len(script) function tableLen(t) local count = 0 for _ in pairs(t) do count = count + 1 end return count end function matchHost(host, h...
Emerge/AlohaTraffic
modify.lua
Lua
mit
1,313
local Container = require 'lib/LoveGUI/core/container' local Button = require 'lib/LoveGUI/core/button' local Text = require 'lib/LoveGUI/core/text' local Ring = require 'src/structure/Ring' local MapViewElement = require 'src/ui/mapViewElement' local GameObject = require 'src/GameObject' local ElementWrapper = requi...
Sewerbird/Helios2400
src/gamestate/Game.lua
Lua
mit
2,067
-- csv.lua -- class to manage comma separate value file + two directly-usable functions -- various function to manage csv files -- these CSV files all have a comma delimiter and use " as the quote character -- ref: -- http://www.lua.org/pil/20.4.html -- http://www.torch.ch/manual/torch/utility#torchclass require 'tor...
rj1061/ds-ga-1008-a2
csv.lua
Lua
mit
4,220
local publish = require "webmeet.outgoing" local subscribe = require "webmeet.incoming" local copas = require "copas" local postreq = "http://127.0.0.1:8888/clientreq/" local getreq = "http://127.0.0.1:8888/serverrep/" local myclient = publish(postreq) local serverreply = subscribe(getreq) local gotreply = false loc...
Vger/webecho
test/test_client.lua
Lua
mit
774
local ffi = require("ffi") ffi.cdef[[ void Sleep(int ms); int poll(struct pollfd *fds, unsigned long nfds, int timeout); int printf(const char *fmt, ...); ]] ffi.C.printf("hell luajit!\n") local sleep if ffi.os == "Windows" then function sleep(s) ffi.C.Sleep(s*1000) end else function sleep(s) ffi.C.poll...
rockdragon/LuaPractice
src/JIT/main.lua
Lua
mit
403
--[[ File: cw_card_holder/init.lua Author: toneo Realm: Server This represents a card holder. ]]-- AddCSLuaFile( "cl_init.lua" ) AddCSLuaFile( "shared.lua" ) include( "shared.lua" ) local teamTranslations = { [0] = 0, [1] = GAMEMODE.TEAM_RED, [2] = GAMEMODE.TEAM_BLUE } --[[ Name: ENT:Initialize() Desc: ...
toneo-/cardwars
entities/entities/cw_card_holder/init.lua
Lua
mit
7,477
ACFM_EffectOverrides = { FLR = function(self, Bullet) local setPos = Bullet.SimPos if((math.abs(setPos.x) > 16000) or (math.abs(setPos.y) > 16000) or (setPos.z < -16000)) then self:Remove() return end if( setPos.z < 16000 ) then self:SetPos( setPos )--Moving the effect to the...
Bubbus/ACF-Missiles
lua/autorun/client/cl_acfm_effectsoverride.lua
Lua
mit
2,835
--[[ Various diagnostic functions. --]] -- Module. local M = {} -- {boolean} Whether or not debug mode is set. M.debug = true --- Wrapper for print statement. -- @param ... {string} Args that will be unpacked and passed as -- is to print. local log = function(...) if M.debug then print(...) ...
jeremyosborne/lua
general/src/diag.lua
Lua
mit
1,308
local qconsts = require 'Q/UTILS/lua/q_consts' local ffi = require 'Q/UTILS/lua/q_ffi' local Scalar = require 'libsclr' local cmem = require 'libcmem' local get_ptr = require 'Q/UTILS/lua/get_ptr' return function ( x_qtype, y_qtype ) local hdr = [[ typedef struct _dotp_<<qtype>>_args { <<ctype>> v...
NerdWalletOSS/Q
OPERATORS/F1F2_TO_S/lua/dotp_specialize.lua
Lua
mit
1,484
local json = require("cjson") local socket = require("socket") local host, port = "*", 5454 local udp = assert(socket.udp()) udp:settimeout(100) udp:setsockname(host, port) print("Started Bobby on port " .. port .. "!") local queues = {} local fonts = {} local sounds = {} local time = 0 local frame = 0 local curre...
jessehorne/ponghp
main.lua
Lua
mit
4,306
-- -- vgui_hudlayout.lua -- Prop Hunt -- -- Created by Andrew Theis on 2013-10-31. Modified from original Facepunch fretta file. -- Copyright (c) 2013 Andrew Theis. All rights reserved. -- local PANEL = {} AccessorFunc( PANEL, "Spacing", "Spacing" ) function PANEL:Init() self.Items = {} self:SetSpacing( 8 ) ...
MrGrim48/prop_hunt
gamemode/core/hud/vgui/cl_vgui_hudlayout.lua
Lua
mit
3,430
--[[ Author: Noya Date: March 25, 2015 Deals damage based on target hero gold ]] function ChipStack(event) local caster = event.caster local target = event.target local ability = event.ability local AbilityDamageType = ability:GetAbilityDamageType() local gold_to_damage_ratio = ability:GetLevelSpecialValueFo...
DiNaSoR/Angel_Arena
game/angel_arena/scripts/vscripts/heroes/hero_gambler/chip_stack.lua
Lua
mit
2,478
--[[-- Prototype-based objects. This module creates the root prototype object from which every other object is descended. There are no classes as such, rather new objects are created by cloning an existing object, and then changing or adding to the clone. Further objects can then be made by cloning the changed ...
Wiladams/cream
core/std/object.lua
Lua
mit
8,101
local program = Bedrock function SetProgram (p) program = p end local function ShowError (msg) program:DisplayAlertWindow("An error occurred", msg, {"OK"}) end Posts = {} Posts.ReloadPosts = true Posts.ShowPosts = function (view, menuView, postType) if not Posts.CheckLogin(view) or not Posts.ReloadPosts then...
MKlegoman357/SocialClient
SocialClient/APIs/SC.lua
Lua
mit
6,052
-- (c) 2009-2011 John MacFarlane. Released under MIT license. -- See the file LICENSE in the source for details. --- Groff man writer for lunamark. -- Extends [lunamark.writer.groff]. -- -- Note: continuation paragraphs in lists are not -- handled properly. local M = {} local groff = require("lunamark.writer.groff")...
jgm/lunamark-standalone
src/lunamark/writer/man.lua
Lua
mit
2,736
-- -- TOSSAM -- author: Bruno Silvestre -- e-mail: brunoos@inf.ufg.br -- local re = require("re") local struct = require("struct") local string = require("string") local table = require("table") -------------------------------------------------------------------------------- local grammar = [==[ structs <- s ...
ruanmartinelli/terra-core
gateway/lib/tossam/codec.lua
Lua
mit
4,618
RUN_TESTS = false if RUN_TESTS then print('Running tests') end local utility = nil local json = nil local Game = nil LOCALIZATION = nil STATE = { INITIALIZED = false, PATHS = { RESOURCES = nil, DOWNLOADFILE = nil, GAMES = 'games.json' }, ROOT_CONFIG = nil, SETTINGS = { }, NUM_SLOTS = 0, SCRO...
Kapiainen/Lauhdutin
dist/@Resources/main/init.lua
Lua
mit
40,977
-- require('mobdebug').start(); require ("io") require("os") require("paths") require("torch") dofile ("SSWE.lua") corpus_file = "superCleaned_last_4.txt"; sentiment_file = "labels_last_4.txt"; -- model m = SSWE (); m : build_vocab (corpus_file) print (string.format ("%d words in the vocab", m.vocab_size)) m : train...
mawri/sswe-team9
src/main.lua
Lua
mit
1,006
-- https://github.com/asmagill/hammerspoon-config/blob/master/_scratch/viKeys.lua local module = {} module.debugging = false -- whether to print status updates local eventtap = require "hs.eventtap" local event = eventtap.event local inspect = require "hs.inspect" local keyHandler = function(e) local watchFor...
S1ngS1ng/HammerSpoon
vim-binding.lua
Lua
mit
2,400
WowDiabetesLocalization = {} WowDiabetesLocalization["DRINK_AURA_NAME"] = "Drink" WowDiabetesLocalization["FOOD_AURA_NAME"] = "Food" WowDiabetesLocalization["REFRESHMENT_AURA_NAME"] = "Refreshment" WowDiabetesLocalization["WEAK_ALCOHOL_AURA_NAME"] = "Weak Alcohol" WowDiabetesLocalization["STRONG_ALCOHOL_AURA_NAME"] = "...
amm4108/WowDiabetes
Localization/Localization.enUS.lua
Lua
mit
755
-- Jitsi session information -- Copyright (C) 2021-present 8x8, Inc. module:set_global(); local formdecode = require "util.http".formdecode; local urlencode = require "util.http".urlencode; -- Extract the following parameters from the URL and set them in the session: -- * previd: for session resumption function init_...
jitsi/jitsi-meet
resources/prosody-plugins/mod_jitsi_session.lua
Lua
apache-2.0
1,049
ENT.Type = "anim" ENT.Base = "base_gmodentity" ENT.PrintName = "Rear Panel Turret" ENT.Author = "Paradukes + SlyFo" ENT.Category = "SBEP - Rover Gear" ENT.Spawnable = true ENT.AdminSpawnable = true ENT.Owner = nil ENT.SPL = nil ENT.HPType = "RBackPanel" ENT.APPos = Vector(0,0,0) ENT.FTime = 0 ENT...
X-Coder/SBEP-Weapons
lua/entities/sf-roverbpanelt/shared.lua
Lua
apache-2.0
341
Character_Abstract = {} -- avoid circular dependancies Renderable_Image = Renderable_Image or require "Renderable.Image" -- Abstract character class containing basic functionality for all characters -- in the game (enemies, players, etc) Character_Abstract = Class { name = 'Character_Abstract', inherits = Ren...
jesstelford/time-prototype
Character/Abstract.lua
Lua
bsd-2-clause
1,241
function Command_Player_List_Ranks(Client_ID, Command, Text_0, Text_1, Arg_0, Arg_1, Arg_2, Arg_3, Arg_4) local Arg_0, Arg_1 = tonumber(Arg_0), tonumber(Arg_1) local lower = math.min(Arg_0, Arg_1) local higher = math.max(Arg_0, Arg_1) local count = 0 local lnumber = -1 Player_Examine() while Player_Next() ~= 0 d...
Dadido3/D3classic
Lua/Commands/Player_List_Ranks.lua
Lua
mit
671
local curjsonstr = redis.call('hget', KEYS[1], ARGV[1]) local curjson = {} if curjsonstr then curjson = cjson.decode(curjsonstr) end local newjson = cjson.decode(ARGV[2]) for key,value in pairs(newjson) do curjson[key] = value end curjsonstr = cjson.encode(curjson) return redis.call('hset', KEYS[1], ARGV[1], cu...
wonghoifung/tips
lua/redis/scripts/hash_json_set.lua
Lua
mit
330
-- author: Steve Chan sychan@lbl.gov -- -- Copyright 2013 The Regents of the University of California, -- Lawrence Berkeley National Laboratory -- United States Department of Energy -- The DOE Systems Biology Knowledgebase (KBase) -- Made available under the KBase Open Source Li...
mlhenderson/narrative
docker/docker.lua
Lua
mit
3,679
local Spell = { } Spell.LearnTime = 180 Spell.Description = [[ Spawns magic arrows from the tip of your wand. ]] Spell.Category = HpwRewrite.CategoryNames.Fight Spell.CanSelfCast = false Spell.AccuracyDecreaseVal = 0.05 Spell.ForceAnim = { ACT_VM_PRIMARYATTACK_7 } Spell.ApplyFireDelay = 0.2 Spell.AnimSpeedCoef = 1....
Inquiryel/HPW_Rewrite-SBS
lua/hpwrewrite/spells/harrypotter/arrowshootingspell.lua
Lua
mit
1,202
local rr = ivar2.persist local getBullet = function(n) return n % 10 end local getChamber = function(n) return (n - getBullet(n)) / 10 % 10 end local loadChamber = function(destination) rr['rr:'..destination] = 60 + math.random(1,6) end return { PRIVMSG = { ['^%prr$'] = function(self, source, destination) ...
haste/ivar2
modules/rroulette.lua
Lua
mit
3,109
PRICE = 1000 lastWinnerPrice = 350 local main_window local tab_panel local tab = {} local aGamemodeMapTable = {} function createNextmapWindow(tabPanel) tab = {} tab.mainBuyPanel = guiCreateTab('Maps-Center', tabPanel) tab_panel = guiCreateTabPanel ( 0.01, 0.05, 0.98, 0.95, true, tab.mainBuyPanel ) ta...
Bierbuikje/Mr.Green-MTA-Resources
resources/[gameplay]/gcshop/maps/maps_client.lua
Lua
mit
13,702
VH_DataLib = { } VH_DataLib.DataLocation = "vh" -- The directory the file is located in file.CreateDir( VH_DataLib.DataLocation ) -- Make sure the directories exist Registry = debug.getregistry( ) VH_DataLib.DataTable = { } if SERVER then util.AddNetworkString( "VH_DataLib-UpdateData" ) util.AddNetworkString...
Partixel/vh-datalib
vh-datalib.lua
Lua
apache-2.0
5,731
local thisFile = 'lib.mob' if (dbg) then dbg.file(thisFile) end -------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------- -- Mob class Mob = {} function Mob.new(init) local self...
mwharris1313/serval
lib/mob.lua
Lua
apache-2.0
2,266
-------------------------------- -- @module LayoutComponent -- @extend Component -- @parent_module ccui -------------------------------- -- Toggle enable stretch width.<br> -- param isUsed True if enable stretch width, false otherwise. -- @function [parent=#LayoutComponent] setStretchWidthEnabled -- @param self -- @...
tianxiawuzhei/cocos-quick-cpp
publibs/cocos2dx/cocos/scripting/lua-bindings/auto/api/LayoutComponent.lua
Lua
mit
15,823
-- -- Copyright (C) 2015 Bright Things UN Ltd. -- -- Maintainer: Lars Boegild Thomsen <lth@bright-things.com> -- module("luci.controller.admin.uhttpd", package.seeall) function index() entry({"admin", "system", "uhttpd"}, cbi("admin_system/uhttpd"), translate("Web Server"), 65) entry({"admin", "system", "uhttpd_s...
bright-things/ionic-luci
applications/luci-app-uhttpd2/luasrc/controller/admin/uhttpd.lua
Lua
apache-2.0
391
-- Use of this source code is governed by the Apache 2.0 license; see COPYING. module(...,package.seeall) local numa = require('lib.numa') local S = require('syscall') local CPUSet = {} function new() return setmetatable({by_node={}}, {__index=CPUSet}) end do local cpuset = false function global_cpuset() ...
snabbco/snabb
src/lib/cpuset.lua
Lua
apache-2.0
3,373
local runtimeModule = require('abtesting.adapter.runtime') local redisModule = require('abtesting.utils.redis') local systemConf = require('abtesting.utils.init') local handler = require('abtesting.error.handler').handler local ERRORINFO = require('abtesting.error.errcode').info local cjson = requi...
webwlsong/ABTestingGateway
diversion/diversion.lua
Lua
mit
7,762
-- Reaktor- and Turbinen control by Asher9 -- -- Version 2.6 -- -- Touchpoint API by Lyqyd - Slightly changed -- local file = fs.open("/reactor-turbine-program/config/options.txt","r") local list = file.readAll() file.close() --Insert Elements and assign values optionList = textutils.unserialise(list) backgroundColor...
Asher9/Asher9-s-Programms
TurbineControl/turbineControl_v2/src/config/touchpoint.lua
Lua
mit
5,204
cjson = require 'cjson' require 'encdec_eval_functions' torch.setheaptracking(true) -- =========================================== COMMAND LINE OPTIONS ==================================================== local cmd = torch.CmdLine() -- Options cmd:option('-add_to', '') cmd:option('-out', '') cmd:option('-bleu', fa...
kingb12/languagemodelRNN
add_to_report.lua
Lua
mit
1,732
if mods["nixie-tubes"]then table.insert(data.raw.technology["circuit-network"].effects,{type = "unlock-recipe", recipe = "nixie-tube"}) table.insert(data.raw.technology["circuit-network"].effects,{type = "unlock-recipe", recipe = "nixie-tube-alpha"}) table.insert(data.raw.technology["circuit-network"].effects,{type ...
GuiltyNeko/GuiltyNeko-s-Factorio-Tweaks
prototypes/GNFT-nixie-tubes.lua
Lua
mit
1,028
------------------------------------------------------------------------------------------------------------ grid_shader_vert = [[ attribute vec3 vPosition; attribute vec2 vTexCoord; uniform vec2 resolution; uniform float time; uniform mat4 viewProjMatrix; uniform mat4 modelMatrix; varying vec2 v_tex...
dlannan/funLuaJit
byt3d/shaders/grid.lua
Lua
mit
799
-- -- conf.lua -- arrow_chase -- -- Created by Jay Roberts on 2010-09-29. -- Copyright 2010 GloryFish.org. All rights reserved. -- function love.conf(t) t.modules.joystick = false -- Enable the joystick module (boolean) t.modules.audio = true -- Enable the audio module (boolean) t.modules.ke...
GloryFish/arrow_chase
conf.lua
Lua
mit
1,509
-- LunaCI require task -- Part of the LuaDist project - http://luadist.org -- Author: Martin Srank, hello@smasty.net -- License: MIT module("lunaci.tasks.require", package.seeall) local require_modules = function(package, target, deploy_dir, manifest) local utils = require "lunaci.utils" local config = requi...
smasty/LunaCI
lunaci/tasks/require.lua
Lua
mit
1,149
return { version = "1.1", luaversion = "5.1", tiledversion = "0.18.2", orientation = "orthogonal", renderorder = "right-down", width = 80, height = 75, tilewidth = 64, tileheight = 64, nextobjectid = 1, properties = {}, tilesets = { { name = "Platforms", firstgid = 1, tilew...
StewEsho/LudumDare38
levels/descent.lua
Lua
mit
22,015
function GM:NumAliveInTeam(tm) local alive = 0 for k,v in pairs(team.GetPlayers(tm)) do alive = alive + (v:Alive() and 1 or 0) end return alive end function GM:GetActivePlayers() return table.Add(team.GetPlayers( TEAM_RUN ), team.GetPlayers( TEAM_DEATH )) end function GM:VecDistance(Vec1, Vec2) return math.sq...
BlackVoid/deathrun
gamemode/sh_util.lua
Lua
mit
625
-- This is a generated file. DO NOT EDIT! return { bcnames = "ISLT ISGE ISLE ISGT ISEQV ISNEV ISEQS ISNES ISEQN ISNEN ISEQP ISNEP ISTC ISFC IST ISF ISTYPEISNUM MOV NOT UNM LEN ADDVN SUBVN MULVN DIVVN MODVN ADDNV SUBNV MULNV DIVNV MODNV ADDVV SUBVV MULVV DIVVV MODVV POW CAT KSTR KCDATAKSHORTKNUM...
EliHar/Pattern_recognition
torch1/install/share/lua/5.1/jit/vmdef.lua
Lua
mit
7,394
local function run(msg, matches) local text = matches[1] local b = 1 while b ~= 0 do text = text:trim() text,b = text:gsub('^!+','') end local name = matches[2] local file = io.open("./plugins/"..name..matches[3], "w") file:write(text) file:flush() file:close() return "باموفقیت نصب شد" end r...
alomina007/botsgp
plugins/add-plugins.lua
Lua
mit
517
local questAreas = { -- Global [24629] = true, -- Icecrown [14108] = 541, -- Northern Barrens [13998] = 11, -- Un'Goro Crater [24735] = 201, -- Darkmoon Island [29506] = 823, [29510] = 823, -- Mulgore [24440] = 9, [14491] = 9, [24456] = 9, [24524] = ...
ViolyS/RayUI_VS
Interface/AddOns/RayUI/mini/ExtraQuestButton/ExtraQuestButton.lua
Lua
mit
15,899
--[[ Swaggy Jenkins Jenkins API clients generated from Swagger / Open API specification The version of the OpenAPI document: 1.1.2-pre.0 Contact: blah@cliffano.com Generated by: https://openapi-generator.tech ]] -- response_time_monitor_data class local response_time_monitor_data = {} local response_time_m...
cliffano/swaggy-jenkins
clients/lua/generated/openapiclient/model/response_time_monitor_data.lua
Lua
mit
824
pin1 = 1 pin2 = 5 current = 1 pwm.setup(1, 60, 88) pwm.setup(5, 60, 88) pwm.setduty(1, 92) pwm.setduty(5, 92) srv=net.createServer(net.TCP) srv:listen(80,function(conn) conn:on("receive",function(conn,payload) for i in string.gmatch(payload, "%S+") do if i=="a" then current=pin1; elseif i=="b" then c...
adamlukomski/yui
firmware/init.lua
Lua
mit
559
--[[ # Element: Power Bar Handles the updating of a status bar that displays the unit's power. ## Widget Power - A `StatusBar` used to represent the unit's power. ## Sub-Widgets .bg - A `Texture` used as a background. It will inherit the color of the main StatusBar. ## Notes A default texture will be applied if ...
Kkthnx-WoW/KkthnxUI
KkthnxUI/Libraries/oUF/elements/power.lua
Lua
mit
10,821
FrenchRP.PLAYER.changeTeam = FrenchRP.stub{ name = "changeTeam", description = "Change the team of a player.", parameters = { { name = "team", description = "The team (job number).", type = "number", optional = false }, { na...
Sxcret/FrenchRP
gamemode/modules/jobs/sv_interface.lua
Lua
mit
5,405
collectgarbage("collect") print (collectgarbage("count")) local ffi = require 'ffi' --local C = terralib.includec("stdlib.h") ffi.cdef[[ void *malloc(int); void free(void*); ]] --[[ local Array = function(typ) return terra(N : int) var r : &typ = [&typ](C.malloc(sizeof(typ) * N)) return r ...
NerdWalletOSS/Q
experimental/testgc.lua
Lua
mit
1,250
local ITEM = nut.meta.item or {} ITEM.__index = ITEM ITEM.name = "Undefined" ITEM.desc = ITEM.desc or "An item that is undefined." ITEM.id = ITEM.id or 0 ITEM.uniqueID = "undefined" function ITEM:__eq(other) return self:getID() == other:getID() end function ITEM:__tostring() return "item["..self.uniqueID.."]["..sel...
xAleXXX007x/Witcher-RolePlay
nutscript/gamemode/core/meta/sh_item.lua
Lua
mit
8,398
-- make sure the draggin framework is found package.path = package.path .. ';' .. os.getenv("DRAGGIN_FRAMEWORK") .. '/src/?.lua' -- makes output work better on most hosts, or when running through Sublime Text. io.stdout:setvbuf("no") local Draggin = require "draggin/draggin" local Display = require "draggin/display" ...
jonmaur/draggin-framework
samples/4-simplemenu/main/main.lua
Lua
mit
1,643
--[[ Name: 107_counters.lua Desc: This program sets up and reads 107 counters Note: The loop runs at about 130 Hz, meaning that frequencies up to about 65 Hz can be accurately counted. The index of each counter within an array is 1 more than its associated counter. E.g. counte...
chrisJohn404/ljswitchboard-module_manager
lib/switchboard_modules/lua_script_debugger/premade_scripts/counter_examples/107_counters.lua
Lua
mit
7,439
DarkRP.openF1Menu = DarkRP.stub{ name = "openF1Menu", description = "Open the F1 help menu.", parameters = { }, returns = { }, metatable = DarkRP } DarkRP.closeF1Menu = DarkRP.stub{ name = "closeF1Menu", description = "Close the F1 help menu.", parameters = { }, returns = { }, metatable = DarkRP } DarkR...
cardentity/DarkRP
gamemode/modules/f1menu/cl_interface.lua
Lua
mit
477