content
stringlengths
5
1.05M
local Observable = require("reactivex.observable") local Observer = require("reactivex.observer") local Subscription = require("reactivex.subscription") local Subject = require("reactivex.subjects.subject") require('reactivex.operators.switch') describe('switch', function() it('errors when the source errors', funct...
local vim = vim local global = {} local home = os.getenv("HOME") function global.load_variables() global.is_mac = jit.os == 'OSX' global.is_linux = jit.os == 'Linux' global.is_windows = jit.os == 'Windows' local path_sep = global.is_windows and '\\' or '/' global.vim_path = home .. path_sep..'.confi...
local Keys = { ["ESC"] = 322, ["BACKSPACE"] = 177, ["E"] = 38, ["ENTER"] = 18, ["LEFT"] = 174, ["RIGHT"] = 175, ["TOP"] = 27, ["DOWN"] = 173 } Config = {} Config.MarkerSize = { x = 1.5, y = 1.5, z = 1.2 } Config.MarkerColor = { r = 0, g = 130, b = 204 } Config.MainMenu = { {x = 2500.960...
-- Do blocks explicitly define lexical scope do local x = 6 y = 7 end print(x, y) -- nil 7
local gearman = require "luagearman.gearman" local ffi = require "ffi" ffi.cdef([[ typedef enum { GEARMAN_WORKER_ALLOCATED= (1 << 0), GEARMAN_WORKER_NON_BLOCKING= (1 << 1), GEARMAN_WORKER_PACKET_INIT= (1 << 2), GEARMAN_WORKER_GRAB_JOB_IN_USE= (1 << 3), GEARMAN_WORKER_PRE_SLEEP_IN_USE=...
-- Unit tests for Util.lua, part of the FitzUtils library. -- Run from the Binds directory -- Load up libs required for testing. require('test/luaunit/luaunit') require("Util") -- Upvalue local U = FitzUtils; TestFitzUtils = {} function TestFitzUtils:setUp() -- Turn off prints U:Debug(false) e...
--[[--ldoc desc 业务自定义的全局管理类 ]] --------------------------------------------------------------------------------------------- local Global = {} -- local globals = {}; -- -- 保护global中定义的全局变量不被修改 -- local protectEnv = function(env) -- local mt = getmetatable(env); -- local cache = {}; -- mt.__newindex = funct...
function love.conf(t) t.releases = { title = "l2 engine", package = "l2", loveVersion = "0.10.2", version = "0.1", author = "Egor Dorichev", email = "egordorichev@gmail.com", description = "l2 engine template", homepage = nil, identifier = "l2", excludeFileList = {}, releaseDirectory = nil } t...
--[[ Name: Alfa For: TalosLife By: TalosLife ]]-- local Car = {} Car.Make = "Kia" Car.Name = "Kia Forte Koup" Car.UID = "kia_Cope" Car.Desc = "A drivable kia by TheDanishMaster" Car.Model = "models/tdmcars/kia_fortekoup.mdl" Car.Script = "scripts/vehicles/TDMCars/kiafortekoup.txt" Car.Price = 19000 Car.FuellTank = ...
--mz.h & mz_zip.h 2.9.1 Zip manipulation local ffi = require'ffi' ffi.cdef[[ enum { MZ_OK = 0, MZ_STREAM_ERROR = -1, MZ_DATA_ERROR = -3, MZ_MEM_ERROR = -4, MZ_BUF_ERROR = -5, MZ_VERSION_ERROR = -6, ...
line_blue = {["off_color"] = "none", ["on_color"] = "none", ["line_color"] = "0cf", ["line_width"] = "3"}; line_pink = {["off_color"] = "none", ["on_color"] = "none", ["line_color"] = "f9c", ["line_width"] = "3"}; line_brown = {["off_color"] = "none", [...
local function file_exists(file) local f = io.open(file, "rb") if f then f:close() end return f ~= nil end local function load_file(file_name) if not file_exists(file_name) then print("File " .. file_name .. " does not exist") return {} end local lines = {} for line in io.lines(file_name) do ...
-- C# program will use this! civ3_home = "/Users/jim/civ3" -- variable init -- vars for bic flag hunt byte_chunks = {} offset = 0 num_bytes = 32 idx = 1 num_bic_with_bldg = 0 num_bic_with_wchr = 0 num_bic_with_both = 0 -- vars for tile hunt tile_off = {} num_mountains = 0 -- called for each sav function process_sa...
corellia_destroy_missions = { minLevelCeiling = 25, lairSpawns = { { lairTemplateName = "corellia_gubbur_lair_neutral_small", minDifficulty = 4, maxDifficulty = 8, size = 20, }, { lairTemplateName = "corellia_meatlump_camp_neutral_medium_theater", minDifficulty = 4, maxDifficulty = 8, s...
local function OffsetCoords(tCoord, offsetX, offsetY) for i = 1, #tCoord, 2 do tCoord[i ] = tCoord[i ] + offsetX tCoord[i + 1] = tCoord[i + 1] + offsetY end end local function ScaleCoords(tCoord, scaleX, scaleY) for i = 1, #tCoord, 2 do tCoord[i ] = tCoord[i ] * scaleX ...
--------------------------------------------- -- Red lotus Blade -- -- Description: Deals fire elemental damage. Damage varies with TP. -- Type: Physical -- Utsusemi/Blink absorb: 1 Shadow? -- Range: Melee --------------------------------------------- require("scripts/globals/monstertpmoves") require("scripts/globals/s...
-------------- -- Includes -- -------------- addEvent('onPlayerChatting', true) addEvent('onClientPlayerChatting', true) -------------------------------- -- Local function definitions -- -------------------------------- local function ChtOnPlayerChatting(chatting) for player, pdata in pairs(g_Players) d...
for i,v in ipairs({ createObject ( 3749, 894.20001, 2246.8, 21.4, 0, 0, 270 ), createObject ( 8417, 875.7998, 2225.5, 15.5, 0, 179.995, 0 ), createObject ( 8417, 834.4502, 2225.5, 15.5, 0, 179.995, 0 ), createObject ( 8417, 875.79999, 2185.5, 15.5, 0, 179.995, 0 ), createObject ( 8417, 834.4502, 2185.5, 15.5, 0, 179.99...
-- See LICENSE for terms return { PlaceObj("ModItemOptionToggle", { "name", "CropsNeverFail", "DisplayName", T(302535920011851, "Crops Never Fail"), "Help", T(302535920011852, "Crops will never fail no matter the conditions (you'll get a random yield amount instead of failing)."), "DefaultValue", false, }), ...
require('./emerald/emerald')
registerNpc(871, { walk_speed = 160, run_speed = 370, scale = 160, r_weapon = 112, l_weapon = 0, level = 69, hp = 2000, attack = 224, hit = 183, def = 190, res = 84, avoid...
scifi_nodes.get_switch_rules = function(param2) -- param2 = 2 local rules = { {x=1, y=-1, z=-1}, {x=1, y=-1, z=1}, {x=0, y=-1, z=-1}, {x=0, y=-1, z=1}, } -- Left and right when looking to +y ? if param2 == 3 then rules = mesecon.rotate_rules_right(mesecon.rotate_rules_right (rules)) elseif param2 == ...
#include "util.lua" function drawEffectsText() UiPush() UiAlign("top left") UiTranslate(20, 20) if string.find(GetString("game.levelid"), "hub") then UiTranslate(0, 40) end UiTextShadow(0, 0, 0, 0.25, 2.0) UiFont("MOD/ui/stranger.ttf", 50) UiColor(1, 0.25, 0.25, 0.75) UiText("Stalker Mod") UiTran...
if op == "+" then r = a + b elseif op == "-" then r = a - b elseif op == "*" then r = a * b elseif op == "/" then r = a / b else error("invalid operation") end if true then foo = 'bar' else foo = nil end if true then print('hello') end if true then print('hello') end if nested then if nested then ...
--[[ Title: world store Author(s): big Date: 2018.8.24 City: Foshan use the lib: ------------------------------------------------------------ NPL.load("(gl)Mod/WorldShare/store/WorldStore.lua") local WorldStore = commonlib.gettable('Mod.WorldShare.store.World') ---------------------------------------------------------...
local Lerp = Lerp local tonumber = tonumber local table_insert = table.insert local table_remove = table.remove local math_ceil = math.ceil local math_abs = math.abs local math_min = math.min local render_StartBeam = render.StartBeam local cam_IgnoreZ = cam.IgnoreZ local render_EndBeam = render.EndBeam local render_Add...
--魔鍵憑神-アシュタルトゥ --Script by mercury233 local s,id,o=GetID() function s.initial_effect(c) --xyz summon aux.AddXyzProcedure(c,nil,8,2) c:EnableReviveLimit() --damage local e1=Effect.CreateEffect(c) e1:SetDescription(aux.Stringid(id,0)) e1:SetCategory(CATEGORY_DAMAGE) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGE...
return { Version = "6.18.1", [1001] = { item_name = "Boots of Speed", cost = 300, cost_total = 300, from = {}, }, [1004] = { item_name = "Faerie Charm", cost = 125, cost_total = 125, from = {}, }, [1006] = { item_name = "Rejuvenation Bead", cost = 150, cost_total = 150, from = {}, }, ...
mainmenu = { waiting = true, timeout = 60, blinkFrames = 0, } mainmenu.title = { x = 0, y = 0, text = 'Galleons', angleX = love.math.random() * math.pi, angleY = love.math.random() * math.pi, } mainmenu.buttons = { {icon = sprites.ui_A, color={r=0.2, g=0.8, b=0.2}, text = 'Play', y...
function Alcohol.ChangeUnits(ply, amount) if not Alcohol.Units[ply:SteamID64()] then Alcohol.ResetUnits(ply, true) end Alcohol.Units[ply:SteamID64()] = Alcohol.Units[ply:SteamID64()] + amount net.Start("Alcohol:Units:Change") net.WriteUInt(Alcohol.Units[ply:SteamID64()], 7) net.Send(ply) hook.Run("Alcohol:...
local mod = DBM:NewMod(1490, "DBM-Party-Legion", 3, 716) local L = mod:GetLocalizedStrings() mod:SetRevision(("$Revision: 15188 $"):sub(12, -3)) mod:SetCreatureID(91789) mod:SetEncounterID(1811) mod:SetZone() mod:RegisterCombat("combat") mod:RegisterEventsInCombat( "SPELL_AURA_APPLIED 193698", "SPELL_...
local ev = require'ev' local ev_common = require'websocket.ev_common' local socket = require'socket' setloop('ev') describe('The ev_common helper module',function() local listen_io setup(function() local listener = socket.bind('*',12345) listener:settimeout(0) listen_io = ev.IO.n...
--[[ Creates a Roact component that is a grey rounded button Props: position : UDim2 - Position of the button. zIndex : number - Determines the order of UI element rendering. anchorPoint : UDim2 - The anchor point of the button. onResume : function() - Fires when the button is activated. ]] local CorePa...
-- some locals local SR = SR_Tracker local config = SR.Config -- -- localizations local ipairs = ipairs local istable = istable local IsValid = IsValid local GetHumans = player.GetHumans local mysql = SR.MySQL local srEncode = SR.Encode local setPlyVar = SR.SetPlyVar local hasMenuPermissions = SR.HasMenuPermissions...
return { generate_xmldoc_under_cursor = require('knife.docs').generate_xmldoc_under_cursor }
---@class SystemInfo C_System = {}
function completor_handle_event(event) return require'completor.handle'.handle(event) end local function autocmd(event) local cmd = string.format( "autocmd %s * lua completor_handle_event('%s')", event, event ) vim.cmd(cmd) end autocmd("TextChangedP") autocmd("TextChangedI") autocmd("InsertEnter") autocmd...
-- -- Copyright (c) 2017, Xavier Gastaldi. -- All rights reserved. -- -- This source code is licensed under the BSD-style license found in the -- LICENSE file in the root directory of this source tree. An additional grant -- of patent rights can be found in the PATENTS file in the same directory. -- require 'nn' ...
TOOL.Category = "Construction" TOOL.Name = "#tool.dynamite.name" TOOL.ClientConVar[ "group" ] = 52 TOOL.ClientConVar[ "damage" ] = 200 TOOL.ClientConVar[ "delay" ] = 0 TOOL.ClientConVar[ "model" ] = "models/dav0r/tnt/tnt.mdl" TOOL.ClientConVar[ "remove" ] = 0 TOOL.Information = { { name = "left" } } cleanup.Registe...
local mpd = { client = require("widgets.playback.mpd.client"), stream = require("widgets.playback.mpd.stream"), } return mpd
local Config = require("AdituV.DetectTrap.Config"); local Effects = require("AdituV.DetectTrap.Magic.Effects"); local Spells = require("AdituV.DetectTrap.Magic.Spells"); local LockData = require("AdituV.DetectTrap.LockData"); local MCPFeature = require("AdituV.DetectTrap.Utility.McpFeature"); local MobilePlayer = requi...
local f = string.format My.Translator:register("de", { comms_directions_label = "Richtungsangaben", comms_directions_main = function() return Util.random({ "Wo soll es denn hingehen?", "Womit kann ich helfen?", }) end, comms_directions_detail = function(stationCa...
-- Gui to Lua -- Version: 3.2 -- Instances: local KATAlyzer = Instance.new("ScreenGui") local MainFrame = Instance.new("Frame") local UICorner = Instance.new("UICorner") local DropFrame = Instance.new("Frame") local CombatBTN = Instance.new("TextButton") local VisualsBTN = Instance.new("TextButton") local CombatWindo...
#!/usr/bin/env lua -- In case we want to run tests when library is not installed. local LUA_PATH_SEP = package.config:sub(3, 3) package.path = package.path .. LUA_PATH_SEP .. '../src/?.lua' local CORRECT_OUTPUT = [[- . . . . . - - . - . . - . . - . - . - . - - . . . . - . - - - . - -...
local base = require('xe.ui.TreeNode') ---@class xe.AssetsNode:xe.ui.TreeNode local M = class('xe.AssetsNode', base) local im = imgui local wi = require('imgui.Widget') function M:ctor(attr) base.ctor(self) self:_updateAttr(attr) self:setOnSelect(function() self:getView():onSelChanged(self) en...
slot0 = class("LevelAwardPage", import("...base.BaseActivityPage")) slot0.OnInit = function (slot0) slot0.bg = slot0:findTF("bg") slot0.award = slot0:findTF("scroll/award") slot0.content = slot0:findTF("scroll/content") slot0.scrollTF = slot0:findTF("scroll") slot0.pageSignDownTF = slot0:findTF("sign") slot0.pag...
local is_blank = assert(foundation.com.is_blank) local ItemInterface = assert(yatm.items.ItemInterface) local fspec = assert(foundation.com.formspec.api) local is_stack_cartridge = assert(yatm_armoury.is_stack_cartridge) local InventorySerializer = assert(foundation.com.InventorySerializer) function get_ammo_can_forms...
--[[ Luci configuration model for statistics - collectd exec plugin configuration (c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net> 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 ...
local BaseClass = require "NJLI.STATEMACHINE.NodeEntity" local Image = {} Image.__index = Image --############################################################################# --DO NOT EDIT ABOVE --############################################################################# --#######################################...
Config = {} Config.Animations = { { name = 'festives', label = 'Festives', items = { {label = "Play music", type = "scenario", data = {anim = "WORLD_HUMAN_MUSICIAN"}}, {label = "Dj", type = "anim", data = {lib = "anim@mp_player_intcelebrationmale@dj", anim = "dj"}}, {label = "Drink a beer", ty...
--[[ The MIT License (MIT) Copyright (c) 2016 Christoph Kubisch 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, ...
local inspect = require 'inspect' local _ = require ("moses") local ml_test = {} ml_test.__index = ml_test local _read_dataset = function(datafile, training_share) local samples_file = assert(io.open(datafile, 'r')) -- get all classes local classes = {} local dataline for line in samples_file:lines() d...
function Mining.Core.GetRandomOre() local pool = {} for k, v in pairs(Mining.Config.Ores) do for i=1, v.rarity do table.insert(pool, k) end end return table.Random(pool) end function Mining.Core.MinedOre(ply, ore) local oreData = Mining.Config.Ores[ore] if not Mining.Users[ply:SteamID64()] then Minin...
function always() print "Hello from Lua!" load "subalf" end function runTask() print "Running from Lua!" end function fromMoon() tasks.subloaded() end
--[[ ____ _____ _____ _____ _ _ _____ | _ \ / ____/ ____| / ____| | | |_ _| | |_) | (___| (___ | | __| | | | | | | _ < \___ \\___ \ | | |_ | | | | | | | |_) |____) |___) | | |__| | |__| |_| |_ |____/|_____/_____/ \_____|\____/|_____| by Alex & Fede --]] -- V3rmill...
--- === hs.caffeinate === --- --- Control system power states (sleeping, preventing sleep, screen locking, etc) --- --- **NOTE**: Any sleep preventions will be removed when hs.reload() is called. A future version of the module will save/restore state across reloads. local caffeinate = require "hs.caffeinate.internal" ...
function onLoad() self.createButton( { click_function = "calculateTotal", function_owner = self, label = "TOT", position = {0, 2.5, -0.37}, rotation = {0, 180, 0}, scale = {0.3, 0.5, 0.5}, width = 350, height = 3...
local function get_variables_hash(msg) if msg.to.type == 'chat' then return 'chat:'..msg.to.id..':variables' end if msg.to.type == 'channel' then return 'channel:'..msg.to.id..':variables' end if msg.to.type == 'user' then return 'user:'..msg.from.id..':variables' end end local function get_val...
----------------------------------- -- Area: Qulun Dome -- NPC: The Mute -- !zone 148 ----------------------------------- function onTrade(player,npc,trade) end; function onTrigger(player,npc) local duration = math.random(600,900); if (player:hasStatusEffect(tpz.effect.SILENCE) == false) then player...
-- pattern for finding figure references -- Example: {#f:fig1ref:t} local patt = "{%#%l:.+:%a}" local id_patt = ":(.+):" local type_patt = "{#(.+):.+:%a}" -- to keep track of which figures have already been seen local seen_elements = {} -- storage for figure numbers arranged by figure type local figure_numbers = {} ...
all_defaults = {["generic注释开始"]=0,["generic注释结束"]=0,["IO口未设置"]=0,["KEY9 按键HOLD消息:"]=255,["KEY8 按键双击消息:"]=255,["KEY8 按键三击消息:"]=255,["KEY9 按键双击消息:"]=255,["期望音量 32"]=0.000000,["KEY9 按键抬按消息:"]=255,["KEY9 按键三击消息:"]=255,["使能32"]=0,["KEY1 按键短按消息:"]=255,["KEY0 按键HOLD消息:"]=255,["KEY0 按键抬按消息:"]=255,["KEY1 按键长按消息:"]=255,["KEY0 按键...
local class = require('opus.class') local Region = require('opus.ui.region') local Util = require('opus.util') local _rep = string.rep local _sub = string.sub local _gsub = string.gsub local colors = _G.colors local Canvas = class() local function genPalette(map) local t = { } local rcolors = Util.transpos...
--- C++ compilers local M = { gcc = require("configure.lang.cxx.compiler.gcc"), clang = require("configure.lang.cxx.compiler.clang"), msvc = require("configure.lang.cxx.compiler.msvc"), } M.env_name = "CXX" M.description = "C++ compiler" local os = Platform.current():os() if os == Platform.OS.linux then M.c...
----------------------------------------- -- Spell: Infrasonics -- Lowers the evasion of enemies within a fan-shaped area originating from the caster -- Spell cost: 42 MP -- Monster Type: Lizards -- Spell Type: Magical (Ice) -- Blue Magic Points: 4 -- Stat Bonus: INT+1 -- Level: 65 -- Casting Time: 5 seconds -- Recast ...
require("luaCallCs") require("luaCallCsReflect") require("csCallLua") require("genCode") --require("luaTdrTest") function islua53() return not not math.type end -- for test case CMyTestEnv = TestEnvironment:new() function CMyTestEnv:new(oo) local o = oo or {} setmetatable(o, self) self.__index = self ...
--[[ Copyright (c) 2016 by Marco Lizza (marco.lizza@gmail.com) This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including...
local table = require('table') local enumerable = {} local enumerator_cache = setmetatable({}, {__mode = 'k'}) local empty_constructor local add_fn = function(x, y) return x + y end local min_fn = function(x, y) return x < y and x or y end local max_fn = function(x, y) return x > y and x or y end enumer...
--redis-store consistency check local ns = ARGV[1] if ns and #ns > 0 then ns = ns..":" end local concat = function(...) local arg = {...} for i = 1, #arg do arg[i]=tostring(arg[i]) end return table.concat(arg, " ") end local dbg =function(...) redis.call('echo', concat(...)); end local errors={} local er...
-- Settings. local winSize = { 800, 600 } local monitor = 0 -- Constants. local PLAYER_SPEED = 300 local BALL_SPEED = 330 -- Game objects. local playerLeft = { pos = { 0, 0 }, size = { 10, 70 }, score = 0, } local playerRight = { pos = { 0, 0 }, size = { 10, 70 }, score = 0, } local ball = { pos = { 0, 0 }, r...
-- -- floating_terminal.lua -- floating terminal -- local config = require("configs").floating_terminal local wm = require("modules.wm") FloatingTerm = {} function FloatingTerm:get_instance () return hs.appfinder.windowFromWindowTitle(config.title) end function FloatingTerm:spawn_instance () os.execute(config.c...
ENT.Type = "nextbot" ENT.Base = "base_nextbot" ENT.RenderGroup = RENDERGROUP_TRANSLUCENT ENT.IsRapist = true AccessorFuncDT(ENT, "RapistType", "Int", 0) AccessorFuncDT(ENT, "RapeVictim", "Entity", 0) function ENT:GetRaping() return self:GetRapeVictim():IsValid() end ENT.IsRaping = ENT.GetRaping function ENT:GetRa...
return Def.ActorFrame {Name = "YOU_WISH_YOU_WERE_PLAYING_BEATMANIA_RIGHT_NOW"}
local topHeight = 0 if System:iOS() then topHeight = window:statusBarHeight() + window:navBarHeight() end linear = ScrollView(false, true):width(MeasurementType.MATCH_PARENT):marginTop(topHeight) -- 默认状态,Label输入文字样式 action1 = Label():marginTop(5):marginBottom(5):bgColor(Color(121, 45, 122, 1.0)):setGravity(Gravity....
describe("Busted unit testing framework", function() describe("should be awesome", function() local router = require("squall_router").new_router() it("router instance not a nil", function() assert.is_true(router ~= nil) end) it("router should accept correct validators", function() local ...
version = 4 volume = 1.0 randSampContainer = 0
--[[ Extra: I have not tested to see if this works on trading plaza! dont dm me about that! Discord webhook is sent when you crash a server, the information sent is the game.JobId and the amount of players crashed. (I made the script loop close robloxguis so youll know when the server crashed when your screen goes blur...
-- state -- LOVE Jam 2022 -- Theme: Earthquake require ("gametitle") require ("gameover") --[[local state = { [1] = "GameTitle", [2] = "GameLoop", [3] = "GameOver" }]]-- currentState = "GameTitle" baseSpeed = 10 font = love.graphics.newFont("fnt/Kenney High Square.ttf", 40) bigFont = love.graphics.newFont("fnt/Ke...
ENT.Type = "anim" ENT.Base = "base_wire_entity" ENT.PrintName = "Keycard (Wire)" ENT.Author = "Jesse Dubay (adb)" ENT.Contact = "jesse@thefortytwo.net" ENT.Spawnable = false ENT.AdminSpawnable = false
--[[ ------------------------------------------------------------------------------ Peep is licensed under the MIT Open Source License. (http://www.opensource.org/licenses/mit-license.html) ------------------------------------------------------------------------------ Copyright (c) 2014 Landon Manning - LManning17@gma...
GLib.Net.DataType = GLib.Enum ( { UInt8 = 0, UInt16 = 1, UInt32 = 2, UInt64 = 3, Int8 = 4, Int16 = 5, Int32 = 6, Int64 = 7, Float = 8, Double = 9, Vector = 10, Char = 11, Bytes = 12, String = 13, LongString = 14, Boolean = 15, } ) GLi...
if _hx_bit_raw then _hx_bit_clamp = function(v) if v <= 2147483647 and v >= -2147483648 then if v > 0 then return _G.math.floor(v) else return _G.math.ceil(v) end end if v > 2251798999999999 then v = v*2 end; if (v ~= v or math.abs(v) == _G.math.huge) then return nil ...
----------------------------------------- -- LOCALIZED GLOBAL VARIABLES ----------------------------------------- local ZGV = _G.ZGV local BugReport = {} local guiRoot, uiCenter, uiTopLeft, uiBottomRight, uiTopRight, ctEditBox = _G.GuiRoot, _G.CENTER, _G.TOPLEFT, _G.BOTTOMRIGHT, _G.TOPRIGHT, _G.CT_EDITBOX local tinser...
--To include this file, use --dofile('csv.lua') or require('csv') --Function to convert a *SV file to a Lua array --file: the name of the file to read --delim: the delimeter (default ',') function dataToTable(file, delim) --Set initial values if delim == nil then --allow delim to be optional delim = ',...
--######################################################### function CheckBoxClass.ProcessEvents(this) if (WM_MOUSEMOVE.occured) then -- --if (WM_MOUSEMOVE.iPar5==this.obj1Num) then -- --else -- --end end if (WM_LBUTTONDOWN.occured) then if...
local TwoGuysInMotorcycleAi = {}; TwoGuysInMotorcycleAi.__index = TwoGuysInMotorcycleAi function TwoGuysInMotorcycleAi:new(actor) assert(actor, "Is needed a actor to manipulate") local this = { actor = actor, elapsedTime = 0 } return setmetatable(this, TwoGuysInMotorcycleAi) end funct...
----------------------------------- -- Area: Port Bastok -- NPC: Ronan -- Start & Finishes Quest: Out of One's Shell ----------------------------------- require("scripts/globals/settings") require("scripts/globals/titles") require("scripts/globals/quests") local ID = require("scripts/zones/Port_Bastok/IDs") ----------...
package("aqt") set_kind("binary") set_homepage("https://github.com/miurahr/aqtinstall") set_description("aqt: Another (unofficial) Qt CLI Installer on multi-platforms") set_license("MIT") if is_host("windows") then add_configs("shared", {description = "Download shared binaries.", default = ...
local void = require('gitsigns.async').void local scheduler = require('gitsigns.async').scheduler local config = require('gitsigns.config').config local mk_repeatable = require('gitsigns.repeat').mk_repeatable local popup = require('gitsigns.popup') local util = require('gitsigns.util') local manager = require('gitsig...
DEFINE_BASECLASS("tfa_nmrih_base") local lastresortnanim = -2 SWEP.Type = "Melee" SWEP.LuaShellEject = false SWEP.Primary.Blunt = false SWEP.Primary.Damage = 60 SWEP.Primary.Reach = 75 SWEP.Primary.RPM = 60 SWEP.Primary.SoundDelay = 0.2 SWEP.Primary.Delay = 0.35 SWEP.Primary.Window = 0.3 SWEP.Secondary.Blunt = fal...
local addonName, G = ... function G.LocalToServer(t) return t ~= 0 and GetServerTime() + t - GetTime() or 0 end function G.ServerToLocal(t) return t ~= 0 and GetTime() + t - GetServerTime() or 0 end function G.Eventer(handlers) local frame = CreateFrame('Frame') for ev in pairs(handlers) do frame:Registe...
local QuestGroupsByName = {} local buttonPool = CreateFramePool("Button", QuestMapFrame.QuestsFrame, "ZQA_AbandonButton") local function Slug(value) return value:lower():gsub('[^a-z]', '') end local function PlaceButton(parent, offset, title, tooltip, slug) title = title or parent:GetText() tooltip = tool...
local E = Brazier.Equals local function _testArray(suite, subSuite, equals) TestSuite.assert(suite)(subSuite)(1)(equals( {})( {})) TestSuite.assert(suite)(subSuite)(2)(equals( { 1 })( { 1 })) TestSuite.assert(suite)(subSuite)(3)(equals({ 1, 2, 3 })({ 1, 2, 3 })) TestSuite.assert(suit...
local o = require("buftabline.options") local add_commands = require("buftabline.add-commands") local reset = function() vim.cmd("comclear") end describe("add_commands", function() it("should create commands", function() reset() add_commands() assert.equals(vim.fn.exists(":ToggleBuftabli...
local M = { } M.trim = function(path) if (string.match(path, "[/\\%.]")) == nil then return "" else return string.match(path, "(.-)[/\\%.]?[^%./\\]+$") end end return M
local cmd = {} cmd.title = "Rocket" cmd.description = "Rocket a player into the sky; they will explode." cmd.author = "Nub" cmd.timeCreated = "Sunday, May 24 2020 @ 12:20 AM CST" cmd.category = "Fun" cmd.call = "rocket" cmd.usage = "<player>" cmd.server = function(caller, args) local targs = nadmin:FindPla...
id = 'V-38677' severity = 'high' weight = 10.0 title = 'The NFS server must not have the insecure file locking option enabled.' description = 'Allowing insecure file locking could allow for sensitive data to be viewed or edited by an unauthorized user.' fixtext = 'By default the NFS server requires secure file-lock req...
ESX = nil TriggerEvent('esx:getSharedObject', function(obj) ESX = obj end) RegisterCommand('setped', function(source, args) if source == 0 then local id = args[1] if id then local tPlayer = ESX.GetPlayerFromId(id) if tPlayer ~= nil then TriggerClientEvent('Tomci0:OpenPedMenu', id) els...
--[[ Copyright (c) 2012 Benjamin Halsted <bhalsted@gmail.com> 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, merg...
-- troubleshoot-item.lua --@ module = true --[====[ troubleshoot-item ================= Print various properties of the selected item. Sometimes useful for troubleshooting issues such as why dwarves won't pick up a certain item. ]====] function find_specific_ref(object, type) for i, ref in pairs(object.specific_...
This is a test for lk. The secret word is 'adagio'.