content stringlengths 5 1.05M |
|---|
Speedrun = Speedrun or {}
local Speedrun = Speedrun
Speedrun.slash = "/speed"
Speedrun.prefix = "|cffffffSpeed|r|cdf4242Run|r: "
Speedrun.debugMode = 0
-- Speedrun.mapName = ""
-------------------------
---- Functions -------
-------------------------
function Speedrun.SlashCommand(c... |
include('shared.lua')
/*---------------------------------------------------------
Name: DrawTranslucent
Desc: Draw translucent
---------------------------------------------------------*/
function ENT:Draw()
end
function ENT:Think ( )
end
function ENT:Initialize ( )
self:SetNotSolid(true)
self:SetNoDraw(tr... |
local defend= {}
defend.optionEnable = Menu.AddOption({ "Utility", "Defend"}, "Enable", "defend")
--defend.fontSize = Menu.AddOption({ "Awareness", "Show defend Count"}, "Font Size", "", 20, 50, 10)
defend.optionDaggerEnable = Menu.AddOption({ "Utility","Defend"}, "Use Dagger","")
defend.optionHurricanEnable = Menu.Ad... |
local PANEL = {}
--panel functions
function PANEL:GetTextureSize() return self.TextureWidth, self.TextureHeight end
function PANEL:GetTextureSizeScaled(size)
--the texture could be something other than a 1:1 ratio
--this function will get dimensions of the texture for it to fit the specified size
size = size or ... |
-- TODO: HTML
local List = require 'pandoc.List'
----# Main OrderedList function #----
function OrderedList(element)
if element.style == 'Example' then
if FORMAT:match 'latex' then
element = sublists(element) -- Inserts xlist tags.
return ins_gb4e(element, 'exe') --top level so we ... |
local images_smoke = {"particle/smokesprites_0001", "particle/smokesprites_0002", "particle/smokesprites_0003", "particle/smokesprites_0004", "particle/smokesprites_0005", "particle/smokesprites_0006", "particle/smokesprites_0007", "particle/smokesprites_0008", "particle/smokesprites_0009", "particle/smokesprites_0010"... |
--[[
Binding.lua
--]]
local Binding, dbg = Object:newClass{ className = 'Binding' }
--- Constructor for extending class.
--
function Binding:newClass( t )
return Object.newClass( self, t )
end
--- Constructor for new instance.
--
function Binding:new( t )
local o = Object.new( ... |
local json = require("json")
function main(input)
return json.encode(input)
end |
--[[ The function, MakeInclTypeFile, will create a header file containing the OpenGL typdefs and preprocessor machinery
It takes these parameters:
- the name of the output file. Without the path.
- the specData, as formatted by LoadLuaSpec.
- an array of strings to write to the front of the header file.
]]
require ... |
if rawget(_G,"LuaVenusCompiler") then
print("LuaVenusCompiler warning: already initialized")
else
LuaVenusCompiler = {}
end
function LuaVenusCompiler.loadFromPath(path)
LuaVenusCompiler.path = path
local ret = dofile(path.."LuaVenusCompiler.lua")
for i,v in pairs(ret) do
LuaVenusCompiler[i] = v
end
r... |
Synapse = class.new();
function Synapse:constructor(weight, deltaWeight);
self.weight = weight;
self.deltaWeight = deltaWeight;
end |
-- Manages undoable listeners
--[[
local dispatcher = ToggleDispatcher:New("My dispatcher");
-- PLAYER_REGEN_DISABLED is fired when we enter combat
dispatcher:AddInstaller(Events.PLAYER_REGEN_DISABLED, dispatcher, "Fire");
-- PLAYER_REGEN_ENABLED is fired when we exit combat
dispatcher:AddInstaller(Events.PLAYER_REG... |
local metatables = require "util.matching.metatables"
local class = require "lib.middleclass"
local Object = class.Object
local env = { is = {} }
local function usemt_call(name)
local mt = metatables[name]
local function call(_, ...) return setmetatable({...}, mt) end
env[name] = setmetatable({}, { __call = cal... |
return function()
local Root = script.Parent.Parent.Parent
local CorePackages = game:GetService("CorePackages")
local PurchasePromptDeps = require(CorePackages.PurchasePromptDeps)
local Roact = PurchasePromptDeps.Roact
local AutoSizedTextLabel = require(script.Parent.AutoSizedTextLabel)
it("should create and de... |
local propZHeight = script:GetCustomProperty("ZHeight")
function Tick(deltaTime)
val = script.parent:GetPosition()
script.parent:SetPosition(Vector3.New(val.x, val.y, propZHeight) )
end
|
local log = require 'log'
box.cfg{
listen = 33013,
memtx_dir='.',
wal_mode='none',
}
box.once('initbox', function()
local s1 = box.schema.space.create('test', {id = 513, if_not_exists = true})
local ip = s1:create_index('primary', {type = 'hash', parts = {1, 'unsigned'}, if_not_exists = true})
local iname =... |
building_lib = {
-- name -> def
buildings = {},
-- name -> def
placements = {},
-- name -> def
conditions = {}
}
local MP = minetest.get_modpath("building_lib")
dofile(MP .. "/register.lua")
dofile(MP .. "/get_building_at_pos.lua")
dofile(MP .. "/get_groups_at_pos.lua")
dofile(MP .. "/show_preview.lua")
dofile... |
--
-- Aliases for map generator outputs
--
minetest.register_alias("mapgen_stone", "default:stone")
minetest.register_alias("mapgen_dirt", "default:dirt")
minetest.register_alias("mapgen_dirt_with_grass", "default:dirt_with_grass")
minetest.register_alias("mapgen_sand", "default:sand")
minetest.register_alias("mapgen_... |
class.compile("src/core/", _G) --compiles classes to _G
love.mouse.setRelativeMode(true)
local sceneManager = engine.sceneManagement.sceneManager
function love.load()
scene:createTestScene()
end
function love.fixedupdate(dt)
end
local DELTAS = {}
local POINTS = {}
for i = 1, 100 do
DELTAS[i] = 0.0
end
function... |
local Randomizer = require 'tetris.randomizers.randomizer'
local AlwaysRandomizer = Randomizer:extend()
function AlwaysRandomizer:new(piece)
self.piece = piece
self:initialize()
self.next_queue = {}
for i = 1, 30 do
table.insert(self.next_queue, self:generatePiece())
end
end
function AlwaysRandomizer:generate... |
object_tangible_loot_undead_outbreak_undead_deathtrooper_gloves = object_tangible_loot_undead_shared_outbreak_undead_deathtrooper_gloves:new {
}
ObjectTemplates:addTemplate(object_tangible_loot_undead_outbreak_undead_deathtrooper_gloves, "object/tangible/loot/undead/outbreak_undead_deathtrooper_gloves.iff")
|
--[[
OEML - REST API
This section will provide necessary information about the `CoinAPI OEML REST API` protocol. <br/> This API is also available in the Postman application: <a href=\"https://postman.coinapi.io/\" target=\"_blank\">https://postman.coinapi.io/</a> <br/><br/> Implemented Standards: * [HTTP1.... |
local PANEL = {}
function PANEL:Init()
self.category = "other"
self:TDLib()
:HideVBar()
self.lThink = CurTime()
self.lCount = -1
self:Update(true)
end
function PANEL:Think()
if self.lThink >= CurTime() then return end
self:Update(false)
self.lThink = CurTime() + 1
end
local function formatTime(time)
t... |
local CorePackages = game:GetService("CorePackages")
local Roact = require(CorePackages.Roact)
local RoactRodux = require(CorePackages.RoactRodux)
local TextService = game:GetService("TextService")
local SetActiveTab = require(script.Parent.Parent.Actions.SetActiveTab)
local TabRowButton = require(script.Parent.TabRo... |
require'nvim-treesitter.configs'.setup {
ensure_installed = "all", -- one of "", "maintained" (parsers with maintainers), or a list of languages
highlight = { enable = true, }, -- false will disable the whole extension
autotag = {
enable = true,
filetypes = { 'html', 'javascript', 'javascriptreact', 'type... |
local KUI, E, L, V, P, G = unpack(select(2, ...))
local KS = KUI:GetModule("KuiSkins")
local S = E:GetModule("Skins")
--Cache global variables
--Lua functions
local _G = _G
--WoW API / Variables
--Global variables that we don't cache, list them here for the mikk's Find Globals script
-- GLOBALS: hooksecurefunc, Contr... |
local addonName, addon = ...
local module = addon:CreateModule("Cast Bars")
module.defaultSettings = {
enable = true,
x = -128,
y = -3,
scale = 1,
width = 80,
}
module.optionsTable = {
enable = {
order = 1,
type = "toggle",
name = "Enable",
set = module.UpdateSettings,
},
break1 = {
... |
--[[
-- added by wsh @ 2017-12-08
-- Lua侧UILayer
--]]
local UILayer = BaseClass("UILayer", UIBaseComponent)
local base = UIBaseComponent
-- 创建
local function OnCreate(self, layer)
base.OnCreate(self)
-- Unity侧原生组件
self.unity_canvas = nil
self.unity_canvas_scaler = nil
self.unity_graphic_raycaster = nil
-- ui ... |
-- This module enables you to place Zone wherever you like within the data model while
-- still enabling third-party applications (such as HDAdmin/Nanoblox) to locate it
-- This is necessary to prevent two ZonePlus applications initiating at runtime which would
-- diminish it's overall efficiency
local replicatedStora... |
require('game.mainworld')
require('game.shopworld')
require('game.game_objects.player')
require('game.game_objects.coin')
require('game.globals')
core = require('core')
input = require('input')
translator = require('translathor')
content = require('content')
utils = require('utils')
function game_cleanup()
end
fun... |
mobs:register_mob("dmobs:tortoise", {
type = "animal",
passive = false,
reach = 1,
damage = 2,
attack_type = "dogfight",
hp_min = 6,
hp_max = 12,
armor = 130,
collisionbox = {-0.2, 0, -0.2, 0.2, 0.3, 0.2},
visual = "mesh",
mesh = "tortoise.b3d",
textures = {
{"dmobs_tortoise.png"},
},
blood_texture = "m... |
return {
NETFS = {
'nfs',
'nfs4',
'smbfs',
'cifs',
'codafs',
'ncpfs',
'shfs',
'fuse',
'fuseblk',
'glusterfs',
'davfs',
'fuse.glusterfs',
},
VIRTFS = {
'proc',
'sysfs',
'tmpfs',
'devtmpfs',
'devpts',
}
}
|
image = bytearray:new(30,30)
fill(image,0)
image:put(10,10,255)
dilate_rect(image,18,18)
write_png("out_o.png",image)
|
local http = require("envel.http")
local json = require("json")
-- converts a dbus.notify priorty to a Pushover priority
local function convert_priority(t)
if type(t) == 'number' then
t = t - 1
end
if t == 'low' then return -1 end
if t == 'normal' then return 0 end
if t == 'high' then retu... |
--
-- Majordomo Protocol client example - asynchronous
-- Uses the mdcli API to hide all MDP aspects
--
-- Author: Robert G. Jakabosky <bobby@sharedrealm.com>
--
require"mdcliapi2"
require"zmsg"
require"zhelpers"
local verbose = (arg[1] == "-v")
local session = mdcliapi2.new("tcp://localhost:5555", verbose)
local... |
--[[
##############################################################################
S V U I By: Failcoder
##############################################################################
--]]
--[[ GLOBALS ]]--
local _G = _G;
local unpack = _G.unpack;
local select = _G.select;
--[[ ADDON ]]--
local SV = _G['InkedSV'];... |
--氷水のエジル
--
--Script by Trishula9
function c101107007.initial_effect(c)
--to hand
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,101107007)
... |
local patch_id = "DISGUISE_AGENT_PORTRAIT"
if rawget(_G, patch_id) then
return
end
rawset(_G, patch_id, true)
print("Loaded patch:"..patch_id)
local old_fn = Widget.AgentPortrait.SetAgent
Widget.AgentPortrait.SetAgent = function(self, agent)
if agent and agent.disguise_agent and agent.disguise_data and agent.... |
require "src/core/arrays"
local intlist = {}
intlist.__index = intlist
local NIL = -1
local EMPTY = -2
function intlist.new(capacity)
local self = setmetatable({}, intlist)
self.values = {}
self.ip = NIL
self.length = 0
self.capacity = capacity
for i = 0, capacity - 1 do
self.values... |
--[[----------------------------------------------------------------------------
Application Name: Visionary_S_AP_PointCloudConverter
Summary:
Show how to calculate a full pointcloud and only a subpart of the image as pointloud in Lua
Description:
Set up the camera to take live images continuously and ... |
--[[-----------------------------------------------------------------------
The MIT License (MIT)
Copyright (c) 2010-2020 Mark Rogaski
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 res... |
instrument { name = "Parabolic SAR", overlay = true }
min_af = input (0.02,"front.newind.parabolicsar.accelmin", input.double, 0.01, 1, 0.01)
step_af = input (0.02,"front.platform.acceleration", input.double, 0.01, 1, 0.01)
max_af = input (0.2,"front.platform.acceleration max", input.double, 0.01, 1, 0.01)
input... |
local ack_data = {}
local function build(instance_id, host_id, service_id)
if not ack_data.start then
ack_data.start = os.time()
end
local retval = {
category = 1,
element = 1,
_type = 65537,
acknowledgement_type = 1,
author = "admin",
comment = "Acknowledged",
deletion_time = 0,
... |
--[[
DDPromise
v1.0.0
by: truedarkdev (DarkDev#3167 at discord)
]]--
local DDPromise = {
STATE_PENDING = 1,
STATE_RUNNING = 2,
STATE_FINISHED = 3,
RESULT_NONE = 1,
RESULT_SUCCEEDED = 2,
RESULT_REJECTED = 3,
}
DDPromise.__index = DDPromise
local DDFuture = {
... |
--[[
Licensed under GNU General Public License v2
* (c) 2013, Luke Bonham
* (c) 2013, Jan Xie
--]]
local icons_dir = require("lain.helpers").icons_di... |
--.---------------------------------------------
--. Rules_MAIN_To_VC.lua (Version:1.0) --
--. Applies rules from: --
--. all: GLB_SYS -> VC_TEST --
--. table: WORK_DEF_ROLES -> GLB_RUN --
--.---------------------------------------------
--.--------------------
... |
-------------------------------------------------------------------------------
-- ElvUI Chat Tweaks By Crackpotx (US, Lightbringer)
-- Based on functionality provided by Prat and/or Chatter
-------------------------------------------------------------------------------
-- Auction Created/Removed additions courtesy of ... |
--[[
/////// //////////////////
/////// PROJECT: MTA iLife - German Fun Reallife Gamemode
/////// VERSION: 1.7.2
/////// DEVELOPERS: See DEVELOPERS.md in the top folder
/////// LICENSE: See LICENSE.md in the top folder
/////// /////////////////
]]
--[[
addEventHandler("onClientRender", root,
function()
... |
-- misc.lua: tests for various useful stuff
-- This file is a part of lua-nucleo library
-- Copyright (c) lua-nucleo authors (see file `COPYRIGHT` for the license)
dofile('lua-nucleo/strict.lua') -- Import module requires strict
dofile('lua-nucleo/import.lua') -- Import module should be loaded manually
local make_sui... |
local scene = nil
local stack = {}
local scenes = {}
local scene_name = nil
function addScene(name, path, type)
scenes[name] = module.load(path)[type]
end
function startScene(name)
if scene then
scene:leave()
scene = nil
end
scene_name = name
if name then
scene = scen... |
RegisterNetEvent("Warns:CheckPermission:Client")
AddEventHandler("Warns:CheckPermission:Client", function(msg, error)
TriggerServerEvent("Warns:CheckPermission", msg, false)
end)
function ShowInfo(text)
SetNotificationTextEntry("STRING")
AddTextComponentSubstringPlayerName(text)
DrawNotification(false, fal... |
spring = class("spring")
function spring:init(x, y)
self.cox = x
self.coy = y
--PHYSICS STUFF
self.x = x-1
self.y = y-31/16
self.width = 16/16
self.height = 31/16
self.static = true
self.active = true
self.drawable = false
self.timer = springtime
self.category = 19
self.mask = {true}
self.fra... |
--[[
frames.lua
Methods for managing frame creation and display
--]]
local ADDON, Addon = ...
local Frames = Addon:NewModule('Frames')
--[[ Startup ]]--
function Frames:OnEnable()
self.registry = {
{id = 'inventory', name = INVENTORY_TOOLTIP},
{id = 'bank', name = BANK},
{id = 'vault', name = VOID_STORAGE... |
-----------------------------------------------------------------------
-- A GameViewControlller class extension that handles collisions (and treasures collection) in the scene
-----------------------------------------------------------------------
----------------------------------------------------------------------... |
local jid_split = require "util.jid".split;
local jid_bare = require "util.jid".bare;
local is_contact_subscribed = require "core.rostermanager".is_contact_subscribed;
function check_subscribed(event)
local stanza = event.stanza;
local to_user, to_host, to_resource = jid_split(stanza.attr.to);
local from_jid = jid... |
local XQueue = torch.class('XQueue')
function XQueue:__init(maxn)
self.MAXN = (maxn or 4294967294) + 1 -- 2^32 - 1, max unsigned int32 in other languages, should be big enough
self.front = 0
self.rear = 0
self.Q = {}
end
function XQueue:push(v)
local nextRear = self:nextPos(self.rear)
if nextRear == sel... |
return Def.Quad {
InitCommand = function(self)
self
:zoomtowidth(232)
:zoomtoheight(24)
:diffuse(color("0.2, 0.2, 0.2, 1"))
:diffusetopedge(color("0.5, 0.5, 0.5, 1"))
end
}
|
local Tract = {}
Tract.fixed = {}
Tract.fixed.L = {}
Tract.fixed.L[1] = 34
Tract.fixed.L[2] = 35
Tract.AreaNose = {}
Tract.AreaNose[1] = 1.5714285714285714
Tract.AreaNose[2] = 1.7179022198839489
Tract.AreaNose[3] = 1.9682276909400922
Tract.AreaNose[4] = 2.2866241438442456
Tract.AreaNose[5] = 2.6441517229455069
Tract.Ar... |
ngx.say("hello world");
|
set_xmakever("2.5.9")
add_requires("glfw", "spdlog", "eigen", "cmake::Vulkan", "tinyobjloader")
add_rules("mode.release", "mode.debug")
set_languages("cxx17")
target("RainEngine")
set_kind("binary")
add_includedirs("src/engine", "src/common", "src/geometry", "src/physics", "src/renderer", "ext/imgui")... |
--[[
© 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/CtfS8r5W3M
developer(s):
... |
local data = require("core.data")
local enums = require("core.enums")
local Inventory = require("core.Inventory")
local Item = require("core.Item")
local math = math
local Chara = require("core.Chara")
local Rand = require("core.Rand")
local shop_inventory = {}
function shop_inventory.default_item_number(args)
ret... |
callsign = "MIS"
password = ""
homebase = "LHBP"
DataRef( "xpdr_f", "sim/cockpit/radios/transponder_mode", "readonly" )
DataRef( "xpdr", "sim/cockpit/radios/transponder_code", "readonly" )
DataRef( "alt", "sim/cockpit2/gauges/indicators/altitude_ft_pilot", "readonly" )
DataRef( "lat", "sim/flightmodel/position/latit... |
-------------------------------------------------------------------------
-- Created by Adriano Spadoni
-- alte_br@hotmail.com
-- 06 Jun 2014
-------------------------------------------------------------------------
local physics = require( "physics" )
local widget = require( "widget" )
local composer = require( "c... |
-- FollowMe
-- Move car around using the arrow keys.
local argparse = require("argparse.argparse")
local assets = require("assets")
local camera = require("entities.camera")
local ctx = require('gamectx.global')
local ground = require("entities.ground")
local logger = require("logger.logger")
local netman = require("ne... |
object_mobile_outbreak_undead_scientist_f_hum_13 = object_mobile_shared_outbreak_undead_scientist_f_hum_13:new {
}
ObjectTemplates:addTemplate(object_mobile_outbreak_undead_scientist_f_hum_13, "object/mobile/outbreak_undead_scientist_f_hum_13.iff")
|
-- HASH SETS with EXPIRE by fields
-- HSETXP key expire(sec) field value [field value...]
---- This command creates a another HASH SETS whose key is KEYS[1]+'.EXPIREAT' contains EXPIREAT TIME by fields
local HSET_EXPIREAT_KEY = KEYS[1]..".EXPIREAT"
local expireAt = tonumber(redis.call('TIME')[1]) + tonumber(KEYS[2])
... |
local status_ok, alpha = pcall(require, "alpha")
if not status_ok then
return
end
local fn = vim.fn
local dashboard = require("alpha.themes.dashboard")
dashboard.section.header.val = {
" ███╗░░██╗███████╗░█████╗░██╗░░░██╗██╗███╗░░░███╗ ",
" ████╗░██║██╔════╝██╔══██╗██║░░░██║██║████╗░████║ ",
" ██╔██╗██║█████... |
CppPackage = {}
function CppPackage.new(id, root)
local self = {}
-- Public fields
-- Private fields:
local _id = id
local _root = root
local _parent = nil
if type(_root) ~= "string" then
_parent = _root
_root = nil
end
-- Public functions
function self.id()
return _id
end
function sel... |
--[[**********************************
*
* Multi Theft Auto - Admin Panel
*
* client\widgets\admin_messages.lua
*
* Original File by lil_Toady
*
**************************************]]
aMessages = {
Form = nil,
Messages = {}
}
function aMessages.Open()
if (not aMessages.Form) then
local x, y = gui... |
local memory = require("memory")
local PANEL = class.create("GCBind", "Button")
PANEL.BUTTONS = {
Z = 0x0010,
R = 0x0020,
L = 0x0040,
A = 0x0100,
B = 0x0200,
X = 0x0400,
Y = 0x0800,
D_LEFT = 0x0001,
D_RIGHT = 0x0002,
D_DOWN = 0x0004,
D_UP = 0x0008,
START = 0x1000,
UP = 0x10000,
DOWN = 0x20000,
LEFT = 0... |
local argparse = require 'argparse'
local lanes = require 'packagemanager/lanes'
local PackageManager = require 'packagemanager/init'
local Repository = require 'packagemanager/repository'
local utils = require 'packagemanager-cli/utils'
local ProcessChangeTasks = require('packagemanager-cli/changes').processChangeTask... |
--[[
Copyright (c) 2015, Vsevolod Stakhov <vsevolod@highsecure.ru>
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 ... |
local function entity_built(event)
local entity = event.created_entity or event.entity or event.destination
if (string.find(entity.name, "RTThrower-")) then
global.CatapultList[entity.unit_number] = {entity = entity, target = "nothing"}
elseif (entity.name == "PlayerLauncher") then
entity.operable = false
en... |
local nats = {
_VERSION = 'lua-nats 0.0.2',
_DESCRIPTION = 'LUA client for NATS messaging system. https://nats.io',
_COPYRIGHT = 'Copyright (C) 2015 Eric Pinto',
}
-- ### Library requirements ###
local cjson = require('cjson')
local uuid = require('uuid')
-- ### Local properties ###
local unp... |
local tokenModule = {
["+"] = { -- key = token, value = dictionary
["type"] = "PLUSANDCONCAT", -- honestly i don't even know...
["context"] = "number_string", -- context is what types are recognized by this token.
["Function"] = function (a,b) -- this handles the functionality of the tok... |
local toInsensitive = function(target)
target = target:gsub("(%W)", "%%%1") -- 预处理:对所有非字母数字转义
target = target:gsub("%a", function(letter)
return "[" .. letter:lower() .. letter:upper() .. "]"
end)
return target
end
local l_target = "this is a search string ABCD [100.00%]"
local l_source = "This... |
local M = {}
-- 定数
M.LEVEL_NONE = 0
M.LEVEL_INFO = 1
M.LEVEL_WARN = 2
M.LEVEL_ERROR = 3
M.LEVEL_DEBUG = 4
-- 変数
M.level = M.LEVEL_ERROR
---------------------------------------
-- 通常ログを出力します.
---------------------------------------
function M.info(...)
if M.level >= M.LEVEL_INFO then
print("[info]", ...)
... |
local ffi = require "ffi"
local r3e = require "r3e"
local r3emap = require "r3emap"
local r3emapfull = r3emap.init(true)
local r3emapbase = r3emap.init(false)
local R3E_TRACE_VERSION = 1
ffi.cdef ([[
typedef struct {
int version;
int frameSize;
int frames;
int pollrate;
int laps;
} r3e_trace_header;
]])
l... |
RegisterClientScript()
-- Table extension
function table.count(tab)
local size = 0
for _, _ in pairs(tab) do
size = size + 1
end
return size
end
function table.join(...)
local t = {}
for _, tab in pairs({...}) do
for k, v in ipairs(tab) do
table.insert(t, v)
end
end
return t
end
-- Utils table
uti... |
--- Require ---
local Class = require("lib.hump.class")
local util = require("lib.self.util")
--- ==== ---
--- Classes ---
local Block = require("objects.game.blocks.block")
--- ==== ---
--- Localised functions ---
local floor = math.floor
local min = math.min
--- ==== ---
--- Class definition ---
local DynamicBl... |
---------------------------------------------
-- Vacuum & Ammeter --
-- Modification of Jason Tatum's original --
-- Brian McMullan 20180324 --
-- Property for background off/on --
-- Property for dimming overlay --
-------------------------------------------... |
local M = {}
function M.setup()
-- Indicate first time installation
local packer_bootstrap = false
-- packer.nvim configuration
local conf = {
profile = {
enable = true,
threshold = 0, -- the amount in ms that a plugins load time must be over for it to be included in the profile
},
di... |
local plfs = {}
-- Return OS names like love.system.getOS
local function _getOS()
local BinaryFormat = package.cpath:match("%p[\\|/]?%p(%a+)")
if BinaryFormat == "dll" then
return "Windows"
end
if BinaryFormat == "so" then
return "Linux"
end
if BinaryFormat == "dylib" then
return "OS X"
end
... |
id = 2001
name = "星际争霸"
desc1 = "人族、虫族和神族,在这个位面不断的战斗着。"
desc2 = "几千万年前,有个科技极为发达的种族赛而那加在宇宙中流浪,他们在所到达的星球创造新的生命,他们试着创造出纯粹的生物形体,其中最成功的作品就是神族和虫族。但野心使得神族和虫族陷入大规模的战争中而无法自拔。赛而那加给了虫族同化寄生主的本领,结果虫族却最终毁灭了赛而那加。在这些种族的的战斗中,哈斯取得了暂时的统一,他们以银河低等种族的保护者自居,但他们始终害怕神族和虫族的挑战。在虫族开始将目标转向神族的时候,人族加入了战争。" |
return {
version = "1.5",
luaversion = "5.1",
tiledversion = "1.7.2",
orientation = "orthogonal",
renderorder = "right-down",
width = 64,
height = 64,
tilewidth = 16,
tileheight = 16,
nextlayerid = 5,
nextobjectid = 268,
properties = {},
tilesets = {
{
name = "dungeon-tileset",
... |
EXPORT_ASSERT_TO_GLOBALS = true
require('luaunit')
TestToto = {} --class
function TestToto:setUp()
-- set up tests
self.a = 1
self.s = 'hop'
self.t1 = {1,2,3}
self.t2 = {one=1,two=2,three=3}
self.t3 = {1,2,three=3}
end
function TestToto:test1_withFailure()... |
ITEM.name = "FSB Helmet (CS-3b)"
ITEM.description = "A newer steel helmet."
ITEM.longdesc = "Heavy assault helmet of Russian make, favored by FSB assault teams. Small respirator helps against tear gas and short exposure to NBC threats, while tactical goggles protect the eyes of the user."
ITEM.model = "models/kek1ch/he... |
local drawableSpriteStruct = require("structs.drawable_sprite")
local rotatingBumper = {}
rotatingBumper.name = "MaxHelpingHand/RotatingBumper"
rotatingBumper.nodeLimits = {1, 1}
rotatingBumper.nodeLineRenderType = "circle"
rotatingBumper.depth = 0
rotatingBumper.placements = {}
rotatingBumper.placements = {
nam... |
require('config')
require('module')
local osm=RE.ogreSceneManager()
osm:setFogNone() -- turn off fog (so that the following skybox is visible)
|
object_tangible_quest_imperial_itp_veers_rebel_server = object_tangible_quest_imperial_shared_itp_veers_rebel_server:new {
}
ObjectTemplates:addTemplate(object_tangible_quest_imperial_itp_veers_rebel_server, "object/tangible/quest/imperial/itp_veers_rebel_server.iff")
|
-- https://github.com/ImagicTheCat/love-webp
-- MIT license (see LICENSE)
--[[
MIT License
Copyright (c) 2020 ImagicTheCat
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, in... |
local playsession = {
{"NappingYG", {7703}},
{"akrause", {4990}},
{"SpS", {578}},
{"jackazzm", {20835}},
{"cogito123", {14284}},
{"Relo", {2205}},
{"moemoesan", {495}},
{"Menander", {508337}},
{"rocifier", {883862}},
{"Krono", {637004}},
{"stafftank", {2053}},
{"Immo", {282843}},
{"jadenw45", {180692}},
{... |
local colors = require "gruvbox.colors"
return {
normal = {
a = { bg = colors.fg4, fg = colors.bg0, gui = "bold" },
b = { bg = colors.bg2, fg = colors.fg4 },
c = { bg = colors.bg1, fg = colors.fg4 },
},
insert = {
a = { bg = colors.blue, fg = colors.bg0, gui = "bold" },
b = { bg = colors.bg2,... |
local Component = require "class.Component"
local stomps = class("misc.stomps", Component)
stomps.argList = {
{"level", "number", 1},
}
function stomps:bottomCollision(dt, actorEvent, obj2)
if obj2:hasComponent("misc.stompable") then
-- self.actor.y = obj2.y-self.actor.height
self.actor.speed[... |
roles.CreateTeam(ROLE.name, {
id = TEAM_IMPOSTER,
color = Color(255, 0, 0)
})
ROLE.id = ROLE_IMPOSTER
ROLE.desc = "Sabotage and kill everyone."
ROLE.color = Color(255, 0, 0)
ROLE.defaultTeam = TEAM_IMPOSTER
ROLE.CanKill = true
ROLE.CanSabotage = true
ROLE.CanVent = true
ROLE.HasTasks = false
ROLE.ShowTeammates = ... |
m_tblNoticeMaterial = {}
m_tblNoticeMaterial[NOTIFY_GENERIC] = Material( "vgui/notices/generic" )
m_tblNoticeMaterial[NOTIFY_ERROR] = Material( "vgui/notices/error" )
m_tblNoticeMaterial[NOTIFY_UNDO] = Material( "vgui/notices/undo" )
m_tblNoticeMaterial[NOTIFY_HINT] = Material( "vgui/notices/hint" )
m_tblNoticeMat... |
Config = {}
Config.Locale = 'en'
Config.EnablePrice = true
Config.Price = 500
Config.Locations = {
vector3(26.5906, -1392.0261, 27.3634),
vector3(167.1034, -1719.4704, 27.2916),
vector3(-74.5693, 6427.8715, 29.4400),
vector3(-699.6325, -932.7043, 17.0139)
} |
local function GetSeasonDuration(season)
local seasonsOfMars = SeasonsOfMars
return MulDivRound(seasonsOfMars[season].Duration, 1, seasonsOfMars.DurationDivider)
end
local function GetSeasonalEffectsText()
return table.concat({
Untranslated("<white>Seasons:</white>"),
Untranslated(string.fo... |
local displayApartBlips = true --SET TO TRUE IF YOU WANT TO ADD BLIPS FOR APPARTMENTS
local interiors = {
[1] = { ["price"] = 100000, ["xe"] = 1394.48278808594, ["ye"] = 1141.74035644531, ["ze"] = 114.606857299805, ["he"] = 0.000, ["xo"] = 1397.33056640625, ["yo"] = 1142.05017089844, ["zo"] = 114.333587646484, ["h... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.