content stringlengths 0 1.05M | origin stringclasses 2
values | type stringclasses 2
values |
|---|---|---|
require("prototypes.entity.e-cheat") | nilq/small-lua-stack | null |
return {
setup = function()
local capabilities = vim.lsp.protocol.make_client_capabilities()
capabilities.textDocument.completion.completionItem.snippetSupport = true
require("lspconfig").cssls.setup({
capabilities = capabilities,
})
end,
}
| nilq/small-lua-stack | null |
local filename, args = ...
local docroot = args
-- create new class XFilterDrop
local XFilterDrop = { }
XFilterDrop.__index = XFilterDrop
-- "classmethod" to create new instance
function XFilterDrop:new(vr)
-- vr:debug("New XSendfile instance")
local o = { }
setmetatable(o, self)
return o
end
-- normal method t... | nilq/small-lua-stack | null |
local enum = require("wordplay.enum")
local TokenType = enum {
-- Single-character tokens.
[0] = "LEFT_PAREN",
"RIGHT_PAREN",
"LEFT_BRACKET",
"RIGHT_BRACKET",
[10] =
"COLON",
"COMMA",
"DOT",
"MINUS",
"PERCEN... | nilq/small-lua-stack | null |
local function upgrade_formspec (upgrades, desc)
local posY = 0.5
local fspec = ""
for k in pairs(upgrades) do
local scrib = elepm.upgrading.dict[k]
if not scrib then
scrib = k
end
fspec = fspec .. "label[1,"..(posY + 0.25)..";"..scrib.."]"
fspec = fspec .. "list[detached:soldering;"..k..";7,"..posY... | nilq/small-lua-stack | null |
fx_version 'adamant'
game 'gta5'
client_scripts {
'cl.lua',
'cfg.lua',
} | nilq/small-lua-stack | null |
local Randy = require('randy')
local Tap = require('tap')
local tap = Tap.new {name='randy.lua'}
tap:addTest(
'integer()',
function (test)
local r = Randy.new()
local ones = 0
local twos = 0
for _ = 1, 1000 do
local result = r:integer(2)
if result == 2 then
twos = twos + 1
... | nilq/small-lua-stack | null |
--[[
bag.lua
A bag button object
--]]
local ADDON, Addon = ...
local L = LibStub('AceLocale-3.0'):GetLocale(ADDON)
local Bag = Addon:NewClass('Bag', 'CheckButton')
Bag.SIZE = 32
Bag.TEXTURE_SIZE = 64 * (Bag.SIZE/36)
Bag.GetSlot = Bag.GetID
--[[ Constructor ]]--
function Bag:New(parent, id)
local bag = self:Bin... | nilq/small-lua-stack | null |
local Gamestate = require("lib.hump.gamestate")
local colors = require("src.colors")
local gfx = require("src.gfx")
local Board = require("src.states.board")
local ENTER = 0.5 -- fade in time
local HOLD = 2.0 -- hold time
local LEAVE = 0.5 -- fade out time
local Studio = {}
function Studio:init()
gfx.loadUniform... | nilq/small-lua-stack | null |
local AuctionHouse =
{
Name = "AuctionHouse",
Type = "System",
Namespace = "C_AuctionHouse",
Functions =
{
{
Name = "CalculateCommodityDeposit",
Type = "Function",
Arguments =
{
{ Name = "itemID", Type = "number", Nilable = false },
{ Name = "duration", Type = "number", Nilable = false },
... | nilq/small-lua-stack | null |
local ft = {}
local function clonefunction(func, env)
return load(string.dump(func, true), nil, "b", env);
end
local function instantiateClass(inst_class_tbl, ...)
local inst_tbl = {}
local environments = {};
local constructors = {}
local function builderrormessage(msg)
return "C... | nilq/small-lua-stack | null |
local backgroundTexture = game.getTexture("res/menu_bg.png")
local buttonTexture = game.getTexture("res/button_small.png")
local function createWorldSelectButton(menu, slot)
local selector = menu:addButton("Create New World")
if slot == 0 then
local name = "World Name"
local date = "01/01/20... | nilq/small-lua-stack | null |
--config.lua
local ticks_per_update = settings.startup["ret-ticks-per-update"].value
function store(power)
return power / 60 * (ticks_per_update + 5)
end
config = {
pole_max_wire_distance = 17,
pole_supply_area = 4,
-- Refills the buffer until the next update
pole_flow_limit = 4800000,
-- Pole enable buffer... | nilq/small-lua-stack | null |
local log = require("log")
local Api = require("coreApi")
local json = require("json")
local http = require("http")
function ReceiveFriendMsg(CurrentQQ, data)
return 1
end
function ReceiveGroupMsg(CurrentQQ, data)
if string.find(data.Content, ".gayhub") == 1 then
Api.Api_SendMsg(--调用发消息的接口
CurrentQQ,
... | nilq/small-lua-stack | null |
class = require 'pl.class'
M = require 'pl.Map'
S = require 'pl.Set'
List = require 'pl.List'
asserteq = require 'pl.test' . asserteq
asserteq2 = require 'pl.test' . asserteq2
MultiMap = require 'pl.MultiMap'
OrderedMap = require 'pl.OrderedMap'
s1 = S{1,2}
s2 = S{1,2}
-- equality
asserteq(s1,s2)
-- union
asserteq(S{... | nilq/small-lua-stack | null |
-- Hit-reg Fix by Devieth
-- Script for SAPP and Chimera
-- Default = 0.08
-- Recommended = 0.05
-- Minimum = 0.045
-- Above 0.08 hit-reg gets worse, unless you want that...
-- Below 0.03 headshots STOP WORKING ENTIRELY!!!
value = 0.046
-- Force enable the fix every time the script is loaded/reloaded.
... | nilq/small-lua-stack | null |
local awful = require("awful")
local beautiful = require("beautiful")
local keys = require("core.keys")
local env = require("environment")
awful.rules.rules = {
-- all clients
{
rule = { },
properties = {
border_width = beautiful.border_width,
... | nilq/small-lua-stack | null |
return [[
dotfiles for osx
Currently using the following:
* iTerm2 terminal
* Terminal theme: Profiles->Colors->Color Presets...-> srcery_iterm
]]
| nilq/small-lua-stack | null |
slot0 = class("WorldAtlas", import("...BaseEntity"))
slot0.Fields = {
achEntranceList = "table",
sairenEntranceList = "table",
replaceDic = "table",
config = "table",
costMapDic = "table",
mapDic = "table",
activeEntranceId = "number",
areaEntranceList = "table",
pressingMapList = "table",
portEntranceList = ... | nilq/small-lua-stack | null |
local function clientReset(player)
-- assert(typeof(playerId) == "string")
return {
type = script.Name,
playerId = tostring(player.UserId),
playerName = tostring(player.Name),
replicateTo = tostring(player.UserId),
}
end
return clientReset | nilq/small-lua-stack | null |
UT.Driving = {}
UT.Driving.units = {}
local settings = UT.getSettings()
UT.Driving.packagesLoaded = settings.loadPackages
function UT.Driving.setPackagesLoading(value)
local settings = UT.getSettings()
settings.loadPackages = value
UT.setSettings(settings)
if value then
UT.showMessage("packag... | nilq/small-lua-stack | null |
local dap = require('dap')
dap.set_log_level('TRACE');
-- Enable virtual text.
vim.g.dap_virtual_text = true
-- Setup for debugging in Node
dap.adapters.node2 = {
type = 'executable',
command = 'node',
args = {os.getenv('HOME') .. '/vscode-node-debug2/out/src/nodeDebug.js'},
}
-- Setup for debugging in Chrome... | nilq/small-lua-stack | null |
local console = require 'console'
function love.load()
-- Step 1: load console, parameters are optional, defaults enumerated below
-- The key to open/close console == `
-- font size == 14
-- false = no key repeat by default, pressing (and not releasing backspace) will act in a strange way
-- nil == fu... | nilq/small-lua-stack | null |
-- Copyright (c) 2021 Trevor Redfern
--
-- This software is released under the MIT License.
-- https://opensource.org/licenses/MIT
local Thunk = require "moonpie.redux.thunk"
local Aliens = require "game.rules.aliens"
local Camera = require "game.ui.camera"
local Character = require "game.rules.character"
loc... | nilq/small-lua-stack | null |
module(...,package.seeall)
require "sys"
require "audio"
require "net"
require "misc"
require "lvsym"
scr0 = nil
scr1 = nil
sign = nil
menu_btn = nil
ret_btn = nil
menu_page = nil
is_hidden = true
clock = nil
key_number = lvgl.KEY_NEXT
key_pending = false
key_state = lvgl.INDEV... | nilq/small-lua-stack | null |
-- premake5.lua
-- Helpers
function os.winSdkVersion()
local reg_arch = iif( os.is64bit(), "\\Wow6432Node\\", "\\" )
local sdk_version = os.getWindowsRegistry( "HKLM:SOFTWARE" .. reg_arch .."Microsoft\\Microsoft SDKs\\Windows\\v10.0\\ProductVersion" )
if sdk_version ~= nil then return sdk_version end
end
... | nilq/small-lua-stack | null |
#!/usr/bin/env lua
-- Copyright (c) 2016 Francois Perrad
local f = arg[1] and assert(io.open(arg[1], 'r')) or io.stdin
local src = string.gsub(f:read'*a', '[^><+%-%.,%[%]]', '')
f:close()
print[[
#!/usr/bin/env lua
io.stdout:setvbuf'no'
local buffer = setmetatable({}, {
__index = function ()
return 0 ... | nilq/small-lua-stack | null |
local fs = require 'diagnosticls-nvim.fs'
return {
sourceName = 'ts_standard',
command = fs.get_executable('ts-standard', 'node'),
debounce = 100,
args = { '--stdin', '--stdin-filename', '%filepath', '--verbose' },
offsetLine = 0,
offsetColumn = 0,
formatLines = 1,
formatPattern = {
[[^\s*([^:]+):(... | nilq/small-lua-stack | null |
-----------------------------------
-- Area: Selbina
-- NPC: Yaya
-- Starts Quest: Under the sea
-- !pos -19 -2 -16 248
-----------------------------------
require("scripts/globals/quests")
-----------------------------------
function onTrade(player, npc, trade)
end
function onTrigger(player, npc)
if player:getF... | nilq/small-lua-stack | null |
function Return(keys)
local caster = keys.caster
local attacker = keys.attacker
local ability = keys.ability
local level = ability:GetLevel() - 1
local strMultiplier = caster:GetStrength() * ability:GetLevelSpecialValueFor("str_to_reflection_pct", level) * 0.01
local multiplier = ((ability:GetLevelSpecialValueFor... | nilq/small-lua-stack | null |
toxic_spray_trap = {
click = function(block, npc)
if (block.blType == BL_PC) then
-- Carnage etc.
if block.state == 1 then
return
end
if not block:canPK(block) then
return
end
end
block.attacker = npc.owner
removeTrapItem(npc)
npc:delete()
toxic_spray.cast(npc, block)
block:update... | nilq/small-lua-stack | null |
Core = {}; -- Core Lib
Scenes = {};
pl = {};
Debug = {};
inspect = require("Lib/Extlibs/Inspect");
pl.Date = require("Lib/Extlibs/pl/Date");
pl.List = require("Lib/Extlibs/pl/List");
pl.String = require("Lib/Extlibs/pl/stringx");
pl.Table = require("Lib/Extlibs/pl/tablex");
pl.Array2d = require("Lib/Extlibs/pl/array2d... | nilq/small-lua-stack | null |
--***********************************************************
--** ROBERT JOHNSON **
--***********************************************************
require "TimedActions/ISBaseTimedAction"
---@class ISAddCoalInFurnace : ISBaseTimedAction
ISAddCoalInFurnace = ISBaseTimedAction:der... | nilq/small-lua-stack | null |
-- "Test cases" for ndex and ndex-list
local ndex = require('Ndex')
local ndexlist = require('Ndex-list')
local nondex = require('test.LoadNondex')
local render = require('Render')
nondex{ types = false }
-- Cases tested:
-- Standard
-- Standard
-- Base form (with alternative forms)
-- Alternative... | nilq/small-lua-stack | null |
if GetLocale() ~= "deDE" then return end
if not DBM_GUI_Translations then DBM_GUI_Translations = {} end
local L = DBM_GUI_Translations
L.MainFrame = "Deadly Boss Mods"
L.TranslationByPrefix = "Übersetzt von "
L.TranslationBy = "Ebmor@EU-Malorne"
L.Website = "Besuche die Diskussions-/Support-Foren: |cF... | nilq/small-lua-stack | null |
local cjson = require("cjson")
local _M = {}
-- 获取http get/post 请求参数
function _M.getArgs(name, default)
local request_method = ngx.var.request_method
local args = {}
-- 参数获取
if "POST" == request_method then
ngx.req.read_body()
local postArgs = ngx.req.get_post_args()
if postArgs... | nilq/small-lua-stack | null |
local util = require("util.util")
local _M = {}
_M._VERSION = '1.0'
local function getCookieValue(s,key)
local i,j = string.find(s,key,0,true)
local value
if i == nil then
return nil
end
local q,_ = string.find(s,";",j,true);
if q == nil then
value = string.sub(s,j+1)
else... | nilq/small-lua-stack | null |
------------------------------------------------------------------------
--- @file esp.lua
--- @brief ESP utility.
--- Utility functions for the esp_header structs
--- Includes:
--- - ESP constants
--- - IPsec IV
--- - ESP header utility
--- - Definition of esp packets
-------------------------------------------------... | nilq/small-lua-stack | null |
animComp = {}
function animComp.newAnim(qFrames, animTime, doRepeat)
local anim = {}
anim.time = animTime
anim.capTime = animTime / qFrames
anim.qFrames = qFrames
anim.canRepeat = (doRepeat==nil or doRepeat==true)
animComp.restart(anim)
return anim;
end
function animComp.update(dt, anim)
anim.curr_tim... | nilq/small-lua-stack | null |
local PluginRoot = script:FindFirstAncestor("PluginRoot")
local load = require(PluginRoot.Loader).load
local Roact = load("Roact")
local ScrollingVerticalList = load("Framework/ScrollingVerticalList")
local StoryWrapper = load("Stories/StoryWrapper")
local e = Roact.createElement
return function(target)
Roact.setGl... | nilq/small-lua-stack | null |
---
--- Generated by EmmyLua(https://github.com/EmmyLua)
--- Created by Bzouk.
--- DateTime: 22.12.2020 11:11
---
require "ISUI/ISPanel"
require "ISUI/ISButton"
require "ISUI/ISInventoryPane"
require "ISUI/ISInventoryPage"
require "ISUI/ISResizeWidget"
require "ISUI/ISMouseDrag"
require "ISUI/ISLayoutManager"
require ... | nilq/small-lua-stack | null |
return {'obboezem','obbink','obbens','obbes'} | nilq/small-lua-stack | null |
ESX = nil
local PlayerData = {}
local isLoggedIn = false
Callbacks = nil
actionCb = {}
isPhoneOpen = false
Citizen.CreateThread(function()
while ESX == nil do
TriggerEvent('esx:getSharedObject', function(obj) ESX = obj end)
Citizen.Wait(0)
end
while ESX.GetPlayerData().job == nil do
Citizen.Wait(10)
end
E... | nilq/small-lua-stack | null |
------------------------------------------------------------------------
--[[ ArgMax ]]--
-- Returns the index of the maxima for dimension dim.
-- Cannot backpropagate through this module.
-- Created for use with ReinforceCategorical.
------------------------------------------------------------------------
local ArgMax... | nilq/small-lua-stack | null |
local THNN = require 'nn.THNN'
local SpatialDownSampling, parent = torch.class('nn.SpatialDownSampling', 'nn.Module')
function SpatialDownSampling:__init(nInputPlane, kW, kH, dW, dH, padW, padH)
parent.__init(self)
dW = dW or 1
dH = dH or 1
self.nInputPlane = nInputPlane
self.nOutputPlane = nInputPlane... | nilq/small-lua-stack | null |
-- LuaJIT's memory profile post-processing module.
local M = {}
local symtab = require "utils.symtab"
function M.form_heap_delta(events, symbols)
-- Auto resurrects source event lines for counting/reporting.
local dheap = setmetatable({}, {__index = function(t, line)
rawset(t, line, {
dbytes = 0,
... | nilq/small-lua-stack | null |
local resty_redis = require("resty.redis")
local strutil = require("acid.strutil")
local rpc_logging = require("acid.rpc_logging")
local to_str = strutil.to_str
local _M = { _VERSION = "0.1" }
local mt = { __index = _M }
local function get_redis_cli(self)
local redis_cli, err_msg = resty_redis:new()
if redis... | nilq/small-lua-stack | null |
-- Command line code to serialize assets for rojo syncing
local feed = "return {\n"
local defaults = {
["Volume"] = 0.5,
["EmitterSize"] = 10,
["MaxDistance"] = 10000,
["Looped"] = false,
["PlaybackSpeed"] = 1,
}
for _, sound in pairs(game.ReplicatedStorage.assets.sounds:GetChildren()) do
fee... | nilq/small-lua-stack | null |
--- @title:
--- GNPanel: <Panel> Base GNLib panel used as a parent for other VGUIs such as GNButton.
--- @note:
--- Parent: DFrame
--- @params:
--- GNPanel/SetColor( Color color ): <function> Set panel color
--- GNPanel/GetColor(): <function> Get panel color
--- GNPanel/SetDefaultCursor( string cursor ): <function... | nilq/small-lua-stack | null |
return {'hor','hora','horde','hordeloop','hordeloopster','hordelopen','hordeloper','horden','horeca','horecabedrijf','horecabeheer','horecabeleid','horecabestemming','horecabeurs','horecabond','horecaboot','horecabranche','horecafaciliteiten','horecafunctie','horecagebied','horecagedeelte','horecagelegenheid','horecagr... | nilq/small-lua-stack | null |
local nn = require 'nn'
require 'cunn'
local Convolution = cudnn.SpatialConvolution
local SBatchNorm = nn.SpatialBatchNormalization
local Max = nn.SpatialMaxPooling
local ReLU = nn.ReLU
local Dropout = nn.Dropout
local function convblock(ninput, noutput)
return nn.Sequential()
:add(Convolution(ninput,noutput... | nilq/small-lua-stack | null |
-- MySQL client library ffi binding.
-- Written by Cosmin Apreutesei. Public domain.
-- Supports MySQL Connector/C 6.1.
-- Based on MySQL 5.7 manual.
local ffi = require 'ffi'
local bit = require 'bit'
require 'mysql_h'
local C
local M = {}
-- select a mysql client library implementation.
local function bind(lib)
... | nilq/small-lua-stack | null |
local tinsert = table.insert
-- --------------------------------------------------------------------------------------------------------
-- Add gltfloader to load meshes into pool temps
-- local gltf = require("meshpool.gltfloader")
local fpgen = require("meshpool.filepool-gen")
-- ----------------------------------... | nilq/small-lua-stack | null |
local Transpose, parent = torch.class('nn.Transpose', 'nn.Module')
-- transpose dimensions:
-- n = nn.Transpose({1,4},{1,3})
-- will transpose dims 1 and 4, then 1 and 3...
function Transpose:__init(...)
parent.__init(self)
self.permutations = {...}
end
function Transpose:updateOutput(input)
for _,perm in i... | nilq/small-lua-stack | null |
local discordia = require('discordia')
local settings = require("./resources/settings.lua")
local client = discordia.Client{fetchMembers=true}
coroutine.wrap(function() require('./resources/framework.lua')(client,{settings=settings}) end)()
client:run(settings.token)
| nilq/small-lua-stack | null |
local shroud = game.Workspace.Orbs:FindFirstChildOfClass('Folder')
local plr = game.Players.LocalPlayer.Character.HumanoidRootPart
while true do
wait(2)
for _, h in pairs(shroud['SpeedOrb']:GetChildren()) do
if h.ClassName == "MeshPart" then
h.CFrame = plr.CFrame
end
end
end | nilq/small-lua-stack | null |
module(..., package.seeall)
local MP = require("ManchesterParser")
require "core"
--ROLE
function setPrefixFromSchemaAssertionRole(compartment, oldValue)
local name = compartment:find("/parentCompartment/subCompartment:has(/compartType[id='Name'])")
local compartment = compartment:filter(function(obj)
re... | nilq/small-lua-stack | null |
-- This Flag is a descendant of the Common folder instead of Modules/Flags
-- because it needs to be accessible by both Modules/Common/LegacyThumbnailUrls and
-- other places like Emotes, InspectAndBuy
--
-- Since the server only has access to the Common and Server folders, it's
-- placed here so both parts of the code... | nilq/small-lua-stack | null |
local Unit = require 'common.class' ()
function Unit:_init(specname)
local spec = require('database.units.' .. specname)
self.spec = spec
self.hp = spec.max_hp
self.hitDamage = self.spec.hitDamage
end
function Unit:get_name()
return self.spec.name
end
function Unit:reset(name, SpriteAtlas)
local pos = s... | nilq/small-lua-stack | null |
Clothes = {
["chapeu"] = {
name = "hats",
hash = 0x9925C067
},
["camisa"] = {
name = "shirts",
hash = 0x2026C46D
},
["colete"] = {
name = "vests",
hash = 0x485EE834
},
["casaco"] = {
name = "coats",
hash = 0x662AC34
},
[... | nilq/small-lua-stack | null |
local L = LibStub("AceLocale-3.0"):NewLocale("StableSnapshot", "deDE")
if not L then return end
--@localization(locale="deDE", format="lua_additive_table", handle-unlocalized="english", handle-subnamespaces="concat")@ | nilq/small-lua-stack | null |
data:extend{
{
type = "int-setting",
name = "RailTools_max-search-distance",
setting_type = "runtime-global",
order = 100,
default_value = 100,
minimum_value = 2,
},
{
type = "int-setting",
name = "RailTools_max-placed-signals",
setting... | nilq/small-lua-stack | null |
--[[
Copyright 2014-2015 The Luvit Authors. 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 applicable law o... | nilq/small-lua-stack | null |
local t =
Def.ActorFrame {
Def.Quad {
InitCommand=function(self)
self:xy(SCREEN_CENTER_X,SCREEN_CENTER_Y):zoomto(SCREEN_WIDTH,SCREEN_HEIGHT):diffuse(color("#000000"))
end,
OnCommand=function(self)
self:stretchto(SCREEN_LEFT,SCREEN_TOP,SCR... | nilq/small-lua-stack | null |
vim.o.termguicolors = true
vim.o.pumblend = 15
vim.o.ignorecase = true
vim.o.smartcase = true
vim.o.incsearch = true
vim.o.hidden = true
vim.o.history = 5000
vim.o.tabstop = 2
vim.o.shiftwidth = vim.o.tabstop
vim.wo.number = true
-- vim.wo.cursorcolumn = true
-- vim.wo.cursorline = true
vim.opt.fillchars["eob"] = "... | nilq/small-lua-stack | null |
-----------------------------------
-- Area: Wajaom Woodlands
-- NPC: Watisa
-- Type: Chocobo Renter
-- !pos -201 -11 93 51
-----------------------------------
require("scripts/globals/chocobo")
-----------------------------------
local eventSucceed = 9
local eventFail = 10
function onTrade(player,npc,trade)
end
... | nilq/small-lua-stack | null |
local memo = require 'memo'
local t = require 'testhelper'
local c = 0
local add=memo(function(a,b) c=c+1 return a+b end)
t(c, 0)
t(add(1,2), 3)
t(c, 1)
t(add(1,2), 3)
t(c, 1)
t(add(1,2), 3)
t(c, 1)
t(add(2,2), 4)
t(c, 2)
t(add(2,2), 4)
t(c, 2)
t.test_embedded_example()
t()
| nilq/small-lua-stack | null |
squid = class:new()
function squid:init(x, y, color, p)
self.x = x-1+2/16
self.y = y-1+4/16
self.width = 12/16
self.height = 12/16
self.rotation = 0 --for portals
self.speedy = 0
self.speedx = 0
self.active = true
self.static = false
self.autodelete = true
self.gravity = 0
self.category = 30
self.co... | nilq/small-lua-stack | null |
LmodMessage("Processing Dependency/5.6")
| nilq/small-lua-stack | null |
--[[
Settings for Player Effects
]]
-- Wheather to use the HUD to expose the active effects to players (true or false)
playereffects.use_hud = true
-- Wheather to use autosave (true or false)
playereffects.use_autosave = true
-- The time interval between autosaves, in seconds (only used when use_autosave is true)
p... | nilq/small-lua-stack | null |
return function (colony)
local bit = require('bit32')
local uv = uv_open()
-- locals
local js_arr = colony.js_arr
local js_obj = colony.js_obj
local js_new = colony.js_new
local js_tostring = colony.js_tostring
local js_instanceof = colony.js_instanceof
local js_typeof = colony.js_typeof
local js_arguments = colony.... | nilq/small-lua-stack | null |
--[[
MIT License
Copyright (c) 2020 DekuJuice
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, modify, merge, publish, d... | nilq/small-lua-stack | null |
--
-- MultinomialAction.lua
-- hard-attention
--
-- Created by Andrey Kolishchak on 09/27/15.
--
require 'nn'
local MultinomialAction, parent = torch.class('nn.MultinomialAction', 'nn.Module')
function MultinomialAction:__init()
parent.__init(self)
self.epsilon = 1e-12
self.input = torch.Tensor()
end
... | nilq/small-lua-stack | null |
--TODO: Add domain-specific manuals, Document
local air = require("air")
local json = require("json")
local file = require("file")
file.activate_json(json)
local segment = {}
segment.setnames = {}
segment.name = "enforcer"
segment.settings = {
automod = {
list = {
},
status = false,
warn_limit = 3
... | nilq/small-lua-stack | null |
local K, C = unpack(select(2, ...))
local Module = K:GetModule("Blizzard")
if not Module then
return
end
local _G = _G
local floor = math.floor
local format = string.format
local CreateFrame = _G.CreateFrame
local hooksecurefunc = _G.hooksecurefunc
local UnitAlternatePowerInfo = _G.UnitAlternatePowerInfo
local Unit... | nilq/small-lua-stack | null |
-- Chinese Traditional localization file for zhTW. by BNSSNB and rest by Google translator
local _
-- global functions and variebles to locals to keep LINT happy
local assert = _G.assert
local LibStub = _G.LibStub; assert(LibStub ~= nil,'LibStub')
-- local AddOn
local ADDON = ...
local AceLocale = LibStub:GetLibrary("... | nilq/small-lua-stack | null |
-- xed-init.lua
local ffi = require("ffi")
ffi.cdef[[
void xed_tables_init();
]]
local xedlib = ffi.load("xed.dll")
local exports = {
xedlib = xedlib;
}
-- This must be called once before using the library
xedlib.xed_tables_init();
return exports;
| nilq/small-lua-stack | null |
measure = {"\(^\circ\)", "'", "''"}
numb = {}
index = {}
for i = 1,3 do
index[i] = math.random(4) - 1
if (index[i] > 0) then
index[i] = 1
end
end
if (index[1] == 0 and index[2] == 0) then
index[1] = 1
end
numb[1] = index[1] * math.random(180)
value = numb[1]
for i = 2,3 do
numb[i] = index[i] *... | nilq/small-lua-stack | null |
project "Lapack"
kind "None"
zpm.export(function()
if zpm.configuration( "lapack-version" ) == "MKL" then
zpm.uses "Zefiros-Software/MKL"
end
end)
| nilq/small-lua-stack | null |
-- Copyright (c) 2020-2021 shadmansaleh
-- MIT license, see LICENSE for more details.
-- stylua: ignore
local colors = {
color3 = '#2c3043',
color6 = '#a1aab8',
color7 = '#82aaff',
color8 = '#ae81ff',
color0 = '#092236',
color1 = '#ff5874',
color2 = '#c3ccdc',
}
return {
replace = {
a... | nilq/small-lua-stack | null |
--- === plugins.core.streamdeck.manager ===
---
--- Elgato Stream Deck Manager Plugin.
local require = require
local log = require "hs.logger".new "streamDeck"
local application = require "hs.application"
local appWatcher = require "hs.application.watcher"
local canvas ... | nilq/small-lua-stack | null |
util.AddNetworkString("StockMenu_Open");
util.AddNetworkString("NewStockDataReceived");
util.AddNetworkString("Player_ShareActions");
util.AddNetworkString("ChatMsg_CL");
stockdata = {};
local function ChatMsgCL(ply, msg)
net.Start("ChatMsg_CL");
net.WriteString(msg);
net.Send(ply);
end
//this reloads the layou... | nilq/small-lua-stack | null |
--[[
EntranceJew made this.
https://github.com/EntranceJew/hooker
Edited by VideahGams to fit the engines needs
]]
--- The hook library allows scripts to interact with game or user created events. It allows you to "hook" a function onto an event created with
-- hook.run or hook.call and run code when that events ha... | nilq/small-lua-stack | null |
--- A module designed to show multiple sprites or UI elements at once.
--- @classmod scene
local scheduler = require "scheduler"
local camera = require "camera"
local parser = parser --Circular dependencies!
local sprite = require "sprite"
local font = love.graphics.getFont()
local fontHeight = font:getHeight()
local... | nilq/small-lua-stack | null |
return {
-- "System.Globalization.Native",
"System.IO.Compression.Native",
-- "System.IO.Ports.Native",
-- "System.Native",
-- "System.Net.Security.Native",
-- "System.Security.Cryptography.Native.OpenSsl"
} | nilq/small-lua-stack | null |
local SwapTest = {}
local SwapCardCtr = import(".SwapCardCtr")
--所有牌
local allCard =
{
0x11,0x12,0x13,0x14,0x15,0x16,0x17,0x18,0x19,0x1A,0x1B,0x1C,0x1D,
0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,0x2A,0x2B,0x2C,0x2D,
0x31,0x32,0x33,0x34,0x35,0x36,0x37,0x38,0x39,0x3A,0x3B,0x3C,0x3D,
0x41,0x42,0x43,0x44,0x... | nilq/small-lua-stack | null |
local OVALE, Ovale = ...
local OvaleScripts = Ovale.OvaleScripts
do
local name = "icyveins_deathknight_blood"
local desc = "[7.0] Icy-Veins: DeathKnight Blood"
local code = [[
Include(ovale_common)
Include(ovale_trinkets_mop)
Include(ovale_trinkets_wod)
Include(ovale_deathknight_spells)
AddCheckBox(o... | nilq/small-lua-stack | null |
-- urHelpers.lua
-- Set of helper functions and commonly used functions wrapped into single calls
-- Created by Bryan Summersett on 3/28/2010
function table.copy(t)
local t2 = {}
for k,v in pairs(t) do
t2[k] = v
end
return t2
end
-- recursively updates an attribute on every element involved
function RSetA... | nilq/small-lua-stack | null |
fx_version 'cerulean'
game 'gta5'
ui_page 'nui/ui.html'
shared_script 'config.lua'
client_script 'client/main.lua'
server_script 'server/main.lua'
files {
'nui/**'
}
| nilq/small-lua-stack | null |
help(
[[
OpenSees is a software framework for developing applications to simulate the performance of structural and geotechnical systems subjected to earthquakes.
]])
whatis("Loads opensees, used to simulate the performance of structural and geotechnical systems subjected to earthquakes")
local version = "6482"
local b... | nilq/small-lua-stack | null |
game 'rdr3'
fx_version 'adamant'
rdr3_warning 'I acknowledge that this is a prerelease build of RedM, and I am aware my resources *will* become incompatible once RedM ships.'
ui_page "html/index.html"
client_script 'client.lua'
server_scripts {
'@mysql-async/lib/MySQL.lua',
'server.lua'
}
files... | nilq/small-lua-stack | null |
level_max_x = {
-- Emerald Hill Zone
["zone=0,act=0"] = 0x2A40,
["zone=0,act=1"] = 0x29C0,
-- Chemical Plant Zone
["zone=13,act=0"] = 0x2840,
["zone=13,act=1"] = 0x2943,
-- Aquatic Ruin Zone
["zone=15,act=0"] = 0x298C,
["zone=15,act=1"] = 0x298D,
-- Casino Night Zone
["zone=12,act=0"] = 0... | nilq/small-lua-stack | null |
local run_plugin = true
local socket = require "socket"
local ffi = require "ffi"
address, port = "127.0.0.1", 49002
udp = socket.udp()
udp:settimeout(0)
udp:setpeername(address, port)
DataRef("AHARS1_pitch", "sim/cockpit2/gauges/indicators/pitch_AHARS_deg_pilot", "readonly")
DataRef("AHARS1_roll", "sim/cockpit2/ga... | nilq/small-lua-stack | null |
local function app(params)
local win1 = WMCreateWindow(params)
function win1.drawForeground(self, ctxt)
--print("win1:drawForeground(): ", self, ctxt)
ctxt:noStroke()
ctxt:fill(255,0,0)
ctxt:circle(self.frame.width/2, self.frame.height/2, self.frame.height/2)
end
win1:... | nilq/small-lua-stack | null |
local t = Def.ActorFrame{};
t[#t+1] = Def.Sprite{
InitCommand=cmd(pause;y,-10;queuecommand,"Set");
SetCommand=function(self)
self:Load(THEME:GetPathG("","ScreenGameplay StageFrame/Stages 1x9"));
local GetStage = GAMESTATE:GetCurrentStage();
if GetStage == 'Stage_1st' then
self:setstate(0);
... | nilq/small-lua-stack | null |
--[[-----------------------------------------------------------------------
* | Copyright (C) Shaobo Wan (Tinywan)
* | Github: https://github.com/Tinywan
* | Author: Tinywan
* | Date: 2017/5/8 16:25
* | Mail: Overcome.wan@Gmail.com
* |------------------------------------------------------------------------
* | ve... | nilq/small-lua-stack | null |
--
-- Testmodule initialisation, this script is called via autoload mechanism when the
-- TeamSpeak 3 client starts.
--
require("ts3init") -- Required for ts3RegisterModule
require("z15announcegrp/events") -- Forwarded TeamSpeak 3 callbacks
require("sgtcommon/sgt-common") -- Common functions for my l... | nilq/small-lua-stack | null |
-- This isn't quite complete yet.
-- It ideally needs to be more flexible.
--
-- See libv01 for some examples.
-- Note that the API has been modified since then.
-- I've tried to get some of the stuff to work,
-- but there's really no guarantees there.
--
-- Stuff in old01 probably won't work without modification.
pr... | nilq/small-lua-stack | null |
-- =============================================================
-- Copyright Roaming Gamer, LLC. 2008-2018 (All Rights Reserved)
-- =============================================================
local public = {}
local getTimer = system.getTimer
function public.create_fps( allowDrag, scale )
scale = scale or 1
local... | nilq/small-lua-stack | null |
require = function() end
local isServer = triggerServerEvent == nil
local isClient = not isServer
local allClasses = {}
local mainString
local oldInit = System.init
local prepareInit = function(classes)
for _, class in ipairs(classes) do
allClasses[#allClasses + 1] = class
end
end
local finalizeInit =... | 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.