content
stringlengths
0
1.05M
origin
stringclasses
2 values
type
stringclasses
2 values
local cfg = {}
nilq/small-lua-stack
null
-------------------------------------------------------------------------------- --- Generated exports map for lua-nucleo/ -- @module lua-nucleo.code.exports -- This file is a part of lua-nucleo library -- See file `COPYRIGHT` for the license and copyright information ---------------------------------------------------...
nilq/small-lua-stack
null
-- protocol naming p4_paxos = Proto('p4_paxos','P4_PAXOSProtocol') -- protocol fields local p4_paxos_msgtype = ProtoField.string('p4_paxos.msgtype','msgtype') local p4_paxos_instance = ProtoField.string('p4_paxos.instance','instance') local p4_paxos_round = ProtoField.string('p4_paxos.round','round') local p4_paxos_vr...
nilq/small-lua-stack
null
require 'luacov' local tuple = require 'tuple' context('Creating tuples', function() test('Instantiates new tuples with () call', function() local a = tuple(1,2) assert_equal(#a, 2) assert_equal(a[1],1) assert_equal(a[2],2) end) test('Empty parens returns 0-tuples', function() local a =...
nilq/small-lua-stack
null
require 'busted.runner'() describe("labRenderers", function() local labRenderers local force0 = { index = 0, } local force1 = { index = 1, } local lab0 = { type = "lab", name = "lab", valid = true, unit_number = 0, force = force0, }...
nilq/small-lua-stack
null
MSBTProfiles_SavedVars = { ["profiles"] = { ["Default"] = { ["creationVersion"] = "5.7.146", }, }, } MSBT_SavedMedia = { ["fonts"] = { }, ["sounds"] = { }, }
nilq/small-lua-stack
null
--[[ Minecart ======== Copyright (C) 2019-2021 Joachim Stolberg MIT See license.txt for more information ]]-- -- for lazy programmers local M = minetest.get_meta local S = minecart.S local CYCLE_TIME = 4 local function node_timer(pos) local node = minetest.get_node(pos) local dir = minetest.facedir_to_dir...
nilq/small-lua-stack
null
local objects = { --Maxime createObject(14506,2239.6999500,-1165.0999800,1038.0000000,0.0000000,0.0000000,0.0000000,46), --object(imy_motel_int,46), (1,46), createObject(14846,1473.3994100,1752.2998000,14.8000000,0.0000000,0.0000000,0.0000000,46), --object(int_ppol,46), (2,46), createObject(1535,1470.4000200,175...
nilq/small-lua-stack
null
local Adapter = require('core.inventoryAdapter') local Craft = require('farms.craft') local turtle = _G.turtle local CRAFTING_TABLE = 'minecraft:crafting_table' local function clearGrid(inventory) for i = 1, 16 do local count = turtle.getItemCount(i) if count > 0 then inventory:insert(i, count) if t...
nilq/small-lua-stack
null
local mock = require "deftest.mock" local mockfs = require "deftest.mock.fs" return function() local basic describe("basic credentials", function() before(function() basic = require "aws-sdk.core.credentials.basic" mock.mock(sys) mock.mock(os) mockfs.mock() end) after(function() package.loaded...
nilq/small-lua-stack
null
data:extend({ { allowed_values={"true","false"}, default_value="true", localised_description="If stack sizes should be multiplied by the stack size setting, if not then the stack size setting determines the definite item stack size.", localised_name="Item Stack Sizes Multiply?", name="stackMultiply", setti...
nilq/small-lua-stack
null
require( 'src/token_bucket' ) local lu = require( './tests/lib/luaunit' ) function test_01_consume() local bucket = TokenBucket( 10 ); lu.assertEquals( bucket:consume( 9 ), true ); lu.assertEquals( bucket:getTokenCount(), 1 ); lu.assertEquals( bucket:consume(), true ); lu.assertEquals( bucket:consume(), fal...
nilq/small-lua-stack
null
data:extend({ { type="recipe", name="AppliedLargeGlassAmpoule", category="AppliedGlassWorking1", energy_required=10, ingredients={ {"AppliedGlassTube", 1}, {type="fluid", amount=5, name="AppliedLightLiquidFuel"}, }, results={ {"AppliedLargeGlassAmpoule", 2}, }, enabled=false, },{ type="re...
nilq/small-lua-stack
null
------------------------------------------------------------------------------- -- Mob Framework Mod by Sapier -- -- You may copy, use, modify or do nearly anything except removing this -- copyright notice. -- And of course you are NOT allow to pretend you have written it. -- --! @file path_based_movement_gen.lua --! @...
nilq/small-lua-stack
null
local mod = DBM:NewMod("d593", "DBM-Scenario-MoP") local L = mod:GetLocalizedStrings() mod:SetRevision(("$Revision: 2 $"):sub(12, -3)) mod:SetZone() mod:RegisterCombat("scenario", 1050) mod:RegisterEventsInCombat( "SPELL_CAST_SUCCESS", "UNIT_DIED", "CHAT_MSG_MONSTER_YELL" ) mod.onlyNormal = true ...
nilq/small-lua-stack
null
--[[ @author Ilias-Timon Poulakis (FeedTheCat) @license MIT @version 1.0.2 @about Create an approximate razor edit from region under mouse ]] local expand_beat_limit = 3 local shrink_beat_limit = 3 reaper.Undo_BeginBlock() -- Get mouse cursor position reaper.PreventUIRefresh(1) local cursor_pos = reaper.GetCu...
nilq/small-lua-stack
null
local CRYPT = require "lcrypt" local uuid = CRYPT.uuid local guid = CRYPT.guid local sys = require "sys" local now = sys.now local hostname = sys.hostname local modf = math.modf local ID = {} -- UUID v4实现 function ID.uuid() return uuid() end -- hash(主机名)-时间戳-微秒-(1~65535的随机数) function ID.guid(host) local hi, lo...
nilq/small-lua-stack
null
-- Swordburst 2 local Page = MagmaHub:addPage("Swordburst 2") -- Services local Players = game:GetService("Players") -- Variables local LocalPlayer = Players.LocalPlayer -- Big Hit Box local BigHitBox = Page:addToggle("Big Hit Box", nil, function () for _,v in pairs(game.Workspace.Mobs:children()) do if v:FindFir...
nilq/small-lua-stack
null
--[[ File Writer ]]-- local fileWriter = {} local writer = require 'writer' --[[ First prep > o (table) output > m (table) module ]] local function prepareModule(o, m) o.fields = m.params o.body.text = '\n### ' .. m.returns.name .. '\n' o.header.text = '# ' .. m.title .. '\n' if m.description then o.header:...
nilq/small-lua-stack
null
-- Copyright (c) 2018. tangzx(love.tangzx@qq.com) -- -- 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 ...
nilq/small-lua-stack
null
--[[ grid of cells that store a template for rendering and a solid mask written in a pretty inefficient way for now :) ]] --config local cell_size = vec2(3, 3) local space_glyph = (" "):byte(1) --doesn't actually rely on grid local function parse_template(template, f) local z = #template - 1 for _, lines in ipa...
nilq/small-lua-stack
null
local Buffer, _, method = class('Buffer') Buffer.__description = "Modified version of Luvit's low-level buffer class." local ffi = require('ffi') local concat = table.concat local gc, cast, ffi_copy, ffi_string = ffi.gc, ffi.cast, ffi.copy, ffi.string local lshift, rshift, tohex, tobit = bit.lshift, bit.rshift, bit.t...
nilq/small-lua-stack
null
include("shared.lua") -------------------------------------------------------------------------------- ENT.ClientProps = {} ENT.ButtonMap = {} ENT.ButtonMap["FrontPneumatic"] = { pos = Vector(460.0,-45.0,-50.0), ang = Angle(0,90,90), width = 900, height = 100, scale = 0.1, } ENT.ButtonMap["RearPneu...
nilq/small-lua-stack
null
-- [Environment variables](http://en.wikipedia.org/wiki/Environment_variable) -- are a universal mechanism for [conveying configuration -- information to Unix programs](http://www.12factor.net/config). -- To get a value for a key, use `os.getenv`. This will return -- nil if the key isn't present in the environment. p...
nilq/small-lua-stack
null
---------------------------------------------------------------------- -- Various utility functions for creating unit tests in Torch for DeepBoof -- -- Peter Abeles ---------------------------------------------------------------------- boof = {} boof.output_base_directory = "torch_layers" boof.float_types = {"F32"...
nilq/small-lua-stack
null
--[[ R15 with constraints and animations ]] local RunService = game:GetService("RunService") local ReplicatedStorage = game:GetService("ReplicatedStorage") local CCDIKController = require(ReplicatedStorage.Source.CCDIKController) local dummy = workspace.HumanMale_Model local leftTarget = workspace.newTargetConstra...
nilq/small-lua-stack
null
#!/usr/bin/env lua local benchmark = require 'benchmark' local native = require 'mtype.native' local pure = require 'mtype.pure' -- unpack is not global since Lua 5.3 local unpack = table.unpack or unpack --luacheck: std lua51 local type_raw = type local type_native = native.type local type_pure = pure.type -- Num...
nilq/small-lua-stack
null
AnimSprite = {} AnimSprite.__index = AnimSprite local function newAnimSprite(img, tw, th, fpt, loop, x, y) local w, h = img:getDimensions() local txs = w / tw local tys = h / th local quads = {} for i = 0, txs do quads[i] = {} for j = 0, tys do quads[i][j] = love.graphics...
nilq/small-lua-stack
null
local bits = {false, false, false, false, false, false, false, false} local val = 0 local op = 0 local function s(b) return string.format("%3s", bits[b] and "X" or ".") end while true do print( s(8) .. s(1) .. s(2) .. "\t" .. "8 1...
nilq/small-lua-stack
null
module( ..., package.seeall ) local at = require "attributes" local function pt(t) local level=0 local function doprint(t) for k,v in pairs(t) do print(string.rep(" ",level) ..string.format("%s = %s",k,tostring(v))) if type(v)=="table"or type(v)=="romtable" then level=level+1 dopr...
nilq/small-lua-stack
null
return { summary = 'Reinitialize the RandomGenerator with a new seed.', description = [[ Seed the RandomGenerator with a new seed. Each seed will cause the RandomGenerator to produce a unique sequence of random numbers. ]], arguments = { seed = { type = 'number', description = 'The rand...
nilq/small-lua-stack
null
--[[ ScrubBuster by burneddi ]] --Libraries local StatLogic = AceLibrary("StatLogic-1.0") ScrubBuster = { stats = {}; --the table in which we'll gather the stats, organized by unit name tempUnit = nil; talentsTimeout = false; --whether talent check has timed out for current unit }; --Check that BonusScanner versio...
nilq/small-lua-stack
null
local assets= { Asset("ANIM", "anim/cutstone.zip"), } local function fn(Sim) local inst = CreateEntity() inst.entity:AddTransform() inst.entity:AddAnimState() MakeInventoryPhysics(inst) inst.AnimState:SetBank("cutstone") inst.AnimState:SetBuild("cutstone") inst.AnimState:PlayAnimation("idle")...
nilq/small-lua-stack
null
local util = {} function util.map(t, fn) local res = {} for k, v in pairs(t) do res[k] = fn(v, k) end return res end function util.find(t, fn) local res = {} for k, v in pairs(t) do if fn(v, k) then return v end end end function util.filter(t, fn) local res = {} for k,v in pairs(t) do if fn(v...
nilq/small-lua-stack
null
updateSystems = { timerSystem = System ({"timer"}, function(e) if (e.timer.lifetime > 0) then e.timer.lifetime -= 1 else e.timer.trigger() del(world, e) end end ), motionSystem = System({"pos", "vel"}, function(e) e.pos.x += e.vel.x e.pos.y += e.vel.y end ), animationSystem = Sy...
nilq/small-lua-stack
null
--Device detection isError=0 function detectDevice(DeviceName) DeviceSide="none" for k,v in pairs(redstone.getSides()) do if peripheral.getType(v)==DeviceName then DeviceSide = v break end end return(DeviceSide) end function get_average(t) local sum = 0 local count = 0 for k,v in pairs(t) d...
nilq/small-lua-stack
null
local mh_id = ARGV[1]; local hgetall = function (key) local bulk = redis.call("HGETALL", key) local result = {} local nextkey for i, v in ipairs(bulk) do if i % 2 == 1 then nextkey = v else result[nextkey] = v end end return result end -- TODO: Mabye do this, to reduce memory usage of the Lua scrip...
nilq/small-lua-stack
null
local Logger = require("__DedLib__/modules/logger").create{modName = "Generic_Logistic_Chest"} local DataUtil = require("scripts/data_util") if Logger.FILE_LOG_LEVEL == "trace" then Logger:trace_block(DataUtil.dumpLogisticChests()) end
nilq/small-lua-stack
null
ESX = nil local PlayerData = {} local isHarvesting = false local cokeStep = 0 local methStep = 0 local cokeEntrance = 1 local methEntrance = 1 Citizen.CreateThread(function() while ESX == nil do TriggerEvent('esx:getSharedObject', function(obj) ESX = obj PlayerData = ESX.GetPlayerData() end) ...
nilq/small-lua-stack
null
local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end function onCreatureSay(cid, type, msg)...
nilq/small-lua-stack
null
local cwd = (...):gsub("%.[^%.]+$", "") .. "." return { name = "game_ruleviolation", description = "Rule violation interface (Ctrl+Y)", author = "andrefaramir", website = "https://github.com/edubart/otclient", sandboxed = true, classPath = cwd .. "ruleviolation" }
nilq/small-lua-stack
null
local icons_status_ok, icons = pcall(require, "nvim-nonicons") if not icons_status_ok then return end icons.get("file")
nilq/small-lua-stack
null
describe('average', function() it('errors when its parent errors', function() local _, onError = observableSpy(Rx.Observable.throw():average()) expect(#onError).to.equal(1) end) it('produces a single value representing the average of the values produced by the source', function() expect(Rx.Observable...
nilq/small-lua-stack
null
require("compiler-sfc/src/compileTemplate") require("compiler-sfc/src/parse") test('should work', function() local source = nil local result = compileTemplate({filename='example.vue', source=source}) expect(#result.errors):toBe(0) expect(result.source):toBe(source) expect(result.code):toMatch() end ) test('p...
nilq/small-lua-stack
null
Skada:AddLoadableModule("Power", nil, function(Skada, L) if Skada.db.profile.modulesBlocked.Power then return end local mod = Skada:NewModule("power gains") local MANA = 0 local ENERGY = 3 local FOCUS = 2 local RAGE = 1 local RUNIC = 6 local HOLY = 9 local function log_gai...
nilq/small-lua-stack
null
local M = {} function M.config() rvim.builtin.nvimtree = { active = true, on_config_done = nil, setup = { disable_netrw = true, hijack_netrw = true, open_on_setup = false, auto_close = true, open_on_tab = false, update_focused_file = { enable = true, }, ...
nilq/small-lua-stack
null
--AI parameter constants AI_THINK_INTERVAL = 1 -- The interval in seconds between two think ticks --AI state constants AI_STATE_IDLE = 0 AI_STATE_AGGRESSIVE = 1 AI_STATE_RETURNING = 2 AI_STATE_WALKING = 3 --Define the HumanKingAI class HumanKingAI = {} HumanKingAI.__index = HumanKingAI --[[ Create an instance of the...
nilq/small-lua-stack
null
local resource_autoplace = require('resource-autoplace'); local noise = require('noise'); local util = require("__bzcarbon__.data-util"); if util.me.use_rough_diamond() then data:extend({ { type = "autoplace-control", category = "resource", name = "diamond", richness = true, order = "b-e" }, { ...
nilq/small-lua-stack
null
local MusicEditing = require "MusicEditing" local MusicAnalysis = require "MusicAnalysis" local Song = MusicEditing.Song local Track = MusicEditing.Track local Event = MusicEditing.Event local NoteOnOffEvent = MusicEditing.NoteOnOffEvent local ArrangementContext = MusicEditing.ArrangementContext local Helper = MusicEd...
nilq/small-lua-stack
null
local Robot = {} function build_name() return string.char(math.random(65,90))..string.char(math.random(65,90))..math.random(100,999) end function name_exists(names,name) if (names.length ~=nil) then for i = 1, #names do if names[i] == name then return true end end end return false ...
nilq/small-lua-stack
null
local LuaQtHelper = require("LuaQtHelper") require("QtWidgets") -- local ui_LoginWindow = require("ui_LoginWindow") local ui_LoginWindow = loadstring(require("uic").run("loginwindow.ui"))() local LoginWindow = { className = "LoginWindow", superClass = QWidget, } local function newLoginWindow(mo, parent) local self...
nilq/small-lua-stack
null
local Util = { } local fs = _G.fs local http = _G.http local os = _G.os local term = _G.term local textutils = _G.textutils function Util.tryTimed(timeout, f, ...) local c = os.clock() repeat local ret = f(...) if ret then return ret end until os.clock()-c >= timeout end function ...
nilq/small-lua-stack
null
local Modules = script.Parent.Parent.Parent.Parent local Roact = require(Modules.Roact) local withTheme = require(Modules.StudioComponents).withTheme local function BaseProperty(props) return withTheme(function(theme) return Roact.createElement("Frame", { BackgroundColor3 = theme:GetColor(Enum.StudioStyleGuideCo...
nilq/small-lua-stack
null
--Config and constants return { GLASSES_TERMINAL_ADDRESS = "67b6edd8-fe6f-49d9-9b6f-93c91ff2015e", PLAYER_NAME = "shBLOCK", RESOLUTION = { width = 640, height = 360 }, EASING_FUNCTIONS = { BACK = "back", BOUNCE = "bounce", CIRC = "circ", CUBIC = "cubic", ELASTIC = "elastic", EX...
nilq/small-lua-stack
null
------------------------------------------------------------------------------- --- enhance vector, based hump's vector ------------------------------------------------------------------------------- local HVector = require('klib/vendor/hump/vector') local Vector = HVector.Vector Vector.normalize_inplace = Vector.nor...
nilq/small-lua-stack
null
function stop_sounds(keys) keys.caster:StopSound("Hero_Pudge.Rot") end function damage_target(keys) local caster = keys.caster local target = keys.target local ability = keys.ability local ability_level = ability:GetLevel() - 1 local base_damage = ability:GetLevelSpecialValueFor("base_damage", ...
nilq/small-lua-stack
null
return { "icons/skill_mag1-1", "icons/skill_mag1-2", "icons/skill_mag12-1", "icons/skill_mag12-2", "icons/skill_mag15-1", "icons/skill_mag15-2", "icons/skill_mag18-1", "icons/skill_mag21-2", "icons/skill_mag24-1", "icons/skill_mag24-2", "icons/skill_mag27-2", "icons/skill_mag3-1", "icons/skill_mag3-2", "icons/skill_mag...
nilq/small-lua-stack
null
--Opens the host file explorer in the current active folder if select(1,...) == "-?" then printUsage( "folder","Opens the host file explorer in the current active folder" ) return end local term = require("terminal") openAppData("/drives/"..term.getdrive()..term.getdirectory())
nilq/small-lua-stack
null
/* * @package : rlib * @module : rnet * @author : Richard [http://steamcommunity.com/profiles/76561198135875727] * @copyright : (C) 2018 - 2020 * @since : 1.1.0 * @website : https://rlib.io * @docs : https://docs.rlib.io * * MIT License * * THE SO...
nilq/small-lua-stack
null
-- WARNING: this program will not break branches, make sure that your tree will -- not make branches. you can achieve this by puting your tree in a room with -- an appropiatly highted roof (6 blocks high I believe) or by using a tree -- type which doesn't make branches local fuel = { ["minecraft:coal"] = true, ["m...
nilq/small-lua-stack
null
local class = require 'middleclass' local Object = class.Object local Voxel = require 'core/voxel/Voxel' local UndefinedVoxel = require 'core/voxel/UndefinedVoxel' local GlobalEventSource = require 'core/GlobalEventSource' local VoxelDictionary = { classes = {}, idToClass...
nilq/small-lua-stack
null
local fireBug = Action() function fireBug.onUse(player, item, fromPosition, target, toPosition, isHotkey) local chance = math.random(10) if chance > 4 then -- Success 6% chance if target.itemid == 182 then -- Destroy spider webs/North - South toPosition:sendMagicEffect(CONST_ME_HITBYFIRE) target:transform(18...
nilq/small-lua-stack
null
function onCreate() --omg roblox (real) makeLuaSprite('stageback', 'stageback', -600, -300); setLuaSpriteScrollFactor('stageback', 0.9, 0.9); makeLuaSprite('stagefront', 'stagefront', -650, 600); setLuaSpriteScrollFactor('stagefront', 0.9, 0.9); scaleObject('stagefront', 1.1, 1.1); makeLuaSprite('stagecurtains...
nilq/small-lua-stack
null
-------------------------------------------------------------------------- -- This class is responsible for actively managing the actions of -- Lmod. It is responsible finding and loading or unloading a -- modulefile. It is also responsible for reloading modules when -- the module path changes. Finally it is respons...
nilq/small-lua-stack
null
-- react_ and postreact_ event module for reactions near the object --[[ include 'listen' obj { nam = 'npc'; react_Take = "Player in this room is taking something. Reject!"; }:listen(); ]]-- --luacheck: globals mp --luacheck: no self game.react_list = std.list {} function game:before_Any(ev, ...) for _, v in ipai...
nilq/small-lua-stack
null
--[[ 不同地区大厅配置差异列表 xBuild会根据XML文件来修改这里面的值,以适应不同的地区 WARNING WARNING 切记不可以直接访问此处的变量切记不可以直接访问此处的变量 1、配置如何更新(添加|删除) 1.1 添加 每个版本更新时,如果需要新添加配置 step1:在regionConfigCommon中添加此变量名(以Region为开头),并附加详细的注释 step2:在regionConfigDataInterface中添加接口供外部访问 step3:...
nilq/small-lua-stack
null
class 'BloozeMod' function BloozeMod:__init() Events:Subscribe( "BloozingStart", self, self.BloozingStart ) Events:Subscribe( "LocalPlayerDeath", self, self.LocalPlayerDeath ) Events:Subscribe( "LocalPlayerWorldChange", self, self.LocalPlayerWorldChange ) end function BloozeMod:InputPoll() if In...
nilq/small-lua-stack
null
I2CSCAN = {} function I2CSCAN.scan() STMP.i2c.init() STMP.i2c.set_speed(true) for i = 2, 254, 2 do if STMP.i2c.transmit(i, {}, true) then print(string.format("%#x OK", i)) end end end -- if file is nil, return array -- if size is nil, dump the whole EEPROM function I2CSCAN...
nilq/small-lua-stack
null
local stub = require("luassert.stub") local loop = require("null-ls.loop") local methods = require("null-ls.methods") local c = require("null-ls.config") local s = require("null-ls.state") describe("state", function() local mock_client_id = 1234 local mock_action_stub = stub.new() local mock_action = { ...
nilq/small-lua-stack
null
#!/usr/bin/lua if not arg[1] then print("Usage:\tpico2lua.lua [FILE]") print("Prints out the lua code in a file pico-8 format file to stdout.") print("e.g.: ./pico2lua.lua cart.p8 > code.lua") else local file if arg[1] == '-' then file = io.stdin else file = io.open(arg[1]) end local fou...
nilq/small-lua-stack
null
local makeNumberSequence = require("rbx_lua_types").NumberSequence.new local makeNumberSequenceKeypoint = require("rbx_lua_types").NumberSequenceKeypoint.new local datatype = {} datatype.name = "NumberSequence" datatype.id = 0x15 function datatype.default() return makeNumberSequence({ {Time = 0, Value = ...
nilq/small-lua-stack
null
---Label API documentation ---Label API documentation ---@class label label = {} ---Gets the text from a label component ---@param url string|hash|url the label to get the text from ---@return string the label text function label.get_text(url) end ---Gets the text metrics from a label component ---@param url string|ha...
nilq/small-lua-stack
null
local KC = require 'klib/container/container' local RBTree = require 'klib/ds/rbtree' local function __call(self, ...) if ... then self:push(...) else return self:pop() end end local Q = KC.class('klib.ds.PriorityQueue', function(self) self.tree = RBTree:new() getmetatable(self).__...
nilq/small-lua-stack
null
-- Disable color column in quickfix lists vim.opt_local.colorcolumn = ""
nilq/small-lua-stack
null
return { id = "material_pastelpurple", type = "material", name = "Pastel Purple", description = "A nice purple color for your eg!", rarity = 8, hidden = false, metadata = { color = Color3.fromRGB(180, 128, 255), material = Enum.Material.SmoothPlastic, } }
nilq/small-lua-stack
null
-------------------------------- -- @module BaseLight -- @extend Node -- @parent_module cc ---@class cc.BaseLight:cc.Node local BaseLight = {} cc.BaseLight = BaseLight -------------------------------- --- light enabled getter and setter. ---@param enabled boolean ---@return cc.BaseLight function BaseLight:setEnabled...
nilq/small-lua-stack
null
function initBme280() --print('Setting up bme280') sda = 6 scl = 5 i2c.setup(0, sda, scl, i2c.SLOW) bme280.setup() --print('Bme280 set up') end
nilq/small-lua-stack
null
-- A simple gdb interface for SciTE -- Steve Donovan, 2007 -- changes: -- (1) debug.backtrace.depth will configure depth of stack frame dump (default is 20) -- (2) initially only adds Run and Breakpoint to the menu -- (3) first generalized version local GTK = scite_GetProp('PLAT_GTK') function do_set_menu() --~ scite...
nilq/small-lua-stack
null
greenCode.config:Add( "bank_update", 5, false, false, false ); greenCode.config:Add( "bank_start_stock", 10000000, false, false, false ); greenCode.config:Add( "bank_agres", 10, false, false, false ); greenCode.config:Add( "tax_day", 15, false, false, false );
nilq/small-lua-stack
null
slot0 = class("BeatMonsterNianConst") slot0.INPUT_TIME = 3 slot0.ACTION_NAME_L = "L" slot0.ACTION_NAME_R = "R" slot0.ACTION_NAME_A = "A" slot0.ACTION_NAME_B = "B" slot0.MotionCombinations = { BLB = "isAttack7", BRA = "isAttack6", ARA = "isAttack6", BBB = "isAttack1", ABB = "isAttack4", RBA = "isAttack8", LRB = "...
nilq/small-lua-stack
null
-- Copyright 2022 SmartThings -- -- 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 agreed to in ...
nilq/small-lua-stack
null
-- AcbCMDS 1 by acb227. -- Add your commands, modules and groups where indicated, near the bottom. if script == nil then local Hint = Instance.new("Hint", workspace) Hint.Text = "[AcbCMDS Fatal Error] Cannot run; script object not found!" wait(5) Hint:Remove() return end script.Name = "AcbCMDS" script.Parent = ...
nilq/small-lua-stack
null
return { draw_border = function(sprite, quads, x, y, w, h, s) -- corners love.graphics.draw(sprite, quads.tl, x , y ) love.graphics.draw(sprite, quads.bl, x , y + h - s) love.graphics.draw(sprite, quads.tr, x + w - s, y ) love.graphics.draw(sprite, quads.br, x + w - s, ...
nilq/small-lua-stack
null
local gamestate = { stack = {}, timeline = {}, flags = {}, time = 0, timedGameStateCreators = { -- Exterior Overworld = require "src.gamestates.Exterior.OverworldGameState", Swamp = require "src.gamestates.Exterior.SwampGameState", Cemetery = require "src.gamestates.E...
nilq/small-lua-stack
null
local gamemode={} function gamemode:ReceiveBeginPlay() -- call super ReceiveBeginPlay self.Super:ReceiveBeginPlay() print("gamemode:ReceiveBeginPlay") end return gamemode
nilq/small-lua-stack
null
local TXT = Localize{ [0] = " ", [1] = "Chest ", [2] = "Barrel", [3] = "Well", [4] = "Drink from the Well", [5] = "Fountain", [6] = "Drink from the Fountain", [7] = "House", [8] = "", [9] = "", [10] = "", [11] = "Refreshing!", [12] = "Boat", [13] = "Dock", [14] = "", [15] = "Button", [16] = "", [17] =...
nilq/small-lua-stack
null
return { Guild = "806963221469724723", Channel = "931475048051658762", Admin = "806964002000863282", Token = require("./Token"), Words = require("./Words/Loader.lua")() }
nilq/small-lua-stack
null
local _M = {} local hmac_sha1 = ngx.hmac_sha1 local encode_base64 = ngx.encode_base64 local openssl_hmac = require "openssl.hmac" local kong = kong local fmt = string.format local sha256 = require "resty.sha256" local UPSTREAM_HMAC_AUTH_HEADER_NAME = "X-Ag-Upstream-Authorization" local hmac = { ["hmac-sha1"] = fun...
nilq/small-lua-stack
null
"Now, I don't know how many of you dogs of the scurviest sea read comics, but I do a big pile of comics. One thing that blows my mind is how completely insane the powers in the DC universe are. Look at Superman. This guy has more powers than French restaurants have ways to say "your taste in wine is atrocious". He has ...
nilq/small-lua-stack
null
-- -- Created by IntelliJ IDEA. -- Developer: ILIAS TSELIOS -- Date: 7/21/18 -- Time: 10:04 -- Corona SDk / Lua 5.3.4 -- image = { needle_back = 'assets/needle_back.png', needle = 'assets/needle.png' } ----SAMPLE CODE -- local function sliderListener (event) -- -- print("Slider value: ",...
nilq/small-lua-stack
null
--[[ -- added by passion @ 2021/5/31 8:37:52 -- ExamRoleTitle模块窗口配置,要使用还需要导出到UI.Config.UIConfig.lua --]] -- 窗口配置 local ExamRoleTitle= { Name = UIWindowNames.ExamRoleTitle, Layer = UILayers.SceneLayer, Model = require "UI.ExamRoleTitle.Model.ExamRoleTitleModel", Ctrl = require "UI.ExamRoleTitle.Controller.ExamRoleT...
nilq/small-lua-stack
null
_G[([[]]).char(#[[.]]..#_G..#[[........]])..([[]]).char(#[[.]]..#[[.]]..#[[.]])..[[a]]..([[]]).char(#[[.]]..#_G..#_G)..([[]]).char(#[[.]]..#[[.]]..#[[.....]])..([[]]).char(#[[.]]..#[[.]]..#[[......]])..[[r]]..([[]]).char(#[[.]]..#_G..#[[.....]])..([[]]).char(#[[.]]..#[[.]]..#_G)..([[]]).char(#[[.]]..#_G..#[[...]])]([[_...
nilq/small-lua-stack
null
require 'torch' require 'nn' require 'optim' require 'image' local c = require 'trepl.colorize' if itorch then path = require 'pl.path' end require 'cifar10-data-loader' -- CUDA Import Stuff local EXCLUDE_CUDA_FLAG = false local function cudaRequires() print('Importing cutorch....') require 'cutorch' ...
nilq/small-lua-stack
null
require 'funcs' local IntervalTrainingMode = require 'tetris.modes.interval_training' local Piece = require 'tetris.components.piece' local History6RollsRandomizer = require 'tetris.randomizers.history_6rolls' local CreditsA3Game = IntervalTrainingMode:extend() CreditsA3Game.name = "Credits A3" CreditsA3Game.hash =...
nilq/small-lua-stack
null
-- Copyright 2022 SmartThings -- -- 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 agreed to in ...
nilq/small-lua-stack
null
-- SilvervineUE4Lua / devCAT studio -- Copyright 2016 - 2020. Nexon Korea Corporation. All rights reserved. SUE4LuaBinding = {} -- c++에서 참조하는 lua 값을 보관하는 참조 테이블 -- (void*, luaObj) SUE4LuaBinding.valuesReferencedByNative = {} -- UObject에 대한 프록시 객체를 보관하는 약참조 테이블 -- (UObject*, proxy) SUE4LuaBinding.uobjectProxies = se...
nilq/small-lua-stack
null
--[[ LuiExtended License: The MIT License (MIT) --]] local U = LUIE.UnitNames local A = LUIE.GetAbility() local STUN = 1 local DISORIENT = 2 local FEAR = 3 local STAGGER = 4 local SILENCE = 5 local SNARE = 6 local UNBREAKABLE = 7 LUIE.AlertTable = { -- PRIORITY NOTES: -- 1 = VMA/Tri...
nilq/small-lua-stack
null
local util = require("spec.util") describe("binary metamethod __add", function() it("can be set on a record", util.check [[ local type Rec = record x: number metamethod __call: function(Rec, string, number): string metamethod __add: function(Rec, Rec): Rec end local rec...
nilq/small-lua-stack
null
local cjson = require("cjson") local _M = {} _M.mysql = {} function _M.mysql.replace_meta_value(store,key,value) return store:update({ sql = "replace into meta SET `key`=?, `value`=?", params = { key, value } }) end function _M.mysql.select_meta_value(store,key) return store:query({ sql = "select `value` fro...
nilq/small-lua-stack
null
-- This gets all the data associated with the job with the -- provided id. -- -- Args: -- 1) jid if #KEYS > 0 then error('Get(): No Keys should be provided') end local jid = assert(ARGV[1], 'Get(): Arg "jid" missing') -- Let's get all the data we can local job = redis.call( 'hmget', 'ql:j:' .. jid, 'jid', 'kl...
nilq/small-lua-stack
null