content
stringlengths
5
1.05M
function digital_root(n, base) p = 0 while n > 9.5 do n = sum_digits(n, base) p = p + 1 end return n, p end print(digital_root(627615, 10)) print(digital_root(39390, 10)) print(digital_root(588225, 10)) print(digital_root(393900588225, 10))
-- Generated by github.com/davyxu/tabtoy -- Version: 3.1.0 return { init = function( g ) g.ExampleKV = { { ServerIP = "8.8.8.8", ServerPort = 1024, GroupID = {10,20}, }, } return g end }
local BasePlugin = require "kong.plugins.base_plugin" local cjson = require "cjson" local DispatchTransformerHandler = BasePlugin:extend() function DispatchTransformerHandler:new() DispatchTransformerHandler.super.new(self, "dispatch-transformer") end local function iter(config_array) return function(config_arra...
--- --- uiconfig.lua --- --- Copyright (C) 2018-2019 Xrysnow. All rights reserved. --- local function uiconfig() end
--- test module for demonstrating app.require_here() local bar = {} function bar.name () return 'bar' end return bar
-------------------------------------------------------------------------------- -- ダンジョンの通路クラスです. -- 通路の点の繋がりを保持します. -------------------------------------------------------------------------------- -- import local class = require "flower.class" -- class local DungeonRoad = class() --- -- コンストラクタ function DungeonRoa...
--- === hs.expose === --- --- Keyboard-driven expose replacement/enhancement --- --- Warning: this module is still somewhat experimental. --- Should you encounter any issues, please feel free to report them on https://github.com/Hammerspoon/hammerspoon/issues --- or #hammerspoon on irc.freenode.net --- --- With this mo...
--! --! \addtogroup progress progress widget --! \brief progress widget界面组件,实现进度条控件。 --! @{ --! local vg = require "vg" local ui = require "ui" return { _round = 5, onInit=function(self,themes) self:setSize(80,20) self._color = themes.color self._colorBG = themes.colorBG self._progress = 0 end, onRelease=f...
local deprecator = function () SU.deprecated("SILE.settings.*", "SILE.settings:*", "0.13.0", "0.14.0") return SILE.settings end local settings = pl.class() function settings:_init() self.state = {} self.declarations = {} self.stateQueue = {} self.defaults = {} self:declare({ parameter = "document....
module ('base.element', package.seeall) require 'lux.object' require 'lux.functional' require 'content.properties' require 'content.triggers' local elements = {} local element = lux.object.new { name = 'Unnamed Element' } getmetatable(_M).__call = function (_, name) if elements[name] then return...
AddCSLuaFile() function EFFECT:Init(data) local ent = data:GetEntity() local att = data:GetAttachment() local origin = self:GetTracerShootPos2(data:GetOrigin(), ent, att) - data:GetNormal() * 20 local emitter = ParticleEmitter(origin) local particle = emitter:Add("weapons/stalker_cop/muzzleflash_x", o...
local fs = require('diagnosticls-configs.fs') -- TODO -- This may or may not work? May want to start implementing some tests return { sourceName = 'flow', command = fs.get_executable('flow', 'node'), debounce = 100, args = { 'check-contents', '--json', '<', '%filepath' }, parseJson = { errorsRoot = 'erro...
--[[ Upbit Open API ## REST API for Upbit Exchange - Base URL: [https://api.upbit.com] - Official Upbit API Documents: [https://docs.upbit.com] - Official Support email: [open-api@upbit.com] OpenAPI spec version: 1.0.0 Contact: ujhin942@gmail.com Generated by: https://github.com/swagger-api/swagger-codeg...
markup = _Awesome.lain.util.markup cpuicon = _Awesome.wibox.widget.imagebox() cpuicon:set_image(_Awesome.beautiful.widget_cpu) cpuwidget = _Awesome.lain.widgets.cpu({ settings = function() widget:set_markup(markup("#e33a6e", cpu_now.usage .. "% ")) end })
----------------------------------- -- Area: Southern San d'Oria -- NPC: Sobane -- Starts and Finishes Quest: Signed in Blood -- Involved in quest: Sharpening the Sword, Riding on the Clouds -- !pos -190 -3 97 230 -- csid: 52 732 733 734 735 736 737 738 739 740 741 ------------------------------------- requi...
-- Copyright (c) Facebook, Inc. and its affiliates. PLUGIN = nil CHUNKS_TO_LOAD = __CHUNKS_TO_LOAD__ hasPlayerJoined = false -- One second is 20 ticks, allow 15 minutes inactive MAX_INACTIVE_TICK = 20 * 60 * 15 function Initialize(Plugin) Plugin:SetName("ShutdownIfNoPlayerJoin") PLUGIN = Plugin hasPl...
--[[ Copyright (c) 2007 Gordon Gremme <gremme@zbh.uni-hamburg.de> Copyright (c) 2007 Center for Bioinformatics, University of Hamburg 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 permissi...
--[[ © 2021 FedeIlLeone EditStats - EditStats server side module Functions: EditStats.Run(admin, data) --> [Success] * Parameter description for "EditStats.Run()": admin [Player] -- Player instance, normally must be an admin data [Table] -- Table with all additional data for the module ...
Talk(0, "小二哥,听说你们正在办什么无量山自助旅游的,是不是啊?", "talkname0", 1); Talk(106, "这位客倌,您真是有眼光.这无量山在我们大理境内,可是风景第一的好去处.怎样,想不想参加呀?", "talkname106", 0); Talk(0, "要怎么参加呢?", "talkname0", 1); Talk(106, "办法很简单,但要先缴报名费100两.", "talkname106", 0); Talk(0, "这么贵?", "talkname0", 1); Talk(106, "还嫌贵,我们可是打了折.", "talkname106", 0); ModifyEvent(-2, -2, -...
--███████╗███╗ ██╗██████╗ ███████╗██████╗ -- --██╔════╝████╗ ██║██╔══██╗██╔════╝██╔══██╗-- --█████╗ ██╔██╗ ██║██║ ██║█████╗ ██████╔╝-- --██╔══╝ ██║╚██╗██║██║ ██║██╔══╝ ██╔══██╗-- --███████╗██║ ╚████║██████╔╝███████╗██║ ██║-- --╚══════╝╚═╝ ╚═══╝╚═════╝ ╚══════╝╚═╝ ╚═╝-- include( "groupchange/config.l...
local outerFolder = (...):match('(.-)[^%.]+$') local Transformable = require(outerFolder .. 'utils.transformable') local classUtilities = require(outerFolder .. 'utils.class-utilities') local rayMarchingShader = love.graphics.newShader('src/ray-marcher.frag') local shaderImage = love.graphics.newImage(love.image.newI...
require "names" data:extend({{ type = "font", name = CATEGORY_FONT_NAME, from = "default-bold", size = 12 }})
ENT.RenderGroup = RENDERGROUP_OPAQUE ENT.Type = "vehicle" ENT.Base = "fighter_base" ENT.PrintName = "Geonosian Transport" ENT.Author = "Servius" ENT.Category = "Star Wars Vehicles: CIS"; list.Set("SWVehiclesEU", ENT.PrintName, ENT); ENT.AutomaticFrameAdvance = true ENT.Spawnable = false; ENT.AdminSpawnable = false; ...
i = 0; for _,__ in pairs(require("liblncurses")) do print(_..": "..type(__));i = i + 1; end print("Total: "..tostring(i)); print("Lua version: ".._VERSION); print("lncurses version: ".._LNCURSES_VERSION);
local BasePlugin = require "kong.plugins.base_plugin" local PathReplacerHandler = BasePlugin:extend() PathReplacerHandler.PRIORITY = 801 function PathReplacerHandler:new() PathReplacerHandler.super.new(self, "path-replacer") end function PathReplacerHandler:access(conf) PathReplacerHandler.super.access(self) ...
local function Attack(cooldown) local object = {} object.timer = cooldown object.can_attack = true object.update = function(dt) if object.can_attack == false then object.timer = object.timer - dt end if object.timer <= 0 then object.can_attack = true end end object.attack = function(dir) if obj...
local hello_world = {} function hello_world.hello( name ) if not name or name == '' then name = 'world' end return 'Hello, ' .. name .. '!' end return hello_world
--Entity function CEntityInstance:SetNetworkableEntityInfo(key, value) local t = CustomNetTables:GetTableValue("custom_entity_values", tostring(self:GetEntityIndex())) or {} t[key] = value CustomNetTables:SetTableValue("custom_entity_values", tostring(self:GetEntityIndex()), t) end function CEntityInstance:Clear...
function onCreate() makeLuaSprite('bedroom2', 'barkey/bedroom2', 0, -100); setScrollFactor('bedroom2', 0.9, 0.9); scaleObject('bedroom2', 0.75, 0.7); addLuaSprite('bedroom2', false); makeLuaSprite('bedroom3', 'barkey/bedroom3', -300, -100); setScrollFactor('bedroom3', 0.9, 0.9); scaleObject('bedroom3', 0.75, 0.7...
local testcase = require('testcase') local chdir = require('testcase.filesystem').chdir local getcwd = require('getcwd') local DIRS = { 'foo', 'bar', 'baz', } local TESTDIR = table.concat(DIRS, '/') local function exec(cmd) if string.find(_VERSION, '5.1', nil, true) then assert(os.execute(cmd)...
--SAFETRIM -- Compile code and remove original .lua files. -- This only happens the first time afer the .lua files are uploaded. -- Skip init.lua! return function(filename) local reboot = false local function compileAndRemoveIfNeeded(f) if file.exists(f) then print('Compiling:', f) ...
slot0 = class("ShipProfileSkinBtn") slot0.Ctor = function (slot0, slot1) slot0._tf = slot1 slot0.sctxt = slot0._tf:Find("mask/Text"):GetComponent("ScrollText") slot0.lockTF = slot0._tf:Find("lock") slot0.selected = slot0._tf:Find("selected") slot0.timelimitTF = slot0._tf:Find("timelimit") slot0.timelimitTxt = sl...
-- invoke as Pandoc writer -- write Javascript file for website search functions and data package.path = package.path .. ';' .. string.gsub(PANDOC_SCRIPT_FILE, '/[^/]+$', '') .. '/agsman.lua' local agsman = require('agsman') function render_keywords(keywords) local buffer = {} local entry = {} -- sort the ke...
--[[ --MIT License -- --Copyright (c) 2019 manilarome --Copyright (c) 2020 Tom Meyers -- --Permission is hereby granted, free of charge, to any person obtaining a copy --of this software and associated documentation files (the "Software"), to deal --in the Software without restriction, including without limitation the ...
local lure = require(select('1', ...):match(".-lure%.")..'init') -- -- Define class -- local class = lure.lib.upperclass:define('lure.dom.Node') -- -- A NamedNodeMap containing the attributes of this node -- class.public : attributes { setter='protected'; type='lure.dom.NamedNodeMap'; } -- -- Returns the abs...
-----basically just gets all the settings and stuff, then calls the actual program Timer = require "timer" require("Settings/UISettings") require("Class") require("GUIElements/GUIMain") require("Data/UI/HudLib") require("Data/CoreDefs/CoreAPI") require("Data/CoreDefs/GameObjDefs") require("Data/Core")
local Event = require("api.Event") local Mef = require("api.Mef") local actions = { "stepped_on", -- on_stepped_on, elona_sys.on_mef_stepped_on "stepped_off", -- on_stepped_off, elona_sys.on_mef_stepped_off { action_name = "updated", event_id = "base.on_mef_updated" }, { action_name = "removed", event_id...
object_mobile_nym_themepark_raynar_cath = object_mobile_shared_nym_themepark_raynar_cath:new { } ObjectTemplates:addTemplate(object_mobile_nym_themepark_raynar_cath, "object/mobile/nym_themepark_raynar_cath.iff")
return function(object: any, method: string?) if not object then return end if method then object[method](object) return end object:Destroy() end
local function runAffects(player,name,dtime) if ( affects._affectedPlayers[name] ) ~= nil then for affectid,a in pairs(affects._affectedPlayers[name]) do applyAffect(name,affectid) end end end adventuretest.register_pl_hook(runAffects,15) local function doSave() affects.saveAffects() minetest.after(affect...
data:define_type("item_chip") data:add_multi( "core.item_chip", { { id = "empty", legacy_id = 0, source = { x = 0, y = 0, } }, { id = "projectile_arrow", legacy_id = 1, source = { x = 48, ...
ENT.Base = "dronesrewrite_base" ENT.DrrBaseType = "walker" ENT.Type = "anim" ENT.PrintName = "Walking Tank" ENT.Spawnable = true ENT.AdminSpawnable = true ENT.Category = "Drones Rewrite" ENT.UNIT = "WT" ENT.Model = "models/dronesrewrite/walkerart/walkerart.mdl" ENT.SpawnHeight = 64 ENT.Weight = 3000 ENT.OverlayName...
eye = false; ceye = false; Time = 0; function onCreate() cli = 0; rx = getRandomInt('0', '500', true); ry = getRandomInt('0', '500', true); rxx = getRandomInt('0', '500', true); ryy = getRandomInt('0', '500', true); Dodged = false; setPropertyFromClass('flixel.FlxG', 'mouse.visible', true); a = 0; end func...
project "EASTL" location "." kind "StaticLib" language "C++" targetdir ("../../../bin/" .. outputdir .. "/%{prj.name}") objdir ("../../../bin/obj/" .. outputdir .. "/%{prj.name}") files { "include/EABase/**.h", "include/EASTL/**.h", "include/EASTL/**.hpp", "...
-- See LICENSE for terms local Translate = ChoGGi.ComFuncs.Translate local SettingState = ChoGGi.ComFuncs.SettingState local Strings = ChoGGi.Strings local Actions = ChoGGi.Temp.Actions local c = #Actions local LocaleInt = LocaleInt -- menu c = c + 1 Actions[c] = {ActionName = Translate(692--[[Resources]]), ActionMe...
local AIComponent = class() function AIComponent:set_status_text_key(key, data) self._sv.status_text_key = key if data and data['target'] then local entity = data['target'] if type(entity) == 'string' then local catalog_data = stonehearth.catalog:get_catalog_data(entity) if ...
local Races = {} RegisterServerEvent('qb-streetraces:NewRace') AddEventHandler('qb-streetraces:NewRace', function(RaceTable) local src = source local RaceId = math.random(1000, 9999) local xPlayer = QBCore.Functions.GetPlayer(src) if xPlayer.Functions.RemoveMoney('cash', RaceTable.amount, "streetrace-cr...
-- NVM功能模块使用的Config文件 -- Author:LuatTest -- CreateDate:20201016 -- UpdateDate:20210520 module(..., package.seeall) strPara = "LuatTest1" numPara = 1 boolPara = false personTablePara = {"name1", "age1", "sex1"} scoreTablePara = { chinese = 1, math = 2, english = 3 } manyTablePara = { table1 = { ...
require("config") --Changes require("prototypes.changes") require("prototypes.recipe-category") --Pumpjack require("prototypes.pump-2") require("prototypes.pump-3") require("prototypes.water-pumpjack") --Mining require("prototypes.mining-range-1") require("prototypes.mining-range-2") require("prototypes.mining-range-3"...
local basePath = minetest.get_modpath("twomt_tinker") dofile(basePath .. "/nodes.lua") dofile(basePath .. "/craftitems.lua") dofile(basePath .. "/crafts.lua") dofile(basePath .. "/tools.lua") dofile(basePath .. "/ores.lua")
----------------------------------------------------------------------------- -- DailyNotes is an Addon for Runes of Magic -- It will show you additional information in tooltips and on bulleting boards. -- feedback to: viertelvor12@gmx.net -- -- License: MIT/X -------------------------------------------------------...
--[[================================================ Anti Noclip PVP - Joske @ nigelarmy.com Modified & re-uploaded - Linkjay @ linkjay.com Originated 3/15/16 Re-uploaded 2/2/17 V2 - Zafiro#2602 - 1/2/19 12PM - 1/3/19 5AM Last modified: 1/3/19 --]] --====================================...
if string.lower(RequiredScript) == "lib/managers/hud/huddriving" then HUDDriving.VEHICLES = { ["Longfellow"] = { ["driver"] = { scale_x = -0.2, scale_y = -0.15, is_seat = true }, ["passenger_front"] = { scale_x = 0.2, scale_y = -0.15, is_seat = true }, ["passenger_back_left"] = { scale_x = -0.2, ...
function opponentNoteHit() setPropertyFromClass('PlayState', 'SONG.speed', math.random(1, 5)) end
-- -- Based heavily on MiddleClick, https://github.com/artginzburg/MiddleClick-Catalina -- local touchdevice = require("hs._asm.undocumented.touchdevice") local menubar = require("hs.menubar") local eventtap = require("hs.eventtap") local canvas = require("hs.canvas") local settings = require("hs.settin...
project "ImGui" kind "StaticLib" language "C++" cppdialect "C++17" targetdir ("%{wks.location}/bin/" .. outputVendorDir .. "/%{prj.name}") objdir ("%{wks.location}/temp/" .. outputVendorDir .. "/%{prj.name}") files { "backends/imgui_impl_glfw.h", "backends/imgui_impl_glfw.cpp", "backends/imgui_i...
local StackingWindow = require('code_action_menu.windows.stacking_window') local TextDocumentEditStatusEnum = require( 'code_action_menu.enumerations.text_document_edit_status_enum' ) local function get_text_document_edit_status_icon(status) return ( status == TextDocumentEditStatusEnum.CREATED and '*' ...
local awful = require('awful') local wibox = require('wibox') local gears = require("gears") local beautiful = require("beautiful") local json = require("json") local utils = require("utils") local owfont = require('../owfont') --local http = require("socket.http") local IPINFO_TOKEN = '7a7b7d106c9490' local IPINFO_UR...
local gate = {} gate.name = "pandorasBox/gate" gate.depth = -9000 gate.placements = { name = "gate", data = { inverted = false, flag = "", texture = "objects/pandorasBox/gate/" } } gate.justification = {0.0, 0.0} gate.offset = {0, -4} function gate.texture(room, entity) local ...
require 'socket' require('engine' .. PATH_SEPARATOR .. 'lib' .. PATH_SEPARATOR .. 'newFuncs') _STARTUP_TIME=gettime() require 'config' LOGGER_GEN=require('engine' .. PATH_SEPARATOR .. 'lib' .. PATH_SEPARATOR .. 'logging.rolling_file') local logName='logs' .. PATH_SEPARATOR .. 'luaHIE.log' LOGGER=LOGGER_GEN(logName, M...
local modDir, modName = MoreRealisticDLCs.modDir, MoreRealisticDLCs.modName; -------------------------------------------------- local prmGetXMLFn = { bool = getXMLBool, flt = getXMLFloat, int = getXMLInt, str = getXMLString }; -- GET VEHICLE MR DATA function MoreRealisticDLCs:getMrData(vehicleDataPath, dlcName) ...
require("hall/onlineSocket/onlineSocketManager"); Run = class(); Run.ctor = function(self) end --保持会话 设置发送指令定时器到时间 发送指令 Run.keepAlive = function(self) EventDispatcher.getInstance():register(Event.Pause,Run,Run.onKeepAliveCallBack); EventDispatcher.getInstance():register(Event.Resume,Run,Run.onKeepAliveC...
--[[ 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...
for i,v in pairs(game.Players:GetChildren()) do if v ~= game.Players.LocalPlayer.Character.Torso then base = Instance.new("BillboardGui", workspace.Camera) local esP = Instance.new("Frame", base) -- Billboard Stuff base.AlwaysOnTop = true base.Enabled = true base.Size = UDim2.new(4.5,0,6,0) base.Name = "...
package.path = "../LjES/?.lua;" .. package.path local demo = require("demo") demo.screen(0, 0) demo.backgroundColor(0.2, 0.2, 0.4) local aSpace = demo.getSpace() local eye = aSpace:addNode(nil, "eye") eye:setPosition(0, 0, 30) local shape = Shape:new() shape:truncated_cone(8, 2, 8, 16) shape:endShape() shape:shader...
local skynet = require "skynet" local gateserver = require "snax.gateserver" --使用netpack进行解包 local netpack = require "skynet.netpack" --必须提供一张表,表里面定义connect、message等相关回调函数 local handler = {} local CMD = {} -- 存储命令 local agents = {} -- 存储agent使用 skynet.register_protocol { name = "client", id = skynet.PTYPE_C...
MOD_LOG_RELEASE = 0 MOD_LOG_DEBUG = 1 local log_level = MOD_LOG_RELEASE global.messages = {} local function mod_print(message) if not game or #game.players <= 0 then global.messages = global.messages or {} table.insert(global.messages, message) else game.print(MOD_STRING .. ": " .. message) end e...
if CLIENT then local function getTime() return os.time()+GetGlobalFloat("MetrostroiTimeOffset",0) end function Metrostroi.GetTimedT(notsync) local T0 = GetGlobalFloat("MetrostroiT0",os.time())+GetGlobalFloat("MetrostroiTY") local T1 = GetGlobalFloat("MetrostroiT1",CurTime()) ...
--------- -- serialized mapblock validation utilities --- validate a single mapblock file -- @param filename the filename of the mapblock -- @return success -- @return error-message if success is false function mapblock_lib.validate(filename) local mapblock = mapblock_lib.read_mapblock(filename .. ".bin") if n...
script_name('Spotlight Example') local mad = require 'MoonAdditions' function main() while true do wait(0) if isPlayerPlaying(PLAYER_HANDLE) then local x, y, z = getCharCoordinates(PLAYER_PED) for _, object in ipairs(mad.get_all_objects(x, y, z, 300)) do local model = getObjectModel(object) if model...
marssurvive={breath_timer=0,player_sp={},air=21,player_space={}, itemdroptime=tonumber(minetest.setting_get("item_entity_ttl")), aliens={},aliens_max=math.random(7,14)} if marssurvive.itemdroptime=="" or marssurvive.itemdroptime==nil then marssurvive.itemdroptime=880 else marssurvive.itemdroptime=hook_tmp_t...
return { version = "1.1", luaversion = "5.1", orientation = "orthogonal", width = 100, height = 100, tilewidth = 32, tileheight = 32, properties = {}, tilesets = { { name = "tilemap2", firstgid = 1, tilewidth = 32, tileheight = 32, spacing = 0, margin = 0, ...
-- 先这样判断是不是Windows if package.config:sub(1, 1) == "\\" then package.cpath = package.cpath .. ";../colib/?.dll" else package.cpath = package.cpath .. ";../colib/?.so" end package.path = package.path ..";../colib/?.lua" local oset = require "oset" local dbg = require "dbg" ---------------------------------...
local function decorate(cls) -- rotate root node -- @param quaternion Ogre::Quaternion function cls:rotate(quaternion) self.render:rotate(quaternion) end -- translate root node -- @param vector Ogre::Vector3 function cls:translate(vector) self.render.root:translate(vector, OgreNode.TS_LOCAL) en...
---------------------------------------------------------------------------------------------------- -- -- Copyright (c) Contributors to the Open 3D Engine Project. For complete copyright and license terms please see the LICENSE at the root of this distribution. -- -- SPDX-License-Identifier: Apache-2.0 OR MIT -- -- -...
local TimerSystem = class("TimerSystem", System) function TimerSystem:update(dt) for index, value in pairs(self.targets) do value:get("Timing").timer = value:get("Timing").timer+dt end end function TimerSystem:requires() return {"Timing", "Position"} end return TimerSystem
require "stategraphs/SGtentacle" local assets= { Asset("ANIM", "anim/tentacle.zip"), Asset("SOUND", "sound/tentacle.fsb"), } local prefabs = { "monstermeat", "tentaclespike", "tentaclespots", } SetSharedLootTable( 'tentacle', { {'monstermeat', 1.0}, {'monstermeat', 1.0}, {'tentaclesp...
--海晶乙女コーラルトライアング -- --Script by Trishula9 function c100426033.initial_effect(c) --link summon aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkSetCard,0x12b),2) c:EnableReviveLimit() --to hand local e1=Effect.CreateEffect(c) e1:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND) e1:SetType(EFFECT_TYPE_IGNITION)...
SWEP.Base = "tfa_3dscoped_base" -- [[ BASIC_INFO ]] -- [ Spawnmenu ] SWEP.PrintName = "DC-15X" SWEP.Category = "TFA Star Wars" SWEP.Spawnable = true SWEP.AdminSpawnable = false -- [ HUD ] SWEP.DrawCrosshair = true SWEP.DrawCrosshairIS = false SWEP.Manufacturer = "" SWEP.Aut...
VehicleSpawnerManager = { --[[ Property descriptions: initialMinVehicles - the minimum number of vehicles from this category that will exist on system startup abandonedTimer -- how long until an abandoned vehicle will be removed from gameplay (in seconds) abandonedRespawnTimer -- how long until an abandoned vehicl...
local quickHelp = {} local helpBg = nil local HELP_WIDTH, HELP_HEIGHT = 400,300 local helpStrKeys = [[Space : W,A,S,D : Cursor Keys : Arrow Keys : Q,E : C : + : - : m : F5 : F1 : h : ]] local helpStr = [[Tactical overlay Move view Move view Move view Zoom view Toggle console Speed up Slow down Toggle map coordinates...
--[[ Animation Controller - Elemental v1.0 by: standardcombo, blackdheart Controls the animations for an NPC based on the Skeleton Animated Mesh. Changes in animation occur in response to movement and state machine changes. --]] local MESH = script:GetCustomProperty("AnimatedMesh"):WaitForObject() lo...
return function() local au = require('_.utils.au') vim.g.startify_padding_left = 5 vim.g.startify_relative_path = 1 vim.g.startify_fortune_use_unicode = 1 vim.g.startify_change_to_dir = 0 vim.g.startify_change_to_vcs_root = 1 vim.g.startify_update_oldfiles = 1 vim.g.startify_use_env = 1 vim.g.startif...
---@meta ---@class cc.Texture2D :cc.Ref local Texture2D={ } cc.Texture2D=Texture2D ---* Gets max T. ---@return float function Texture2D:getMaxT () end ---* ---@param alphaTexture cc.Texture2D ---@return self function Texture2D:setAlphaTexture (alphaTexture) end ---* Returns the pixel format.<br> ---* since v2....
FrenchRP.hookStub{ name = "playerAFKDemoted", description = "When a player is demoted for being AFK.", parameters = { { name = "ply", description = "The player being demoted.", type = "Player" } }, returns = { { name = "shouldDe...
local MAJOR, MINOR = "AceGUI-3.0-Search-EditBox", 1 local lib, oldminor = LibStub:NewLibrary(MAJOR,MINOR) if not lib then return end local AceGUI = LibStub("AceGUI-3.0") local function Constructor(options) local self = AceGUI:Create("SearchEditBox_Base") self.options = type(options) == "table" and options or { GetV...
if minetest.get_modpath("default") then minetest.register_craft({ output = "hopper:hopper", recipe = { {"default:steel_ingot","default:chest","default:steel_ingot"}, {"","default:steel_ingot",""}, } }) minetest.register_craft({ output = "hopper:chute", recipe = { {"default:steel_ingot","default...
local Firebug = Class(function(self, inst) self.inst = inst self.time_to_fire = 60 self.inst:StartUpdatingComponent(self) end) function Firebug:OnUpdate(dt) if self.inst.components.sanity and self.inst.components.sanity:GetPercent() < TUNING.WILLOW_LIGHTFIRE_SANITY_THRESH then self.time_to_fir...
--[[ Author: Arbiter Clockwork Version: 0.88a. Credits: A small part of this code comes from kurozael's DoorCommands Plugin. Heavily based off the works of Cervidae Kosmonaut in Faction Doors. --]] local PLUGIN = PLUGIN; -- Called when Clockwork has loaded all of the entities. function PLUGIN:ClockworkInitPo...
function debug_draw_hitbox(pos, hit) if not DEBUGGING then return end local x1 = pos.x + hit.offx local y1 = pos.y + hit.offy local x2 = x1 + hit.width local y2 = y1 + hit.height rect(x1, y1, x2, y2, 12) end function are_hitboxes_colliding( pos_a, hit_a, pos_b, hit_b) local ax1 = pos_a.x + hit_a.offx loca...
-- Aero Server -- Crazyman32 -- July 21, 2017 local AeroServer = { Services = {}; Modules = {}; Shared = {}; } local mt = {__index = AeroServer} local servicesFolder = game:GetService("ServerStorage").Aero.Services local modulesFolder = game:GetService("ServerStorage").Aero.Modules local sharedFolder = game:Get...
local Azimuth, GateFounderConfig -- client/server local gateFounder_window, gateFounder_xBox, gateFounder_yBox, gateFounder_coordsLabel, gateFounder_distanceLabel, gateFounder_maxDistanceLabel, gateFounder_priceLabel, gateFounder_foundGateBtn, gateFounder_stationButtons -- UI local PassageMap, gateFounder_x, gateFounde...
local M = {} local p = require('monokai.palette') local function load_highlights(highlights) for group_name, group_settings in pairs(highlights) do vim.api.nvim_set_hl(0, group_name, group_settings) end end local hl = { vim = { common = { ColorColumn = { bg = p.gray1, fg = p.none,...
local PANEL = {} AccessorFunc( PANEL, "NumSlider", "NumSlider" ) AccessorFunc( PANEL, "m_fSlideX", "SlideX" ) AccessorFunc( PANEL, "m_fSlideY", "SlideY" ) AccessorFunc( PANEL, "m_iLockX", "LockX" ) AccessorFunc( PANEL, "m_iLockY", "LockY" ) AccessorFunc( PANEL, "Dragging", "Dragging" ) AccessorFunc( PA...
regroup = regroup or {} local modloader = {} function modloader.loadmod(mod) log("loading: %s", mod) local _log = log log = regroup.logging.makelog(mod) require("mods/" .. mod) --restore log log = _log end function modloader.loadmods(modlist, orderlist) for i=1,#orderlist,1 do local mod = modlist[orderli...
---------------------------------------------------------------------------------------------------------------------------------------------------- DefineClass.Sanatorium = { __parents = {"ElectricityConsumer", "TrainingBuilding"}, properties = { }, training_type = "curing", max_traits = 3, total_cured = 0, } ...
-- Compatibility with Lua 5.1 with no built-in bitwise operations. if not pcall(require, 'bit32') then -- The BitOp library required. require('bit') bit32 = bit end local bnot, band, bor = bit32.bnot, bit32.band, bit32.bor local lrotate, rrotate = bit32.lrotate or bit32.lshift, bit32.rrotate or bit32.rshif...
-- hot模式只适合本地调试,可以使用package打包为dist上线(参考example) -- 下面是注册你的本机路径,识别lua目录的加载 package.path = package.path .. ";Z:\\Workspace\\war3\\hunzsig-warcraft3\\h-lua\\?.lua" package.path = package.path .. ";Z:\\Workspace\\war3\\hunzsig-warcraft3\\w3x-test-breakdown\\?.lua" require "loader"
require 'scripts.utility' require 'scripts.native' require 'scripts.common' require 'scripts.blizzard' require 'scripts.war3map' main()
---Data passed to hit callbacks, such as the various functions in SkillListeners.lua ---@class HitData local HitData = { ID = "HitData", Target = "", Attacker = "", Skill = "", Damage = 0, Handle = 0, IsFromSkll = false, ---@type boolean The hit did not miss. Success = true } HitData.__index = HitData ---@par...