content stringlengths 0 1.05M | origin stringclasses 2
values | type stringclasses 2
values |
|---|---|---|
--[[
ComputerCraft Package Tool Installer
Author: PentagonLP
Version: 1.0
Lines of Code: 161; Characters: 5541
]]
-- Read arguments
args = {...}
-- FILE MANIPULATION FUNCTIONS --
--[[ Checks if file exists
@param String filepath: Filepath to check
@return boolean: Does the file exist?
--]]
function file_exists... | nilq/small-lua-stack | null |
fort_spikes = {
wood_durability_index = 0.4,
iron_durability_index = 0.9
}
-- add damage to any object.
fort_spikes.do_damage = function(obj, durability_index)
if obj == nil then return end
if obj:is_player() or (obj:get_luaentity() ~= nil and obj:get_luaentity().name ~= "__builtin:item") then
obj:punch(o... | nilq/small-lua-stack | null |
local public = {}
public.create = function(c)
local border = display.newGroup()
local topBorder = display.newRect( centerX, (centerY - (screenH / 2)), screenW, 5 )
topBorder.type = "wall"
topBorder:setFillColor(color.hex(c))
physics.addBody(topBorder, "static", { isSensor = false })
border:insert(topBorder)
l... | nilq/small-lua-stack | null |
PLUGIN.name = "3D2D Blur Library"
PLUGIN.author = "Black Tea"
PLUGIN.desc = "Plugin for Developers."
nut.blur3d2d = nut.blur3d2d or {}
nut.blur3d2d.list = nut.blur3d2d.list or {}
-- for easy managements
function nut.blur3d2d.add(id, pos, ang, scale, callback)
if (id and pos and ang and scale and callback) then
nut... | nilq/small-lua-stack | null |
cBnivCfg = {
["CompressEmpty"] = true,
["SortBags"] = true,
["scale"] = 1.2,
["Unlocked"] = true,
["Armor"] = true,
["Junk"] = true,
["NewItems"] = true,
["CoolStuff"] = false,
["BankBlack"] = false,
["TradeGoods"] = true,
["SortBank"] = true,
["FilterBank"] = true,
["AmmoAlwaysHidden"] = false,
}
cB_Cust... | nilq/small-lua-stack | null |
description = [[
Detecta CITRIX Application Delivery Controller (ADC) potencialmente vulnerables a CVE-2019-19781
]]
local http = require "http"
local shortport = require "shortport"
local vulns = require "vulns"
local stdnse = require "stdnse"
local string = require "string"
---
-- @hackyseguridad
-- nmap -Pn -sVC ... | nilq/small-lua-stack | null |
hs.application = require("hs.application")
hs.dockicon = require("hs.dockicon")
function testAttributesFromBundleID()
local appName = "Safari"
local appPath = "/Applications/Safari.app"
local bundleID = "com.apple.Safari"
assertTrue(hs.application.launchOrFocusByBundleID(bundleID))
local app = hs.applicati... | nilq/small-lua-stack | null |
-- Terrain editing prototype
-- Water example.
-- This sample demonstrates:
-- - Creating a large plane to represent a water body for rendering
-- - Setting up a second camera to render reflections on the water surface
require "LuaScripts/Utilities/Sample"
require "LuaScripts/nodegraphui"
uiStyle = cache:GetR... | nilq/small-lua-stack | null |
return {
table = "ssl_servers_names",
primary_key = { "name" },
fields = {
name = { type = "text", required = true },
ssl_certificate_id = { type = "id", foreign = "ssl_certificates:id" },
created_at = {
type = "timestamp",
immutable = true,
dao_insert_value = true,
required = ... | nilq/small-lua-stack | null |
local _={}
_.name="Pegasus"
_.new=function(options)
local result=BaseEntity.new(options)
result.x=0
result.y=0
result.mountX=27
result.mountY=31
result.originX=27
result.originY=31
result.footX=22
result.footY=46
Entity.setSprite(result,"pegasus")
result.isDrawable=true
result.aiEnabled=Session... | nilq/small-lua-stack | null |
local lunaconf = require('lunaconf')
local awful = require('awful')
local gears = require('gears')
local run_picom = function()
lunaconf.utils.run_once('picom --config ' .. gears.filesystem.get_configuration_dir() .. '/configs/picom.conf -b')
end
local restart_picom = function()
lunaconf.utils.spawn('killall picom'... | nilq/small-lua-stack | null |
local add_fertilizer_from = function(fish)
local recipe = table.deepcopy(data.raw.recipe["fertilizer"])
if recipe ~= nil then
recipe.name = "fertilizer-from-" .. fish
local element = 1
for _,v in pairs(recipe.ingredients) do
if v.name then element = 'name' end
if v[element] == "biomass" then... | nilq/small-lua-stack | null |
-- reload every lua file (except me)
function make()
local some = io.popen("ls *.lua")
for one in some:lines() do
if (one ~= "0.lua") then
print("-- loading " .. one)
dofile(one)
end
end
some:close()
end
make()
| nilq/small-lua-stack | null |
-- Additional Plugins
lvim.plugins = {
-- Themes
{ "folke/tokyonight.nvim" },
{ "ellisonleao/gruvbox.nvim", requires = { "rktjmp/lush.nvim" } },
{ "sainnhe/sonokai" },
--Trouble diagnostics and more
{
"folke/trouble.nvim",
cmd = "TroubleToggle",
},
-- TODO and keywords in comment highlight
{
"folke/todo-... | nilq/small-lua-stack | null |
object_tangible_tcg_series4_decorative_child_bed_01 = object_tangible_tcg_series4_shared_decorative_child_bed_01:new {
}
ObjectTemplates:addTemplate(object_tangible_tcg_series4_decorative_child_bed_01, "object/tangible/tcg/series4/decorative_child_bed_01.iff") | nilq/small-lua-stack | null |
-- Dimensional Accumulator --
-- Entity --
local daE = {}
daE.type = "accumulator"
daE.name = "DimensionalAccumulator"
daE.icon = "__Mobile_Factory_Graphics__/graphics/icones/DimensionalAccumulator.png"
daE.icon_size = 32
daE.flags = {"placeable-neutral", "player-creation"}
daE.minable = {mining_time = 0.5, r... | nilq/small-lua-stack | null |
-- Constants
local gravity = 0.8165
local accel = 0.166
local decel = 0.3
local jmpStg = -13.0
local minJmp = -6.5
local maxSpd = 0.0
local defMaxSpd = 4.0
local runMaxSpd = 8.5
local hitboxRad = {16.0, 32.0}
-- Variables
local direction = 1.0
local ground = false
local speed = {0.0, 0.0, 0.0... | nilq/small-lua-stack | null |
-- Neovim indent file
-- Language: Tree-sitter query
-- Last Change: 2022 Mar 29
-- it's a lisp!
vim.cmd [[ runtime! indent/lisp.vim ]]
| nilq/small-lua-stack | null |
if string.find(Var "Element", "Active") then
return Def.Sprite {
Texture = NOTESKIN:GetPath("_Down", "Hold Active"),
Frame0000 = 0,
Delay0000 = 1
}
else
return Def.Sprite {
Texture = NOTESKIN:GetPath("_Down", "Tap Note"),
Frame0000 = 0,
Delay0000 = 1
}
end
| nilq/small-lua-stack | null |
if not opt then
cmd = torch.CmdLine()
cmd:option('-root_data_dir', '', 'Root path of the data, $DATA_PATH.')
cmd:text()
opt = cmd:parse(arg or {})
assert(opt.root_data_dir ~= '', 'Specify a valid root_data_dir path argument.')
end
dofile 'utils/utils.lua'
dofile 'entities/relatedness/relatedness.lua'
in... | nilq/small-lua-stack | null |
local vfs = vfs or {}
local fs = require("modules.fs")
vfs.mounts = {}
function vfs.getMounts(pre)
assertType(pre, "string")
return vfs.mounts[pre]
end
function vfs.mount(path, pre)
assertType(path, "string")
assertType(pre, "string")
vfs.unmount(path)
path = path:gsub("\\","/")
if path:sub(1,1) == "/" then... | nilq/small-lua-stack | null |
class 'HControls'
function HControls:__init()
Events:Subscribe( "ModulesLoad", self, self.ModulesLoad )
Events:Subscribe( "EngHelp", self, self.EngHelp )
end
function HControls:EngHelp()
Events:Fire( "HelpRemoveItem",
{
name = "Часто задаваемые вопросы (FAQ)"
} )
Events:Fire( "HelpAddItem",
... | nilq/small-lua-stack | null |
ModifyEvent(-2, 19, -2, -2, -1, -1, -1, -1, -1, -1, -2, -2, -2);
ModifyEvent(-2, 21, -2, -2, -1, -1, -1, -1, -1, -1, -2, -2, -2);
ModifyEvent(-2, 3, 0, 0, -1, -1, -1, -1, -1, -1, -2, -2, -2);
ModifyEvent(-2, 4, 0, 0, -1, -1, -1, -1, -1, -1, -2, -2, -2);
ModifyEvent(-2, 5, 0, 0, -1, -1, -1, -1, -1, -1, -2, -2, -2);
do r... | nilq/small-lua-stack | null |
--
-- Licensed to the Apache Software Foundation (ASF) under one or more
-- contributor license agreements. See the NOTICE file distributed with
-- this work for additional information regarding copyright ownership.
-- The ASF licenses this file to You under the Apache License, Version 2.0
-- (the "License"); you may ... | nilq/small-lua-stack | null |
-- requires subliminal, version 1.0 or newer
-- default keybinding: b
-- add the following to your input.conf to change the default keybinding:
-- keyname script_binding auto_load_subs
local utils = require 'mp.utils'
function title_fn()
mp.osd_message(mp.get_property("path"))
end
mp.add_key_binding("N", "print_ti... | nilq/small-lua-stack | null |
function clone(object)
local lookup_table = {}
local function _copy(object)
if type(object) ~= "table" then
return object
elseif lookup_table[object] then
return lookup_table[object]
end
local new_table = {}
lookup_table[object] = new_table
... | nilq/small-lua-stack | null |
--------------------------------
-- @module ccui
--------------------------------------------------------
-- the ccui VideoPlayer
-- @field [parent=#ccui] VideoPlayer#VideoPlayer VideoPlayer preloaded module
return nil
| nilq/small-lua-stack | null |
module("php.utils", package.seeall)
local ffi = require "ffi"
ffi.cdef[[
struct in_addr {
uint32_t s_addr;
};
int inet_aton(const char *cp, struct in_addr *inp);
uint32_t ntohl(uint32_t netlong);
char *inet_ntoa(struct in_addr in);
uint32_t htonl(uint32_t hostlong);
]]
local C = ffi... | nilq/small-lua-stack | null |
--This was programmed by vissequ#1301 (Discord). You may use this any way you wish, but please do not remove this credit.
--you will need the dependant scripts included in the Complex Weather System (same repo)
local L = game:service("Lighting")
local RS = game:GetService("ReplicatedStorage")
local REs = RS:WaitForCh... | nilq/small-lua-stack | null |
--[[
Kill Confirmed
PvE Ground Branch game mode by Jakub 'eelSkillz' Baranowski
More details @ https://github.com/JakBaranowski/ground-branch-game-modes/wiki/game-mode-kill-confirmed
]]--
local MTeams = require('Players.Teams')
local MSpawnsGroups = require('Spawns.Groups')
local MSpawnsCommo... | nilq/small-lua-stack | null |
--- @module ColorPicker
-- Allows users to choose colors from a palette
-- @commonParams
-- @option caption string
-- @option color string|table The currently-selected color
-- @option captionFont number A font preset
-- @option captionColor string|table A color preset
-- @option frameColor string|table A color preset
... | nilq/small-lua-stack | null |
local S = homedecor.gettext
local cutlery_cbox = {
type = "fixed",
fixed = {
{ -5/16, -8/16, -6/16, 5/16, -7/16, 2/16 },
{ -2/16, -8/16, 2/16, 2/16, -4/16, 6/16 }
}
}
homedecor.register("cutlery_set", {
drawtype = "mesh",
mesh = "homedecor_cutlery_set.obj",
tiles = { "homedecor_cutlery_set.png" },
invento... | nilq/small-lua-stack | null |
-- Copyright (C) 2012 by Yichun Zhang (agentzh)
local ffi = require "ffi"
module(...)
_VERSION = '0.08'
ffi.cdef[[
typedef unsigned long SHA_LONG;
typedef unsigned long long SHA_LONG64;
enum {
SHA_LBLOCK = 16
};
]];
| nilq/small-lua-stack | null |
-- test.lua - test suite for lib module.
-- 'findbin' -- https://github.com/davidm/lua-find-bin
package.preload.findbin = function()
local M = {_TYPE='module', _NAME='findbin', _VERSION='0.1.1.20120406'}
local script = arg and arg[0] or ''
local bin = script:gsub('[/\\]?[^/\\]+$', '') -- remove file name
if bi... | nilq/small-lua-stack | null |
IncludeDir = {}
IncludeDir["ImGui"] = "%{wks.location}/vendor/ImGui"
IncludeDir["rlImgui"] = "%{wks.location}/vendor/rlImgui"
IncludeDir["raylib"] = "%{wks.location}/vendor/raylib/src"
IncludeDir["SPDLOG"] = "%{wks.location}/vendor/spdlog/include"
IncludeDir["ENTT"] = "%{wks.location}/vendor/entt/src/"
IncludeDir["Icon... | nilq/small-lua-stack | null |
-- UDPBroadcaster.lua
-- David Skrundz
--
-- udp = UDPBroadcaster.new()
-- udp:start(ip, port, message, interval)
-- bool = udp:isBroadcasting()
-- udp:stop()
UDPBroadcaster = {}
function UDPBroadcaster.new()
local _udpbroadcaster = {}
setmetatable(_udpbroadcaster, {__index = UDPBroadcaster})
return _udpbroadcas... | nilq/small-lua-stack | null |
--[=[
@class GameConfigCmdrUtils
]=]
local require = require(script.Parent.loader).load(script)
local GameConfigAssetTypes = require("GameConfigAssetTypes")
local GameConfigCmdrUtils = {}
function GameConfigCmdrUtils.registerAssetTypes(cmdr, configPicker)
assert(cmdr, "Bad cmdr")
assert(configPicker, "Bad config... | nilq/small-lua-stack | null |
resource_manifest_version '77731fab-63ca-442c-a67b-abc70f28dfa5'
client_script 'client.lua'
| nilq/small-lua-stack | null |
local timestamp = require "kong.tools.timestamp"
local connection = require "kong.plugins.scalable-rate-limiter.policies.connection"
local kong = kong
local pairs = pairs
local null = ngx.null
local shm = ngx.shared.kong_rate_limiting_counters
local fmt = string.format
local EMPTY_UUID = "00000000-0000-0000-0000-000... | nilq/small-lua-stack | null |
-- Factorio-Lib: https://factoriolib.github.io/flib/index.html
local table = require("__flib__.table")
-- Ban research pack fron the planning
local BanResearchPacks = {packs = {}}
BanResearchPacks.__index = BanResearchPacks
function BanResearchPacks:hydrate(o) setmetatable(o, self) end
function BanResearchPacks:apply... | nilq/small-lua-stack | null |
--local config = require("bots/config")
--
--function TeamToChar()
-- -- TEAM_RADIANT==2 TEAM_DIRE==3. Makes total sense!
-- if GetTeam() == TEAM_RADIANT then return 'R' else return 'D' end
--end
--
--function GetBotNames ()
-- truncated_team_id = string.sub(config.game_id, 1, 8) .. "_" .. TeamToChar()
-- retu... | nilq/small-lua-stack | null |
local Vector2 = import("./Vector2")
local function extractValues(v)
return { v.X, v.Y }
end
describe("types.Vector2", function()
it("should have an empty constructor", function()
local v = Vector2.new()
assert.not_nil(v)
assert.are.same({0, 0}, extractValues(v))
end)
it("should have a constructor with tw... | nilq/small-lua-stack | null |
function showCredits()
outputChatBox("------------------------------------------", 255, 194, 14)
outputChatBox("Script by Daniels, Chamberlain, Hankey, Cazomino05, mabako, Carlo, Serizzim, Konstantine & Flobu.", 255, 194, 14)
outputChatBox("Special thanks to Arc_, Ryden and Talidan.", 255, 194, 14)
outputChat... | nilq/small-lua-stack | null |
local self = {}
GLib.Containers.BinarySetOperatorController = GLib.MakeConstructor (self)
GLib.Containers.SetIntersectionController = function (...) return GLib.Containers.BinarySetOperatorController (function (left, right) return left and right end, ...) end
GLib.Containers.SetUnionController = function (.... | nilq/small-lua-stack | null |
local md5 = require "md5"
local ut = require "lluv.utils"
local struct = require "lluv.pg.utils.bin"
local FSM = require "lluv.pg.utils.fsm"
local MessageEncoder = require "lluv.pg.msg".encoder
local MessageDecoder = require "lluv.pg.msg".decoder
local DataTypes = require ... | nilq/small-lua-stack | null |
require('style')
| nilq/small-lua-stack | null |
DDHT = {}
DDHT.__index = DDHT
function DDHT:create(pin, sample_rate)
local this = {
-- The pin number of the DHT sensor, cannot be 0, type of a number.
executing_pin = pin;
-- The reference to the global DHT object.
DHT = dht;
-- The last status that was determined when reading from the Ddht.
... | nilq/small-lua-stack | null |
local create_server = require "nvim-lsp-installer.servers.vscode-langservers-extracted"
return create_server("jsonls", "vscode-json-language-server")
| nilq/small-lua-stack | null |
-- Copyright 2012,2013 Green Code LLC
-- All rights reserved.
--
-- 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... | nilq/small-lua-stack | null |
local Dta = select(2, ...)
Dta.Lang.English = {}
local English = Dta.Lang.English
----------------------------------------
--Help
----------------------------------------
---Intro------------------------------------------------------------------
English.Intro = {}
English.Intro.Label = "Intro"
English.Intro.Text1 = "... | nilq/small-lua-stack | null |
local filters = require "kong.plugins.corax.filters"
local mocks = require "spec.mocks"
local PLUGIN_NAME = require("kong.plugins.corax").PLUGIN_NAME
describe(PLUGIN_NAME .. ": (filters) ", function()
local conf
before_each(function()
conf = {
request_method = {"GET", "POST"},
content_type = {"ap... | nilq/small-lua-stack | null |
function zb_sailInfo()
resetGUI()
local text = "Welcome the new SAIL window! In addition to the new look, this rework can:\n\n > View non-vanilla currencies (Which cannot be displayed in the inventory because of hardcoded limitations)\n\n > Missions are split into main, and secondary tabs, as well as notifying you w... | nilq/small-lua-stack | null |
--[[
Filter target, then use a hidden channel to tp
]]
local tent = Entities:FindByClassname(nil, "npc_dota_tower")
--[[function OnSpellStart(keys)
print("oss called by" .. keys.caster:GetClassname())
local caster = keys.caster
local channel = caster:FindAbilityByName("troll_hidden_tp_channel")
print(channel:GetC... | nilq/small-lua-stack | null |
--
-- Created by IntelliJ IDEA.
-- User: nander
-- Date: 03/03/2019
-- Time: 10:17
-- To change this template use File | Settings | File Templates.
--
--
-- Created by IntelliJ IDEA.
-- User: nander
-- Date: 01/03/2019
-- Time: 21:57
-- To change this template use File | Settings | File Templates.
--
local dist = func... | nilq/small-lua-stack | null |
local e=epoe -- we cant be in epoe table or we'd need to add locals here on everything too
local TagHuman=e.TagHuman
-- For reloading
if ValidPanel(e.GUI) then e.GUI:Remove() end
local gradient = surface.GetTextureID( "VGUI/gradient_up" )
local epoe_font = CreateClientConVar("epoe_font", "BudgetLabel", true, false)... | nilq/small-lua-stack | null |
module 'mock'
local defaultTextStyle = MOAITextStyle.new()
defaultTextStyle:setFont( getFontPlaceHolder() )
defaultTextStyle:setSize( 10 )
local textAlignments={
center=MOAITextBox.CENTER_JUSTIFY,
left=MOAITextBox.LEFT_JUSTIFY,
right=MOAITextBox.RIGHT_JUSTIFY
}
local function countLine(s)
local c = 0
for _ in s... | nilq/small-lua-stack | null |
local Item = "ItemName"
local Quantity = 10
local Land = nil
for i,v in pairs(game.Workspace.Properties:GetChildren()) do
if v.Owner.Value == game.Players.LocalPlayer then
Land = v
break
end
end
if not Land then
for i,v in pairs(game.Workspace.Properties:GetChildren()) do
if v.Owner.Value... | nilq/small-lua-stack | null |
local t = Def.ActorFrame{};
t[#t+1] = Def.ActorFrame{
LoadActor("base");
LoadActor("hl")..{
InitCommand=cmd(diffusealpha,0);
OnCommand=cmd(smooth,0.3;diffusealpha,1;diffuseshift;effectcolor1,color("1,1,1,1");effectcolor2,color("1,1,1,0");effectperiod,1);
};
};
return t;
| nilq/small-lua-stack | null |
local whw = {}
-- utility functions
-- return output of given command
whw.capture = function(cmd, raw)
local f = assert(io.popen(cmd, "r"))
local s = assert(f:read("*a"))
f:close()
if raw then return s end
s = string.gsub(s, "^%s+", "")
s = string.gsub(s, "%s+$", "")
s = string.gsub(s, "[... | nilq/small-lua-stack | null |
Locales['en'] = {
['updating_information'] = '[%s] Updating player information....',
['waiting_information'] = '[%s] Waiting for database connection....',
['updated_information'] = '[%s] Player information updated....'
} | nilq/small-lua-stack | null |
highscoreList = {}
-- this is out here because it needs to be accessible before highscoreList:init() is called
highscoreList.file = 'highscores.txt'
function highscoreList:init()
self.leftAlign = 75
self.initialsInput = {' ', ' ', ' '}
self.selectorPos = 1
self.playerScore = 0
self.fromGame = false
self.scoreEn... | nilq/small-lua-stack | null |
---@meta
---@class cc.EaseSineOut :cc.ActionEase
local EaseSineOut={ }
cc.EaseSineOut=EaseSineOut
---*
---@param action cc.ActionInterval
---@return self
function EaseSineOut:create (action) end
---*
---@return self
function EaseSineOut:clone () end
---*
---@param time float
---@return self
function EaseSineOut... | nilq/small-lua-stack | null |
require "Polycode/Resource"
class "Cubemap" (Resource)
function Cubemap:Cubemap(...)
if type(arg[1]) == "table" and count(arg) == 1 then
if ""..arg[1]:class() == "Resource" then
self.__ptr = arg[1].__ptr
return
end
end
for k,v in pairs(arg) do
if type(v) == "table" then
if v.__ptr ~= nil then
... | nilq/small-lua-stack | null |
-- vessels_mtg/init.lua
minetest.register_alias("vessels:glass_bottle", "base_vessels:glass_bottle")
minetest.register_alias("vessels:steel_bottle", "base_vessels:steel_bottle")
minetest.register_alias("vessels:drinking_glass", "base_vessels:drinking_glass")
| nilq/small-lua-stack | null |
return
function(self)
self.indents_obj:init()
self.chunk_length = utf8.len(self.indents_obj.indent_chunk)
end
| nilq/small-lua-stack | null |
function onCreate()
makeAnimatedLuaSprite('static', 'tripletroublestuff/Phase3Static') --change to your static image path
addAnimationByPrefix('static', 'idle', 'Phase3Static instance 1', 24, false);
scaleObject('static', 4,4);
setProperty('static.alpha', 0.7);
setObjectCamera('static', 'hud')
setProperty('static... | nilq/small-lua-stack | null |
local ops = require("mongodbOps") --加载mongodb操作模块
local row = ops.rawRow() --当前数据库的一行数据,table类型,key为列名称
local action = ops.rawAction() --当前数据库事件,包括:insert、update、delete
local id = row["ID"] --获取ID列的值
local userName = row["USER_NAME"] --获取USER_NAME列的值
local password = row["PASSWORD"] --获取USER_NAME列的值
local c... | nilq/small-lua-stack | null |
project "Engine.UI.GDI"
kind "StaticLib"
pchheader "ghuigdipch.h"
pchsource "src/ghuigdipch.cpp"
staticruntime "on"
dependson {
"Engine.Core",
"Engine.UI"
}
files {
"src/**.h",
"src/**.cpp"
}
includedirs {
"src",
includeDir["Engine.Core"],
includeDir["Engine.UI"],
includeDir["tinyxml2"]
}
| nilq/small-lua-stack | null |
--[[
MIT License
Copyright (c) 2019 Michael Wiesendanger
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, mod... | nilq/small-lua-stack | null |
--救いの架け橋
--
--Script by Trishula9
function c100287014.initial_effect(c)
--activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TODECK+CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,100287014+EFFECT_COUNT_CODE_DUEL)
e1:SetCondition(c100287014.condition)... | nilq/small-lua-stack | null |
inFile = io.open("input.txt", "r")
data = inFile:read("*all") -- may be abbreviated to "*a";
-- other options are "*line",
-- or the number of characters to read.
inFile:close()
outFile = io.open("output.txt", "w")
outfile:write(data)
outfile:close()
-- Oneliner ... | nilq/small-lua-stack | null |
C_ReportSystem = {}
---@param playerLocation PlayerLocationMixin
---@return boolean canReport
---[Documentation](https://wow.gamepedia.com/API_C_ReportSystem.CanReportPlayer)
function C_ReportSystem.CanReportPlayer(playerLocation) end
---@param playerLocation PlayerLocationMixin
---@return boolean canReport
---[Docum... | nilq/small-lua-stack | null |
describe("Arithmetic progression", function()
local arithmetic_progression = require("numeric.sum.arithmetic_progression")
-- Compare against a simple for loop
local function arithmetic_progression_loop(from, to, step)
local sum = 0
for i = from, to, step do
sum = sum + i
end
return sum
end
it("returns ... | nilq/small-lua-stack | null |
local gateway = require("./gateway")
local format = string.format
local Bot = {}
function Bot:login(token)
if token == nil then return error("Nil token.") end
gateway:pack({token = token, first_heartbeat = true,
reconnecting = true,
session_id = nil,
sequence = 0,
... | nilq/small-lua-stack | null |
local huge = math.huge;
local VUHDO_CUSTOM_DEBUFF_CONFIG = { };
local VUHDO_UNIT_CUSTOM_DEBUFFS = { };
setmetatable(VUHDO_UNIT_CUSTOM_DEBUFFS, VUHDO_META_NEW_ARRAY);
local VUHDO_LAST_UNIT_DEBUFFS = { };
local VUHDO_PLAYER_ABILITIES = { };
local VUHDO_IGNORE_DEBUFFS_BY_CLASS = { };
local VUHDO_IGNORE_DEBUFF_NAMES ... | nilq/small-lua-stack | null |
--死境残存
local m=14000107
local cm=_G["c"..m]
function cm.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(cm.actcon)
e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:R... | nilq/small-lua-stack | null |
local L = LibStub("AceLocale-3.0"):NewLocale("TidyPlatesThreat", "koKR", false)
if not L then return end
L[" <no option> Displays options dialog"] = " <옵션 없음> 옵션 대화창 표시"
L[" 8.4-design Changes default settings to new look and feel (introduced with 8.4)"] = " 8.4-design 기본 설정을 새로운 모양과 느낌... | nilq/small-lua-stack | null |
-- themerooms is an array of tables and/or functions.
-- the tables define "frequency", "contents", "mindiff" and "maxdiff".
-- frequency is optional; if omitted, 1 is assumed.
-- mindiff and maxdiff are optional and independent; if omitted, the room is
-- not constrained by level difficulty.
-- a plain function has f... | nilq/small-lua-stack | null |
--- @class VolumeWatcherInfo
--- @field path string
| nilq/small-lua-stack | null |
before_each(function()
lor = _G.lor
app = lor({
debug = true
})
Request = _G.request
Response = _G.response
req = Request:new()
res = Response:new()
end)
after_each(function()
lor = nil
app = nil
Request = nil
Response = nil
req = nil
res = nil
end)
describ... | nilq/small-lua-stack | null |
local trigger = {}
trigger.name = "MaxHelpingHand/CameraCatchupSpeedTrigger"
trigger.placements = {
name = "trigger",
data = {
catchupSpeed = 1.0,
revertOnLeave = true
}
}
return trigger | nilq/small-lua-stack | null |
return {'set','setpoint','setpunt','setstanden','settelen','setter','setting','settopbox','setverlies','setwinst','setsysteem','seth','setz','seton','settels','setje','setjes','sets','setters','settertje','settopboxen','setpoints','settelde','setpunten','seths'} | nilq/small-lua-stack | null |
------------------------------------------------------------------------------
-- Button class
------------------------------------------------------------------------------
local ctrl = {
nick = "button",
parent = iup.WIDGET,
creation = "S-",
callback = {
action = "",
}
}
function ctrl.createElement(... | nilq/small-lua-stack | null |
--------------------------------------------------------------------------------
-- АРС-АЛС
--------------------------------------------------------------------------------
Metrostroi.DefineSystem("BARS")
TRAIN_SYSTEM.DontAccelerateSimulation = true
function TRAIN_SYSTEM:Initialize()
self.Train:LoadSystem("RC2... | nilq/small-lua-stack | null |
local requestedIpl = {"h4_islandairstrip", "h4_islandairstrip_props", "h4_islandx_mansion", "h4_islandx_mansion_props", "h4_islandx_props", "h4_islandxdock", "h4_islandxdock_props", "h4_islandxdock_props_2", "h4_islandxtower", "h4_islandx_maindock", "h4_islandx_maindock_props", "h4_islandx_maindock_props_2", "h4_Island... | nilq/small-lua-stack | null |
-- --------------------
-- TellMeWhen
-- Originally by Nephthys of Hyjal <lieandswell@yahoo.com>
-- Other contributions by:
-- Sweetmms of Blackrock, Oozebull of Twisting Nether, Oodyboo of Mug'thol,
-- Banjankri of Blackrock, Predeter of Proudmoore, Xenyr of Aszune
-- Currently maintained by
-- Cybeloras... | nilq/small-lua-stack | null |
local categories = require "category"
local function new(category)
local x = map.startX
local y = map.startY
local speedX = categories.speedX[category] or categories.speedX[#categories.speedX]
local speedY = categories.speedY[category] or categories.speedY[#categories.speedY]
local radius = categories.radius... | nilq/small-lua-stack | null |
Inventory = {
Items = {},
ItemCount = 0,
}
function Inventory:AddItem( item )
System:LogToConsole( "Add item to inventory..." );
self.ItemCount = self.ItemCount + 1;
self.Items[ self.ItemCount ] = item;
end
function Inventory:RemoveItem( itemid )
System:LogToConsole( "Remove item to inventory..." );
local i;
... | nilq/small-lua-stack | null |
return {
components = {
bone = {},
parentConstraint = {
enabled = false,
},
},
children = {
{
components = {
bone = {
transform = {0, 0, 0, 1 / 32, 1 / 32, 6, 3},
},
parentConstraint = {},
sprite = {
image = "carnelia/resources/im... | nilq/small-lua-stack | null |
local class = require "lib.lua-oop"
Timer = class("Timer")
function Timer:constructor(timeOutSecs, oneShoot, start)
self.timeOutSecs = timeOutSecs
self.oneShoot = oneShoot
self.destroyed = false
self.started = false
self.hasTimeOuted = false
self.timeout = false
self.onTimeouts = {}
... | nilq/small-lua-stack | null |
--[[
LibPlayerSpells-1.0 - Additional information about player spells.
(c) 2013-2018 Adirelle (adirelle@gmail.com)
This file is part of LibPlayerSpells-1.0.
LibPlayerSpells-1.0 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 Softwar... | nilq/small-lua-stack | null |
-- LuaDist Package dependency solver
-- Part of the LuaDist project - http://luadist.org
-- Author: Martin Srank, hello@smasty.net
-- License: MIT
local const = require("rocksolver.constraints")
local utils = require("rocksolver.utils")
local Package = require("rocksolver.Package")
local DependencySolver = {}
Depend... | nilq/small-lua-stack | null |
response.status = "500 Internal Server Error"
if string.lower(response['content-type'] or "") == 'text/plain' then
print("An error occurred while processing this request")
print(request.params.error or "")
print(request.params.trace or "")
else
template:out("500", {error = webylene.config.show_errors and request.p... | nilq/small-lua-stack | null |
-- example of button click and hover events.
-- Should be in client context, as buttons would generally be per-player
local button = script.parent
function OnClicked(whichButton)
print("button clicked: " .. whichButton.name)
Events.Broadcast('AnswerChosen', whichButton.text)
end
button.clickedEvent:Connect(OnClicke... | nilq/small-lua-stack | null |
local debuglinetrace = ImportPackage("debuglinetrace")
local function Check_aim_npc()
if IsPlayerAiming() then
local weap = GetPlayerWeapon(GetPlayerEquippedWeaponSlot())
if GetWeaponType(weap) ~= 0 then
local range = 2000
local camX, camY, camZ = GetCameraLocation()
... | nilq/small-lua-stack | null |
--[[
© CloudSixteen.com do not share, re-distribute or modify
without permission of its author (kurozael@gmail.com).
Clockwork was created by Conna Wiles (also known as kurozael.)
http://cloudsixteen.com/license/clockwork.html
--]]
include("shared.lua")
-- Called when the target ID HUD should be painted.
functio... | nilq/small-lua-stack | null |
local filter = EasyDestroyFilterCriteria:New("Item Name", "name", 20)
-- There's no reason a filter should show up more than once
-- So we can treat it as a singleton and just use this to
-- get any previous creations of the filter frame, or
-- create it if it's not yet been made
function filter:Initialize()
-- We... | nilq/small-lua-stack | null |
local awful = require("awful")
local wibox = require("wibox")
local beautiful = require("beautiful")
local vicious = require("vicious")
local naughty = require("naughty")
-- Spacers
volspace = wibox.widget.textbox()
volspace:set_text(" ")
-- {{{ BATTERY
-- Battery attributes
local bat_state = ""
local bat_charge = 0... | nilq/small-lua-stack | null |
require('harpoon').setup({
nav_first_in_list = true,
})
vim.keymap.set('n', '<leader>hm', ':lua require("harpoon.mark").add_file()<CR>')
vim.keymap.set('n', '<leader>hum', ':lua require("harpoon.ui").toggle_quick_menu()<CR>')
vim.keymap.set('n', '<leader>hcm', ':lua require("harpoon.cmd-ui").toggle_quick_menu()<CR... | nilq/small-lua-stack | null |
local skynet = require "skynet"
local protobuf = require "protobuf" --引入文件protobuf.lua
skynet.start(function()
protobuf.register_file("./protos/test.pb")
protobuf.register_file("./protos/person.pb")
skynet.error("protobuf register:test.pb person.pb")
stringbuffer = protobuf.encode("cs.test", --对应pers... | nilq/small-lua-stack | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.