content
stringlengths
0
1.05M
origin
stringclasses
2 values
type
stringclasses
2 values
headToolbarLayout= { name="headToolbarLayout",type=0,typeName="View",time=0,x=0,y=0,width=1280,height=720,visible=1,nodeAlign=kAlignTopLeft,fillParentWidth=1,fillParentHeight=1, { name="per_info_bg",type=0,typeName="Image",time=107172465,x=0,y=0,width=1246,height=64,nodeAlign=kAlignBottom,visible=1,fillParentWidth=...
nilq/small-lua-stack
null
--local Model = require( 'models/base' ) local MuutForum = class( 'MuutForum' ) --, Model ) MuutForum.static.key = '[]' MuutForum.static.secret = '[]' function MuutForum.sso( personid, name, email, is_admin ) local is_admin = is_admin or false local results = { key = MuutForum.static.key, timestamp = ng...
nilq/small-lua-stack
null
ITEM.name = "SSP-99 suit" ITEM.model ="models/kek1ch/ecolog_outfit_orange.mdl" ITEM.newModel ="models/nasca/stalker/male_ssp_eco.mdl" ITEM.description= "An SSP-99 suit, used by ecologists." ITEM.longdesc = "A SSP-99 Scientific Research suit specially designed for the Zone conditions. It is used by scientific expedition...
nilq/small-lua-stack
null
require 'cunn' -- example of extracting descriptors on GPU N = 76 -- the number of patches to match patches = torch.rand(N,1,64,64):cuda() -- load the network net = torch.load'../networks/siam2stream/siam2stream_liberty_nn.t7':cuda() print(net) -- to extract the descriptors we need a branch of the first parallel mo...
nilq/small-lua-stack
null
local alpha = require("alpha") local dashboard = require("alpha.themes.dashboard") -- Set header dashboard.section.header.val = { " ", " ███╗ ██╗███████╗ ██████╗ ██╗ ██╗██╗███╗ ███╗ ", " ████╗ ██║██╔════╝██╔═══██╗██║ ██║██║████╗ ████║ ", " ...
nilq/small-lua-stack
null
RuneSystem = CreateModule("RuneSystem", GAME_PHASE_GAME) local spawnTicket = {}; function RuneSystem:Init() self.gameManager = GetGameManager() self.gameManager:RegisterVariable("Rune_Spawn_Interval", 120) self.gameManager:RegisterVariable("First_Rune_Spawn_Time", 25) self.RuneSpawners = GameManagerRequestBus.B...
nilq/small-lua-stack
null
outputFiles = { NormvolumeCumulative={ --experimental data filename="Collecteddata/data_7_cities.csv", selected_columns=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14], }
nilq/small-lua-stack
null
-- rIngameModelViewer -- zork 2011 --------------------------------------------------------------------- -- DO NOT TOUCH ANYTHING HERE --------------------------------------------------------------------- local cfg = { size = 200, page = 1, num = 0, rows = 0, cols = 0, ...
nilq/small-lua-stack
null
local lambda = require "lambda" local t = require "testhelper" -- lambda-like syntax t( 1, lambda"x|x+1"( 0 ) ) -- multiple arguments t( 4, lambda"x,y|x+y"( 1, 3 ) ) -- additional statement, only the last expression is returned t( 3, lambda"x| x=x+1; x+1"( 1 ) ) -- default args are a,b,c,d,e,f,...( vararg ) t( 1, l...
nilq/small-lua-stack
null
return function() local liter = require(game:GetService('ReplicatedStorage').liter) it('should return the successor and then nil', function() local iter = liter.successors(1, function(number) local new = number * 10 return new <= 10_000 and new or nil end) expect(iter:after()).to.equal(1) ex...
nilq/small-lua-stack
null
--- Recipe class -- @classmod Recipe local Recipe = { _class = "Recipe" } setmetatable(Recipe, {__index = require("stdlib/data/data")}) local Item = require("stdlib/data/item") function Recipe:_get(recipe) return self:get(recipe, "recipe") end Recipe:set_caller(Recipe._get) -- Returns a formated ingredient ...
nilq/small-lua-stack
null
local ffi = require "ffi" local bit = require "bit" local bnot = bit.bnot local band = bit.band local bor = bit.bor local lshift = bit.lshift local rshift = bit.rshift -- Contains the protypes for the vchi functions. require "vcos" require "vchi_cfg" require "vchi_common" require "connection" require "vchi_mh" VC...
nilq/small-lua-stack
null
print("Hello from Lua") print(" Arguments:", arg) freq_ghz = sim.config.get("perf_model/core/frequency") print(" core frequency = ", freq_ghz, "GHz") sim.hooks.register(sim.hooks.HOOK_ROI_BEGIN, function() sim.dvfs.set_frequency(0, 3.92) end) function roi_end() print("ROI end from Lua") time_fs = sim...
nilq/small-lua-stack
null
-- LovePainter/Border --[[ TODO draw line type "double". ]]-- module("LovePainter.Border", package.seeall) require "Tools/Object" local Border = {} function Border.initialize(style,width,color) local obj = { width= width or 1, color=color or {love.graphics.getColor()}, style=style or 'solid', hidden=false, corne...
nilq/small-lua-stack
null
--[[ changes an attribute of an entity. Simple not requiring verification. This is not setup for sharding yet but does take mining fees (as supplied by the originator). KEYS[1] is originator pubKey (inserted automatically). Pays mining fees KEYS[2] is entity to update TODO: take in counter to ma...
nilq/small-lua-stack
null
return { ["NameLimit"] = 7, ["HitCorrection"] = 1, ["InitItem"] = { 1001, 1002, 1003 }, ["InitMission"] = { "M101", "M102" } }
nilq/small-lua-stack
null
local a=20140920.13;local b="-[ JSON.lua package by Jeffrey Friedl (http://regex.info/blog/lua/json) version 20140920.13 ]-"local OBJDEF={VERSION=a,AUTHOR_NOTE=b}local c={__tostring=function()return"JSON array"end}c.__index=c;local d={__tostring=function()return"JSON object"end}d.__index=d;function OBJDEF:newArray(e)re...
nilq/small-lua-stack
null
#!/usr/bin/lua local url = require "socket.url"; for smtp_url in io.lines() do local parsed_url = url.parse(smtp_url); print("# "..smtp_url); for k, v in pairs(parsed_url) do print("# "..k.." = "..v) end print "" local protocol = parsed_url.scheme or "smtp"; local default_port = (protocol == "smtps" and 465) o...
nilq/small-lua-stack
null
local BannerText = mainForm:GetChildChecked('Announce', false ) BannerText:SetVal('value', GTL('ACTIVATE A BANNER!')) BannerText:SetClassVal('class', 'LogColorOrange' ) local StartCheck = false function CheckBuff(params) if StartCheck then if IsBannerActive() then BannerText:Show(false) else BannerText:Show(tru...
nilq/small-lua-stack
null
XYZUI = {} XYZUI.Config = {} XYZUI.Core = {} XYZUI.Elements = {} print("Loading XYZ UI 1") local path = "xyz_ui/" if SERVER then local files, folders = file.Find(path .. "*", "LUA") for _, folder in SortedPairs(folders, true) do print("Loading folder:", folder) for b, File in SortedPairs(file.Find(path ....
nilq/small-lua-stack
null
local HttpService = game:GetService("HttpService") local HttpError = {} HttpError.__index = HttpError HttpError.__tostring = function(he) return HttpService:JSONEncode(he) end HttpError.ErrorCodes = { BadRequest = 400, Unauthorized = 401, Forbidden = 403, NotFound = 404, ServerError = 500, } func...
nilq/small-lua-stack
null
function ENT:SetupDataTables() self:NetworkVar( "Int", 0, "Freq" ) self:NetworkVar( "Int", 1, "Range" ) self:NetworkVar( "Bool", 0, "Sending" ) self:NetworkVar( "Bool", 1, "Online" ) self:NetworkVar( "Bool", 2, "Hearable" ) self:NetworkVar( "Bool", 3, "Radio" ) self:NetworkVar( "Entity", 0, "Speaker" ) end func...
nilq/small-lua-stack
null
-- -*- coding:utf-8 -*- --- 数据库实例. -- 使用具体的技术(mysql 等)实现一个持久化数据库。 -- @classmod example_db -- @author:phenix3443@gmail.com local cjson = require("cjson.safe") local class = require("pl.class") local mysql_helper = require("database.mysql_helper") local M = class(mysql_helper) --- 示例程序. --查询数据库版本信息 function M:get_mys...
nilq/small-lua-stack
null
-- add lua implementations of the intersection functions l1 = { a = vec3d(0,0,0), b = vec3d(100,0,100) } l2 = { a = vec3d(70,0,0), b = vec3d(0,0,100) } c1 = { c = vec3d(10,0,40), r = 50 } c2 = { c = vec3d(10,0,-40), r = 50 } function renderLine(l) drawLine(l.a.x, l.a.y, l.a.z, l.b.x, l.b.y, l.b.z) end f...
nilq/small-lua-stack
null
-- physics tests import('GlobalVars') import('PrintRecursive') import('Physics') local messages = { "Velocity X:", "Velocity Y:", "Position X:", "Position Y:", "Press ESC to go to main menu" } local objects = {} local dt = 0 local st = 0 local lastTime = 0 local testSelected = false local testNum = 0 local forceToApp...
nilq/small-lua-stack
null
local meta = FindMetaTable("Entity") function meta:IsDestructible() return self:GetClass() == "prop_physics" end function meta:GetStable() return self:GetNWBool("Stable") end function meta:GetDamaged() return self:GetNWBool("Damaged") end function meta:GetRecoveryPerOnce() return self...
nilq/small-lua-stack
null
/sc --[[ solar ]] local stats = (game.player.selected or game.player.surface.find_entities_filtered{type="electric-pole",limit=1,position=game.player.position,radius=32}[1] or error("Script needs mouseover of electric pole.", 0)).electric_network_statistics local function printf(...) game.print(string.format(...)) ...
nilq/small-lua-stack
null
require 'settings/autocmds' local api = vim.api local o = vim.o local g = vim.g api.nvim_set_option('omnifunc', 'v:lua.vim.lsp.omnifunc') -- Leader key configuation -- https://learnvimscriptthehardway.stevelosh.com/chapters/06.html g.mapleader = "\\" -- define leader key g.localmapleader = "," -- define lo...
nilq/small-lua-stack
null
local selected = turtle.getSelectedSlot() local ingredients = {} local result = turtle.getItemDetail(selected) for i=1, 16 do if i ~= selected then table.insert(ingredients, turtle.getItemDetail(i)) end end if result == nil or #ingredients == 0 then print("Please put the ingredients in the turt...
nilq/small-lua-stack
null
-- -- (C) 2016 Kriss@XIXs.com -- local coroutine,package,string,table,math,io,os,debug,assert,dofile,error,_G,getfenv,getmetatable,ipairs,Gload,loadfile,loadstring,next,pairs,pcall,print,rawequal,rawget,rawset,select,setfenv,setmetatable,tonumber,tostring,type,unpack,_VERSION,xpcall,module,require=coroutine,package,str...
nilq/small-lua-stack
null
--====================================================================-- -- Lua Corovel Unit Tests -- -- Sample code is MIT licensed, the same license which covers Lua itself -- http://en.wikipedia.org/wiki/MIT_License -- Copyright (C) 2014-2015 David McCuskey. All Rights Reserved. --===================================...
nilq/small-lua-stack
null
-- table-utils.lua: tests for small table utilities -- This file is a part of lua-nucleo library -- Copyright (c) lua-nucleo authors (see file `COPYRIGHT` for the license) dofile('lua-nucleo/strict.lua') dofile('lua-nucleo/import.lua') local make_suite = select(1, ...) assert(type(make_suite) == "function") local en...
nilq/small-lua-stack
null
return { name = "truemedian/lfs", version = "0.1.2", description = "A libuv equivalent for the popular lfs library", tags = { "lua", "lfs", "filesystem" }, license = "MIT", author = { name = "Nameless", email = "truemedian@gmail.com" }, homepage = "https://keplerproject.github.io/luafilesystem", dependencies = ...
nilq/small-lua-stack
null
function CRATE:__installed__() AddCSLuaFile(self.__path__..'lib/markdown.min.lua') if !Markdown then Markdown = include(self.__path__..(SERVER and 'lib/markdown.lua' or 'lib/markdown.min.lua')) end end
nilq/small-lua-stack
null
events = {} EventType = { NEW_JOB = 0, LOST_JOB = 1, NEW_JOB_LOCATION = 2, NEW_CHILD = 3, NEW_SCHOOL_LOCATION = 4, ZONING_RULE_CHANGE = 5, } function addHouseHoldEvent (day, type, householdId) event = ExternalEvent() event.day = day; event.householdId = househo...
nilq/small-lua-stack
null
local parquet = require 'parquet' --local thrift_print_r = require 'thrift.print_r' local filename = 'model2-data-part-00002.parquet' --[[ KMeans model, trained and exported uncompressed with: $ docker run -it gettyimages/spark bin/spark-shell --conf spark.sql.parquet.compression.codec=uncompressed import org.apach...
nilq/small-lua-stack
null
bc.sidePanel.members.template = { member = { name = "Player", value = "SteamID", type = "options", options = { "Admin", "Member", "Remove" }, optionValues = { 0, 1, 2 }, default = 1, extra = "Set this player's role in the group", onChange = function( d...
nilq/small-lua-stack
null
object_intangible_saga_system_sage_intangible_holocron = object_intangible_saga_system_shared_sage_intangible_holocron:new { } ObjectTemplates:addTemplate(object_intangible_saga_system_sage_intangible_holocron, "object/intangible/saga_system/sage_intangible_holocron.iff")
nilq/small-lua-stack
null
local class = require("class") local common = require("common") local M = {} -- Lazy way to compare classes that is used generically. -- Would be more efficient to implement a __eq for each class. local function lazyEq(self, other) return common.tableEq(self, other) end -- Arithmetic expressions M.IntAexp = class(...
nilq/small-lua-stack
null
function love.draw() local x, y = love.mouse.getPosition() love.graphics.print("Hello World", x, y) end
nilq/small-lua-stack
null
local backupSpam = {} addEvent( "onPlayerPayfine", true ) addEventHandler( "onPlayerPayfine", root, function ( theMoney ) exports.AURpayments:takeMoney( source, theMoney,"DENpolice fine" ) exports.server:setPlayerWantedPoints( source, 0 ) exports.NGCdxmsg:createNewDxMessage(source,"You have paid $"..exports.server...
nilq/small-lua-stack
null
 --[[ $project: Give Me Peace $copyright: © Copyright Michael Boyle. All Rights Reserved. ]]-- -- -- Setup localisation. -- function Peace_Localisation() -- wheres this client then? local client_area = GetLocale(); -- this is the default silent whisper sent to players who were bl...
nilq/small-lua-stack
null
-- -- The Roller, or Metal Former, takes various metals or plates and forms them into other shapes. -- local Directions = assert(foundation.com.Directions) local is_blank = assert(foundation.com.is_blank) local itemstack_is_blank = assert(foundation.com.itemstack_is_blank) local format_pretty_time = assert(foundation.c...
nilq/small-lua-stack
null
--- -- Lua module to use a hd44780 compatible LCD display with the Raspberry Pi GPIO interface. -- @module GPIO.lcd-hd44780 -- -- based on code from lrvick, LiquidCrystal and Adafruit -- -- lrvic - `https://github.com/lrvick/raspi-hd44780/blob/master/hd44780.py` -- -- LiquidCrystal - `https://github.com/arduino/Arduino...
nilq/small-lua-stack
null
local games = require "src.games" local title = true local success = false local failure = false local updateTime = 0.2 local gameTime = 0 local game = games.create() function love.load() math.randomseed(os.time()) end function love.update(deltaTime) if (not title and not success and not failure) then ...
nilq/small-lua-stack
null
local jsp = require("./jspower.lua") local String = jsp.String print(String.fromCharCode(97)) -- a print(String.charAt("hello, world!",8)) -- w print(String.charCodeAt("hello, world!",8)) -- 119 print(String.concat("hello,", " lua!")) -- hello, lua! print(String.startsWith("banana", "ba")) -- true print(String.endsW...
nilq/small-lua-stack
null
-- Random utilities local glmath = require("moonglmath") local random = math.random local randomseed = math.randomseed local pi = math.pi local sqrt = math.sqrt local sin, cos = math.sin, math.cos local vec3 = glmath.vec3 local function uniform_hemisphere() local x1, x2 = random(), random() local s = sqrt(1.0- ...
nilq/small-lua-stack
null
-- Autogenerated from KST: please remove this line if doing any edits by hand! local luaunit = require("luaunit") require("nav_parent3") TestNavParent3 = {} function TestNavParent3:test_nav_parent3() local r = NavParent3:from_file("src/nav_parent2.bin") luaunit.assertEquals(r.ofs_tags, 8) luaunit.asser...
nilq/small-lua-stack
null
-- ADADELTA -- For single worker only -- Author: Minwei Feng (mfeng@us.ibm.com) require 'optim' function optim.adadeltasingle(opfunc, w, config, state) local config = config or {} local state = state or config local rho = config.rho or 0.9 local epsilon = config.epsilon or 1e-6 local pc = config.pclient or n...
nilq/small-lua-stack
null
CheckTimer = {} playerElement = nil function CreateCheckWindow() Window = {} Button = {} Label = {} Image = {} Window[1] = guiCreateWindow(28,271,454,248,"Player check.",false) --Button[1] = guiCreateButton(0.3524,0.8387,0.2026,0.0968,"Recon player.",true,Window[1]) --addEventHandler( "onClientGUIClick"...
nilq/small-lua-stack
null
-- // Name: http.lua -- // Description: HTTP request handler -- // Author: @Jumpathy -- // Credits: @evaera (promises) local http,internal = {},{}; local httpService = game:GetService("HttpService"); local promise = require(script:WaitForChild("promise")); local encode = function(...) return httpService:JSONEncode(...
nilq/small-lua-stack
null
for i,arg1 in pairs(arg) do print(i,arg1) end
nilq/small-lua-stack
null
--[[ Jamba - Jafula's Awesome Multi-Boxer Assistant Copyright 2008 - 2015 Michael "Jafula" Miller License: The MIT License ]]-- local L = LibStub("AceLocale-3.0"):NewLocale( "Jamba-Team", "enUS", true ) L["Slash Commands"] = true L["Team"] = true L["Core: Team"] = true L["Add"] = true L["Add a member to the team list....
nilq/small-lua-stack
null
local druid = require("druid.druid") local druid_style = require("example.ysdkdebug.druid_style") local yagames = require("yagames.yagames") local log_print = require("example.ysdkdebug.log_print") local print = log_print.print local M = {} function M.init(self) local is_desktop = gui.get_node("text_is_desktop")...
nilq/small-lua-stack
null
if SL.Global.GameMode == "StomperZ" then return end local player = ... local playerStats = STATSMAN:GetCurStageStats():GetPlayerStageStats(player) local grade = playerStats:GetGrade() local style = ThemePrefs.Get("VisualTheme") local c = GetCurrentColor() -- "I passd with a q though." local title = GAMESTATE:GetCur...
nilq/small-lua-stack
null
----------------------------------- -- Area: Labyrinth of Onzozo -- Mob: Labyrinth Manticore -- Note: Place holder Narasimha ----------------------------------- local ID = require("scripts/zones/Labyrinth_of_Onzozo/IDs") require("scripts/globals/regimes") require("scripts/globals/mobs") -------------------------------...
nilq/small-lua-stack
null
local KUI, E, L, V, P, G = unpack(select(2, ...)) local FQ = KUI:NewModule("FlightQueue", "AceEvent-3.0", "AceTimer-3.0") local queueSlotIndex = 0 local queueIsFerry = false local queueNodeID = 0 local queueContinent = 0 local bypass = false --local changed = false --local firstRun = false function GetCurrentMapConti...
nilq/small-lua-stack
null
function outlook_archive_email() hs.application.launchOrFocus("Microsoft Outlook") local outlook = hs.appfinder.appFromName("Microsoft Outlook") local str_archive = {"Message", "Archive"} local archive = outlook:findMenuItem(str_archive) outlook:selectMenuItem(str_archive) end hs.hotkey.bind({"c...
nilq/small-lua-stack
null
_.states['test'] = { tests = {}, coverage = {}, to_cover = {}, init = function(this) cls() print("loading coverage items...",5) local omitlist = {"draw", "update", "draw_path"} for cover, item in pairs(this.coverage) do for k,v in pairs(item) do if type(v) == 'function' and not con...
nilq/small-lua-stack
null
-- base global environment code to bootstrap a rascal thread -- defines detach, as a standard way to split off other threads -- copyright 2014 Samuel Baird MIT Licence -- lua modules local table = require('table') -- core module, class, array, queue local array = require('core.array') -- rascal lua globals -- debug ...
nilq/small-lua-stack
null
number = {} sign = {} oper = {} sp = "\( \) " min_range = 39 max_range = 60 test = 0 for i = 1,3 do number[i] = min_range - math.random(max_range); if (i > 1 and number[i] < 0) then test = 1 end end if (test == 0) then ch = 1 + math.random(2) number[ch] = -number[ch] end result = number[1] for i...
nilq/small-lua-stack
null
function onCreate() makeLuaSprite('bg','sky',-150,-600) addLuaSprite('bg',false) setLuaSpriteScrollFactor('bg', 0, 0) makeAnimatedLuaSprite('clouds','clouds',-5000,-300) addAnimationByPrefix('clouds','move','Float',24,true) addLuaSprite('clouds',false) objectPlayAnimation('clouds','move',false) setLuaSpriteSc...
nilq/small-lua-stack
null
-- Generated By protoc-gen-lua Do not Edit local protobuf = require "protobuf/protobuf" module('ItemFuse_pb') ITEMFUSE = protobuf.Descriptor(); local ITEMFUSE_FUSELEVEL_FIELD = protobuf.FieldDescriptor(); local ITEMFUSE_FUSEEXPCOUNT_FIELD = protobuf.FieldDescriptor(); ITEMFUSE_FUSELEVEL_FIELD.name = "fuseLevel" ITEM...
nilq/small-lua-stack
null
-- local null_ls = require("null-ls") -- local formatting = null_ls.builtins.formatting -- local diagnostics = null_ls.builtins.diagnostics -- local completion = null_ls.builtins.completion -- local sources = { -- sources = { -- -- Formatoes -- -- formatting.autopep8, -- -- formatting.isort, -- format...
nilq/small-lua-stack
null
-- Export all detail maps from legends -- version 1.0 gui = require 'gui' local vs = dfhack.gui.getCurViewscreen() local i = 0 local MAPS = { [0] = "Standard biome+site map", "Elevations including lake and ocean floors", "Elevations respecting water level", "Biome", "Hydrosphere", "Temperature", "Rainfall", ...
nilq/small-lua-stack
null
function onSay(cid, words, param, channel) local toPos = getCreatureLookPosition(cid) if(isInArray({"full", "all"}, param:lower())) then doCleanTile(toPos, false) doSendMagicEffect(toPos, CONST_ME_MAGIC_RED) return true end local amount = 1 param = tonumber(param) if(param) then amount = param end ...
nilq/small-lua-stack
null
object_tangible_quest_quest_start_ep3_hunt_loot_spiketop_horn = object_tangible_quest_quest_start_shared_ep3_hunt_loot_spiketop_horn:new { } ObjectTemplates:addTemplate(object_tangible_quest_quest_start_ep3_hunt_loot_spiketop_horn, "object/tangible/quest/quest_start/ep3_hunt_loot_spiketop_horn.iff")
nilq/small-lua-stack
null
local dict = { critical = "critical", error = "error", warning = "warning", info = "info", } local key_default = secrets:get("pagerduty_key_default") local routing_keys = { default = key_default, critical = secrets:get("pagerduty_key_critical") or key_default, error = secrets:get("pagerduty_k...
nilq/small-lua-stack
null
local var = ngx.var local i = var.a local j = var.b local sequare = require("sequare") local s1 = sequare:new(i, j) return s1:get_square()
nilq/small-lua-stack
null
test_run = require('test_run').new() -- -- gh-2677: box.session.push binary protocol tests. -- -- -- Usage. -- box.session.push() box.session.push(1, 'a') fiber = require('fiber') messages = {} test_run:cmd("setopt delimiter ';'") -- Do push() with no explicit sync. Use session.sync() by default. function do_pushes()...
nilq/small-lua-stack
null
--[=[ @class IKResource ]=] local BaseObject = require(script.Parent.Parent.Parent.Classes.BaseObject) local Janitor = require(script.Parent.Parent.Parent.Parent.Janitor) local IKResource = setmetatable({}, BaseObject) IKResource.ClassName = "IKResource" IKResource.__index = IKResource function IKResource.new(Data)...
nilq/small-lua-stack
null
--[[-- Initialization. This module handles the initialization of the plugin. ]] local kommentary = require("kommentary.kommentary") local config = require("kommentary.config") local util = require("kommentary.util") local M = {} local context = config.context local modes = config.get_modes() --[[-- Function to be cal...
nilq/small-lua-stack
null
if not pcall(node.flashindex("_init")) then return nil; end require("helper") require("ap") require("sta") require("udp") require("webserver") -- set dht11 pin dht_pin = 2 dht_info = {} dht_info.temp = nil dht_info.humi = nil -- set wifi mode wifi.setmode(wifi.STATIONAP) -- set egc mode node.egc.setmode(node.eg...
nilq/small-lua-stack
null
-- String: A text entry that will send whenever it loses focus nzu.AddExtensionSettingType("String", { NetRead = net.ReadString, NetWrite = net.WriteString, Panel = { Create = function(parent) local p = vgui.Create("DTextEntry", parent) p:SetTall(40) function p:OnFocusChanged(b) if not b then p:Send...
nilq/small-lua-stack
null
SkillConfig = { } SkillConfig[100001]={id=100001,remark='技能描述',type=1,icon='icon_skill_0000',name='Base',cooldown=0,animName='skill1'} SkillConfig[100002]={id=100002,remark='技能描述',type=1,icon='icon_skill_0001',name='Base',cooldown=0,animName='skill2'} SkillConfig[100003]={id=100003,remark='技能描述',type=1,icon='icon_skill...
nilq/small-lua-stack
null
object_ship_bwing_tier8 = object_ship_shared_bwing_tier8:new { } ObjectTemplates:addTemplate(object_ship_bwing_tier8, "object/ship/bwing_tier8.iff")
nilq/small-lua-stack
null
local RTG = {} local RTGTypes = { "image", "gif" } function RTG:Init() self.offset = { ["x"] = 0, ["y"] = 0, ["w"] = 0, ["h"] = 0 } self.useOffset = false self.doRender = true self.prevDoRender = true self.color = Color( 255, 255, 255, 255 ) self.sizeScale = nil end function RTG:SetSizeScale( ...
nilq/small-lua-stack
null
--[[ Jamba - Jafula's Awesome Multi-Boxer Assistant Copyright 2008 - 2015 Michael "Jafula" Miller License: The MIT License ]]-- local L = LibStub("AceLocale-3.0"):NewLocale( "Jamba-QuestWatcher", "enUS", true ) L["Slash Commands"] = true L["Quest"] = true L["Quest: Watcher"] = true L["Quest Watcher"] = true L["Push Se...
nilq/small-lua-stack
null
-------------------------------------------------------------------------------- --- Head: Require -- -- Standard awesome library local gears = require("gears") local awful = require("awful") require("awful.autofocus") -- Widget and layout library local wibox = require("wibox") -- -- Tail: Require ----------------...
nilq/small-lua-stack
null
-- Beatmap Download List -- Part of Live Simulator: 2 -- See copyright notice in main.lua local love = require("love") local Luaoop = require("libs.Luaoop") local JSON = require("libs.JSON") local AssetCache = require("asset_cache") local Gamestate = require("gamestate") local LoadingInstance = require("loa...
nilq/small-lua-stack
null
-- -- This test checks that when the WAL thread runs out of disk -- space it automatically deletes old WAL files and notifies -- the TX thread so that the latter can shoot off WAL consumers -- that need them. See gh-3397. -- test_run = require('test_run').new() engine = test_run:get_cfg('engine') fio = require('fio') ...
nilq/small-lua-stack
null
local main = require(game.Nanoblox) local User = require(main.shared.Packages.Remote.ClientRemote) return User
nilq/small-lua-stack
null
--- A defines module for retrieving colors by name. -- Extends the Factorio defines table. -- @usage require('stdlib/utils/defines/anticolor') -- @module defines.anticolor -- @see Concepts.Color --- Returns white for dark colors or black for lighter colors. -- @table anticolor -- @tfield Concepts.Color green defines.c...
nilq/small-lua-stack
null
OptionsState = Class { __includes = BaseState } local noTrailImage = love.graphics.newImage('assets/images/noTrail.png') local TrailImage = love.graphics.newImage('assets/images/trail.png') local musicSlider local SFXValue function OptionsState:enter(params) self.suit = Suit.new() settingsOption = { ...
nilq/small-lua-stack
null
----------------------------- ----------------------------- ---------BASE CODE----------- ----------------------------- ----------------------------- --RECT ----------------------------- function Rect_new(self, x, y, width, height) self.type = "Rect" self.x = x or 0 self.y = y or self.x self.width = width or 0 se...
nilq/small-lua-stack
null
render = {} if DrawSprite then render.white_sprite = LoadSprite("../../mods/umf/assets/image/white.png") render.white_fade_sprite = LoadSprite("../../mods/umf/assets/image/white_fade.png") render.frame_sprite = LoadSprite("../../mods/umf/assets/image/frame.png") render.grid_sprite = LoadSprite("../../mods/umf/ass...
nilq/small-lua-stack
null
--[[ Copyright (C) 2018 Google Inc. 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 option) any later version. This program is distributed in the hope th...
nilq/small-lua-stack
null
return { summary = 'Load a file as Lua code.', description = 'Load a file containing Lua code, returning a Lua chunk that can be run.', arguments = { { name = 'filename', type = 'string', description = 'The file to load.' } }, returns = { { name = 'chunk', type = 'fun...
nilq/small-lua-stack
null
local utils = require 'utils.utils' local net_utils = {} local c = require 'trepl.colorize' function net_utils.decode_sequence(ix_to_word, seq) local D,N = seq:size(1), seq:size(2) local out = {} for i=1,N do local txt = '' for j=1,D do local ix = seq[{j,i}] local word = ix_to_word[tostring(i...
nilq/small-lua-stack
null
local function openArrestMenu(npc, prisoner) local frame = XYZUI.Frame("Arrest Someone", Color(200, 100, 40)) frame:SetSize(ScrH()*0.4, ScrH()*0.6) frame:Center() local shell = XYZUI.Container(frame) --shell:DockPadding(5, 5, 5, 5) shell.Paint = nil local stateCache = {} local _, punishmentList = XYZUI.Lists(...
nilq/small-lua-stack
null
local Action = require "action" local Consume = Action:extend() Consume.name = "eat" Consume.targets = {targets.Item} function Consume:perform(level) local consumable = self:getTarget(1) level:destroyActor(consumable) end return Consume
nilq/small-lua-stack
null
local LAM2 = LibStub:GetLibrary("LibAddonMenu-2.0") ----------------- ---- Globals ---- ----------------- AsylumOlorime = AsylumOlorime or { } local AsylumOlorime = AsylumOlorime AsylumOlorime.name = "AsylumOlorime" AsylumOlorime.version = "1.1.3" AsylumOlorime.groupMembers = {} timeLeft = {0,0,0,0,0,0,0,0...
nilq/small-lua-stack
null
local CorePackages = game:GetService("CorePackages") local Rodux = require(CorePackages.Rodux) local InspectAndBuyFolder = script.Parent.Parent local ShowMenu = require(InspectAndBuyFolder.Actions.ShowMenu) local HideMenu = require(InspectAndBuyFolder.Actions.HideMenu) return Rodux.createReducer( true , { [ShowMenu....
nilq/small-lua-stack
null
DLCore.Functions = {} DLConfig.Server.Webhooks = { ["default"] = "https://discordapp.com/api/webhooks/859758099048693770/i4NaZNhVrdxtWAm7oqfyOfBDtXJIn409nY0FAhgCCK4Lu5RkP2ezSdbYDVBKnSwzPyx9", ["dropped"] = "https://discordapp.com/api/webhooks/859758217638576158/oYf7TtXbV3i6T46ULujg9_sSc3O80hgBehxRYQPeYBJCn8S...
nilq/small-lua-stack
null
--[[ Server Name: AuroraRPG Resource Name: AURjob_miner Version: 1.0 Developer/s: Curt ]]-- local minerPositions = { {-360.34240722656, 2169.6997070313, -13.902812957764}, {-347.7375793457, 2178.6799316406, -13.902812957764}, {-356.66101074219, 2180.265625, -13.902812957764}, {-348.71392822266, 2167.4548339844, -1...
nilq/small-lua-stack
null
local path = minetest.get_modpath("giants") giants = {} local mod_storage = minetest.get_mod_storage() local storagedata = mod_storage:to_table() -- Assuming there are only messages in the mod configuration --print("storage data: \n") --print(dump(storagedata)) if storagedata ~= nil then --print("loading group ...
nilq/small-lua-stack
null
-------------------------------- -- @module EaseQuinticActionOut -- @extend ActionEase -- @parent_module cc ---@class cc.EaseQuinticActionOut:cc.ActionEase local EaseQuinticActionOut = {} cc.EaseQuinticActionOut = EaseQuinticActionOut -------------------------------- --- ---@param action cc.ActionInterval ---@retur...
nilq/small-lua-stack
null
local tests = {} for i, file in ipairs(love.filesystem.getDirectoryItems("cases")) do if file:match(".lua$") then local thread = love.thread.newThread("cases/" .. file) thread:start() table.insert( tests, { name = file, thread = thread, } ) end end local RUNNING, ...
nilq/small-lua-stack
null
local ITEM = {}; ITEM.ID = 116; ITEM.Reference = "item_stim_pack"; ITEM.MaxStack = 100; ITEM.Weight = 5; ITEM.Cost = 300; ITEM.Name = "Stim Pack"; ITEM.Description = "Heals your wounds."; ITEM.InventoryModel = "models/healthvial.mdl"; ITEM.WorldModel = "models/healthvial.mdl"; ITEM.ModelCamPos = Vector(12, -4, 9); IT...
nilq/small-lua-stack
null
script_name("spawncar") script_author("dmitriyewich") script_url("https://vk.com/dmitriyewichmods") script_properties('work-in-pause', 'forced-reloading-only') script_version("0.1") local lffi, ffi = pcall(require, 'ffi') local lmemory, memory = pcall(require, 'memory') -- local imgui = require 'mimgui' loc...
nilq/small-lua-stack
null