content
stringlengths
0
1.05M
origin
stringclasses
2 values
type
stringclasses
2 values
local M = {} -- local function file_exists(filename) local f = io.open(filename, "r") if not f then return false end f:close() return true end -- set some default values local default_env = { -- these values are used in add.lua alphabet = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789", ...
nilq/small-lua-stack
null
_G.TURBO_SSL = true local turbo = require 'turbo' local uuid = require 'uuid' local ffi = require 'ffi' local md5 = require 'md5' require 'pl' torch.setdefaulttensortype('torch.FloatTensor') torch.setnumthreads(4) require './lib/portable' require './lib/LeakyReLU' local iproc = require './lib/iproc' local reconstruc...
nilq/small-lua-stack
null
-- Unlock recipes if mod was installed after technology was researched script.on_configuration_changed(function(e) for _, force in pairs(game.forces) do if force.technologies["nuclear-power"].researched then force.recipes["steamWorks-steam-expansion"].enabled = true end end end)
nilq/small-lua-stack
null
Sprite = Object:extend("Sprite") function Sprite.prototype:constructor(image) self.image = image or nil self.srcRect = Rect(0, 0, 1, 1) self.position = Point() self.scale = Point(1, 1) self.offset = Point() self.shearing = Point() self.quad = love.graphics.newQuad(0, 0, 1, 1, 1, 1) self.angle = 0 end ...
nilq/small-lua-stack
null
local function FacingWall(client) local data = {} data.start = client:EyePos() data.endpos = data.start + client:GetForward() * 20 data.filter = client if (!util.TraceLine(data).Hit) then return "@faceWall" end end local function FacingWallBack(client) local data = {} data.start = client:LocalToWorld(clien...
nilq/small-lua-stack
null
package.path = "./lua/?/init.lua;./lua/?.lua" local color_module = require("twilight.colors") local function write(str, filename) print("[write]: extra/" .. filename) local file = io.open("extras/" .. filename, "w") file:write(str) file:close() end local extras = { alacritty = "yml", fish = "fish", kitty = "c...
nilq/small-lua-stack
null
return { ignore={ -- optimization=true, -- debug=true, -- reserved msvc_isystem={force_system_flag=true}, }, _option_strs = {}, start=function(_, optprefix) _:_vcond_init({ _not='not', _and='and', _or='or', openblock='', closeblock='', ifopen='', ifclose...
nilq/small-lua-stack
null
function get_selected_tracks() tracks = {} for index = 0, reaper.CountSelectedTracks() do track = reaper.GetSelectedTrack(0, index) table.insert(tracks, track) end return tracks end --effectively, distance between leftmost-panned and rightmost --remember that 0.0 is center, -1.0 is 100% left etc ...
nilq/small-lua-stack
null
local g_RegisterJobWithColor local g_RegisterJobWithCategory local function RegisterJobCategory(name, color) g_RegisterJobWithColor = color or Color(255, 0, 0) g_RegisterJobWithCategory = name or "Other" end --[[--------------------------------------------------------------------------- DarkRP custom jobs --------...
nilq/small-lua-stack
null
-- Copyright 2016 The Cartographer Authors -- -- 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...
nilq/small-lua-stack
null
modifier_mars_counter_displacement = class({}) function modifier_mars_counter_displacement:OnCreated(params) if IsServer() then self.meele_stun_duration = self:GetAbility():GetSpecialValueFor('meele_stun_duration') end end function modifier_mars_counter_displacement:OnDestroy() if IsServer() then self:Ge...
nilq/small-lua-stack
null
function readfile(path) local f = assert(io.open(path,'r')) local ctx = f:read('*a') f:close() return ctx end function savefile(file,data) local f = assert(io.open(file,'w')) f:write(data) f:close() end function dump(t,i) for k,v in pairs(t) do...
nilq/small-lua-stack
null
return {'roro','roroschip','rorschachtest','rory','rorije','roroschepen','rorschachtests','rorys'}
nilq/small-lua-stack
null
local hit_effects = require ("__base__/prototypes/entity/demo-hit-effects") local sounds = require("__base__/prototypes/entity/demo-sounds") data:extend( { { type = "item", name = "colonists-generator", icon = "__base__/graphics/icons/steam-engine.png", icon_size = 64, icon_mipmaps ...
nilq/small-lua-stack
null
local monitor = {} -- Monitor utility module monitor.iMonitor = nil monitor.nativeTerm = nil monitor.oldCursor = {} -- Set the monitor to be used by all the other functions -- Should be the peripheral name of the monitor function monitor.set(monitorName) iMonitor = peripheral.wrap(monitorName) end -- Cl...
nilq/small-lua-stack
null
local filesystem = require('gears.filesystem') -- Thanks to jo148 on github for making rofi dpi aware! local with_dpi = require('beautiful').xresources.apply_dpi local get_dpi = require('beautiful').xresources.get_dpi local rofi_command = 'env /usr/bin/rofi -dpi ' .. get_dpi() .. ' -width ' .. with_dpi(400) .. ' -show...
nilq/small-lua-stack
null
class("Rect", Shape) { create = function(self) self.view = display.newRect(self.x, self.y, self.width, self.height) Shape.create(self) end }
nilq/small-lua-stack
null
data:extend( { -- update speed modules { type = "recipe", name = "speed-module", enabled = false, ingredients = { {"advanced-circuit", 5}, {"electronic-circuit", 5} }, energy_required = 10, result = "speed-module" }, { type = "recipe", name = ...
nilq/small-lua-stack
null
return { version = "1.2", luaversion = "5.1", tiledversion = "2018.11.14", orientation = "orthogonal", renderorder = "right-down", width = 33, height = 20, tilewidth = 64, tileheight = 64, nextlayerid = 62, nextobjectid = 22, properties = {}, tilesets = { { name = "autumn 16x32", ...
nilq/small-lua-stack
null
require "control.lua" require "text_control.lua" ---@class ListViewRow : ControlObject @Listview 컨트롤의 row 를 wrapping 한 클래스 ListViewRow = Class(ControlObject) -- 기본 색 ListViewRow.DEFAULT_BACKGROUND_COLOR = { Normal = { R = 0xFF, G = 0xFF, B = 0xFF }, Focused = { R = 0x00, ...
nilq/small-lua-stack
null
module('luatype', package.seeall) Player = Table({ id=Int, name = String, quote = Maybe(String), extra = Maybe(Table({ lv = Int, league = Maybe(Int), })), online = Bool, }) debug.dump(sample(Player), 'sample :: Player') function prop_test(a, b) local x = a ...
nilq/small-lua-stack
null
--[[ -- 32 lines of goodness. -- Links to original source of code and usage documentation: -- http://love2d.org/wiki/32_lines_of_goodness -- http://love2d.org/forums/viewtopic.php?f=5&t=3344 -- Patches by Robin and FSX (which bring it to 41 lines) --]] local mt_class = {__index = mt_class, __call = define} function m...
nilq/small-lua-stack
null
-------------------------------------------------------------------------- -- Access is the MCP mode that handles help message or whatis messages. -- almost all other module commands are ignored. -- @classmod MC_Access require("strict") -------------------------------------------------------------------------- -- Lmo...
nilq/small-lua-stack
null
-- Use of this source code is governed by the Apache 2.0 license; see COPYING. module(..., package.seeall) local S = require("syscall") local lib = require("core.lib") local numa = require("lib.numa") local ingress_drop_monitor = require("lib.timers.ingress_drop_monitor") local function fatal (msg) print(msg) ...
nilq/small-lua-stack
null
-- -- 长短链接映射api:加载长短链接配置到共享缓存中 -- author :wwh6 local BaseAPI = require("gateway.plugins.base_api") local common_api = require("gateway.plugins.common_api") local link = require("gateway.plugins.map_link.link") local api = BaseAPI:new("map_link-api", 2) api:merge_apis(common_api("map_link")) api:get("/map_link/reload"...
nilq/small-lua-stack
null
solution "mandelbrot" configurations {"debug", "release"} project "mandelbrot" language "C" kind "ConsoleApp" files {"*.h", "*.c"} buildoptions {"-std=c99"} flags { "ExtraWarnings", "FatalWarnings" } newoption { trigger = "with-output-image", description = "Enable output to image [default...
nilq/small-lua-stack
null
-- MIT License -- -- Copyright (c) 2017 Gabriel de Quadros Ligneul -- -- 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 u...
nilq/small-lua-stack
null
local function hello() return "Hello!" end return { Hello = {hello = hello} }
nilq/small-lua-stack
null
--------------------------------------------------------------------------------- -- -- Prat - A framework for World of Warcraft chat mods -- -- Copyright (C) 2006-2018 Prat Development Team -- -- This program is free software; you can redistribute it and/or -- modify it under the terms of the GNU General Public Licen...
nilq/small-lua-stack
null
local ngx_log = ngx.log local string_gsub = string.gsub local NGX_DEBUG = ngx.DEBUG local NGX_ERR = ngx.ERR local PrometheusLogger = {} PrometheusLogger.__index = PrometheusLogger local function map_labels(labels, values) mapped = {} for _, label in pairs(labels) do table.insert(mapped, valu...
nilq/small-lua-stack
null
--[[----------------------------------------------------------------------------------------------------------------------- Explode a player -----------------------------------------------------------------------------------------------------------------------]]-- local PLUGIN = {} PLUGIN.Title = "Explode" PLUGIN.Des...
nilq/small-lua-stack
null
-- !!!!!!!!!!!!!!!!!!!!!!! WARNING !!!!!!!!!!!!!!!!!!!!!!! -- This file is automaticly generated. Don't edit manualy! -- !!!!!!!!!!!!!!!!!!!!!!! WARNING !!!!!!!!!!!!!!!!!!!!!!! ---@alias CalendarCommandType number|"Enum.CalendarCommandType.CalendarCommandCreate"|"Enum.CalendarCommandType.CalendarCommandInvite"|"Enum.C...
nilq/small-lua-stack
null
local ffi = require "ffi" ffi.cdef[[ #pragma pack(push, 1) typedef struct { char x; double y; } foo; #pragma pack(pop) ]] assert(ffi.sizeof("foo") == 9)
nilq/small-lua-stack
null
-- this menu is applied as a context menu to the workspace- buttons in the statusbar return { {"CLI Group", "/global/open/terminal_group"}, {"Open", "/global/open/target"}, {"System", "/global/system"}, {"Settings", "/global/settings"}, {"Input", "/global/input"}, };
nilq/small-lua-stack
null
-- theme identification file themeInfo = { Name = "'Til Death", Version = "1.07", Date = "20161121" } function getThemeName() return themeInfo["Name"] end function getThemeVersion() return themeInfo["Version"] end function getThemeDate() return themeInfo["Date"] end
nilq/small-lua-stack
null
----------------------------------- -- Area: Wajaom Woodlands -- Mob: Jaded Jody ----------------------------------- function onMobDeath(mob, player, isKiller) end;
nilq/small-lua-stack
null
require "src/core/arrays" local flatmap = {} flatmap.__index = flatmap function flatmap.new() local self = setmetatable({}, flatmap) self.keys = {} self.values = {} return self end function flatmap.empty(self) return 0 == #(self.keys) end function flatmap.length(self) return #(self.keys) e...
nilq/small-lua-stack
null
local objecteffect = import("..common.NEObjectActionEffect") local UISpriteEx = {} function UISpriteEx:Init(parent, id, index, assetspath) self.parent = parent self.id = id or app.currentChapterID self.index = index or app.currentChapterIndex self.assetspath = (assetspath == nil and string.format("ChapterMat...
nilq/small-lua-stack
null
kShaderDefaultVsh = [[ attribute vec4 a_position; attribute vec2 a_texCoord; attribute vec4 a_color; #ifdef GL_ES varying mediump vec4 v_fragmentColor; varying mediump vec2 v_texCoord; #else varying vec4 v_fragmentColor; varying vec2 v_texCoord; #endif void main() { gl_Position = CC_PMatrix * a_position; v_fr...
nilq/small-lua-stack
null
local math_randomseed = math.randomseed local ngx = ngx local exports = {} exports.on_parse_conf = function(conf) math_randomseed(ngx.now() + ngx.worker.id()) return {} end return exports
nilq/small-lua-stack
null
return {'bed','bedaagd','bedaard','bedaardheid','bedacht','bedachtzaam','bedachtzaamheid','bedaking','bedankbrief','bedanken','bedankje','bedankt','bedaren','bedauwd','bedauwen','bedbank','bedbodem','bedden','beddenbak','beddencapaciteit','beddengoed','beddenhuis','beddenkruik','beddenkussen','beddenlaken','beddenpan',...
nilq/small-lua-stack
null
object_tangible_quest_corellia_disappearances_5_cage_2 = object_tangible_quest_shared_corellia_disappearances_5_cage_2:new { } ObjectTemplates:addTemplate(object_tangible_quest_corellia_disappearances_5_cage_2, "object/tangible/quest/corellia_disappearances_5_cage_2.iff")
nilq/small-lua-stack
null
local mappings = { { value = 1000, numeral = 'M' }, { value = 900, numeral = 'CM' }, { value = 500, numeral = 'D' }, { value = 400, numeral = 'CD' }, { value = 100, numeral = 'C' }, { value = 90, numeral = 'XC' }, { value = 50, numeral = 'L' }, { value = 40, numeral = 'XL' }, { value = 10, numeral = '...
nilq/small-lua-stack
null
-- Advent of Code 2018. Day 5, second part. -- Luis Delgado. local db = require "Process" Data_File="Data.txt"; local File = io.open (Data_File,"r"); function Tablecopy(Dest,Src) for k,v in pairs(Src) do table.insert(Dest,v) end end function ReducePolymer(Mem,PolymerSize) local MinSize = PolymerSize Dest = ni...
nilq/small-lua-stack
null
--[[ Copyright (c) 2013 David Young dayoung@goliathdesigns.com This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, ...
nilq/small-lua-stack
null
local util = require('wowless.util') local Mixin = util.mixin local function toTexture(parent, tex) if type(tex) == 'string' or type(tex) == 'number' then local t = parent:CreateTexture() t:SetTexture(tex) return t else return tex end end local function mkBaseUIObjectTypes(api) local log = api...
nilq/small-lua-stack
null
package.path = "./?.lua" local js = require("js") -- minimal shims just to allow the compilers to load in Fengari package.loaded.ffi = {typeof=function() end} os = {getenv=function() end} io = {open=function() end} bit = {band = function(a,b) return a & b end, rshift=function(a,b) return a >> b end} unpack = ta...
nilq/small-lua-stack
null
body = Cuboid(Point3D(0, 0, 0), Point3D(100, 100, 100)) lcs = LCS(Point3D(0, 0, 0)) Move(body, lcs)
nilq/small-lua-stack
null
modifier_upgrade_phantom_dash_damage = class({}) function modifier_upgrade_phantom_dash_damage:RemoveOnDeath() return false end function modifier_upgrade_phantom_dash_damage:IsPurgable() return false end function modifier_upgrade_phantom_dash_damage:OnCreated(params) self.range_bonus = 25 if IsServer() then ...
nilq/small-lua-stack
null
require 'funcs' local GameMode = require 'tetris.modes.gamemode' local Piece = require 'tetris.components.piece' local History6RollsRandomizer = require 'tetris.randomizers.history_6rolls' local PacerTest = GameMode:extend() PacerTest.name = "TetrisGram™ Pacer Test" PacerTest.hash = "PacerTest" PacerTest.tagline = ...
nilq/small-lua-stack
null
concommand.Add( "set_time", function( ply, cmd, args ) if IsValid(ply) and !ply:IsAdmin() then return end AirWars:SetTimeLeft(util.StringToType( args[1], "int" )) end )
nilq/small-lua-stack
null
local enabled = { enable = true } require'nvim-treesitter.configs'.setup { ensure_installed = 'all', indent = enabled, highlight = enabled, autotag = enabled, matchup = enabled, textobjects = { select = { enable = true, lookahead = true, keymaps = { ["af"] = "@function.outer", ...
nilq/small-lua-stack
null
-------------------------------------------------------------------------------- -- Module Declaration -- local mod, CL = BigWigs:NewBoss("Dargrul", 1458, 1687) if not mod then return end mod:RegisterEnableMob(91007) mod.engageId = 1793 --------------------------------------------------------------------------------...
nilq/small-lua-stack
null
module 'mock' local ccreate, cresume, cyield, cstatus = coroutine.create, coroutine.resume, coroutine.yield, coroutine.status local insert, remove = table.insert, table.remove -------------------------------------------------------------------- --FastForward ---------------------------------------------------------...
nilq/small-lua-stack
null
-- Natural Selection 2 Competitive Mod -- Source located at - https://github.com/xToken/CompMod -- lua\CompMod\Utilities\GameReporter\server.lua -- - Dragon gRankingDisabled = true -- ProGmod doesnt report back to UWE/stats/etc gDisableCompModReporting = false local kCompModReportingURL = "https://s8dhscedtd.execute-a...
nilq/small-lua-stack
null
--[[ Title: Common Load World Author(s): big CreateDate: 2021.01.20 ModifyDate: 2022.1.5 City: Foshan use the lib: ------------------------------------------------------------ local CommonLoadWorld = NPL.load('(gl)Mod/WorldShare/cellar/Common/LoadWorld/CommonLoadWorld.lua') ---------------------------------------------...
nilq/small-lua-stack
null
-- Helpers for searching and parsing tags local Tags = {} -- return [forward,backward] values for a specific tag. -- e.g. for maxspeed search forward: -- maxspeed:forward -- maxspeed -- and backward: -- maxspeed:backward -- maxspeed function Tags.get_forward_backward_by_key(way, data, key) local forward =...
nilq/small-lua-stack
null
function PresenceOfDeath(keys) local caster = keys.caster local ability = keys.ability local stacks = caster:GetModifierStackCount("modifier_boss_kel_thuzad_immortality", caster) local dmg_pct = ability:GetSpecialValueFor(caster:HasModifier("modifier_boss_kel_thuzad_immortality") and stacks <= ability:GetSpecialVal...
nilq/small-lua-stack
null
--------------------------------- --! @file ConnectorBase.lua --! @brief コネクタ基底クラス --------------------------------- --[[ Copyright (c) 2017 Nobuhiko Miyamoto ]] local ConnectorBase= {} --_G["openrtm.ConnectorBase"] = ConnectorBase ConnectorBase.ConnectorInfo = {} -- コネクタ情報格納オブジェクト初期化 -- @param name_ 名前 -- @param ...
nilq/small-lua-stack
null
local core = require "sys.core" local socket = require "sys.socket" local stream = require "http.stream" require "utils.tableutils" local assert = assert local tonumber = tonumber local sub = string.sub local find = string.find local format = string.format local gmatch = string.gmatch local insert = table.insert loca...
nilq/small-lua-stack
null
local utils = require("kong.plugins.pre-transform.utils") local plugin = { -- highest priority -- execute plugin at first PRIORITY = 1000001, VERSION = "0.1", } function plugin:access(plugin_conf) transform_request(plugin_conf) end function transform_request(plugin_conf) local transform_config = utils.ge...
nilq/small-lua-stack
null
modifier_earth_spirit_rolling_boulder_lua = class({}) -------------------------------------------------------------------------------- -- Classifications function modifier_earth_spirit_rolling_boulder_lua:IsHidden() return false end function modifier_earth_spirit_rolling_boulder_lua:IsDebuff() return false end fun...
nilq/small-lua-stack
null
---@class LevelTransmitWindow local LevelTransmitWindow = DClass("LevelTransmitWindow", BaseWindow) _G.LevelTransmitWindow = LevelTransmitWindow function LevelTransmitWindow:ctor(data) self.consoleId = data[1] --控制台ID self.levelId = data[2] --关卡ID end function LevelTransmitWindow:onInit() self:addEvent...
nilq/small-lua-stack
null
ep3_rryatt_gotal_hunter_trapper_02 = Creature:new { customName = "Gotal Hunter Trapper", randomNameType = NAME_GENERIC_TAG, socialGroup = "townsperson", faction = "", level = 85, chanceHit = 0.85, damageMin = 1200, damageMax = 1800, baseXp = 8500, baseHAM = 45000, baseHAMmax = 55000, armor = 3, resists = {...
nilq/small-lua-stack
null
--[[ Global constants ]] WINDOW_WIDTH = 1024 WINDOW_HEIGHT = 640 STATE_GAME_OVER = 0 STATE_PLAYING = 1 TILE_SIZE_X = 32 TILE_SIZE_Y = 32 MAX_TILES_X = WINDOW_WIDTH / TILE_SIZE_X MAX_TILES_Y = WINDOW_HEIGHT / TILE_SIZE_Y TILE_EMPTY = 0 TILE_SNAKE_HEAD = 1 TILE_SNAKE_BODY = 2 TILE_APPLE = 3 SNAKE_SPEED = 0.1 -- ...
nilq/small-lua-stack
null
-- scaffold geniefile for nkf nkf_script = path.getabsolute(path.getdirectory(_SCRIPT)) nkf_root = path.join(nkf_script, "nkf") nkf_includedirs = { path.join(nkf_script, "config"), nkf_root, } nkf_libdirs = {} nkf_links = {} nkf_defines = {} ---- return { _add_includedirs = function() includedirs { nkf_include...
nilq/small-lua-stack
null
--[[ Sample args format: KEYS: SAMPLE_CHANNEL SAMPLE_KEY_SET SAMPLE_DEL_KEY_SET _SAMPLE:key_0 _SAMPLE:key_1 ARGV: G (String to be published to channel) 2 (Count of objects to set) key_0 key_1 0 (Count of objects to del) 2 (Count of A/V pair of object 0) attribute_0 value_...
nilq/small-lua-stack
null
return function() require('spectre').setup({ color_devicons = true, line_sep_start = '┌-----------------------------------------', result_padding = '¦ ', line_sep = '└-----------------------------------------', highlight = { ui = "String", search = "DiffDel...
nilq/small-lua-stack
null
local function id(...) return ... end local function run(f) local co = coroutine.create(f) local function resume(ok, ...) if not ok then error(debug.traceback(co, ...), 0) end if coroutine.status(co) == "dead" then return end return resume(coroutine.resume(co, ...)) end return resume(true) end run(functio...
nilq/small-lua-stack
null
--Torso-- local h = Instance.new("Part") h.Name = "Handle" h.Parent = Workspace.acb227 h.Size = Vector3.new(1.9,2,1) h.formFactor = "Brick" h.BrickColor = BrickColor.new("Really black") h.TopSurface = "Smooth" h.BottomSurface = "Smooth" h.Transparency = 0 h.Reflectance = 0.3 ---------------------mesh m = In...
nilq/small-lua-stack
null
-- this file contains several tests for lupy basics require 'array' require 'curry' local class = require 'lupy' local namespace = class -- alias local module = class -- alias local printTable = compose(print, Array) -- namespace, module and class refers to the same function, but we assume this: -- 1. namespace is ju...
nilq/small-lua-stack
null
meths = b.a ns = meths.create_namespace 'test' meths.buf_clear_namespace(0, ns, 0, -1) vim.cmd [[hi Boldy gui=bold blend=50]] meths.buf_set_extmark(0, ns, 4, 0, { virt_text={{'|', 'LineNr'}}, virt_text_pos='overlay'}) meths.buf_set_extmark(0, ns, 5, 22, { virt_text={{'r aaaaa', 'Boldy'}}, virt_text_pos='overlay', hl_mo...
nilq/small-lua-stack
null
local Cache = require "Cache" local config = require "config" local assert = assert local Cached = { __Version__ = 0.1 } function Cached.init() Cached.__cache__ = Cache:new{ host = config.CACHED_HOST, port = config.CACHED_PORT, auth = config.CACHED_AUTH, max = config.CACHED_POOL, } return Cach...
nilq/small-lua-stack
null
local colors = require('colors') local gameDeckBasics = require('gameDeckBasics') local gameDeckCards = require('gameDeckCards') local gameUi = require('gameUi') local ui = require('ui') local utils = require('utils') local deck = gameDeckBasics.deck local discard = gameDeckBasics.discard local hand = gameDeckBasics.h...
nilq/small-lua-stack
null
--[[ Los Santos Customs V1.1 Credits - MythicalBro /////License///// Do not reupload/re release any part of this script without my permission ]] local Proxy = module("vrp", "lib/Proxy") local Tunnel = module("vrp", "lib/Tunnel") vRP = Proxy.getInterface("vRP") vRPclient = Tunnel.getInterface("vRP","lscustom") local ...
nilq/small-lua-stack
null
object_tangible_furniture_tatooine_uber_aurilia_obelisk = object_tangible_furniture_tatooine_shared_uber_aurilia_obelisk:new { } ObjectTemplates:addTemplate(object_tangible_furniture_tatooine_uber_aurilia_obelisk, "object/tangible/furniture/tatooine/uber_aurilia_obelisk.iff")
nilq/small-lua-stack
null
-- -- Created by IntelliJ IDEA. -- User: Sling -- Date: 10-03-2019 -- Time: 20:02 -- Made for CiviliansNetwork -- Citizen.CreateThread( function() while true do Citizen.Wait(200) for vehicle in EnumerateVehicles() do if vehicle ~= 0 then local plate = GetVehicleNumberPla...
nilq/small-lua-stack
null
local addOnName, ns = ...; local RPTAGS = RPTAGS; local Module = RPTAGS.queue:GetModule(addOnName); Module:WaitUntil("MODULE_F", function(self, event, ...) local layout = RPTAGS.utils.frames.RPUF_NewLayout("thumbnail", "small"); function get_frame_dimensions(self) return self:Public("ConfGet", "RPUF_...
nilq/small-lua-stack
null
-- initialization -- ensure imports are from file instead of cache local function import(path) package.loaded[path] = nil local imported = require (path) package.loaded[path] = nil return imported end -- import dependancies local botTools =...
nilq/small-lua-stack
null
--- -- @module UIInventoryDragboard -- -- ------------------------------------------------ -- Required Modules -- ------------------------------------------------ local Observable = require( 'src.util.Observable' ) local TexturePacks = require( 'src.ui.texturepacks.TexturePacks' ) local Translator = require( 'src.uti...
nilq/small-lua-stack
null
function drawText(x, y, text) gui.text(x, y, text) end
nilq/small-lua-stack
null
-- Move the warning message to front constantly function popup:Think() self:MoveToFront() end
nilq/small-lua-stack
null
-- -- Bonus inventory data.raw["character"]["character"].inventory_size = 100
nilq/small-lua-stack
null
object_tangible_item_beast_converted_ikopi_decoration = object_tangible_item_beast_shared_converted_ikopi_decoration:new { } ObjectTemplates:addTemplate(object_tangible_item_beast_converted_ikopi_decoration, "object/tangible/item/beast/converted_ikopi_decoration.iff")
nilq/small-lua-stack
null
return { name = "demo_parent", desc ="demo parent", parent_name = "", keys = { {name="v1",desc="v1 haha", is_static=false, type="BOOL", type_class_name=""}, }, }
nilq/small-lua-stack
null
giveCoin = function(coin, name, work) if room.isInLobby then return end local playerData = players[name] if not playerData then return end players[name].coins = playerData.coins + coin if players[name].coins < 0 then players[name].coins = 0 end if work then setLifeStat(name, 1, playerData.job == 'farmer' and...
nilq/small-lua-stack
null
--[[ <statements> ]] return function(self, node) node.body = node[1] node[1] = nil end
nilq/small-lua-stack
null
-- -- The server uses a Lua 5.1 interpreter and the java client uses a Lua 5.2 interpreter from the -- "Luaj" library. -- -- Luaj's 5.1 implementation (2.0.3) is not multi-threaded or even multi VM state. -- Luaj's 5.2 implementation (3.0) is multi-threaded as long as each as each thread uses a distinct VM state. ...
nilq/small-lua-stack
null
function embed_semcom(prefix, lexer_name) local lexer = require('lexer') local token = lexer.token local parent_lexer = lexer.load(lexer_name) local semcom_lexer = lexer.load('semantic_comments') local semcom_start_rule = token('semcom_tag', prefix) local semcom_end_rule = token('semcom_tag', '\n') pare...
nilq/small-lua-stack
null
--- --- 一个least recently cache实现, 使用哈希表和循环链表。 --- --- Created by colin. --- DateTime: 2021/3/23 10:23 --- local sformat = string.format local pairs = pairs local mmin = math.min local setmetatable = setmetatable ---@alias LruDelfunc fun(cache: LruCache, k: any, v: any) 删除函数回调原型 ---@class LruNode 缓存结点 ...
nilq/small-lua-stack
null
--- Items are inventory objects Actors may hold. -- Their skeletons are generated via `make items` from image files in /game/items. -- Items are automatically loaded via the 2-load-items.lua service. mrequire "src/class" import items from Adventure items = { } --- The Item class. -- Constructor signature is (id, nam...
nilq/small-lua-stack
null
-- Lsp Installer local lsp_installer = require("nvim-lsp-installer") local lsp_servers = { "sumneko_lua", "tsserver", "tailwindcss", "jsonls", "jdtls", "rust_analyzer", "intelephense", "yamlls", } -- Install servers for _, name in ipairs(lsp_servers) do local ok, server = require("nvim-lsp-installer.servers"...
nilq/small-lua-stack
null
-------------------------------- -- @module FadeOutDownTiles -- @extend FadeOutUpTiles -- @parent_module cc ---@class cc.FadeOutDownTiles:cc.FadeOutUpTiles local FadeOutDownTiles = {} cc.FadeOutDownTiles = FadeOutDownTiles -------------------------------- --- brief Create the action with the grid size and the durati...
nilq/small-lua-stack
null
local class = require "xgame.class" local Event = require "xgame.event.Event" local KeyboardEvent = require "xgame.event.KeyboardEvent" local TouchEvent = require "xgame.event.TouchEvent" local assert = assert local table = table local EventAgent = class("EventAgent") function EventAgent:ctor() ...
nilq/small-lua-stack
null
---------------------------------------- -- Sassilization -- Shared Unit Module -- http://sassilization.com -- By Spacetech & Sassafrass ---------------------------------------- local CMD = {} function CMD:Init( Target ) self.target = Target end function CMD:Start( Unit ) assert( IsValid( Un...
nilq/small-lua-stack
null
-- https://github.com/nvim-telescope/telescope.nvim -- https://github.com/nvim-telescope/telescope-media-files.nvim -- https://github.com/nvim-telescope/telescope-symbols.nvim require'telescope'.setup { defaults = { vimgrep_arguments = { 'rg', '--color=never', '--no-head...
nilq/small-lua-stack
null
local moon = require("moon") print("Press Ctrl-C exit server") moon.exit(function( ) print("exit once") moon.async(function () moon.sleep(1000) print("t1") moon.sleep(1000) print("t2") moon.sleep(1000) print("t3") moon.sleep(1000) print("t4") ...
nilq/small-lua-stack
null
local ID = require("scripts/zones/Arrapago_Remnants/IDs") function onTrigger(entity, npc) if (npc:getInstance():getStage() == 5) then entity:startEvent(300) else entity:messageSpecial(ID.text.DOOR_IS_SEALED) end end function onEventUpdate(player,csid,option) end function onEventFinish(en...
nilq/small-lua-stack
null
local INC = 0 local MOVE = 1 local PRINT = 3 local LOOP = 4 local function Tape() local pos = 1; local data = {0}; local get = function() return data[pos]; end local inc = function(x) data[pos] = data[pos] + x; end local move = function(x) local length = #data; pos = pos + x; for i...
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