content
stringlengths
0
1.05M
origin
stringclasses
2 values
type
stringclasses
2 values
---@type ccb.Program local M = {} --- Specify the value of a uniform variable for the current program state object. ---@param name_or_location string|ccb.UniformLocation ---@param buffer number[] function M:setUniform(name_or_location, buffer) end return M
nilq/small-lua-stack
null
--究極宝玉獣 レインボー・ドラゴン --Scripted by nekrozar function c100259013.initial_effect(c) --special summon local e1=Effect.CreateEffect(c) e1:SetDescription(aux.Stringid(100259013,0)) e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetCode(EVENT_ATTACK_ANNOUNCE) e1:SetRange(...
nilq/small-lua-stack
null
function Client_PresentSettingsUI(rootParent) local vert = UI.CreateVerticalLayoutGroup(rootParent); UI.CreateLabel(vert).SetText('Cannot attack other players for the first ' .. Mod.Settings.NumTurns .. ' turns'); end
nilq/small-lua-stack
null
ug_load_script("ug_util.lua") local pfile = util.GetParam ("-p" , "") --gets argument after -p when calling script local sfile = util.GetParam ("-s" , "") if (pfile ~= "") then ug_load_script(pfile) print("LOADED "..pfile) pFileLoaded = true end -----------------------------------------------------------------...
nilq/small-lua-stack
null
-- @brief The GPU Launch model. local model = {} -- The texture local texture -- The color drawer. local colorDrawer -- The texture drawer. local texDrawer -- The GPU queue. local gpuQueue -- @brief Creates a color drawer. -- @param color The color. local function createColorDrawer(color) -- create drawer ...
nilq/small-lua-stack
null
count = 0 emu.registerafter(function() count = count + 1 -- print(count) end) savestate.registersave(function() print("save", count) return count end) savestate.registerload(function(_,a) count = tostring(a) print("load", count) end)
nilq/small-lua-stack
null
function string.Comma(n) local f = n while true do f, k = string.gsub(f, "^(-?%d+)(%d%d%d)", '%1,%2') if (k == 0) then break end end return f end function string.EndsWith(s, e) return e == "" or s:sub(-#e) == e end function string.Explode(s, d, p) local t = {} for word in (s .. d):gmatch(p == tru...
nilq/small-lua-stack
null
-- Load the SoundDispatcher script into Studio local soundDispatcherName = "SoundDispatcher" local ServerScriptService = game:GetService("ServerScriptService") local function LoadScript(name, parent) local originalModule = script.Parent:WaitForChild(name) local script = Instance.new("Script") script.Name = name sc...
nilq/small-lua-stack
null
local lhlh_common = require "module.lhlh_common" local lhlh_proxy = require "module.lhlh_proxy" local lhlh_redis_proto = require "module.lhlh_redis_proto" local lhlh_redis_cluster = require "module.lhlh_redis_cluster" local upper = string.upper local table = table local lower = string.lower local tostring = tostring l...
nilq/small-lua-stack
null
newoption { trigger = "rebuild-sdl", description = "Rebuilds SDL for the specified platform." } if _OPTIONS["rebuild-sdl"] then include "lib/sdl" end PROJECT_NAME = path.getname(os.getcwd()) minko.project.library("minko-plugin-" .. PROJECT_NAME) files { "include/**.hpp", "src/**.cpp", "src/**.hpp" } ...
nilq/small-lua-stack
null
local ButtonGroup = {} local ButtonGroupMt = {__index = ButtonGroup} local function nop() end local mouseWasDown = false local function between(a, minA, maxA) return a >= minA and a <= maxA end local function within(x, y, button) return ( between(x, button.x, button.x + button.w) and between(y, button.y,...
nilq/small-lua-stack
null
------------------------------- -- External Includes ---------- ------------------------------- require("cupid.debug") ------------------------------- -- Includes ------------------- ------------------------------- require "derp_math" -- these are global, careful? require "defines" ------------------------------- ...
nilq/small-lua-stack
null
--[[ TheNexusAvenger Class representing a view for displaying the settings. --]] local NexusGit = require(script.Parent.Parent.Parent.Parent):GetContext(script) local NexusWrappedInstance = NexusGit:GetResource("NexusPluginFramework.Base.NexusWrappedInstance") local Settings = NexusGit:GetResource("Persistence.Settin...
nilq/small-lua-stack
null
local type = type local pairs = pairs local ipairs = ipairs local tostring = tostring local concat = table.concat local ok, new_tab = pcall(require, "table.new") if not ok then new_tab = function(narr, nrec) return {} end end local _M = {} function _M.create(num, engine) local bits = new_tab(num + 1, 0) ...
nilq/small-lua-stack
null
--[=[ Module for working with Vector3int16. @class Vector3int16Utils ]=] local Vector3int16Utils = {} --[=[ Creates a Vector3int16 from a Vector3 @param vector3 Vector3 @return Vector3int16 ]=] function Vector3int16Utils.fromVector3(vector3) return Vector3int16.new(vector3.x, vector3.y, vector3.z) end return V...
nilq/small-lua-stack
null
AddCSLuaFile() SWEP.PrintName = "Blowtorch" SWEP.Author = "Q2F2" SWEP.Instructions = "Break peoples props during a raid" SWEP.Purpose = "Destroys Props" SWEP.Spawnable = true SWEP.AdminSpawnable = false SWEP.ViewModelFOV = 65 SWEP.ViewModel = "models/weapons/v_irifle.mdl" SWEP.WorldModel ...
nilq/small-lua-stack
null
BigWigs:AddColors("Chopper Redhook", { [257288] = "orange", [257326] = "orange", [257348] = {"blue","red"}, [257459] = {"blue","yellow"}, [257585] = "orange", [273721] = {"green","orange"}, ["adds"] = "yellow", }) BigWigs:AddColors("Sergeant Bainbridge", { [257585] = "orange", [260924] = "orange", [260954] ...
nilq/small-lua-stack
null
local base = require('litcord.structures.base') local Channel = require('litcord.structures.Channel') local User = class(base) function User:__constructor () self.servers = utils.Cache() end function User:sendMessage (...) if not self.channel then local data, err = self.parent.rest:request( Route( 'users/...
nilq/small-lua-stack
null
return { init_effect = "", name = "减速", time = 2.5, picture = "", desc = "减速回复", stack = 1, id = 12585, icon = 12585, last_effect = "Darkness", effect_list = { { type = "BattleBuffFixVelocity", trigger = { "onAttach", "onRemove" }, arg_list = { add = 0, mul = -8000 } }, { ...
nilq/small-lua-stack
null
target("ltui") -- add source files add_files("**.c") -- add defines add_defines("PDC_WIDE")
nilq/small-lua-stack
null
Journalator.Constants = { ARCHIVE_INTERVAL = 30 * 24 * 60 * 60, STORE_PREFIX = "Logs-", }
nilq/small-lua-stack
null
local utils = {} function utils.make_singleton(klass, ...) local instance = klass.new(...) for k, v in pairs(klass) do if type(v) == "function" then instance[k] = function(...) return v(instance, ...) end end end return instance end return utils
nilq/small-lua-stack
null
local View = {} function View:Start() self.view = SGK.UIReference.Setup(self.gameObject); self.conversation = {}; self.views = {} self.index = 0; SGK.Action.DelayTime.Create(0.5):OnComplete(function() CS.UGUIClickEventListener.Get(self.view.gameObject, true).onClick = function() ...
nilq/small-lua-stack
null
local c = require('../constants') local u = require('../utils') -- testing local envkey = require('../../env.lua') balls = {} ---@param init string -- Sets the api key for the client. balls.client = function(init) -- assert(type(init) == 'string', 'parameter must be a string') local self = { token = init, head...
nilq/small-lua-stack
null
local checkTimer = 0 function OnPackageStart() Delay(5000, function() checkTimer = CreateTimer(Check, 5000) Check() end) end AddEvent("OnPackageStart", OnPackageStart) function Check() local x, y, z = GetPlayerLocation() local terrain = GetTerrainHeight(x, y, 99999.9) if z < 0 and terrain -...
nilq/small-lua-stack
null
local t = require( "taptest" ) local atan2 = require( "atan2" ) local round = require( "round" ) t( round( atan2( 1, 1 ), 9 ), 0.785398163 ) t( round( atan2( -1, -1 ), 8 ), -2.35619449 ) t( round( atan2( -1, -1 ) * 180 / math.pi, 0 ), -135 ) t( round( math.deg( atan2( -1, -1 ) ), 0 ), -135 ) t()
nilq/small-lua-stack
null
local Q = require 'Q/q_export' local qc = require 'Q/UTILS/lua/qcore' local ffi = require 'ffi' local cmem = require 'libcmem' local qconsts = require 'Q/UTILS/lua/qconsts' local get_ptr = require 'Q/UTILS/lua/get_ptr' local record_time = require 'Q/UTILS/lua/record_time' local...
nilq/small-lua-stack
null
function Client_PresentSettingsUI(rootParent) local vert = UI.CreateVerticalLayoutGroup(rootParent); UI.CreateLabel(vert).SetText("The hills can found by clicking 'Game' on the bottom left and then 'Mod: King Of The Hill'"); NumberOfHills = Mod.Settings.NumberOfHills; if NumberOfHills < 0 then NumberOfHi...
nilq/small-lua-stack
null
local function onMouseDown(self, e) if self:hitTestPoint(e.x, e.y) then self.touchid = -1 self.x0 = e.x self.y0 = e.y e.stop = true end end local function onMouseMove(self, e) if self.touchid == -1 then local x1, y1 = self:globalToLocal(self.x0, self.y0) local x2, y2 = self:globalToLocal(e.x...
nilq/small-lua-stack
null
Block = Class {} function Block:init(x, w, m, v) self.x = x; self.y = love.graphics.getHeight() - w - 80; self.w = w; self.v = v; self.m = m; end --[[ returns True if the block has hit the edge of the screen. ]] function Block:HitWall() return self.x <= 0 end --[[ Change the direction...
nilq/small-lua-stack
null
---------------------------- -- SSBase -- -- Created by Skeyler.com -- ---------------------------- ENT.Type = "anim" /*--------------------------------------------------------- OnRemove ---------------------------------------------------------*/ function ENT:OnRemove() end /*--------------------...
nilq/small-lua-stack
null
object_draft_schematic_furniture_furniture_armoire_rustic = object_draft_schematic_furniture_shared_furniture_armoire_rustic:new { } ObjectTemplates:addTemplate(object_draft_schematic_furniture_furniture_armoire_rustic, "object/draft_schematic/furniture/furniture_armoire_rustic.iff")
nilq/small-lua-stack
null
local Players: Players = game:GetService("Players") local ReplicatedStorage: ReplicatedStorage = game:GetService("ReplicatedStorage") local Player = Players.LocalPlayer local Portal = require(ReplicatedStorage:WaitForChild("Packages"):WaitForChild("Portal")) Portal = Portal.new() local Subscriptions = require(Replica...
nilq/small-lua-stack
null
-- ========== THIS IS AN AUTOMATICALLY GENERATED FILE! ========== PlaceObj('XTemplate', { group = "Default", id = "PopsMessageButton", PlaceObj('XTemplateWindow', { '__class', "XTextButton", 'RolloverTemplate', "Rollover", 'RolloverAnchor', "bottom", 'Padding', box(0, 0, 50, 0), 'MaxHeight', 45, 'Backgr...
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
if SERVER then AddCSLuaFile( "shared.lua" ) end SWEP.PrintName = "Speed Boost" SWEP.Base = "weapon_banana" SWEP.ViewModel = "models/weapons/pbecustom/v_glassbottle.mdl" SWEP.WorldModel = "models/weapons/pbecustom/w_glassbottle.mdl" function SWEP:Throw() if SERVER then owner = self.Owner owner:SetRunSp...
nilq/small-lua-stack
null
require "SltRuntime" function copy(obj, seen) -- Handle non-tables and previously-seen tables. if type(obj) ~= 'table' then return obj end if seen and seen[obj] then return seen[obj] end -- New table; mark it as seen and copy recursively. local s = seen or {} local res = {} s[obj] = res for k, v in pa...
nilq/small-lua-stack
null
local AddonName, AddonTable = ... -- Legion Legendaries AddonTable.legendaries = { -- Generic 132444, 144259, 152626, -- Mage -- Priest -- Warlock 132357, 132369, 132378, 132394, 132457, 132375, 132381, 144364, 151649, 151821, -- Rogue 144236, ...
nilq/small-lua-stack
null
PLUGIN.name = "Bigger Bars" PLUGIN.desc = "Now bars are bigger" PLUGIN.author = "Lechu2375" PLUGIN.license = "MIT not for use on Kaktusownia opensource.org/licenses/MIT" if CLIENT then BAR_HEIGHT = 11.5 //change this if you want smaller/bigger bars end
nilq/small-lua-stack
null
rangedAttacks = { skellibone = ranged_attack:new({ name = "Bonerang", description = "Throw your enemy a bone, literally!", projectile=true, projectile_name="skellibone", sound="bonerang", accuracy=70, best_distance_min=4, best_distance_max=5, accuracy_decay = 10, min_range=2 })...
nilq/small-lua-stack
null
-------------------------------- ---COPYRIGHT © Centurion#0457--- -------------------------------- resource_manifest_version '44febabe-d386-4d18-afbe-5e627f4af937' description 'Praca Farmera Centurion#0457 | Farmer Job Centurion#0457' -------------------------------- ---COPYRIGHT © Centurion#0457--- ----------------...
nilq/small-lua-stack
null
local Follower, super = Class(Character) function Follower:init(chara, x, y, target) super:init(self, chara, x, y) self.index = 1 self.target = target self.state_manager = StateManager("WALK", self, true) self.state_manager:addState("WALK") self.state_manager:addState("SLIDE", {enter = self.b...
nilq/small-lua-stack
null
fig = {"црвена", "плава", "браон"} ans = { "На циљ ће прва стићи ", " фигура.", "На циљ ће истовремено стићи све три фигуре." } vez = "и"
nilq/small-lua-stack
null
local display = false RegisterCommand("nui", function(source, args) SetDisplay(not display) end) --very important cb RegisterNUICallback("exit", function(data) chat("exited", {0,255,0}) SetDisplay(false) end) -- this cb is used as the main route to transfer data back -- and also where we hanld the data...
nilq/small-lua-stack
null
local current current = redis.call("incr", KEYS[1]) if tonumber(current) == 1 then redis.call("expire", KEYS[1], ARGV[1]) end return current
nilq/small-lua-stack
null
function main(args) ret, err=syscall_callstate("ch7UB74hyCf5zTwN6ab4yb9P7sZ1c5DXYK", "cUEcerP7bxEUnrLx8RfTJEGU5VGDu652i", "USD") return err end
nilq/small-lua-stack
null
function checkValidCharacterName(theText) local foundSpace, valid = false, true local lastChar, current = ' ', '' for i = 1, #theText do local char = theText:sub( i, i ) if char == ' ' then -- it's a space if i == #theText then -- space at the end of name is not allowed valid = false return false, "I...
nilq/small-lua-stack
null
function countCangKuEmpty() keepScreen(true) local count=0 for x=0,3 do for y=0,4 do local flag = true for j=349,448,1 do color = getColor(j+x*183, 365+y*183) if color ~=12103896 then flag = false end end if flag == true then count = count+1 end end end keepScreen(...
nilq/small-lua-stack
null
------------------------------------------------------------------------------- --- AUTHOR: Nostrademous --- GITHUB REPO: https://github.com/pydota2 ------------------------------------------------------------------------------- local ActionClear = {} ActionClear.Name = "Clear Action" ActionClear.NumArgs = 2 -------...
nilq/small-lua-stack
null
class("CancelLearnTacticsCommand", pm.SimpleCommand).execute = function (slot0, slot1) slot2 = slot1:getBody() slot4 = slot2.type slot6 = getProxy(NavalAcademyProxy).getStudentById(slot5, slot3) slot7 = slot2.callback slot8 = slot2.onConfirm if not getProxy(BayProxy).getShipById(slot9, slot6.shipId).skills[slot6...
nilq/small-lua-stack
null
--[[ Pixel Vision 8 - Draw Tool Copyright (C) 2017, Pixel Vision 8 (http://pixelvision8.com) Created by Jesse Freeman (@jessefreeman) Please do not copy and distribute verbatim copies of this license document, but modifications without distributing is allowed. ]]-- local spritePanelID = "SpritePanelUI" functi...
nilq/small-lua-stack
null
-- betterchapters.lua -- seeks forward until a black screen appears. -- Keybind names: skip_scene script_name = mp.get_script_name() detect_label = string.format("%s-detect", script_name) detecting = false threshold = 0.9 detection_span = 0.05 negation = false normal_speed = 1 seek_position = 0.0 function toggle_detec...
nilq/small-lua-stack
null
-- ####################################### -- ## Project: MTA:scp-088 ## -- ## Name: MapLoader ## -- ## Author: Noneatme ## -- ## Version: 1.0 ## -- ## License: See top Folder ## -- ####################################### -- FUNCTIONS / METHODS -- local cFunc = {}; -- Local Functions local cSettin...
nilq/small-lua-stack
null
local module = {} module.init = function() local Stylesheet = module.Latte.Modules.Stylesheet if not Stylesheet.Duration then Stylesheet.Duration = { ["VeryShort"] = 0.15, ["Short"] = 0.3 } end if not Stylesheet.Fonts then Stylesheet.Fonts = { ["Light"] = Enum.Font.Gotham, ["Book"] = Enum.Font.G...
nilq/small-lua-stack
null
measure = {"m", "dm", "cm"} measure2 = {"m\(^2\)", "dm\(^2\)", "cm\(^2\)"} ind = 3 dim = 10^4 edge1 = (35 + math.random(20)) * 10 edge2 = (25 + math.random(20)) * 10 edge3 = (21 + math.random(10)) * 10 window1 = (10 + math.random(5)) * 5 window2 = (12 + math.random(8)) * 5 window = window1 * window2 ...
nilq/small-lua-stack
null
--* Initiation / Engine of SohighUI local _G = _G local unpack, select, tonumber = unpack, select, tonumber local UnitName = UnitName local UnitClass = UnitClass local UnitRace = UnitRace local UnitLevel = UnitLevel local UnitFactionGroup = UnitFactionGroup local UnitAffectingCombat = UnitAffectingCombat lo...
nilq/small-lua-stack
null
-------------------------------------------------------------------------------- -- map.lua - Defines a map which manages the construction of the hex grid and the path within -------------------------------------------------------------------------------- require "source/pathfinder" require "source/utilities/vector" ...
nilq/small-lua-stack
null
-- Copyright (c) 2013 The Chromium Authors. All rights reserved. -- Use of this source code is governed by a BSD-style license that can be -- found in the LICENSE file. --- GUI function for creating menus, etc.. local util = require 'util' local gui = { FONT_NAME = 'Arial.ttf', FONT_SIZE = 48 } --- Layout me...
nilq/small-lua-stack
null
--- --- Generated by EmmyLua(https://github.com/EmmyLua) --- Created by shuieryin. --- DateTime: 12/01/2018 10:42 PM --- function visualizeFit(X, mu, sigma2) --VISUALIZEFIT Visualize the dataset and its estimated distribution. -- VISUALIZEFIT(X, p, mu, sigma2) This visualization shows you the -- probab...
nilq/small-lua-stack
null
BuildEnv(...) local SummaryGrid = Addon:NewClass('SummaryGrid', GUI:GetClass('DataGridViewGridItem')) function SummaryGrid:Constructor() local ExpirationTime = self:CreateFontString(nil, 'ARTWORK', 'GameFontGreenSmall') do ExpirationTime:SetWidth(35) ExpirationTime:SetPoint('RIGHT', -35, 0) ...
nilq/small-lua-stack
null
mkql_Saved = nil
nilq/small-lua-stack
null
local desc = fs.read(path.expand("$sd/../../dump.desc.json")) T.Equal("GearType", desc:Enum("GearType"), { Name = "GearType", Tags = {"Deprecated"}, }) T.Equal("NormalId", desc:Enum("NormalId"), { Name = "NormalId", Tags = {}, })
nilq/small-lua-stack
null
--- a ux for surrounding character pairs -- @module surround local M = {} local parser = require("surround.parser") local utils = require("surround.utils") local OPENING = 1 local CLOSING = 2 local FUNCTION = 3 local LINE = 1 local COLUMN = 2 --- Surround selection. -- Adds a character surrounding the user's selectio...
nilq/small-lua-stack
null
-- Filter codeblocks with this function if the target format is LaTeX if FORMAT:match 'latex' then function CodeBlock (block) -- Replace all codeblocks with our manuscript environment -- https://tex.stackexchange.com/a/511575/10824 -- my very naive solution to have whatever the user places in the ...
nilq/small-lua-stack
null
protocol = Proto("goodix", "Goodix Fingerprint Sensor Message Protocol") cmd0_field = ProtoField.uint8("goodix.cmd0", "Command 0", base.HEX, nil, 0xf0) cmd1_field = ProtoField.uint8("goodix.cmd1", "Command 1", base.HEX, nil, 0x0e) length_field = ProtoField.uint16("goodix.length", "Length", base.DEC) checksum_field = P...
nilq/small-lua-stack
null
-- local log = require("vim/lsp/log") local cmp_nvim_lsp = require("cmp_nvim_lsp") local diagnosticls = require("diagnosticls") local lsp_python = require("lsp_python") local lsp_status = require("lsp-status") local lspconfig = require("lspconfig") local util = require("lspconfig/util") local function on_attach(client...
nilq/small-lua-stack
null
object_tangible_dungeon_mustafar_decrepit_droid_factory_security_controller = object_tangible_dungeon_mustafar_decrepit_droid_factory_shared_security_controller:new { } ObjectTemplates:addTemplate(object_tangible_dungeon_mustafar_decrepit_droid_factory_security_controller, "object/tangible/dungeon/mustafar/decrepit_dro...
nilq/small-lua-stack
null
local plugin = script:FindFirstAncestorWhichIsA("Plugin") local require = require(plugin:FindFirstChild("Lighter", true)) local Outlet = require("Outlet") local Command = {} Command.Alias = { "d", "cli" } Command.Params = { "enable/disable" } Command.Info = { "Enable/disable the Deliver CLI", "Provide 'enable' or '...
nilq/small-lua-stack
null
dofile("helper.luac") dofile("Component.luac") dofile("Keyboard.luac") dofile("TextureManager.luac") dofile("Terrain.luac") dofile("Audio.luac") dofile("Launcher.luac") dofile("component/RigidBody.luac") dofile("component/Sprite.luac") dofile("component/WarBehavior.luac") dofile("component/BardBehavior.luac") dofile("c...
nilq/small-lua-stack
null
local env = {} -- user configurable function function env.istype(obj, typename) local mt = getmetatable(obj) if type(mt) == 'table' then local objtype = rawget(mt, '__typename') if objtype then return objtype == typename end end return type(obj) == typename end function env.type...
nilq/small-lua-stack
null
-- source: https://github.com/raiguard/Factorio-LtnManager/blob/master/src/prototypes/sprite.lua local indicator_sprites = {{ type = "sprite", name = "ltn-cleanup-signal-white", filename = "__core__/graphics/gui-new.png", position = {128, 96}, size = 28, scale = 0.4, shift = {0, 1}, tin...
nilq/small-lua-stack
null
--ダイナ・ベース --Script by mercury233 local s,id,o=GetID() function s.initial_effect(c) --special summon local e1=Effect.CreateEffect(c) e1:SetDescription(aux.Stringid(id,0)) e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetType(EFFECT_TYPE_IGNITION) e1:SetRange(LOCATION_HAND) e1:SetCountLimit(1,id) e1:SetCo...
nilq/small-lua-stack
null
Cache = {} function Cache:new() local this = {} this._entries = {} self.__index = self return setmetatable(this, self) end function Cache:has(pKey, pCheckTTL) local cached = self._entries[pKey] if cached == nil then return false end return pCheckTTL and GetGameTimer() - cached.time > cached.ttl or ...
nilq/small-lua-stack
null
--[[ File: main.lua Author: Sam Triest The main program. ]] -- Dependencies require "Entities/Paddle" require "Entities/Ball" -- Game window dimensions WINDOW_WIDTH = 1200 WINDOW_HEIGHT = 900 --[[ Initial program setup. ]] function love.load() -- Set the display mode and properties of the game w...
nilq/small-lua-stack
null
local script = {} script.ScriptComponentManager = require("heart.script.ScriptComponentManager") script.ScriptSystem = require("heart.script.ScriptSystem") return script
nilq/small-lua-stack
null
--------------------------------------------------------------- -- UIProbe.lua: Secure probes for signed code --------------------------------------------------------------- -- Probes are used to trigger callbacks to different handles -- when an event happens that normally can't be processed in a -- secure scope. A pro...
nilq/small-lua-stack
null
local path = "qnSwfRes/sfw/red_envelope_wait_open_swf_pin.png" local red_envelope_wait_open_swf_pin_map = { ["red_envelope_wait_open_6.png"] = { file=path, x=2,y=2, width=244,height=223, offsetX=1,offsetY=0, utWidth=224, utHeight=245, rotated=true }, ["red_envelope_wait_open_7.png"] = { file=path,...
nilq/small-lua-stack
null
local skynet = require "skynet" local libdbproxy = require "libdbproxy" local faci = require "faci.module" local module = faci.get_module("queryboard") local dispatch = module.dispatch local forward = module.forward local event = module.event --���а� local cache = nil --cache = { -- name = "queryboard" -- t = { -- ...
nilq/small-lua-stack
null
-- color _col = ofTable() _col.red = 0xff0000 _col.yellow = 0xffff00 _col.green = 0x00ff00 _col.cyan = 0x00ffff _col.blue = 0x0000ff _col.magenta = 0xff00ff _col.navy = 0x000080 -- bin local bin = ofTable() function bin.new() local o = ofTable() -- pl o.pl = ofTable() function o.pl.new(mass, x0, y0, vx0, vy0,...
nilq/small-lua-stack
null
local Class = require("hs/lang/Class") TestClass = {} ------------------------------------------------------------ function TestClass:setUp() self.objA = TestClass.ClassA:new("aaa") self.objB = TestClass.ClassB:new("aaa", "bbb") self.objC = TestClass.ClassC:new("ccc") end function TestClass:test1_init() ...
nilq/small-lua-stack
null
local Typer = require(script.Parent.Parent.Parent.Typer) local copy = require(script.Parent.copy) local function removeKey(dictionary, key) local new = copy(dictionary) new[key] = nil return new end return Typer.AssignSignature(Typer.Table, Typer.NonNil, removeKey)
nilq/small-lua-stack
null
--[[---------------------------------------------------------------------------- This file is part of Friday Night Funkin' Rewritten by HTV04 ------------------------------------------------------------------------------]] return Sprite ( sheets["notes"], { {x = 784, y = 232, width = 157, height = 153, offs...
nilq/small-lua-stack
null
--a helper for mapgen local function is_even(number) if (number % 2 == 0) then return(true) else return(false) end end --helps read tables function dump(o) if type(o) == 'table' then local s = '{ ' for k,v in pairs(o) do if type(k) ~= 'number' then k = '"'..k..'"' end s = s .. ...
nilq/small-lua-stack
null
--[[ level.lua Provides data structures and functions used to store and manipulate a level. ]] require("tileset") --[[ Cell A cell is a single space in the level. It contains a tile ID and up to one entity, as well as pointers to cells in each cardinal direction. Tile IDs are relative to the custom tileset, ...
nilq/small-lua-stack
null
--TWIRL TELEKINESIS (unleaked) local next=next local sin=math.sin local cos=math.cos local max=math.max local min=math.min local tau=2*math.pi local atan2=math.atan2 local random=math.random local gp=game:service'Players' local M=gp.LocalPlayer script.Parent=nil local function test(f) local a,b=coroutine.res...
nilq/small-lua-stack
null
-- ---- Copyright (c) 2014, Facebook, Inc. ---- All rights reserved. ---- ---- This source code is licensed under the Apache 2 license found in the ---- LICENSE file in the root directory of this source tree. ---- --NOTE: REQUIRES PARAMS, LOCATED IN loop.lua. Run from loop.lua gpu = false if gpu then requi...
nilq/small-lua-stack
null
local ffi = require "ffi" local ffi_cdef = ffi.cdef ffi_cdef[[ typedef struct sha1_ctx { uint32_t state[5]; uint64_t count; uint8_t block[64]; unsigned int index; } SHA1_CTX; ]]
nilq/small-lua-stack
null
#!/usr/bin/env lua if table.getn(arg) < 2 then io.write("Convert raw data to frequency aggregated by interval\n") io.write("Usage: raw2freq.lua <data_file> <aggr_interval>\n") do return end end local f = assert(io.open(arg[1], "r")) local interval = tonumber(arg[2]) local total = 0 local data = {} setmetatable(da...
nilq/small-lua-stack
null
local database = {} local component = require("component") function database.add_to_set(set, key) set[key] = true end function database.remove_from_set(set, key) set[key] = nil end function database.set_contains(set, key) return set[key] ~= nil end function database.get_all_db_entries() local resul...
nilq/small-lua-stack
null
local TAG = "WorldAnswerModule" local EventManager = require 'utils.EventManager'; local NetworkService = require "utils.NetworkService"; local Time = require "module.Time" local RightNum = nil local gift = {} local gid = nil --记录当前第几轮答题 local function date(now) local now = now or Time.now(); return os.date...
nilq/small-lua-stack
null
if not data.raw["custom-input"] or not data.raw["custom-input"]["toggle-train-control"] then data:extend({ { type = "custom-input", name = "toggle-train-control", key_sequence = "J" } }) end
nilq/small-lua-stack
null
if IsValid(TESTP) then TESTP:Remove() end local frame = vgui.Create("DFrame") frame:SetSize(250, 250) frame:SetTitle("DListLayout Example") frame:MakePopup() frame:Center() local layout = vgui.Create("DListLayout", frame) layout:SetSize(100, 100) layout:SetPos(20, 50) //Draw a background so we can see what it's doin...
nilq/small-lua-stack
null
require 'pl' local template = require 'pl.template' local pretty = require 'pl.pretty' local List = require 'pl.List' local stringx = require 'pl.stringx' class.PerPlatform() function PerPlatform:_init(root,vtype,key,base) self.root = root self.vtype = vtype self.key = key self.basename = base sel...
nilq/small-lua-stack
null
arachne_widow = Creature:new { objectName = "@mob/creature_names:arachne_widow", socialGroup = "arachne", faction = "", level = 58, chanceHit = 0.53, damageMin = 400, damageMax = 510, baseXp = 5647, baseHAM = 11000, baseHAMmax = 14000, armor = 1, resists = {140,140,5,170,180,5,180,-1,-1}, meatType = "meat_...
nilq/small-lua-stack
null
describe('parse', function() local parse = require 'graphql.parse' test('comments', function() local document document = parse('#') expect(document.definitions).to.equal({}) document = parse('#{}') expect(document.definitions).to.equal({}) expect(parse('{}').definitions).to_not.equal({}) ...
nilq/small-lua-stack
null
require("scripts.chest")
nilq/small-lua-stack
null
local ffi = require("ffi") local libovs = require("lib.libopenvswitch"); libovs(); -- make things global local function test_dirs() print("ovs_sysconfdir:", ovs_sysconfdir()); print("ovs_pkgdatadir:",ovs_pkgdatadir()); print(" ovs_rundir:",ovs_rundir()); print(" ovs_logdir:",ovs_logdir()); ...
nilq/small-lua-stack
null
local filter_plugin = {} local src = { args="filter args" } local sink = { name = "filter_plugin", ver = "0.1" } function filter_plugin.output(self, list, flg) if flg == 0 then return end for k,v in pairs(list) do print(k,v) end end function filter_plugin.push(self, stream...
nilq/small-lua-stack
null
-- ============================================================= -- Copyright Roaming Gamer, LLC. 2008-2018 (All Rights Reserved) -- ============================================================= local sbc = {} -- == -- sbc.prep_tableRoller( button, srcTable [ , chainedCB [ , underBarSwap ] ]) - Prepares a button t...
nilq/small-lua-stack
null
--[=[ Utility methods to interactive with Roblox datastores. @server @class DataStorePromises ]=] local require = require(script.Parent.loader).load(script) local Promise = require("Promise") local DataStoreService = game:GetService("DataStoreService") local DataStorePromises = {} --[=[ Promises a Roblox datast...
nilq/small-lua-stack
null