content
stringlengths
0
1.05M
origin
stringclasses
2 values
type
stringclasses
2 values
SWEP.PrintName = "Road Editor" SWEP.Author = "Tom.bat" SWEP.Instructions = "" SWEP.Category = "RPGM - Map" SWEP.Spawnable = true SWEP.AdminOnly = false SWEP.Base = "rpgm_map_editor_base" SWEP.Primary.ClipSize = -1 SWEP.Primary.DefaultClip = -1 SWEP.Primary.Automatic = true SWEP.Primary.Ammo = "none" SWEP.Primary.Aut...
nilq/small-lua-stack
null
-- FYI: this library was designed to do 1 specific thing: scale game from virtual size to entire window; -- you don't need to lock window from resizing or do other methods for that; -- you can set virtual game size/resolution to 1280x720 and that amount of content will be showed in -- window with 1024x600 or 1920x1080;...
nilq/small-lua-stack
null
return { npcType = script.Name, name = "Big Slime", propsGenerator = function() return { ActorStats = { maxHealth = 10, health = 10, moveSpeed = 5, baseDamage = 1 }, ItemDrops = { item...
nilq/small-lua-stack
null
local Thread = class('Thread', Thread) Thread.static.count = 0 function Thread:initialize() if not self.inner then return end self.thread = love.thread.newThread(self.inner) self.channel_id = Thread.count self.mosi = love.thread.getChannel(tostring(self.channel_id)) self.miso = love.thread.getChannel(tostri...
nilq/small-lua-stack
null
--- -- @class PANEL -- @section DNumSliderWang local math = math local table = table local vgui = vgui local PANEL = {} --- -- @accessor number -- @realm client AccessorFunc(PANEL, "m_fDefaultValue", "DefaultValue") --- -- @accessor boolean -- @realm client AccessorFunc(PANEL, "m_autoFocus", "AutoFocus") --- -- @i...
nilq/small-lua-stack
null
--[[ Chair - Client v1.1 by: standardcombo --]] local ROOT = script:GetCustomProperty("Root"):WaitForObject() local OUTER_TRIGGER = script:GetCustomProperty("OuterTrigger"):WaitForObject() local SIT_TRIGGER = script:GetCustomProperty("SitTrigger"):WaitForObject() local SIT_EVENT_ID = "sit_"..ROOT.id local GET_UP_E...
nilq/small-lua-stack
null
-- slspawn.lua - Slots spawner -- This file is under copyright, and is bound to the agreement stated in the EULA. -- Any 3rd party content has been used as either public domain or with permission. -- © Copyright 2016-2017 Aritz Beobide-Cardinal All rights reserved. function ARCSlots.SpawnSlotMachines() ARCSlots...
nilq/small-lua-stack
null
local CoreGui = {} CoreGui.__index = CoreGui local Framework local CreateGui = require("Create") function CoreGui.new(PlayerGui) local self = setmetatable({}, CoreGui) self.Components = {CreateGui(PlayerGui)} self.PlayerGui = PlayerGui self.player_index = PlayerGui.player.index self.player = Pl...
nilq/small-lua-stack
null
-- -- Created by IntelliJ IDEA. -- User: root -- Date: 2018/11/20 -- Time: 17:27 -- To change this template use File | Settings | File Templates. -- local limit_req=require("resty.limit.req") local rate=1 --每秒1个 local burst=2 --延迟队列2个 local error_status=503 local lim,err=limit_req.new("limit_req_store",rate,burs...
nilq/small-lua-stack
null
local mod = get_mod("Penlight Lua Libraries") if not rawget(_G, "_penlight_require_hook") then rawset(_G, "_penlight_require_hook", true) local original_require = _G.require _G.require = function(require_name) if string.find(require_name, "pl.") == 1 then require_name = string.gsub(require_name, "pl.", "", 1) ...
nilq/small-lua-stack
null
--[[ --MIT License -- --Copyright (c) 2019 manilarome --Copyright (c) 2020 Tom Meyers -- --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 ...
nilq/small-lua-stack
null
local datafiles = require "datafiles" local nmap = require "nmap" local shortport = require "shortport" local snmp = require "snmp" local stdnse = require "stdnse" local string = require "string" local table = require "table" local target = require "target" description = [[ Attempts to enumerate network interfaces thr...
nilq/small-lua-stack
null
-- See LICENSE for terms -- I included all the original costs just in case they change them later on. -- This won't block extra materials from being added to the cost. -- thanks to a "modder" removing objects I get to wrap all of these in ifs... function OnMsg.ClassesPostprocess() local bt = BuildingTemplates if ...
nilq/small-lua-stack
null
return { id = "S901", type = 2, skippable = true, scripts = { { actor = 101030, side = 0, say = "有人吗" }, { actor = 101030, side = 1, say = "谁?", options = { { content = "既然你诚心诚意地问了" }, { content = "不告诉你", skip = 2 }, { content = "(无视)", skip = ...
nilq/small-lua-stack
null
return { cmd = { "/usr/local/bin/node", "/Users/limit/.local/share/nvim/site/pack/packer/start/vim-rescript/server/out/server.js", "--stdio" }, }
nilq/small-lua-stack
null
-- loads function used for registering udatatypes gUDataTypes = {} -- called by c when registering a udata type function RegisterUDataType (name,metatable) -- metatable.methods = {...c methods...} -- set by c right before this function is called (luabind.h) metatable.typename = name metatable.instance_metatable =...
nilq/small-lua-stack
null
-- Client Base Scripts client_script "cl_clip.lua" client_script "heli_client.lua" client_script "jumelles_cl.lua" client_script "nitro_cl.lua" --client_script 'c_main.lua -- Server Base Scripts server_script "sv_clip.lua" server_script "heli_server.lua" server_script "jumelles_sv.lua" server_script "nitro_sv.lua"
nilq/small-lua-stack
null
do (nil)(5 % 3) end
nilq/small-lua-stack
null
-- contrib/countfiles_all.lua -- Copyright (C) 2017 Jörg Thalheim <joerg@higgsboson.tk> -- -- This file is part of Vicious. -- -- Vicious 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 ...
nilq/small-lua-stack
null
--[[ sv_init.lua ]]-- util.AddNetworkString("_Open_PW_Menu") util.AddNetworkString("PW_BuyWeapon") util.AddNetworkString("PW_SellWeapon") net.Receive("PW_BuyWeapon", function(len, ply) local wep = net.ReadString() if ( !wep || PermWeapons.HasWeapon(ply, wep) ) then return end for k, v in pairs(NPCPW.I...
nilq/small-lua-stack
null
local vector = {} function vector.new(x, y) return { x = x or 0, y = y or 0, } end function vector.sub(v1, v2) return { x = v1.x - v2.x, y = v1.y - v2.y, } end function vector.length2(v) return (v.x * v.x) + (v.y * v.y) end function vector.length(v) local l2 =...
nilq/small-lua-stack
null
roam.register_on_tick(function () file = io.open("log", "a") io.output(file) local player = roam.player io.write(string.format("P: %s\n", player)) player.pos = {x = player.pos.x + 1} io.write(string.format("P2: %s\n", player)) io.close(file) end)
nilq/small-lua-stack
null
GeometryUtil = {} function GeometryUtil.getRectangleCenter(position, size, off) local x = 0 local y = 0 if not off or string.lower(off) == "center" then x = position.x y = position.y elseif string.lower(off) == "corner" then x = position.x + (size.x / 2) y = position.y ...
nilq/small-lua-stack
null
function HandleDebugCommand( inSplit, inPlayer ) inPlayer:SendMessage( "TD: Fractional:"..tostring(Settings.FractionalTrade)..", Barter: "..tostring(Settings.Barter)..", Item: "..tostring(Settings.BarterItem).. ", SelfTrade: "..tostring(Settings.HaltSelfTrade)..", UsingProt: "..tostring(Settings.UsingProtection)..", ...
nilq/small-lua-stack
null
--FlowPad Gifted by TheRedAngel, Regular Script! local name = "BRICKER24alt" local p = Instance.new("Part") p.Parent = workspace p.Locked = true p.BrickColor = BrickColor.new("White") p.BrickColor = BrickColor.new(255) p.Size = Vector3.new(8, 1.2, 8) p.Anchored = true local m = Instance.new("CylinderMesh") m...
nilq/small-lua-stack
null
require "utils.string" require "utils.table" -- 格式化输出(美化) _G["var_dump"] = function (data, showMetatable, lastCount) if type(data) ~= "table" then --Value if type(data) == "string" then io.write('"', data, '"') else io.write(tostring(data)) end else ...
nilq/small-lua-stack
null
-- customer_money_transfer.lua local customerKeyspace = "customer:" local balanceField = "balance" local fromCustomerId = customerKeyspace .. KEYS[1] local toCustomerId = customerKeyspace .. KEYS[2] local fromBalance = tonumber(redis.call("HGET", fromCustomerId, balanceField)) local toBalance = tonumber(redis.call("HG...
nilq/small-lua-stack
null
--[===[DOC = tapfail [source,lua] ---- local function tapfail( ) --> streamFunc( lineStr ) --> errorStr ---- With this function, a stream in the TAP format can be searched for errors (Test Anything Protocol). Itself returns the `streamFunc` function that performs the real analisys. `streamFunc` must be called on ea...
nilq/small-lua-stack
null
local PLUGIN = PLUGIN; AddCSLuaFile() ENT.Type = "anim" ENT.Name = "Container" ENT.Author = "Chessnut and rebel1324" ENT.Spawnable = false ENT.PersistentSave = false; if (SERVER) then function ENT:Initialize() self:SetModel("models/props_lab/filecabinet02.mdl") self:SetNetVar("maxWeight", 10); self:SetNetVar("...
nilq/small-lua-stack
null
if (SERVER) then AddCSLuaFile() end if (CLIENT) then SWEP.PrintName = "KSwep Mag Loader Tool" SWEP.Author = "vurtual" SWEP.Slot = 0 SWEP.SlotPos = 99 end SWEP.Spawnable = true SWEP.Category="KSwep Equipment" SWEP.AdminSpawnable = true SWEP.ViewModel = nil SWEP.WorldModel = "models/weapons/w_package.mdl" SWEP.Flash...
nilq/small-lua-stack
null
--[[ Author: Noya Date: April 5, 2015 Increases the casters current and max HP, and applies a damage bonus. ]] function DeathPact( event ) local caster = event.caster local target = event.target local ability = event.ability local duration = ability:GetLevelSpecialValueFor( "duration" , ability:GetLevel() - 1 ) ...
nilq/small-lua-stack
null
local bit = {} bit.band = function(a,b) return a & b end bit.bor = function(a,b) return a | b end bit.lshift = function(a,b) return a << b end bit.rshift = function(a,b) return a >> b end return bit
nilq/small-lua-stack
null
require("util") local isMain = Util.isMain() require("text/Text") Viewer = {} local V = Viewer --[[-- read all docs in a dir, and concat them together @param dir @param sep @return full text ]] function Viewer.readAll(dir, sep) local texts = {} local sources = listdir(dir) for i, source in ipa...
nilq/small-lua-stack
null
local ringCount = 0; local evilMode = 0; local tooslowEnd = 0; function onCreate() makeLuaSprite('ringCounter', 'ringCounter', 990, 12) scaleObject('ringCounter', 1, 1); setObjectCamera('ringCounter', 'hud') addLuaSprite('ringCounter', true) end function onUpdate() for i = 0, getProperty...
nilq/small-lua-stack
null
require 'torch' require 'nn' torch.setdefaulttensortype('torch.FloatTensor') mlp = nn.Sequential(); inputs = 2; outputs = 1; HUs = 20; mlp:add(nn.Linear(inputs, HUs)) mlp:add(nn.Tanh()) mlp:add(nn.Linear(HUs, outputs)) criterion = nn.MSECriterion() for i = 1,2500 do local input= torch.randn(2); local output= t...
nilq/small-lua-stack
null
local ffi = require("ffi") ffi.cdef [[ struct upipe_mgr *upipe_nacl_g2d_mgr_alloc(void); struct upipe_mgr *upipe_nacl_audio_mgr_alloc(void); ]] libupipe_nacl = ffi.load("libupipe_nacl.so.0", true) libupipe_nacl_static = ffi.load("libupipe-nacl.static.so", true)
nilq/small-lua-stack
null
function projectile_kb(victim,projectile,kbamount) if victim:get_pos() and projectile:get_pos() then rw_proj_kb_pos_x = victim:get_pos().x - projectile:get_pos().x rw_proj_kb_pos_y = victim:get_pos().y - projectile:get_pos().y rw_proj_kb_pos_z = victim:get_pos().z - projectile:get_pos().z else rw_proj_kb_pos_x = 1 ...
nilq/small-lua-stack
null
local tilesize = require "lib.tilesize" local Entity = function() local e = {} e.type = "entity" e.x = 0 e.y = 0 e.z = 100 e.zfight = math.random()*0.1 -- against zfighting when drawing e.w = tilesize e.h = tilesize e.dir = 1 e.draw = function() end e.update = function() ...
nilq/small-lua-stack
null
require 'src/Dependencies' --[[ Called just once at the beginning of the game; used to set up game objects, variables, etc. and prepare the game world. ]] function love.load() -- Set love's default filter to "nearest-neighbor", so there wouldn't be any filtering of pixels. love.graphics.setDefaultFilte...
nilq/small-lua-stack
null
local packpath = os.getenv("PACKPATH") or "/tmp/babelfish/nvim/site" vim.cmd("set packpath=" .. packpath) if pcall(require, "nvim-treesitter.parsers") then local parser_config = require "nvim-treesitter.parsers".get_parser_configs() parser_config.markdown = { install_info = { url = "https://github.com/i...
nilq/small-lua-stack
null
function SetupWrapper(name) if not EnabledManagedProjects() then return end project(name .. ".CSharp") SetupManagedTestProject() dependson { name .. ".Native", "NamespacesDerived.Gen" } links { "CppSharp.Runtime" } SetupTestGeneratorBuildEvent("NamespacesDerived") files { path...
nilq/small-lua-stack
null
require "assets.stylesheet" local moonpie = require "moonpie" local store = require "game.store" local Components = require "moonpie.ui.components" local app = {} -- -- Called by main to specify the app should load -- function app.load() store.reset() app.title() moonpie.events.afterUpdate:add(app.up...
nilq/small-lua-stack
null
return {'trojaan','trojaans','trochee','trocheus','trocheisch','troebel','troebelen','troebelheid','troebleren','troef','troefaas','troefkaart','troel','troela','troep','troepen','troepenbeweging','troepenconcentratie','troepencontingent','troepeneenheden','troepeneenheid','troepenleverancier','troepenmacht','troepenop...
nilq/small-lua-stack
null
local API_NPC = require(script:GetCustomProperty("API_NPC")) local API_ID = require(script:GetCustomProperty("API_ID")) local API_RE = require(script:GetCustomProperty("APIReliableEvents")) local EFFECT_TEMPLATE = script:GetCustomProperty("EffectTemplate") local HAND_HELPER_TEMPLATE = script:GetCustomProperty("Ha...
nilq/small-lua-stack
null
--- CaptureInvItem is the @{Entity} definition for the carried version of the multiplayer flag. -- Subclass of @{Collectable}. -- @entity CaptureInvItem
nilq/small-lua-stack
null
require "performer" -- for i=1,500 do -- Performer:getInstance():startAGame() -- end for i=1,200 do Performer:getInstance():startTrain() end
nilq/small-lua-stack
null
-- log.lua -- local ffi = require('ffi') ffi.cdef[[ typedef void (*sayfunc_t)(int level, const char *filename, int line, const char *error, const char *format, ...); enum say_logger_type { SAY_LOGGER_BOOT, SAY_LOGGER_STDERR, SAY_LOGGER_FILE, SAY_LOGGER_PIPE, ...
nilq/small-lua-stack
null
--[[ Name: "cl_init.lua". Product: "nexus". --]] include("sh_init.lua") -- Called when the target ID HUD should be painted. function ENT:HUDPaintTargetID(x, y, alpha) local colorTargetID = nexus.schema.GetColor("target_id"); local colorWhite = nexus.schema.GetColor("white"); local index = self:GetSharedVar("sh_Ind...
nilq/small-lua-stack
null
local status_ok, telescope = pcall(require, 'telescope') if not status_ok then vim.notify('Failed to load Telescope.') return end local actions = require('telescope.actions') telescope.setup({ defaults = { prompt_prefix = '  ', selection_caret = ' ', path_display = { 'smart' }, mappings = { ...
nilq/small-lua-stack
null
--* This Document is AutoGenerate by OrangeFilter, Don't Change it! * ---@meta --- ---[3.6]animation clip, contains curve data[parent:Object#object] --- ---@class AnimationClip AnimationClip = {} --- ---[3.6]get time length --- --- @return float --- @nodiscard function AnimationClip:getTimeLength() end return Anima...
nilq/small-lua-stack
null
craft('default:coalblock') machine.compress('default:coalblock') if check_inventory.self('default:diamond 10','main') then craft('default:diamondblock',18) end self.label(string.format('Power: %d',machine.energy()))
nilq/small-lua-stack
null
----------------------------------------------------------- -- Neovim LSP configuration file ----------------------------------------------------------- -- Plugin: nvim-lspconfig -- for language server setup see: https://github.com/neovim/nvim-lspconfig local nvim_lsp = require 'lspconfig' -- Add additional capabili...
nilq/small-lua-stack
null
CNoobcarsManager = inherit(cSingleton) function CNoobcarsManager:constructor() local start = getTickCount() local qh = CDatabase:getInstance():query("Select * From noobcars") for i,v in ipairs(qh) do local noobcar = createVehicle(v["Model"],v["X"], v["Y"], v["Z"],v["RX"],v["RY"],v["RZ"],"NOOBCAR") enew(noobcar...
nilq/small-lua-stack
null
local present, neogit = pcall(require, "neogit") if not present then return end local setup = { disable_hint = false, disable_context_highlighting = false, disable_signs = false, disable_commit_confirmation = false, disable_builtin_notifications = false, disable_insert_on_commit = true, use_magit_keybi...
nilq/small-lua-stack
null
include("shared.lua") function ENT:Initialize() end function ENT:Draw() end function ENT:Think() end net.Receive('userQueryPrestige', function(len) Derma_Query( "Do you want to prestige? THIS WILL RESET YOUR LEVEL!", "Are you sure?", "Yes.", function() net.Start("userAcceptPrestige") net.SendToServer() ...
nilq/small-lua-stack
null
-- These are the 100 most popular domain names according to Alexa on 2013-11-08 -- See http://www.alexa.com/topsites. -- -- Note that some of these sites contain adult content, so it might not be -- appropriate to run these in some locations. return { "http://www.google.com", "http://www.facebook.com", "http://w...
nilq/small-lua-stack
null
local ffi = require "ffi" local ffi_cdef = ffi.cdef local ffi_typeof = ffi.typeof ffi_cdef [[ void nettle_md2_init(struct md2_ctx *ctx); void nettle_md2_update(struct md2_ctx *ctx, size_t length, const uint8_t *data); void nettle_md2_digest(struct md2_ctx *ctx, s...
nilq/small-lua-stack
null
-- Copyright 2013 by Till Tantau -- -- This file may be distributed an/or modified -- -- 1. under the LaTeX Project Public License and/or -- 2. under the GNU Public License -- -- See the file doc/generic/pgf/licenses/LICENSE for more information -- @release $Header$ --- -- This library offers a number of methods fo...
nilq/small-lua-stack
null
local rep = string.rep local fmt = string.format local clamp = math.clamp type CodifyOptions = { Framework: string?, CreateMethod: string?, BrickColorFormat: string?, Color3Format: string?, UDim2Format: string?, EnumFormat: string?, NamingScheme: string?, NumberRangeFormat: string?, PhysicalPropertiesFormat: ...
nilq/small-lua-stack
null
-- Returns first available component with given type function component.get(type) local address = component.list(type)() if address then return component.proxy(address) end return nil, "component with type \"" .. type .. "\" doesn't exists" end -- Checks if component with gieven type is available in computer e...
nilq/small-lua-stack
null
local EntityLeaderboard = {} local Entry = require "lib.EntityLeaderboard.Entry" local SortedEntryArray = require "lib.EntityLeaderboard.SortedEntryArray" local KillReason = require "lib.KillReason" local table_insert = table.insert local instance_metatable = {__index = EntityLeaderboard} function EntityLeaderboard.n...
nilq/small-lua-stack
null
class = require 'middleclass' Level = class("Level") function Level:initialize( width , height , SquareSize) self.position = Vector2:new( 0 , 0 ) self.size = Vector2:new( width , height ) self.SquareSize = SquareSize self.ActualSize = Vector2:new( width * SquareSize , height * SquareSize ) self.LastColorChangeTi...
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
local SKIP_GEN_CHECKS = false local trees = {"evergreen_short", "evergreen_normal", "evergreen_tall"} local function tree() return "evergreen"--trees[math.random(#trees)] end require "map/terrain" local function pickspawnprefab(items_in, ground_type) -- if ground_type == GROUND.ROAD then -- return -- end local...
nilq/small-lua-stack
null
-- Copyright 2022 SmartThings -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in ...
nilq/small-lua-stack
null
/* * @package : rlib * @author : Richard [http://steamcommunity.com/profiles/76561198135875727] * @copyright : (C) 2018 - 2020 * @since : 1.0.0 * @website : https://rlib.io * @docs : https://docs.rlib.io * * MIT License * * THE SOFTWARE IS PROVIDED "AS IS",...
nilq/small-lua-stack
null
--[[ DRAW THE HUD ELEMENTS ]] if CLIENT then -- Parameters local LOG_XOFFSET, LOG_YOFFSET = 5, 5; --[[ HUDPaint hook ]] hook.Add("HUDPaint", "q1hud_draw", function() if (not Q1HUD:IsEnabled()) then return end; local scale = Q1HUD:GetHUDScale(); Q1HUD:DrawScreenFlash(); Q1HUD:DrawLog(L...
nilq/small-lua-stack
null
teleport_places = { HOME = { place = "HOME", name = "Home (Rattay Mill)", locations = { IN = { x = 2451, y = 701, z = 28 } } }, GLADE = { place = "GLADE", name = "Glade", locations = { IN = { x = 2849, y = 1913, z = ...
nilq/small-lua-stack
null
Weapon.PrettyName = "TAR-21" Weapon.WeaponID = "m9k_tar21" Weapon.DamageMultiplier = 0.6 Weapon.WeaponType = WEAPON_PRIMARY
nilq/small-lua-stack
null
pg = pg or {} pg.ship_level = { { exp_ur = 120, level_limit = 0, arena_durability_ratio = 0.912, arena_durability_add = 0, exp = 100, energy_recover_time_ratio = 5, level = 1, fight_oil_ratio = 5050, need_item_rarity2 = {}, need_item_rarity3 = {}, need_item_rarity4 = {}, need_item_rarity5 = {},...
nilq/small-lua-stack
null
--[[ THE C-KERMIT 9.0 LICENSE Fri Jun 24 14:43:35 2011 Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + Redistributions of source code must retain the above copyright notice, this list of conditions a...
nilq/small-lua-stack
null
---------------------------- -- SSBase -- -- Created by Skeyler.com -- ---------------------------- surface.CreateFont("ss.slider.text", {font = "DeJaVu Sans", size = 12, weight = 400}) local panel = {} local color_line = Color(255, 255, 255, 120) local color_knob_inner = Color(39, 207, 255, 255)...
nilq/small-lua-stack
null
att.PrintName = "Schism" att.Icon = Material("entities/tfa_hce_snow_objectiveflag.png", "smooth mips") att.Description = "For those against the Great Journey" att.Desc_Pros = { " Purely Cosmetic" } att.Desc_Cons = { " when" } att.Slot = "skin_h3cars" att.Free = true att.ActivateElements = {"schism"} att.Attac...
nilq/small-lua-stack
null
local M = {} -- Filter the diagnostics per line to show the highest priority. -- By default, the LSP just displays the last diagnostic, without -- instead of showing the one with the highest priority. function M.filter_diagnostics_per_line_by_severity(diagnostics, last_only) local line_diagnostics = {} for _, diag...
nilq/small-lua-stack
null
local Fan = Class(function(self, inst) self.inst = inst self.canusefn = nil self.onusefn = nil end) function Fan:SetCanUseFn(fn) self.canusefn = fn end function Fan:SetOnUseFn(fn) self.onusefn = fn end function Fan:Fan(target) if self.onusefn and (not self.canusefn or (self.canusefn and self.canusefn(self.in...
nilq/small-lua-stack
null
return _csharp_getType("net.LuaICredentialCache");
nilq/small-lua-stack
null
----------------------------------------- -- ID: 4840 -- Scroll of Bio III -- Teaches the black magic Bio III ----------------------------------------- function onItemCheck(target) return target:canLearnSpell(232) end function onItemUse(target) target:addSpell(232) end
nilq/small-lua-stack
null
foodPanel = { button = {}, staticimage = {}, label = {} } function centerWindows ( theWindow ) local screenW,screenH=guiGetScreenSize() local windowW,windowH=guiGetSize(theWindow,false) local x,y = (screenW-windowW)/2,(screenH-windowH)/1.5 guiSetPosition(theWindow,x,y,false) end --foodPan...
nilq/small-lua-stack
null
local cobalt = { config = { path = "/cobalt", pollingRate = 1/20, }, lib = {}, application = {}, utils = {}, loop = true, version = "2.0", raw = false, } -- Load librares --cobalt.lib.surface = dofile(cobalt.config.path .. "/lib/surface.lua") --cobalt.lib.class = dofile(cobalt.config.path .. "/lib/cla...
nilq/small-lua-stack
null
local NotOp, parent = torch.class('nn.NotOp', 'nn.Module') function NotOp:__init() parent.__init(self) end function NotOp:updateOutput(input) self.output:resizeAs(input):copy(input):mul(-1):add(1) return self.output end function NotOp:updateGradInput(input, gradOutput) self.gradInput:resizeAs(gradOu...
nilq/small-lua-stack
null
function onResourceStart() local players = getElementsByType ("player") for key, player in ipairs (players) do setPlayerNametagShowing(player, false) end end addEventHandler("onResourceStart", resourceRoot, onResourceStart) function onPlayerJoin() setPlayerNametagShowing (source, false) ...
nilq/small-lua-stack
null
object_draft_schematic_armor_component_armor_layer_advanced_four = object_draft_schematic_armor_component_shared_armor_layer_advanced_four:new { } ObjectTemplates:addTemplate(object_draft_schematic_armor_component_armor_layer_advanced_four, "object/draft_schematic/armor/component/armor_layer_advanced_four.iff")
nilq/small-lua-stack
null
-- This is a part of uJIT's testing suite. -- Copyright (C) 2020-2021 LuaVela Authors. See Copyright Notice in COPYRIGHT -- Copyright (C) 2015-2020 IPONWEB Ltd. See Copyright Notice in COPYRIGHT -- This test checks that JIT doesn't emit NEWREF for existing key. jit.on() assert(jit.status()) jit.opt.start(0, 'hotloop=...
nilq/small-lua-stack
null
function ARCLib.IsCTRLDown() if system.IsOSX() then -- OSX is special with their COMMAND key return input.IsKeyDown( KEY_LWIN ) || input.IsKeyDown( KEY_RWIN ) else return input.IsKeyDown( KEY_LCONTROL ) || input.IsKeyDown( KEY_RCONTROL ) end end
nilq/small-lua-stack
null
--[[ * The MIT License * Copyright (C) 2011 Derick Dong (derickdong@hotmail.com). All rights reserved. * * 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 * with...
nilq/small-lua-stack
null
sip = require("siphash") function http_mb(session, data, dir, meta, glo) session:table().headers = {} end function http_header_field(session, data, dir) table.insert(session:table().headers, tostring(data)) end function http_hc(session, data, dir) if dir == 0 then local hash = sip.siphash(table.concat(sess...
nilq/small-lua-stack
null
-- Local instances of Global tables -- local PA = PersonalAssistant local PAB = PA.Banking local PAHF = PA.HelperFunctions -- --------------------------------------------------------------------------------------------------------------------- local function withdrawCurrency(ccyAmountToWithdraw, currencyType) loc...
nilq/small-lua-stack
null
local Workspace = game:GetService("Workspace") local ViewportFrame = {} ViewportFrame.__index = ViewportFrame function ViewportFrame.withReferences(objectRef) local state = { objectRef = objectRef, rbx = nil, } local self = setmetatable(state, ViewportFrame) local rbx = Instance.new("ViewportFrame") rbx.Cur...
nilq/small-lua-stack
null
local tools = require('Utils.ToolSet') local UBBParser = require('Utils.UBBParser').inst GTextInput = class('GTextInput', GTextField) local getters = GTextInput.getters local setters = GTextInput.setters function GTextInput:ctor() GTextInput.super.ctor(self) self._editable = true self._autoSize = Aut...
nilq/small-lua-stack
null
project "glfw3" kind "StaticLib" language "C" targetdir("build/%{cfg.system}/%{cfg.architecture}/%{cfg.shortname}/bin") objdir("build/%{cfg.system}/%{cfg.architecture}/%{cfg.shortname}/bin-int") defines { "_CRT_SECURE_NO_WARNINGS"} includedirs { "include/" } files { "src/window.**", "src/context.**", ...
nilq/small-lua-stack
null
vim.cmd([[ augroup terminal autocmd! autocmd TermOpen * setlocal nonumber norelativenumber sidescrolloff=0 signcolumn=auto | startinsert augroup END ]]) _G.Terminal = { Open = function() if _G.TerminalBuffer == nil or not vim.api.nvim_buf_is_valid(_G.TerminalBuffer) then _G.TerminalBuffer = vim.api.nvi...
nilq/small-lua-stack
null
-- shamelessly stolen from Ghoul's balance mod -- Copyright Ghoul -- Licensed under the MIT License --Todo: Receive this via a alienteam method local kUpgrades = { [kTechId.Shell] = { kTechId.Carapace, }, [kTechId.Carapace] = kTechId.Shell, [kTechId.Regeneration] = kTechId.Shell, [kTechId.Camouflage] = kTechId.Sh...
nilq/small-lua-stack
null
X = {type = "type", contents = "contents", tabsize = 2} function X.convertall(elements, indent) indent = indent or 0 if not (type(elements) == "table") then error("malformed XML elements") end local result = "" for _,element in ipairs(elements) do result = result .. X.convert(elemen...
nilq/small-lua-stack
null
-- Autogenerated from KST: please remove this line if doing any edits by hand! local luaunit = require("luaunit") require("default_endian_expr_inherited") TestDefaultEndianExprInherited = {} function TestDefaultEndianExprInherited:test_default_endian_expr_inherited() local r = DefaultEndianExprInherited:from_fi...
nilq/small-lua-stack
null
--[[ ============================================================================================================ Author: Rook Date: February 4, 2015 Called when Arcane Boots is cast. Restores mana to nearby allies. Additional parameters: keys.ReplenishAmount and keys.ReplenishRadius ==============================...
nilq/small-lua-stack
null
--[[ This file was extracted by 'EsoLuaGenerator' at '2021-09-04 16:42:27' using the latest game version. NOTE: This file should only be used as IDE support; it should NOT be distributed with addons! **************************************************************************** CONTENTS OF THIS FILE IS COPYRI...
nilq/small-lua-stack
null
-- test keybinding recognition interactively gui = require 'gui' DFH_MOD_SHIFT = 1 DFH_MOD_CTRL = 2 DFH_MOD_ALT = 4 KEYS = {} for c = string.byte('A'), string.byte('Z') do table.insert(KEYS, string.char(c)) end for c = string.byte('0'), string.byte('9') do table.insert(KEYS, string.char(c)) end function keys() l...
nilq/small-lua-stack
null
--* This Document is AutoGenerate by OrangeFilter, Don't Change it! * ---@meta --- ---[4.10]Dirty Table[parent:] --- ---@class DirtyTable DirtyTable = {} return DirtyTable
nilq/small-lua-stack
null
local Guivar = 0 local gMe = getLocalPlayer() local Fenster = {} local TabPanel = {} local Tab = {} local Knopf = {} local Checkbox = {} local Label = {} local Edit = {} local Scrollbar = {} local Memo local setting = {} local sirenSettings = {} setting["anzahlsirenen"] = 1 setting["sirenentype"] = 2 setting["360flag...
nilq/small-lua-stack
null
--[[ MIT LICENSE Copyright (c) 2014 Phoenix C. Enero 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...
nilq/small-lua-stack
null