content stringlengths 0 1.05M | origin stringclasses 2
values | type stringclasses 2
values |
|---|---|---|
-- Custom Extensions to the God-Controller
local God = {}
God.onBuiltEntityFilters = {
{ filter = "type", type = "tile-ghost" },
{ filter = "type", type = "entity-ghost" },
{ filter = "type", type = "item-request-proxy" },
}
-- Whether the Entity or Tile is a Ghost (can be revived)
function God.IsCreatabl... | nilq/small-lua-stack | null |
ITEM.name = "12.7×40mm M228 SAP-HP"
ITEM.model = "models/Items/BoxSRounds.mdl"
ITEM.ammo = "pistol" -- type of the ammo
ITEM.ammoAmount = 240 -- amount of the ammo
ITEM.description = "M228 Semi-Armor-Piercing High-Penetration ammunition used in the M6C/SOCOM."
| nilq/small-lua-stack | null |
return {'ulo','uloschool','uloscholen'} | nilq/small-lua-stack | null |
-- Create a standard Solar2D newText display object and reveal it character by character.
local function newRollingText( text, x, y, font, fontSize, revealTime )
if type( text ) == "string" then
local length = text:len()
if length > 0 then
local object = display.newText( "", x or 0, y or 0, font or native.syste... | nilq/small-lua-stack | null |
local AddonName, AddonTable = ...
AddonTable.skinning = {
110609, -- Raw Beast Hide
110610, -- Raw Beast Hide Scraps
}
| nilq/small-lua-stack | null |
local F, G, V = unpack(select(2, ...))
function F.rebackdrop(frame)
frame:SetBackdrop(nil)
frame:SetBackdrop({
bgFile = [[Interface\Buttons\WHITE8x8]],
edgeFile = [[Interface\Buttons\WHITE8x8]],
edgeSize = 1,
})
frame:SetBackdropColor(unpack(G.colors.base))
frame:SetBackdropBorderColor(unpack(G.colors.borde... | nilq/small-lua-stack | null |
function onCreate()
setProperty('timeTxt.text', 'Target');
end | nilq/small-lua-stack | null |
local PixelShuffle, parent = torch.class("nn.PixelShuffle", "nn.Module")
-- Shuffles pixels after upscaling with a ESPCNN model
-- Converts a [batch x channel*r^2 x m x p] tensor to [batch x channel x r*m x r*p]
-- tensor, where r is the upscaling factor.
-- @param upscaleFactor - the upscaling factor to use
function ... | nilq/small-lua-stack | null |
return {
load="viewer/load.lua",
doInitSDL=true,
}
| nilq/small-lua-stack | null |
local lzug = require('luftzug')
vim.api.nvim_buf_set_keymap(0, 'n', '<Plug>LzugAddReference', "<cmd>call v:lua.lzug_add_reference()<CR>", { noremap = true})
vim.api.nvim_buf_set_keymap(0, 'n', '<Plug>LzugFollowFootnoteOrLink', "<cmd>call v:lua.lzug_handle_tab()<CR>", { noremap = true})
vim.api.nvim_buf_set_keymap(0, '... | nilq/small-lua-stack | null |
local p2p_discovery = require "defnet.p2p_discovery"
local udp = require "defnet.udp"
local trickle = require "game.trickle"
local M = {}
local P2P_PORT = 50000
local UDP_SERVER_PORT = 9192
local STATE_LISTENING = "STATE_LISTENING"
local STATE_JOINED_GAME = "STATE_JOINED_GAME"
local STATE_HOSTING_GAME = "STATE_HOS... | nilq/small-lua-stack | null |
-- Copyright (c) 2021, The Pallene Developers
-- Pallene is licensed under the MIT license.
-- Please refer to the LICENSE and AUTHORS files for details
-- SPDX-License-Identifier: MIT
local util = require "pallene.util"
local typedecl = require "pallene.typedecl"
local types = require "pallene.types"
local ast... | nilq/small-lua-stack | null |
object_tangible_holiday_empire_day_component_dh17_cartridge_grips = object_tangible_holiday_empire_day_component_shared_dh17_cartridge_grips:new {
}
ObjectTemplates:addTemplate(object_tangible_holiday_empire_day_component_dh17_cartridge_grips, "object/tangible/holiday/empire_day/component/dh17_cartridge_grips.iff")
| nilq/small-lua-stack | null |
object_tangible_quest_frn_all_security_terminal_wall_03 = object_tangible_quest_shared_frn_all_security_terminal_wall_03:new {
}
ObjectTemplates:addTemplate(object_tangible_quest_frn_all_security_terminal_wall_03, "object/tangible/quest/frn_all_security_terminal_wall_03.iff")
| nilq/small-lua-stack | null |
dziendziecka = true
local dzien_dziecka_loc = {
--{2240.42,-72.21,26.50,359,id=218,2240.23,-70.06,25.6}, -- PC cmentarz
--{-2273.89,533.18,35.02,270, id=219, -2271.82,533.16,34.3}, -- SF stacja
--{389.39,-1525.02,32.27,38.4, id=220, 388.27,-1524.06,31.3}, -- LS Rodeo
--{2322.61,2394.16,10.82,92.7, id=221, 2320.14,... | nilq/small-lua-stack | null |
-- require particle
_ichor.add('particle_system', {
init = function(this)
this.particles = {}
end,
add = function(this, particle)
particle.system = this
add(this.particles, particle)
particle:init()
end,
del = function(this, particle)
del(this.particles, particle)
particle:destroy()
... | nilq/small-lua-stack | null |
CommonGameScene2 = class(CommonScene);
-- 一些界面控件的index
CommonGameScene2.s_controls =
{
commonView_01 = ToolKit.getIndex();
commonView_02 = ToolKit.getIndex();
commonView_03 = ToolKit.getIndex();
commonView_04 = ToolKit.getIndex();
bgImage = ToolKit.getIndex();
gameLogoView = T... | nilq/small-lua-stack | null |
description 'FoRa_noobpack'
version '1.0.2'
server_scripts {
"@mysql-async/lib/MySQL.lua",
'@es_extended/locale.lua',
'server/server.lua'
}
client_scripts {
'client/client.lua'
}
| nilq/small-lua-stack | null |
--[[
# Pandoc filters
--]]
-- #T# Table of contents
-- #C# Basic usage
-- #C# Terminology and synonyms
-- #C# Pandoc AST
-- #C# Elements
-- #C# - Parts of an element
-- #C# - Types of elements
-- #C# - Other functions and methods
-- #T# Beginning of content
-- #C# Basic usage
-- # |------------------------------... | nilq/small-lua-stack | null |
require "../lua/init"
require "../lua/third_party_project"
third_party_project( "xGL", "StaticLib" )
files
{
"%{prj.name}/src/xgl.cpp",
"%{prj.name}/src/xgl.h"
}
defines
{
"_CRT_SECURE_NO_WARNINGS"
}
includedirs
{
"%{prj.name}/src/**.h"
}
filter "system:windows"
systemversion "latest"
filter... | nilq/small-lua-stack | null |
require'indent_blankline'.setup {
char_list = {'|', '¦', '┆', '┊'},
-- context_patterns = {'class', 'function', 'method', 'if', 'foreach'},
-- show_current_context = true,
-- show_current_context_start = true,
show_trailing_blankline_indent = false,
use_treesitter = true,
}
| nilq/small-lua-stack | null |
dofile_once("data/scripts/lib/utilities.lua")
dofile_once("data/scripts/perks/perk.lua")
function death( damage_type_bit_field, damage_message, entity_thats_responsible, drop_items )
-- kill self
local entity_id = GetUpdatedEntityID()
local pos_x, pos_y = EntityGetTransform( entity_id )
local perk_id = perk_spa... | nilq/small-lua-stack | null |
local i = 0
return function(func)
local t = {}
local n = func()
while n ~= 10 do
table.insert(t,n)
n = func()
end
return t
end,{function() i = i+1 return i end},{{1,2,3,4,5,6,7,8,9}}
| nilq/small-lua-stack | null |
--虚拟大陆 每个玩家拥有一个
local skynet = require "skynet"
local util = require "util"
local json = require "cjson"
require "skynet.manager"
--大陆上的据点 (简化版城市)
local STRONGHOLD = {}
--大陆上的怪物
local MONSTER = {}
--数据持久化服务
local db_game
local db_guild
local arg = table.pack(...)
assert(arg.n == 1)
local player_id = tonumber(arg[1])... | nilq/small-lua-stack | null |
print("Running editor.lua!")
setdefaultfont("Menlo", 15)
function hook(s)
removeattribute("NSColor", makerange(1, #s))
local i, j = 0, 0
while true do
i, j = s:find('hi!', i + 1)
if i == nil then break end
addattribute("NSColor", makecolor("orangeColor"),
makerange(i, j ... | nilq/small-lua-stack | null |
-- Copyright (C) Miracle
-- Copyright (C) OpenWAF
local _M = {
_VERSION = "0.0.2"
}
local twaf_func = require "lib.twaf.inc.twaf_func"
local twaf_conf = require "lib.twaf.twaf_conf"
_M.api = {}
_M.help = {}
_M.api.rules = {}
-- get rules, e.g: GET /api/rules/{rule_id}
_M.api.rules.get = function(_twaf,... | nilq/small-lua-stack | null |
-- Copyright (C) 2017 josephzeng <josephzeng36@gmail.com>
--
-- Distributed under terms of the MIT license.
--
local M = {}
M.environment = 0
M.mysql_ini = {
host = "127.0.0.1",
port = 3306,
database = "zsq_game",
user = "root",
password = "123456",
max_packet_size = 1024 * 1024
--on_conne... | nilq/small-lua-stack | null |
--
-- Copyright (c) 2010 Ted Unangst <ted.unangst@gmail.com>
--
-- Permission to use, copy, modify, and distribute this software for any
-- purpose with or without fee is hereby granted, provided that the above
-- copyright notice and this permission notice appear in all copies.
--
-- THE SOFTWARE IS PROVIDED "AS IS" A... | nilq/small-lua-stack | null |
local UID = KEYS[1]
local record = redis.call('zscore', 'rec', UID)
return record | nilq/small-lua-stack | null |
--[[
Falling from the Sky
-- SeaStuff Class --
Author: Yoru Sung
https://github.com/spero61/falling-from-the-sky
SeaStuff vibrates at the top of the game window for a couple of seconds
upon creation of its object. Then falls faster than other 'stuff's.
]]
SeaStuff = Class{__includes = Stuff}
... | nilq/small-lua-stack | null |
Route = {}
Route.active = {}
Route.SetGps = function(route)
ClearGpsMultiRoute()
StartGpsMultiRoute(8, true, false)
for _, s in pairs(route.stops) do
AddPointToGpsMultiRoute(s.x+.0, s.y+.0, s.z+.0)
end
SetGpsMultiRouteRender(true)
end
-- Show the blips for all the stops we plan to make
Rou... | nilq/small-lua-stack | null |
ESX = nil
kontrol = 2000
kontrol2 = 2000
kazma = false
local zone = nil
local sayac = 60
local anliktoken = 0
local alabilir = false
local var = false
local vehicle = nil
sesler = { "rockhit1", "rockhit2", "rockhit3", "rockhit4"}
Citizen.CreateThread(f... | 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 |
object_tangible_loot_creature_loot_collections_space_reactor_mark_03_incom = object_tangible_loot_creature_loot_collections_space_shared_reactor_mark_03_incom:new {
}
ObjectTemplates:addTemplate(object_tangible_loot_creature_loot_collections_space_reactor_mark_03_incom, "object/tangible/loot/creature/loot/collections... | nilq/small-lua-stack | null |
--[[
This file was extracted by 'EsoLuaGenerator' at '2021-09-04 16:42:26' 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 |
local drawableSprite = require("structs.drawable_sprite")
local cassetteCassette = {}
local colors = {
{73 / 255, 170 / 255, 240 / 255},
{240 / 255, 73 / 255, 190 / 255},
{252 / 255, 220 / 255, 58 / 255},
{56 / 255, 224 / 255, 78 / 255},
}
local depth = -1000000
local colorNames = {
["Blue"] = 0... | nilq/small-lua-stack | null |
#!/usr/bin/env lua
local fin = assert(io.open(arg[1], "rb"))
local data = {}
local sum = -25
local chSum = 0
repeat
local inStr = fin:read(4096)
for c in (inStr or ''):gmatch"." do
data[#data+1] = c:byte()
end
until not inStr
fin:close()
for i=1, #data do
if i > 0x134 and i <= 0x14d then
sum = sum - ... | nilq/small-lua-stack | null |
local plugin_name = vim.split((...):gsub("%.", "/"), "/", true)[1]
local helper = require("vusted.helper")
helper.root = helper.find_plugin_root(plugin_name)
function helper.before_each()
require("piemenu.view.background").Background._click = function() end
end
function helper.after_each()
helper.cleanup()
hel... | nilq/small-lua-stack | null |
local ByteArray = require("ByteArray")
ProtoBasePack = class("ProtoBasePack")
function ProtoBasePack:ctor()
self._byteData = ByteArray.new()
self._byteData:setEndian(ByteArray.ENDIAN_BIG)
end
function ProtoBasePack:clear()
self._byteData:clear()
end
ProtoBaseUnpack = class("ProtoBaseUnpack")
function P... | nilq/small-lua-stack | null |
-- Copyright (C) 2018-2021 by KittenOS NEO contributors
--
-- Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted.
--
-- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTI... | nilq/small-lua-stack | null |
--@sec: Simplex
--@ord: -1
--@doc: Simplex noise algorithm in Lua.
--
-- - [Original Java implementation by Stefan Gustavson][java]
-- - [Paper][paper]
--
-- [java]: https://weber.itn.liu.se/~stegu/simplexnoise/SimplexNoise.java
-- [paper]: https://staffwww.itn.liu.se/~stegu/simplexnoise/simplexnoise.pdf
local Simplex ... | nilq/small-lua-stack | null |
--VERSION SUPPORT: 1.1-beta
PLUGIN.name = "Cook Food"
PLUGIN.author = "Black Tea"
PLUGIN.desc = "How about getting new foods in NutScript?"
hungrySeconds = 39600 -- 1100 = 300 seconds i guess (3 Hours to Starve)
nut.config.add("hungerTime", 5, "Amount of time between each hunger update." );
COOKLEVEL = {
[1] = {"c... | nilq/small-lua-stack | null |
--some code taken from moreblocks(the collision and selection boxes), license below:
--Copyright (c) 2011-2015 Calinou and contributors.
--Licensed under the zlib license.
scifi_nodes = {}
function scifi_nodes.register_slope(name, desc, texture, light)
minetest.register_node("scifi_nodes:slope_"..name, {
description... | nilq/small-lua-stack | null |
----
-- Recipe data.
--
-- Includes recipe data in data sidebar.
--
-- **Source Code:** [https://github.com/dstmodders/dst-mod-dev-tools](https://github.com/dstmodders/dst-mod-dev-tools)
--
-- @classmod data.RecipeData
-- @see data.Data
--
-- @author [Depressed DST Modders](https://github.com/dstmodders)
-- @copyright ... | nilq/small-lua-stack | null |
#! /usr/bin/lua
require( "common" )
require( "lfs" )
require( "imlib2" )
Items = data( "items" )
local Dir = "weapons"
local SharpDir = "sharp"
local CacheDir = "cache"
local Names, NamesCount = loadNames( Dir .. "/names.txt" )
local Types =
{
"gs",
"ls",
"sns",
"ds",
"hm",
"hh",
"lc",
"gl",
"sa",
}
lo... | nilq/small-lua-stack | null |
-- hamster_ball, video game
-- Copyright (C) 2014-2015 Pavel Dolgov
--
-- See the LICENSE file for terms of use.
local x, y, enemies, shots, speed, dt1, dt2, bg, ball
local is_winner = false
local is_loser = false
local group_number = 0
local tableLength = function(T)
local count = 0
for _ in pairs(T) do coun... | nilq/small-lua-stack | null |
local Queue = {}
function Queue:new()
local o = {} -- create object if user does not provide one
setmetatable(o, self)
self.__index = self
o.first = 0;
o.last = -1;
return o
end
function Queue:push(value)
local last = self.last + 1
self.last = last
self[last] = value... | nilq/small-lua-stack | null |
me = game.Players.yfc
if script.Parent.className ~= "HopperBin" then
h = Instance.new("HopperBin")
h.Parent = me.Backpack
h.Name = "Thing"
script.Parent = h
end
sp = script.Parent
hold = false
function sel(mouse)
mouse.Button1Down:connect(function()
hold = true
local char = me.Character
local namb = 0
while h... | nilq/small-lua-stack | null |
--[[
© Asterion Project 2021.
This script was created from the developers of the AsterionTeam.
You can get more information from one of the links below:
Site - https://asterionproject.ru
Discord - https://discord.gg/Cz3EQJ7WrF
developer(s):
... | nilq/small-lua-stack | null |
local assets =
{
Asset("ANIM", "anim/ruins_rubble.zip"),
}
local prefabs =
{
"rocks",
"thulecite",
"cutstone",
"trinket_6",
"gears",
"nightmarefuel",
"greengem",
"orangegem",
"yellowgem",
}
local function workcallback(inst, worker, workleft)
local pt = Point(inst.Transform:Ge... | nilq/small-lua-stack | null |
local Validator = script.Parent
local Style = Validator.Parent
local App = Style.Parent
local UIBlox = App.Parent
local Packages = UIBlox.Parent
local t = require(Packages.t)
return t.strictInterface({
RelativeSize = t.numberMinExclusive(0),
RelativeMinSize = t.numberMinExclusive(0),
Font = t.EnumItem,
}) | nilq/small-lua-stack | null |
-- Generated By protoc-gen-lua Do not Edit
local protobuf = require "protobuf/protobuf"
local STAGETROPHYDATA_PB = require("StageTrophyData_pb")
module('StageTrophy_pb')
STAGETROPHY = protobuf.Descriptor();
local STAGETROPHY_TROPHYDATA_FIELD = protobuf.FieldDescriptor();
local STAGETROPHY_TOTAL_SCORE_FIELD = protobuf... | nilq/small-lua-stack | null |
local L = LibStub("AceLocale-3.0"):NewLocale("GatherLite", "zhCN")
if not L then
return
end
L["tracking"] = "追踪类型"
L["mining"] = "矿石"
L["herbalism"] = "草药"
L["fish"] = "鱼群"
L["containers"] = "箱子"
L["worldmap.show"] = "显示 GatherLite"
L["worldmap.hide"] = "隐藏 GatherLite"
L["settings.node"] = "采集点设置"
L["settings.no... | nilq/small-lua-stack | null |
local style = require "core.style"
local common = require "core.common"
style.background = { common.color "#303841" }
style.background2 = { common.color "#1d2227" }
style.background3 = { common.color "#1d2227" }
style.text = { common.color "#9ea191" }
style.caret = { common.color "#61efce" }
style.accent = { common.co... | nilq/small-lua-stack | null |
---
-- @author wesen
-- @copyright 2020 wesen <wesen-ac@web.de>
-- @release 0.1
-- @license MIT
--
local Input = require "Input"
local CliInput = Input:extend()
function CliInput:parse(_parameters)
self.commandName = _parameters[1]
local nextParameterIsOptionValue
for i = 1, #_parameters, 1 do
if (subs... | nilq/small-lua-stack | null |
local inp_size = 4
local out_size = 2
local conns = 3
local brain_size = 25
local return_v = false
local value_v = 0
local gauss_random
gauss_random = function()
if return_v then
return_v = false
return value_v
end
local u = 2 * math.random() - 1
local v = 2 * math.random() - 1
local r = u ^ 2 + v ^ 2... | nilq/small-lua-stack | null |
net.Receive("GBaySetMySQL", function()
local DFrame = vgui.Create("DFrame")
DFrame:SetSize(300, 185)
DFrame:SetTitle("GBay MySQL info!")
DFrame:Center()
DFrame:SetDraggable(true)
DFrame:ShowCloseButton(true)
DFrame:MakePopup()
local HostEntry = vgui.Create("DTextEntry", DFrame)
HostEntry:SetPos(10, 30)
HostEn... | nilq/small-lua-stack | null |
-- See LICENSE for terms
local mod_Option1
-- fired when settings are changed/init
local function ModOptions()
mod_Option1 = CurrentModOptions:GetProperty("Option1")
end
-- load default/saved settings
OnMsg.ModsReloaded = ModOptions
-- fired when option is changed
function OnMsg.ApplyModOptions(id)
if id ~= Curre... | nilq/small-lua-stack | null |
-- Standard awesome library
local awful = require("awful")
local gears = require("gears")
-- Widget library
local wibox = require("wibox")
-- Theme handling library
local beautiful = require("beautiful")
local xresources = require("beautiful.xresources")
local dpi = xresources.apply_dpi
-- Rubato
local rubato = requ... | nilq/small-lua-stack | null |
return {
tag = 'devices',
summary = 'Check if an audio device is started.',
description = 'Returns whether an audio device is started.',
arguments = {
{
name = 'type',
type = 'AudioType',
default = [['playback']],
description = 'The type of device to check.'
}
},
returns = {
... | nilq/small-lua-stack | null |
local default_value_patterns={
name="DLI PLC49",
input_name="Input %d",
output_name="Outlet %d",
adc_name="ADC %d",
cycle_time="1",
}
return {
get_value=function(name,index)
local ret
if file.open("config/"..name..(index and "/"..tostring(index) or "")) then
ret=file... | nilq/small-lua-stack | null |
return {
-- bluetooth applet
-- 'blueman-applet',
-- power manager
'xfce4-power-manager',
-- network applet
'nm-applet',
-- redshift
'redshift',
-- xorg compositor
'picom -b',
-- screenshot applet
'flameshot',
-- input method
'fcitx5',
-- proxy
'clash',
-- policy kit
-- '/usr/lib/pol... | nilq/small-lua-stack | null |
require("pl")
ec = require("editorconfig")
local progname = arg[0]
local function print_usage(ret)
print(ec._VERSION)
print("Usage: " .. progname .. " [OPTIONS] FILEPATH1 [FILEPATH2 FILEPATH3 ...]")
-- print("FILEPATH can be a hyphen (-) if you want to path(s) to be read from stdin.")
print()
pri... | nilq/small-lua-stack | null |
local var_2 = require("mod")
print(var_2.hello("Yea"))
print(var_2.add(3, 6))
| nilq/small-lua-stack | null |
return {'mahdi','maharadja','maharishi','mahdist','mahjong','mahonie','mahonieboom','mahoniehout','mahoniehouten','maha','maher','mahmoud','mahmud','mahieu','mahler','mahabier','mahu','mahamed','mahabali','mahadew','mahn','mahamud','mahmood','mahesh','maharadjas','mahdisten','mahoniebomen','mahas','mahdis','mahers','ma... | nilq/small-lua-stack | null |
require "scripts/class"
function CreateEntity()
local en = {}
en.tags = {}
-------------------------------------------
function en:AddTag(tag)
table.insert(self.tags, tag)
end
function en:HasTag(tag)
for _, i in ipairs(self.tags) do
if i == tag then return true end
end
return false
end
-------------... | nilq/small-lua-stack | null |
local unpack = table.unpack or unpack;
local interpolation = require "util.interpolation";
local template = interpolation.new("%b$$", function (s) return ("%q"):format(s) end);
--luacheck: globals meta idsafe
local action_handlers = {};
-- Takes an XML string and returns a code string that builds that stanza
-- usi... | nilq/small-lua-stack | null |
if vim.b.did_ftp == true then
return
end
vim.bo.commentstring = "#\\ %s"
vim.bo.suffixesadd = ".qml"
vim.opt_local.cursorline = false
vim.opt_local.cursorcolumn = false
| nilq/small-lua-stack | null |
-----------------------------------------
-- ID: 4947
-- Scroll of Utsusemi: Ni
-- Teaches the ninjutsu Utsusemi: Ni
-----------------------------------------
function onItemCheck(target)
return target:canLearnSpell(339)
end
function onItemUse(target)
target:addSpell(339)
end | nilq/small-lua-stack | null |
local NotifyFont
do
local _class_0
local _base_0 = {
Setup = function(self)
surface.SetFont(self.m_font)
local x, y = surface.GetTextSize('W')
self.m_height = y
end,
FixFont = function(self)
if not self.IsValidFont(self.m_font) then
self.m_font = 'Default'
... | nilq/small-lua-stack | null |
class "LightInfo"
function LightInfo:__getvar(name)
if name == "importance" then
return Polycode.LightInfo_get_importance(self.__ptr)
elseif name == "position" then
local retVal = Polycode.LightInfo_get_position(self.__ptr)
if retVal == nil then return nil end
local __c = _G["Vector3"]("__skip_ptr__")
__c... | nilq/small-lua-stack | null |
package.path = "./?.lua;./?/init.lua"
require 'names'
require 'markovDetect'
require 'config'
for i,n in ipairs(arg) do
local b = bayes(n, prior)
print(("%s has %g prob, %g real and %g fake. %s"):format(n, b, probability(n), probFake(n), ((b>threshold and 'Would be filtered') or 'would not be filtered')))
end | nilq/small-lua-stack | null |
-- Tests not used with travis
stdengine = "etex"
checkengines = {"etex"}
checksearch = true
testfiledir = "testfiles-local"
| nilq/small-lua-stack | null |
workspace "Niking2D"
architecture "x86_64"
startproject "Sandbox"
configurations{
"Debug",
"Release",
"Dist"
}
outputdir = "%{cfg.buildcfg}-%{cfg.system}-%{cfg.architecture}"
IncludeDir ={}
IncludeDir["GLFW"] = "Niking2D/vendor/GLFW/include"
IncludeDir["Glad"] = "Niking2D/vendor/Glad/include"
Include... | nilq/small-lua-stack | null |
require 'TextBox'
function love.conf(t)
t.identity = nil -- The name of the save directory (string)
t.appendidentity = false -- Search files in source directory before save directory (boolean)
t.version = "11.3" -- The LÖVE version this game was made for (string)... | nilq/small-lua-stack | null |
--
-- Copyright (c) 2013 Juniper Networks, Inc. All rights reserved.
--
local sm = ARGV[1]..":"..ARGV[2]..":"..ARGV[3]..":"..ARGV[4]
redis.log(redis.LOG_NOTICE,"DelRequest for "..sm)
local db = tonumber(ARGV[5])
redis.call('select',db)
local typ = redis.call('smembers',"TYPES:"..sm)
local res = {}
for k,v in pairs(ty... | nilq/small-lua-stack | null |
local Explode = {}
function Explode.OnAdd(e)
Explode[e] = true
end
function Explode.OnRemove(e)
Explode[e] = nil
end
return Explode
| nilq/small-lua-stack | null |
-----------------------------------------
-- ID: 4658
-- Scroll of Shell III
-- Teaches the white magic Shell III
-----------------------------------------
function onItemCheck(target)
return target:canLearnSpell(50)
end
function onItemUse(target)
target:addSpell(50)
end | nilq/small-lua-stack | null |
local Tunnel = module("vrp","lib/Tunnel")
local Proxy = module("vrp","lib/Proxy")
local Tools = module("vrp","lib/Tools")
tvRP = {}
local players = {}
Tunnel.bindInterface("vRP",tvRP)
vRPserver = Tunnel.getInterface("vRP")
Proxy.addInterface("vRP",tvRP)
local user_id
function tvRP.setUserId(_user_id)
user_id = _user... | nilq/small-lua-stack | null |
object_mobile_nova_orion_garrick_orion = object_mobile_shared_nova_orion_garrick_orion:new {
}
ObjectTemplates:addTemplate(object_mobile_nova_orion_garrick_orion, "object/mobile/nova_orion_garrick_orion.iff")
| nilq/small-lua-stack | null |
data:extend
{
{
type = "fluid",
name = "chlorine",
base_color = {r=0, g=255, b=0, a=0},
default_temperature = 21.0,
flow_color = {r=0, g=255, b=0, a=0},
icons = {icon={icon="__base__/graphics/icons/fluid/steam.png", tint={r=0, g=255, b=0, a=255}}},
icon_size ... | nilq/small-lua-stack | null |
return PlaceObj("ModDef", {
"title", "Example Sidepanel Controls",
"version", 1,
"version_major", 0,
"version_minor", 1,
"id", "ChoGGi_ExampleSidepanelControls",
"author", "ChoGGi",
"code", {
"Code/Script.lua",
},
"image", "Preview.png",
"lua_revision", 1007000, -- Picard
"description", [[Adds some exampl... | nilq/small-lua-stack | null |
local data_network = assert(yatm.data_network)
local CLUSTER_GROUP = 'yatm_data'
-- Allows the cluster tool to lookup normal clusters
yatm.cluster_tool.register_cluster_tool_lookup(CLUSTER_GROUP, function (pos, state)
local member = data_network:get_member_at_pos(pos)
local network = data_network:get_network_at_po... | nilq/small-lua-stack | null |
require("deepcore/std/class")
require("deepcore/std/callable")
require("eawx-util/ChangeOwnerUtilities")
require("deepcore/statemachine/dsl/conditions")
require("eawx-util/StoryUtil")
---@class PlanetTransferBuilder
PlanetTransferBuilder = class()
---@vararg string
function PlanetTransferBuilder:new(...)
---@type... | nilq/small-lua-stack | null |
reb.gui = {}
surface.CreateFont( "Reb_HUD_small", {
font = "Arial",
extended = false,
size = ScreenScale(6),
weight = 1000,
blursize = 0,
scanlines = 0,
antialias = true,
} )
surface.CreateFont( "Reb_HUD_med", {
font = "Arial",
extended = false,
size = ScreenScale(10),
weight = 1000,
blursize = 0,
scanli... | nilq/small-lua-stack | null |
local parse_c11 = require 'parsers.c11'
local lpegrex = require 'lpegrex'
local lester = require 'tests.lester'
local describe, it = lester.describe, lester.it
local function eqast(source, expected)
local aststr = lpegrex.prettyast(parse_c11(source))
expected = expected:gsub('^%s+', ''):gsub('%s+$', '')
if not ... | nilq/small-lua-stack | null |
local config = require("vlua.config")
local Util = require("vlua.util")
local NextTick = require("vlua.nextTick")
local nextTick, devtools = NextTick.nextTick, Util.devtools
local splice = Util.splice
local tsort = table.sort
local tinsert = table.insert
local warn = Util.warn
local MAX_UPDATE_COUNT = 100
---@type Wa... | nilq/small-lua-stack | null |
baekhos_blade_rogue = {
cast = function(player)
local weap = player:getEquippedItem(EQ_WEAP)
local magic = 6000
if (not player:canCast(1, 1, 0)) then
return
end
if (player.magic < magic) then
player:sendMinitext("You do not have enough mana.")
return
end
if player:checkIfCast(enchants) or playe... | nilq/small-lua-stack | null |
-- All entries must go above this line
}
| nilq/small-lua-stack | null |
--
-- toolchains.lua
-- Declare toolchains to use with GENie
-- Copyright (c) 2020 Christian Helmich and the GENie project
--
premake.toolchain = { }
--
-- The list of registered tools.
--
premake.toolchain.list = { }
--
-- Register a new toolchain.
--
-- @param a
-- The new toolchain object.
--
function prem... | nilq/small-lua-stack | null |
return{
name = "chickenfinger",
} | nilq/small-lua-stack | null |
--Button disable flag. True for now, because button CANT do what I want it to...
local disableButton = true
if disableButton == false then require("button") end
function recheck_all_recipes(rf)
for _, research in pairs(rf.technologies) do
if research.researched then
if research.effects then
... | nilq/small-lua-stack | null |
--easy script configs
IntroTextSize = 25 --Size of the text for the Now Playing thing.
IntroSubTextSize = 30 --size of the text for the Song Name.
IntroTagColor = 'FFDD00' --Color of the tag at the end of the box.
IntroTagWidth = 15 --Width of the box's tag thingy.
--easy script configs
--actual script
function onCrea... | nilq/small-lua-stack | null |
cc = cc or {}
---Physics3DPointToPointConstraint object
---@class Physics3DPointToPointConstraint : Physics3DConstraint
local Physics3DPointToPointConstraint = {}
cc.Physics3DPointToPointConstraint = Physics3DPointToPointConstraint
--------------------------------
---get pivot point in A's local space
---@return vec3_... | nilq/small-lua-stack | null |
return {
skip_compat53 = true,
source_dir = "lgetchar",
include = { "**/*" },
}
| nilq/small-lua-stack | null |
function getAllGates(thePlayer, commandName, ...)
if exports.mrp_integration:isPlayerAdmin(thePlayer) or exports.mrp_integration:isPlayerScripter(thePlayer) then
if table.concat({...}, " ") ~= "" then
outputChatBox("SYNTAX: /"..commandName.." - Open Gates Manager", thePlayer, 255, 194, 14)
else
local gatesLi... | nilq/small-lua-stack | null |
object_mobile_naboo_peacewar_drenn = object_mobile_shared_naboo_peacewar_drenn:new {
}
ObjectTemplates:addTemplate(object_mobile_naboo_peacewar_drenn, "object/mobile/naboo_peacewar_drenn.iff")
| nilq/small-lua-stack | null |
include("shared.lua")
--------------------------------------------------------------------------------
ENT.ClientProps = {}
ENT.ButtonMap = {}
-----
-- ALS Panel
-----
ENT.ButtonMap["ARSPanel"] = {
pos = Vector(463.08,-52.68,28.05),
ang = Angle(0,-90-29,90),
width = 38,
height = 240,
scale = 0.0... | 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 |
--[[
LuCI - Lua Configuration Interface
Copyright 2008 Jo-Philipp Wich <xm@subsignal.org>
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
$Id: trunks.l... | 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.