content
stringlengths
0
1.05M
origin
stringclasses
2 values
type
stringclasses
2 values
-- Custom local propRoot = script:GetCustomProperty("root"):WaitForObject() local propPlayerSpot1 = script:GetCustomProperty("PlayerSpot1"):WaitForObject() local propPlayerSpot2 = script:GetCustomProperty("PlayerSpot2"):WaitForObject() local propRPS_action_rock = script:GetCustomProperty("RPS_action_rock") local prop...
nilq/small-lua-stack
null
local Class = require "Utils/Class" local CtrlBase = require "UI/CtrlBase" local Logger = require "Logger/Logger" local UIConfig = require "Config/UIConfig" local Ctrl = Class("Ctrl", CtrlBase) local function __init(self, UIName) self.uiName = UIName end local function __delete() end local function Init(self...
nilq/small-lua-stack
null
-- -- User: Glastis -- Date: 15-Nov-19 -- local composer = require 'composer' local mui = require 'materialui.mui' local views = require 'views.common' local utilitie = require 'common.utilities' local widget = require 'widget' local muiData = require 'materialui.mui-data' views.set_active_view(3) local background ...
nilq/small-lua-stack
null
propMonster = { [MONSTER_ID_1] = { ID=1, Name="MONSTER 1", Desc="monster 1 desc" }, [MONSTER_ID_2] = { ID=2, Name="MONSTER 2", Desc="monster 2 desc" }, }
nilq/small-lua-stack
null
local Wall = {} function Wall.new(left, top, width, height) local wall = {} wall.x = left wall.y = top wall.w = width wall.h = height wall.vx = 0 wall.vy = 0 wall.color = {0, 0, 255} wall.is_ground = true wall.collision = {} wall.static = true return wall end ret...
nilq/small-lua-stack
null
object_tangible_furniture_city_road_torch_12x64_01 = object_tangible_furniture_city_shared_road_torch_12x64_01:new { } ObjectTemplates:addTemplate(object_tangible_furniture_city_road_torch_12x64_01, "object/tangible/furniture/city/road_torch_12x64_01.iff")
nilq/small-lua-stack
null
local m = {} m.paths = require("red4ext/paths") m.project = require("red4ext/project") m.version = require("red4ext/version") return m
nilq/small-lua-stack
null
/*--------------------------------------------------------- Initializes the effect. The data is a table of data which was passed from the server. ---------------------------------------------------------*/ function EFFECT:Init( data ) self.Origin = data:GetOrigin() self.DirVec = data:...
nilq/small-lua-stack
null
--local let = require("vim_interfaces/vars").let --let.g("SuperTabDefaultCompletionType", "<Down>")
nilq/small-lua-stack
null
--[[ MIT License Copyright (c) 2018 Scott Bengs 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, ...
nilq/small-lua-stack
null
if ( SERVER ) then AddCSLuaFile( "shared.lua" ) end if ( CLIENT ) then SWEP.PrintName = "E-60R Rocket Launcher" SWEP.Author = "ahnok" SWEP.ViewModelFOV = 60 SWEP.Slot = 4 SWEP.SlotPos = 1 SWEP.WepSelectIcon = surface.GetTextureID("HUD/killicons/E60R") killicon.Add( "weapon_jew_e60r...
nilq/small-lua-stack
null
---[[---------------------------------------------------------------------]]--- -- __ __ _ -- -- ____ ____ / /_ ______ ___ ____ _________ / /_ (_)____ -- -- / __ \/ __ \/ / / / / __ `__ \/ __ \/ ___/ __ \/ __ \/ / ___/ -- ...
nilq/small-lua-stack
null
local Pattern = require'compe.pattern' local String = require'compe.utils.string' local Character = require'compe.utils.character' local Helper = {} --- determine Helper.determine = function(context, option) option = option or {} local trigger_character_offset = 0 if option.trigger_characters and context.befor...
nilq/small-lua-stack
null
---@class hrect hrect = { WORLD_BOUND = cj.GetWorldBounds(), MAP_INITIAL_PLAYABLE_AREA = cj.Rect( cj.GetCameraBoundMinX() - cj.GetCameraMargin(CAMERA_MARGIN_LEFT), cj.GetCameraBoundMinY() - cj.GetCameraMargin(CAMERA_MARGIN_BOTTOM), cj.GetCameraBoundMaxX() + cj.GetCameraMargin(CAMERA_MARG...
nilq/small-lua-stack
null
--Always set to false before uploading a release! DEBUG=false SHIELD_STEPS_NORMAL = 9 SHIELD_STEPS_LONG = 13 SHIELD_VALUE_ON_PREVIOUS_TICK=2 --in energy units, not shield HP! HP_BAR=3 ORIENTATION=4 SHIELD_EFFECT_ENTITY=5 SHIELD_VALUE_ON_LAST_TICK=6 ELECTRIC_GRID_INTERFACE=7 TURRET_ENTITY=8 DMG_SINCE_LAST_TICK=9 --Nu...
nilq/small-lua-stack
null
local skynet = require "skynet" local socket = require "skynet.socket" local function accept(id, addr) skynet.error(addr .. " acccepted") -- 当前服务开始使用套接字 socket.start(id) local str = socket.read(id) if (str) then socket.write(id, string.upper(str)) end -- 不想使用了,这个时候遗弃控制权 socket.abandon(id) ...
nilq/small-lua-stack
null
local room_more_info_test = require("view/kScreen_1280_800/games/common2/room_more_info_test"); --[[ 重连测试、查看子游戏的版本号信息 ]] local RoomMoreInfoTest = class(CommonGameLayer, false); RoomMoreInfoTest.s_controls = { bg = ToolKit.getIndex(); moreView = ToolKit.getIndex(); reconnect_btn = ToolKit.g...
nilq/small-lua-stack
null
-- Copyright (c) 2021 Trevor Redfern -- -- This software is released under the MIT License. -- https://opensource.org/licenses/MIT return { COUNT = "STATISTIC_COUNT", SET = "STATISTIC_SET" }
nilq/small-lua-stack
null
do ---IADS Unit Tests SKYNET_UNIT_TESTS_NUM_EW_SITES_RED = 18 SKYNET_UNIT_TESTS_NUM_SAM_SITES_RED = 17 --factory method used in multiple unit tests function IADSContactFactory(unitName) local contact = Unit.getByName(unitName) local radarContact = {} radarContact.object = contact local iadsContact = SkynetIADSCon...
nilq/small-lua-stack
null
module(..., lunit.testcase, package.seeall) local common = dofile("common.lua") local http = require("luanode.http") local net = require("luanode.net") -- Verify that the 'upgrade' header causes an 'upgrade' event to be emitted to -- the HTTP client. This test uses a raw TCP server to better control server -- behavio...
nilq/small-lua-stack
null
local drpath = require("directories") drpath.addPath("myprograms", "ZeroBraineProjects", "CorporateProjects", -- When not located in general directory search in projects "ZeroBraineProjects/dvdlualib", "ZeroBraineProje...
nilq/small-lua-stack
null
fx_version 'cerulean' use_fxv2_oal 'yes' lua54 'yes' game 'gta5' --[[ Original Release ]] -- author 'snakewiz' -- description 'A flexible player customization script for FiveM.' -- repository 'https://github.com/pedr0fontoura/fivem-appearance' -- version '1.2.2' author 'Linden' description 'A flexibl...
nilq/small-lua-stack
null
--[[ lang.lua Copyright (C) 2019 Kano Computing Ltd. License: http://www.gnu.org/licenses/gpl-2.0.txt GNU GPLv2 Generated translation from 'en_QQ' locale po file ]]-- return { ["letsGo"] = "\239\188\172\239\189\133\239\189\148'\239\189\147 \239\189\135\239\189\143! [\239\188\165\239\188\174\239\188\180\239\18...
nilq/small-lua-stack
null
littoral.schematic = {} local n1 = { name = "air" } local n2 = { name = "littoral_tech:hal1" } local n3 = { name = "littoral_tech:ramp", param2 = 2 } local n4 = { name = "littoral_tech:ramp_corner", param2 = 2 } local n5 = { name = "littoral_tech:ramp_corner", param2 = 1 } local n6 = { name = "littoral_tech:ramp", par...
nilq/small-lua-stack
null
--[[ Copyright (C) 2018 Google Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope th...
nilq/small-lua-stack
null
local defs = {} defs["enums"] = {} defs["enums"]["ImDrawFlags_"] = {} defs["enums"]["ImDrawFlags_"][1] = {} defs["enums"]["ImDrawFlags_"][1]["calc_value"] = 0 defs["enums"]["ImDrawFlags_"][1]["name"] = "ImDrawFlags_None" defs["enums"]["ImDrawFlags_"][1]["value"] = "0" defs["enums"]["ImDrawFlags_"][2] = {} defs["enums"]...
nilq/small-lua-stack
null
prowling_gurreck = Creature:new { objectName = "@mob/creature_names:gurreck_prowler", socialGroup = "gurreck", faction = "", level = 45, chanceHit = 0.44, damageMin = 365, damageMax = 440, baseXp = 4370, baseHAM = 8900, baseHAMmax = 10900, armor = 0, resists = {165,165,30,30,-1,30,30,30,-1}, meatType = "me...
nilq/small-lua-stack
null
local t = require 'torch' local autograd = require 'autograd' local util = require 'util.util' return function(opt) local model = {} local maxGradNorm = opt.maxGradNorm or 0.25 -- load and functionalize embedding nets local model1 = require(opt.learner)({ nClasses=opt.nClasses.train, useCUDA=opt.use...
nilq/small-lua-stack
null
require("moonsc").import_tags() -- Test that states are entered in entry order (parents before children -- with document order used to break ties) after the executable content -- in the transition is executed. -- event1, event2, event3, event4 should be raised in that order when the -- transition in s01 is taken ...
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
-- TODO: See about spreading from trees. Unfortunately, an event doesn't -- TODO: trigger when trees are damaged by fire, unlike other entities. -- TODO: Will probably need to modify prototype to create_entity -- TODO: See about nuclear bombs and other "fire" sources lighting -- TODO: creep on fire. Or maybe jus...
nilq/small-lua-stack
null
-- Copyright [2018] [Dominic Tootell] -- 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 i...
nilq/small-lua-stack
null
local Prop = {} Prop.Name = "Bazaar Market 4" Prop.Cat = "Stores" Prop.Price = 250 Prop.Doors = { Vector( -12205, -8688.5, 347 ), Vector( -12147, -8455.5, 347 ), } GM.Property:Register( Prop )
nilq/small-lua-stack
null
local skynet = require("skynet") local exporter = require("fly.prometheus.exporter") -- https://github.com/apache/incubator-apisix/blob/master/doc/plugins/prometheus-cn.md -- https://github.com/openresty/lua-nginx-module -- curl -i http://127.0.0.1:43002/fly/prometheus/metrics local _M = {} function _M.init(conf) ...
nilq/small-lua-stack
null
-- -*- mode: lua; tab-width: 2; indent-tabs-mode: 1; st-rulers: [70] -*- -- vim: ts=4 sw=4 ft=lua noet ---------------------------------------------------------------------- -- @author Daniel Barney <daniel@pagodabox.com> -- @copyright 2015, Pagoda Box, Inc. -- @doc -- -- @end -- Created : 15 May 2015 by Daniel Barne...
nilq/small-lua-stack
null
local craft = function(itemstack, player, old_craft_grid) if itemstack:get_name() == "core:ns_node" and old_craft_grid[1]:get_name() == "core:ns_node" and (old_craft_grid[2]:get_name() == "core:file_node" or old_craft_grid[2]:get_name() == "core:dir_node") then local inventory = player:g...
nilq/small-lua-stack
null
--Converts ANSI file to UTF-8 --Usage: luajit ansitoutf8.lua inputfile.iss [encoding] > outputfile.iss --Default encoding is 1252 local ffi = require("ffi") ffi.cdef[[ int MultiByteToWideChar(unsigned int CodePage, unsigned int dwFlags, const char* lpMultiByteStr, int cbMultiByte, wchar_t* lpWideCharStr, int cchWi...
nilq/small-lua-stack
null
local time = ... if not time then time = 0.5; end return Def.ActorFrame{ Def.Quad{ InitCommand=function(self) self:FullScreen():diffuse(color("#000000FF")) end; OnCommand=function(self) self:linear(time):diffusealpha(0) end; }; };
nilq/small-lua-stack
null
--[[ -- added by wsh @ 2017-11-30 -- Lua面向对象设计 --]] --保存类类型的虚表 local _class = {} -- added by wsh @ 2017-12-09 -- 自定义类型 ClassType = { class = 1, instance = 2, } function BaseClass(classname, super) assert(type(classname) == "string" and #classname > 0) -- 生成一个类类型 local class_type = {} -- 在创建对象的时候自动调用 class...
nilq/small-lua-stack
null
exports.name = "Luvit Odoo Connector" exports.version = "0.0.1" local http = require("http") local table = require("table") local rpc = require("json-rpc") local string = require("string") string.split = function(inputstr, sep) if sep == nil then sep = "%s" end local t={} ; i=1 for str in string.gmatch...
nilq/small-lua-stack
null
local this = {} function this.getFailureString(container) return "You failed to harvest anything of value." end function this.getSuccessString(container, ingredient, quantity) return string.format("You harvested %s %s.", quantity, ingredient.name) end return this
nilq/small-lua-stack
null
class 'WarpGui' function WarpGui:__init() self.actions = { [3] = true, [4] = true, [5] = true, [6] = true, [11] = true, [12] = true, [13] = true, [14] = true, [17] = true, [18] = true, [105] = true, [137] = true, [138] = true, [139] = true, [16] = true } self.cool...
nilq/small-lua-stack
null
project("RED4ext.Loader") targetname("d3d11") targetdir(red4ext.paths.build("bin")) kind("SharedLib") language("C++") pchheader("stdafx.hpp") pchsource("stdafx.cpp") dependson({ "RED4ext.Dll" }) -- Remove these defines, else Resource Compiler will cry. removedefines({ "WINV...
nilq/small-lua-stack
null
object_intangible_pet_beast_master_bm_spiderclan_consort = object_intangible_pet_beast_master_shared_bm_spiderclan_consort:new { } ObjectTemplates:addTemplate(object_intangible_pet_beast_master_bm_spiderclan_consort, "object/intangible/pet/beast_master/bm_spiderclan_consort.iff")
nilq/small-lua-stack
null
local translatedChatMessage local next_file_load local send_bot_room_crash local file_id local webhooks = {_count = 0} local runtime = 0 local room = tfm.get.room local onEvent do local os_time = os.time local math_floor = math.floor local runtime_check = 0 local events = {} local scheduled = {_count = 0, _pointe...
nilq/small-lua-stack
null
require("apps").default_paths() -- default search paths so things can easily be found local utf8=require("utf8") local wgrd=require("wetgenes.grd") local wpack=require("wetgenes.pack") local wstring=require("wetgenes.string") local bitdown=require("wetgenes.gamecake.fun.bitdown") local funfont64=require("funfont64...
nilq/small-lua-stack
null
local shortport = require "shortport" local stdnse = require "stdnse" local libssh2_util = require "libssh2-utility" description = [[ Performs username and password as log4shell payload against SSH server. ]] --- -- @usage -- nmap -p 22 --script ssh-log4shell --script-args log4shell.payload=log4shell.payload="${jn...
nilq/small-lua-stack
null
CustomizableWeaponry:addFireSound("CW_M1014_FIRE", "weapons/bf4_1014/shottie-1.wav", 1, 115, CHAN_STATIC) CustomizableWeaponry:addReloadSound("CW_M1014_PUMP", "weapons/bf4_1014/pull.wav") CustomizableWeaponry:addReloadSound("CW_M1014_INSERT", "weapons/bf4_1014/insert.wav") CustomizableWeaponry:addReloadSound("CW_M3SUP...
nilq/small-lua-stack
null
require("iuplua") require("iupluagl") require("luagl") require("luaglu") require("imlua") --filename = [[C:\LUA\im-3.8.2_Win32_dllw4_lib\im-3.8.2_Examples\im\html\examples\flower.jpg]] filename =[[flower.jpg]] heightfac=math.sqrt(3)*0.5 -- ratio from height to side in equilateral triangle iup.key_open() texture = 0 ...
nilq/small-lua-stack
null
--[[ 调用方式:EVAL(script, 0, operate, username, token, expires, userDetails, authorities) 实现功能:单点登录,指定时间内token自动过期 这里实现登录 4个map auth:token:username field是token,value是username auth:username:token field是username,value是token auth:token:userdetails field是token,value是userdetails auth:token:aut...
nilq/small-lua-stack
null
VictoryState = class{__includes = BaseState} function VictoryState:enter(params) self.level = params.level self.score = params.score self.paddle = params.paddle self.health = params.health self.ball = params.ball self.highScores = params.highScores end function VictoryState:update(d...
nilq/small-lua-stack
null
local currentPlayer = GetPlayerPed(-1) local speedcams = {} --object size speed local units = 3.6 --kmh --local units = 2.23694 --mph TriggerEvent('chat:addSuggestion', '/create', 'creates a speedtrap', { { name="size", help="size of the speedtrap" }, { name="speed", help="speed on which to trigger" } }) func...
nilq/small-lua-stack
null
-- Code created by Kwik - Copyright: kwiksher.com {{year}} -- Version: {{vers}} -- Project: {{ProjName}} -- local _Command = {} local _K = require "Application" ----------------------------- ----------------------------- function _Command:new() local command = {} -- function command:execute(params) loca...
nilq/small-lua-stack
null
local defaults = require'hop.defaults' local M = {} -- Get the first key of a key set. local function first_key(keys) return keys:sub(1, 1) end -- Get the next key of the input key in the input key set, if any, or return nil. local function next_key(keys, key) local i = keys:find(key) if i == #keys then r...
nilq/small-lua-stack
null
local ffi = require "ffi" local bit = require "bit" local band = bit.band local bor = bit.bor local rshift = bit.rshift local lshift = bit.lshift ffi.cdef[[ void * malloc ( size_t size ); void free ( void * ptr ); void * realloc ( void * ptr, size_t size ); ]] function bzero(dest, nbytes) ffi.fill(dest, nbytes) ...
nilq/small-lua-stack
null
local _tonumber = tonumber local _tostring = tostring local _unpack = unpack local clientRoomName = KEYS[1] local currentTime = _tonumber(redis.call('get', 'serverTime')) if(not currentTime) then return redis.error_reply('NO SERVERTIME') end local rk = { roomInfo = "rooms|"..KEYS[1].."|info", r...
nilq/small-lua-stack
null
-- * _JOKER_VERSION: 0.0.1 ** Please do not modify this line. --[[---------------------------------------------------------- Joker - Jokes, Riddles, Fun Facts, & Other Tomfoolery ---------------------------------------------------------- * * ADDING YOUR OWN JOKES: * Be aware that modifying this file incorrectl...
nilq/small-lua-stack
null
--- A container that holds and maintains a dynamically arranged collection of @{Frame}s. -- @classmod Box local Base = require("vyzor.base") local BoxMode = require("vyzor.enum.box_mode") local Lib = require("vyzor.lib") local Box = Base("Compound", "Box") --- Box constructor. -- @function Box -- @string _name The n...
nilq/small-lua-stack
null
local F, C = unpack(select(2, ...)) if not C.appearance.fonts then return end local normalFont = C.font.normal local headerFont = C.font.header local chatFont = C.font.chat local dmgFont = C.font.damage _G.STANDARD_TEXT_FONT = normalFont _G.UNIT_NAME_FONT = headerFont _G.DAMAGE_TEXT_FONT = dmgFont local function Res...
nilq/small-lua-stack
null
slots = 16 function string:split(delimiter) local result = { } local from = 1 local delim_from, delim_to = string.find( self, delimiter, from ) while delim_from do table.insert( result, string.sub( self, from , delim_from-1 ) ) from = delim_to + 1 delim_from, delim_to = string.find( self, delimi...
nilq/small-lua-stack
null
Build { Env = { CPPDEFS = { { "SHARED"; Config = "*-*-*-shared" } }, }, Units = function () local lib_static = StaticLibrary { Name = "foo_static", Config = "*-*-*-static", Sources = { "lib.c" }, } local lib_shared = SharedLibrary { Name = "foo_shared", Con...
nilq/small-lua-stack
null
include("shared.lua") function ENT:ApplyNewSize(NewSize) local Size = self:GetOriginalSize() local Scale = Vector(1 / Size.x, 1 / Size.y, 1 / Size.z) * NewSize local Bounds = NewSize * 0.5 self.Matrix = Matrix() self.Matrix:Scale(Scale) self:EnableMatrix("RenderMultiply", self.Matrix) self:PhysicsInitBox(-Bo...
nilq/small-lua-stack
null
--[[ --=====================================================================================================-- Script Name: Flip a Coin, for SAPP (PC & CE) Description: A simple addon that lets you flip a text-based virtual coin! Copyright (c) 2020, Jericho Crosby <jericho.crosby227@gmail.com> * Notice: You can use th...
nilq/small-lua-stack
null
local _G = getfenv(0) local AtlasLoot = _G.AtlasLoot local BonusRoll = {} AtlasLoot.Addons.BonusRoll = BonusRoll local QLF = AtlasLoot.GUI.QuickLootFrame local AL = AtlasLoot.Locales -- lua local match = string.match local tonumber = tonumber -- DB -- /run BonusRollFrame_StartBonusRoll(227131, "", 180, 1273) -- /run ...
nilq/small-lua-stack
null
module('love.mouse') function getCursor() end function getPosition() end function getRelativeMode() end function getSystemCursor() end function getX() end function getY() end function hasCursor() end function isDown() end function isGrabbed() end function isVisible() end function newCursor() end function setCursor() e...
nilq/small-lua-stack
null
return function(Modules, ReplicatedModules) local public = {} local GameGui local FocusData = {Enabled = false, TransitionLength = 10, DarkenTransparencyGoal = 0.5, BlurGoal = 20} local CenterPages = {} local PageSettings = {} local CurrentPage = nil function public.Awake() GameGui = game.Players.LocalPlayer...
nilq/small-lua-stack
null
-- main.lua -- Implements the main plugin entrypoint -- Configuration -- Use prefixes or not. -- If set to true, messages are prefixed, e. g. "[FATAL]". If false, messages are colored. g_UsePrefixes = true -- Global variables Messages = {} WorldsSpawnProtect = {} WorldsWorldLimit = {} WorldsWorldDifficulty...
nilq/small-lua-stack
null
return { armorbweaver = { acceleration = 0.15, activatewhenbuilt = true, brakerate = 0.45, buildcostenergy = 1658, buildcostmetal = 70, builder = false, buildpic = "armorbweaver.dds", buildtime = 5423, canguard = true, canmove = true, canpatrol = true, canstop = 1, category = "ALL MOBILE TINY...
nilq/small-lua-stack
null
local qconsts = require 'Q/UTILS/lua/qconsts' local ffi = require 'ffi' local get_ptr = require 'Q/UTILS/lua/get_ptr' local cmem = require 'libcmem' local Scalar = require 'libsclr' local function mem_initialize(subs) local hdr = [[ typedef struct _reduce_max_<<qtype>>_args { <<reduce_ctype>> max_val; ...
nilq/small-lua-stack
null
--[[ * ReaScript Name: Track Inspector * Author: Hector Corcin (HeDa) * Author URI: http://reaper.hector-corcin.com * Licence: Copyright © 2016-2017, Hector Corcin ]] instance = 3 -- change to another number in a copy of this file to allow another instance master_track = false -- (true or false)...
nilq/small-lua-stack
null
local Pause = {} local Input = require ("src.boundary.input") local Palette = require ("src.boundary.palettes") local Sound = require ("src.boundary.audio.pause") Pause.OPTIONS = {" palette ", "screen size", " quit "} Pause.selected = 1 function Pause.update () if Input.keyPressed (Input.KEYS.UP) then ...
nilq/small-lua-stack
null
--Dx Functions local dxDrawLine = dxDrawLine local dxDrawImage = dxDrawImageExt local dxDrawImageSection = dxDrawImageSectionExt local dxDrawText = dxDrawText local dxGetFontHeight = dxGetFontHeight local dxDrawRectangle = dxDrawRectangle local dxSetShaderValue = dxSetShaderValue local dxGetPixelsSize = dxGetPixelsSize...
nilq/small-lua-stack
null
--Minetest --Copyright (C) 2013 sapier -- --This program is free software; you can redistribute it and/or modify --it under the terms of the GNU Lesser General Public License as published by --the Free Software Foundation; either version 2.1 of the License, or --(at your option) any later version. -- --This program is ...
nilq/small-lua-stack
null
WireLib.RTFix = {} local RTFix = WireLib.RTFix --------------------------------------------------------------------- -- RTFix Lib --------------------------------------------------------------------- RTFix.List = {} function RTFix:Add(ClassName, NiceName, Function) RTFix.List[ClassName] = {NiceName, Function} end...
nilq/small-lua-stack
null
_class("AbstractEntityIndex") ---@param name 索引名称 ---@param group 索引监听的组 ---@param getkey 获取entity的key或keys ---@param ismultikey 指定true则getkey返回多个key --- function AbstractEntityIndex:Constructor(name, group, getkey, ismultikey) self.name = name self.group = group self.getkey = getkey self.is...
nilq/small-lua-stack
null
ITEM.name = "MP9a1" ITEM.description= "A compact machine pistol. Fires 9x19mm." ITEM.longdesc = "The Machine Pistol 9 is a Swiss-made submachinegun from the early 2000s, it weighs 1.4 kilograms unloaded and is generally compact.\nIt features a drop, trigger and ambidextrious safety switch and has a fire-rate of 900 rou...
nilq/small-lua-stack
null
-- Tests on BUFPUT constant folding. -- Copyright (C) 2015-2019 IPONWEB Ltd. See Copyright Notice in COPYRIGHT jit.opt.start('fold', 'jitstr') local s for i = 1, 100 do local n = 42.42 s = string.format("%d-%s-%s-%d-%s", i, "foo", "bar", 2 * n, "") end assert(s == "100-foo-bar-84-")
nilq/small-lua-stack
null
-- create some basic global vars portal_network = {} portal_pages = {} portal_mgc = {} portal_mgc.modname = minetest.get_current_modname() portal_mgc.modpath = minetest.get_modpath(portal_mgc.modname) -- check technic mod is enabled if (minetest.get_modpath("technic")) ~= nil then portal_mgc.is_technic = true else por...
nilq/small-lua-stack
null
--[[ © 2020 TERRANOVA do not share, re-distribute or modify without permission of the author. --]] ITEM.name = "Flat Cap"; ITEM.model = "models/fty/items/flatcap.mdl" ITEM.description = "An old pre-Union 'cabbie hat', named as such from British taxi drivers, who commonly wore the hats. Not CWU approved."; ITEM.p...
nilq/small-lua-stack
null
local file_version = require 'ffi.file_version' local stormlib = require 'ffi.stormlib' local language_map = { [0x00000409] = 'enUS', [0x00000809] = 'enGB', [0x0000040c] = 'frFR', [0x00000407] = 'deDE', [0x0000040a] = 'esES', [0x00000410] = 'itIT', [0x00000405] = 'csCZ', [0x0...
nilq/small-lua-stack
null
----------------------------------- -- Area: Crawlers' Nest -- NPC: ??? - Guardian Crawler (Spawn area 1) -- !pos 124.335 -34.609 -75.373 197 ----------------------------------- local ID = require("scripts/zones/Crawlers_Nest/IDs") require("scripts/globals/npc_util") ----------------------------------- function onTra...
nilq/small-lua-stack
null
--[[ A version of Component with a `shouldUpdate` method that forces the resulting component to be pure. Exposed as Roact.PureComponent ]] local Component = require(script.Parent.Component) local PureComponent = Component:extend("PureComponent") -- When extend()ing a component, you don't get an extend method. --...
nilq/small-lua-stack
null
ConfigStaticChests = { -- { -- x, -- y, -- z, -- h, -- Heading -- type, -- GLOBAL[0] | PUBLIC[1] | PRIVATE[2] -- capacity, -- 0-∞ -- }, { -3145.66, 1091.81, 20.69, 180.00, 0, 20 } }
nilq/small-lua-stack
null
return { NetworkingError = "NetworkingError", QuickLaunchError = "QuickLaunchError", PlayButtonError = "PlayButtonError", PurchaseMessage = "PurchaseMessage", GameFollowError = "GameFollowError", SuccessConfirmation = "SuccessConfirmation", InformationMessage = "InformationMessage", }
nilq/small-lua-stack
null
local identity = Device2.getIdentity(operation) if identity.error then return identity end local configIO = require("vendor.configIO") if configIO then identity.state.config_io = { timestamp = require("c2c.utils").getTimestamp(configIO.timestamp), set = configIO.config_io, reported = configIO.config_io ...
nilq/small-lua-stack
null
print('XLUAAPP')
nilq/small-lua-stack
null
function love.load() amount=255 music=love.audio.newSource('music/se/boss-intro.mp3') music:play() end function love.update(dt) amount=amount-255/amount if amount<=0 then loadState('boss/boss'..love.stage) end end function love.draw() love.graphics.setColor(amount,amount,amount) love.graphics.rectan...
nilq/small-lua-stack
null
ModifyEvent(-2, -2, -1, -1, -1, -1, -1, 2492, 2492, 2492, -2, -2, -2);--by fanyu 打开宝箱,改变贴图 场景22-编号4 AddItem(17, 6); AddItem(103, 10); do return end;
nilq/small-lua-stack
null
local Canvas = require("gesture.view.canvas").Canvas local windowlib = require("gesture.lib.window") local M = {} local Background = {} Background.__index = Background M.Background = Background function Background.open(click) vim.validate({click = {click, "function"}}) local width = vim.o.columns local height...
nilq/small-lua-stack
null
local gs = require 'vendor/gamestate' local Splat = {} Splat.__index = Splat local splatters = love.graphics.newImage('images/splatters.png') local splatterSize = {width=300,height=250} local splattersAvail = splatters:getWidth() / splatterSize.width local quads = { love.graphics.newQuad(0, 0, splatterSize.width,...
nilq/small-lua-stack
null
local load = require 'loadClasses' local room = require 'core/room' local entity = require 'core/entity' local log = require 'log' local luaRoom = require 'core/luaRoomLoader' load.loadClassesFromFile("entities/player.json") local initRoom = luaRoom.fromFile('test.json') entity.spawnRoot(initRoom) local root = en...
nilq/small-lua-stack
null
require 'trace' require 'Camera' require 'Grapple' require 'Common' require 'Tool' Player = {} -- Utilities local function getPlayerCoordinates() return getCircleCoords(Player.Pos, Properties.PlayerRadius) end local function applyGravity() applyForce( Player, {x = Properties.Gravity.x * Propert...
nilq/small-lua-stack
null
--[[ Profile configuration file. All variables put in here will be processed once during the jester bootstrap. If you have a variable foo that you want to have a value of "bar", do: foo = "bar" Array/record syntax is like this: foo = { bar = "baz", bing = "bong" } Variables from the main configuration...
nilq/small-lua-stack
null
local luaunit = require 'luaunit' local class = require 'pl.class' local encoder = require 'krpc.encoder' local platform = require 'krpc.platform' local Types = require 'krpc.types' local schema = require 'krpc.schema.KRPC' local TestEncoder = class() local types = Types() function TestEncoder:test_encode_message() ...
nilq/small-lua-stack
null
local AddonName, AddonTable = ... -- Mogu'shan Vaults AddonTable.mv = { 95618, -- Shared 89768, 89767, -- The Stone Guard 167047, 85922, 85923, 85924, 85925, 85926, 85975, 85976, 85977, 85978, 85979, 86134, 86739, 86740, 86741, 86742, ...
nilq/small-lua-stack
null
return { fields = { allowed_number_query_args = { default = 100, type = "number" }, allowed_number_post_args = { default = 100, type = "number" }, } }
nilq/small-lua-stack
null
local PLAYER = FindMetaTable("Player") function PLAYER:IsPolice() return self:Team() == FACTION_POLICE end
nilq/small-lua-stack
null
describe('take', function() it('produces an error if its parent errors', function() local observable = Rx.Observable.of(''):map(function(x) return x() end) expect(observable).to.produce.error() expect(observable:take(1)).to.produce.error() end) it('produces nothing if the count is zero', function() ...
nilq/small-lua-stack
null
--------------------------------------------------------------------------------------------------- -- func: hastitle -- desc: Check if player already has a title. --------------------------------------------------------------------------------------------------- require("scripts/globals/titles"); cmdprops = { pe...
nilq/small-lua-stack
null
-- -- term.lua -- Additions to the 'term' namespace. -- Copyright (c) 2017 Blizzard Entertainment and the Premake project -- -- default colors. term.black = 0 term.blue = 1 term.green = 2 term.cyan = 3 term.red = 4 term.purple = 5 term.brown = 6 term.lightGray = 7 term.gr...
nilq/small-lua-stack
null