content
stringlengths
5
1.05M
-- luacheck: std lua53 if _VERSION < 'Lua 5.3' then require ('compat53') end local bit32 = require (jit and 'bit' or 'bit32') -- luacheck: globals jit -- Credit to HiveWE for format and information: -- - https://github.com/stijnherfst/HiveWE/wiki/war3map.w3e-Terrain local W3E = {} local unpack = string.unpack local...
--JSON syntax parser --Push the current state into the states stack local function pushState(state) state.stack[#state.stack + 1] = state.current end --Pop the current state from the states stack local function popState(state) state.current = state.stack[#state.stack] state.stack[#state.stack] = nil end ...
local skynet = require "skynet" local sname = require "bw.sname" local M = {} setmetatable(M, { __index = function(t, k) local v = rawget(t, k) if v then return v else return function(...) return skynet.call(sname.REDIS, "lua", k, ...) ...
require('nvim-treesitter.configs').setup { textobjects = { select = { enable = false, keymaps = { -- You can use the capture groups defined in textobjects.scm ["ob"] = "@block.outer", ["ib"] = "@block.inner", }, }, }, }
-- LoveHud/Hud.lua module("LoveHud.Hud", package.seeall) require "LovePainter/Border" require "Tools/Object" require "Math/Position" require "Math/Polygon" require "LoveHud/HudObject" local Hud = {} function Hud.initialize(pos,id) local obj = LoveHud.Hud.getObj(pos, id) -- Extends Hud attributes return Ncr7.tOb...
local module = { authenticationRequired = true; }; function module.run(authentication,groupId,input,callback) local run = function(input) if(input ~= nil) then local userId = input; local endpoint = "https://groups.roblox.com/v1/groups/"..groupId.."/join-requests/users/"..userId; local response,body = api...
function Server_Created(game, settings) settings.OneArmyStandsGuard = false end
vRPclient = Tunnel.getInterface("vRP", "utils") vRPUtilS = Tunnel.getInterface("utils", "utils") vRPUtil = {} Tunnel.bindInterface("utils", vRPUtil) Proxy.addInterface("utils", vRPUtil) local status = {} local playerStress = 0.0 local showPlayerList = false local markers = {} -- * Class local Utils = cl...
require("lua/game/quest") require("lua/game/citizens/citizen") Town = {} Town.__index = Town setmetatable(Town, { __index = Town, __call = function (cls, ...) local self = setmetatable({}, cls) self:_init(...) return self end, }) function Town:_init() self.name = "" self.townSize = 0 self.day = ...
require "plugins.plugin-lua-coc-data" require "plugins.plugin-lua-coc-speech" local function tolog(s, r) io.write("\t+ stage ( "..string.format("%s", s).." ) ret ( "..string.format("%s", r).." )\n") end local function isreload() local ret io.write("-- begin isreload ( 000 )\n") ret = LuaObject...
ui_page "/Users/ash/Personal/Repositories/gta/ui-template/html/index.html" files{"/Users/ash/Personal/Repositories/gta/ui-template/html/96c342ee6d5d50fc5b3fa76a6f6932b9.ttf","/Users/ash/Personal/Repositories/gta/ui-template/html/main.js","/Users/ash/Personal/Repositories/gta/ui-template/html/index.html"}
local SceneMahJong = {} ----------------------------- START ----------------------------------------- -- Declare Global Tables of Game Levels = {} Grid = {} Img = {} MahJong = {} -- local BM = BouttonManager.newBM() local Boutton = {} -- local AM = AudioManager.newAM() local sound_mahjongFind = AM:addSound("scenes/MahJ...
return { -- Constants constSmokeTimer = 0.5, constVYThreshold = 0.60, constGravity = 0.6, -- enumerators basetypeFuel = 2, -- TODO: Get rid of those by doing something similar to scripts/modules.lua -- this is when we don't care about building1 or building2 i.e. any buildin...
-- Code created by Kwik - Copyright: kwiksher.com {{year}} -- Version: {{vers}} -- Project: {{ProjName}} -- local json = require('json') local _M = {} local _K = require("Application") _K.screenshot = _M local needle = "Storage" -- Helper function that determines if a value is inside of a given table. local functio...
-- -- bowtie2 2.4.2 modulefile -- -- "URL: https://www.psc.edu/resources/software" -- "Category: Biological Sciences" -- "Description: bowtie2 is an ultrafast and memory-efficient tool for aligning sequencing reads to long reference sequences" -- "Keywords: singularity bioinformatics" whatis("Name: bowtie2") whatis("V...
local config = { hyper = {"ctrl", "alt"}, hyper_cmd = {"ctrl", "alt", "cmd"}, hyper_shift = {"ctrl", "alt", "shift"}, hyper_cmd_shift = {"ctrl", "alt", "shift", "cmd"}, kwmc = '/usr/local/Cellar/kwm/3.0.1/bin/kwmc', movementThreshold = 20, grid = { height = 2, width = 10, marginx = 1, marginy = 1 } } r...
local kBlipInfo = debug.getupvaluex(GUIMinimap.Initialize, "kBlipInfo") local kBlipColorType = debug.getupvaluex(GUIMinimap.Initialize, "kBlipColorType") local kBlipSizeType = debug.getupvaluex(GUIMinimap.Initialize, "kBlipSizeType") local kStaticBlipsLayer = debug.getupvaluex(GUIMinimap.Initialize, "kStaticBlipsLayer"...
--- luafp Result module. For now see: http://folktale.origamitower.com/api/v2.0.0/en/folktale.result.html -- @module luafp.Result -- @alias Result local Ok = {} setmetatable(Ok, { __call = function(t, value) t.__ok = true t.value = value return t end, __tostring = function(t) ...
for i, force in pairs(game.forces) do if force.technologies["wooden-boxing"].researched then force.recipes["wooden-box-rail"].enabled = true; force.recipes["wooden-unbox-rail"].enabled = true; for j, recipe in pairs(force.recipes) do if recipe.subgroup.name == "boxing-wooden-terrain" or recipe.subgroup.na...
local cmd = vim.cmd -- to execute Vim commands e.g. cmd('pwd') local g = vim.g -- a table to access global variables cmd([[packadd packer.nvim]]) return require('packer').startup(function() -- plugin management use('wbthomason/packer.nvim') -- treesitter (LSP) use({ 'nvim-treesitter/nvim-treesitter', run = '...
require "busted.runner"() local Helper = require "spec/scripts/devtools/menu/option/helper" describe("SubmenuOption", function() -- setup local match -- before_each initialization local options, submenu local SubmenuOption, submenuoption setup(function() match = require("luassert.mat...
-- Copyright 2006-2021 Mitchell. See LICENSE. -- Fennel LPeg lexer. -- Contributed by Momohime Honda. local lexer = require('lexer') local token, word_match = lexer.token, lexer.word_match local P, S = lpeg.P, lpeg.S local lex = lexer.new('fennel', {inherit = lexer.load('lua')}) -- Whitespace. lex:add_rule('whitespa...
ChristmasWebhook = "" -- put your webhook link for calendar log
--[[ MIT License Copyright (c) 2020 VerticalLongboard Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, pu...
local S = technic.getter local has_digilines = minetest.get_modpath("digilines") local quarry_dig_above_nodes = tonumber(technic.config:get("quarry_dig_above_nodes")) local quarry_max_depth = tonumber(technic.config:get("quarry_max_depth")) local quarry_time_limit = tonumber(technic.config:get("quarry_time_limit")) ...
----------------------------------- -- Area: Pashhow Marshlands -- NM: Bo'Who Warmonger ----------------------------------- require("scripts/globals/regimes") ----------------------------------- function onMobDeath(mob, player, isKiller) tpz.regime.checkRegime(player, mob, 60, 1, tpz.regime.type.FIELDS) end fun...
-- -- Class Mods - Druid settings -- -- Check the player's class before creating these settings if (select(2, UnitClass("player")) ~= "DRUID") then return end -- -- ResourceBar Module -- ClassMods.enableprediction = true ClassMods.powerGenerationSpells = { [1] = { -- Balance { 194153, 12 }, -- Lunar Strike { ...
local fs = require('diagnosticls-configs.fs') return { sourceName = 'pylint', command = fs.executable('pylint'), args = { '--output-format', 'text', '--score', 'no', '--msg-template', [['{line}:{column}:{category}:{msg} ({msg_id}:{symbol})']], '%file', }, offsetColumn = 1, forma...
local Forcefield, super = Class(Event) function Forcefield:init(x, y, w, h, properties) super:init(self, x, y, w, h) self.end_sprite = Assets.getFramesOrTexture("world/events/forcefield/end") self.middle_sprite = Assets.getFramesOrTexture("world/events/forcefield/middle") self.single_sprite = Assets.g...
local hex_dump = require "utils.string.hex_dump" local utf8 = require "utf8" local sfmt = string.format local print = print local error = error --TODO: don't think this should throw an error, rather do return nil, message local function check_utf8(utf8str) local len, errpos = utf8.len(utf8str) if not len then pri...
-- Cette ligne permet d'afficher des traces dans la console pendant l'éxécution io.stdout:setvbuf('no') -- Empèche Love de filtrer les contours des images quand elles sont redimentionnées -- Indispensable pour du pixel art love.graphics.setDefaultFilter("nearest") -- Cette ligne permet de déboguer pas à pas dans Zero...
------------------------------------------------------------------- --------------------------- CCC:wrapper ------------------------- ------------------------------------------------------------------- --[[ UI side: cccwrp.widget_register(supportedList, f_register, f_setValue) -- Register Widget ccc...
Platform = Object:extend() function Platform:new(x, y, w, h) self.x = x self.y = y self.w = w self.h = h end function Platform:display(mode, red, green, blue, alpha) local color = {} color.red = red or 1 color.green = green or 1 color.blue = blue or 1 love.graphics.setColor(color.red...
-- TE4 - T-Engine 4 -- Copyright (C) 2009 - 2014 Nicolas Casalini -- -- This program is free software: you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation, either version 3 of the License, or -- (at your option) any later version....
-- ****************************************************************** -- /\ /| @file Class.lua -- \ V/ @brief lua面向对象模拟 -- | "") @author Shadowrabbit, yingtu0401@gmail.com -- / | -- / \\ @Modified 2021-04-27 16:59 -- *(__\...
player = game.Players.yfc wait(0.2) if (script.Parent.className~="HopperBin") then if (script.Parent.className~="Part") then if (script.Parent.Name~=player.Character.Name) then t=Instance.new("HopperBin") t.Name="Wand" --t.Parent=game.Lighting t.Parent=player.Backpack script.Parent=t mm = Instance.n...
require("gameData/dataInterfaceBase"); require("hall/safeBox/data/safeBoxDataInterface"); require("hall/main/data/hallDataInterface"); --[[ 保险箱操作 ]] SafeBoxIsolater = class(DataInterfaceBase); SafeBoxIsolater.Delegate = { onUpdateSafeBoxCallBack = "onUpdateSafeBoxCallBack"; } SafeBoxIsolater.getInst...
local json = require("json") local mascara = require("mascara") local all_good = true local function check_fail(impl, expected, output) local caller_caller = assert(debug.getinfo(3)) print(string.format("fail at line %d for <%s>:", caller_caller.currentline, impl)) print("== Expected:") print(json.stringi...
-- Copyright 2020 André Luiz Alvares. See License.txt -- Nelua LPeg lexer. -- This was written from scratch, using the Textadept's Lua -- lexer from mitchell as guide -- TODO: Update Lua libraries and other things once Lua 5.4 launches local lexer = require('lexer') local token, word_match = lexer.token, lexer.word_...
-- Plain lua i/FFT implementation -- zorg @ 2020 § ISC -- Mostly based on the lua port of the KissFFT Library (by Mark Borgerding) by Benjamin von Ardenne, -- as well as KissFFT proper. -- Currently implements the following: -- - Recursive complex fft and ifft -- - Optimized butterfly functions for factors 2,3,4,5 and...
--[[ --MIT License -- --Copyright (c) 2019 PapyElGringo --Copyright (c) 2019 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 th...
yatm.blasts = yatm.blasts or {} yatm_blasts.blasts_system = yatm_blasts.BlastsSystem:new() yatm.blasts.system = yatm_blasts.blasts_system minetest.register_on_mods_loaded(yatm.blasts.system:method("init")) nokore_proxy.register_globalstep("yatm_blasts.update/1", yatm.blasts.system:method("update")) minetest.register_...
function fileExists(name) local f=io.open(name,"r") if f~=nil then io.close(f) return true else return false end end newoption { trigger = "embed_kernels", description = "Embed CL kernels into binary module" } newoption { trigger = "use_tbb", description = "Use Intel(R) TBB library for multi...
x = 5 y = 10 z = "abc" l = {x,y,z} for i =1,3 do --print(l[i]) end function f(x) print(z) end f()
local history = require("flompt.history") local vim = vim local M = {} local Buffer = {} Buffer.__index = Buffer M.Buffer = Buffer local FILETYPE = "flompt" local PATH_PREFIX = FILETYPE .. "://" function Buffer.new(bufnr, source_bufnr, source_cmd) vim.validate({ bufnr = {bufnr, "number"}, source_bufnr = {...
-- -- Project: lua-object -- objects for Lua -- -- Copyright 2015 Alexander Nusov. Licensed under the MIT License. -- See @license text at http://www.opensource.org/licenses/mit-license.php -- local object = {} function object:__getinstance() o = setmetatable({___instanceof=self}, self) self.__index = self retu...
local translate = require("scripts/translation") local await_export = false global.export_data = {} local function table_chunk(tbl, size) local chunks = {[1] = {}} local i = 1 local j = 0 for k, v in pairs(tbl) do if j == size then i = i + 1 j = 0 chunks[i] = {} end j = j + 1 ...
slot0 = class("EscortShop", import(".BaseVO")) slot0.Ctor = function (slot0) slot0.goods = {} slot0.type = ShopArgs.ShopEscort end slot0.update = function (slot0, slot1, slot2) slot0.id = slot1 slot0.configId = slot0.id slot3 = {} for slot7, slot8 in ipairs(slot2) do slot3[slot8.shop_id] = slot8.count end ...
--[[ This file was extracted by 'EsoLuaGenerator' at '2021-09-04 16:42:28' 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...
timer.Remove('HintSystem_OpeningMenu') timer.Remove('HintSystem_Annoy1') timer.Remove('HintSystem_Annoy2') -- Called when the client connects and spawns. function GM:InitPostEntity() PLAYER = LocalPlayer() Cable.send('fl_player_set_lang', GetConVar('gmod_language'):GetString()) timer.Simple(0.4, function() ...
---------------------------------- -- This file holds Rcon tools -- -- Be careful with these... -- ---------------------------------- function ulx.sendlua( calling_ply, target_plys, lua, should_silent ) for k,v in pairs( target_plys ) do v:SendLua( lua ) end if should_silent then ulx.fancyLogAdmin( ...
----------------------------------- -- Area: Metalworks -- NPC: High Bear -- Type: Quest Giver -- !pos 25.231 -14.999 4.552 237 ----------------------------------- local ID = require("scripts/zones/Metalworks/IDs") require("scripts/globals/quests") require("scripts/globals/keyitems") require("scripts/globals/titles")...
--[[ 游戏中布局设置 位置索引 ]] local POS_TYPE = { SCENE_BG = 1, --场景BG TEXT_NAME_BG = 2, --文本背景显示位置 TEXT_NAME_CONTENT = 3, --文本背景显示位置 TEXT_BG = 4, --文本背景显示位置 TEXT_CONTENT = 5, --文本内容显示位置 MENU_POS = 6, --菜单显示位置 CHOICE_POS = 7, --选项位置 ROLE_LEFT = 8, --角色在左侧显示位置 ROLE_RIGHT = 9, --角色在右侧显示位置...
local API = {}; Particle = API;
local function spell_check_iter(text, _) local sum = 0 return function() while #text > 0 do local word, type = unpack(vim.fn.spellbadword(text)) if word == '' then -- No bad words return end -- spellbadword() doesn't tell us the location of the bad word so we need ...
local Spell = { } Spell.LearnTime = 120 Spell.Description = [[ Summons a light source and places it at your aim position, dies in 8-16 seconds. ]] Spell.Category = HpwRewrite.CategoryNames.Lighting Spell.OnlyIfLearned = { "Lumos Maxima" } Spell.AccuracyDecreaseVal = 0.25 Spell.CanSelfCast = false Spell.ApplyFireDe...
assaultTimers = {} --[[ This one is called when a map is loaded. It reads the mapfile, creates the text displays and lets player choose their teams, starting the first round afterwards ]] function startAssaultMap(startedMap) local mapRoot = getResourceRootElement(startedMap) outputDebugString("Starting assault map....
----------------------------------- -- Area: Windurst Walls -- NPC: Kobunono -- Type: Adv. Assistant -- !pos 52.042 -3.499 -57.588 239 -- -- Auto-Script: Requires Verification (Verfied by Brawndo) ----------------------------------- function onTrade(player, npc, trade) end function onTrigger(player, npc) player...
X = {} local IBUtil = require(GetScriptDirectory() .. "/ItemBuildlogic"); local npcBot = GetBot(); local talents = IBUtil.FillTalenTable(npcBot); local skills = IBUtil.FillSkillTable(npcBot, IBUtil.GetSlotPattern(1)); X["items"] = { "item_boots", "item_magic_wand", "item_arcane_boots", "item_glimmer_cape", "it...
vim.g.NERDTreeAutoDeleteBuffer = 1 vim.g.NERDTreeMinimalMenu = 1 vim.g.NERDTreeMinimalUI = 1 vim.g.NERDTreeGitStatusShowIgnored = 1 -- git vim.g.NERDTreeGitStatusIndicatorMapCustom = { Modified = "M", Staged = "+", Untracked = "U", Renamed = "R", Unmerged = "N", Deleted = "X", Dirty = "D", ...
data:extend( { { type = "turret", name = "turret_auto_car", icon = "__base__/graphics/icons/medium-worm.png", flags = {"placeable-player", "placeable-enemy", "not-repairable", "breaths-air"}, order="b-b-e", subgroup="enemies", max_health = 800, resistances = { { t...
-- desc table utils functions local table_utils = {} local function to_boolean(value) return not not value end function table_utils.slice(source, first, last, step) local sliced = {} for i = first or 1, last or #source, step or 1 do sliced[#sliced + 1] = source[i] end return sliced end function table_utils...
local Draw = require("api.Draw") local Gui = require("api.Gui") local I18N = require("api.I18N") local Ui = require("api.Ui") local Event = require("api.Event") local UiList = require("api.gui.UiList") local UiWindow = require("api.gui.UiWindow") local InputHandler = require("api.gui.InputHandler") local IInput = requ...
--- GENERATED CODE - DO NOT MODIFY -- AWS Greengrass (greengrass-2017-06-07) local M = {} M.metadata = { api_version = "2017-06-07", json_version = "1.1", protocol = "rest-json", checksum_format = "", endpoint_prefix = "greengrass", service_abbreviation = "", service_full_name = "AWS Greengrass", signature_ve...
-- This code is a mess but its basicly a dump for useful functions we cant live with out. (yeH) local Entity = FindMetaTable("Entity") local Player = FindMetaTable("Player") function toExp(level) local exp = tonumber(level) or 0 if exp <= 1 then exp = 0 end return math.floor(math.pow(exp * 6, 2)) end function toLe...
local JSON = require('json') local timer = require('timer') local http = require('http') local boundary = require('boundary') local __pgk = "BOUNDARY ELASTICSEARCH" function berror(err) if err then print(string.format("%s ERROR: %s", __pgk, tostring(err))) return err end end --- do a http request local ...
local ECS = require('wacky-ecs.wacky-ecs') local resourceManager = ECS.System.new('resource_manager', nil) resourceManager.textures = {} resourceManager.tilesets = {} function resourceManager:getTexture(file) if not self.textures[file] then self.textures[file] = love.graphics.newImage(file) end return self...
local UTIL, CONST = require(script:GetCustomProperty("MetaAbilityProgressionUTIL_API")) local ClassMenuData = script:GetCustomProperty("ClassMenuData"):WaitForObject() local TrainingMenuPanel = script:GetCustomProperty("TrainingMenuPanel"):WaitForObject() local TrainingSidePanel = script:GetCustomProperty("TrainingSide...
local curStage = GAMESTATE:GetCurrentStage(); local curStageIndex = GAMESTATE:GetCurrentStageIndex(); local t = LoadFallbackB(); local function PercentScore(pn) local t = LoadFont("_overpass Score")..{ InitCommand=cmd(zoom,1;diffuse,Color("Black");diffusealpha,0.75;); BeginCommand=cmd(playcommand,"Set"); SetCom...
weathereffect = {} local WeatherEffect = {} WeatherEffect.__index = WeatherEffect weathereffect.metatable = WeatherEffect function weathereffect.create(rect, strEffectId) local table = {} setmetatable(table, WeatherEffect) table.handle = AddWeatherEffect(rect.handle, FourCC(strEffectId)) table._isEna...
return { { description = "A featureless white room. A pitch black void in the shape of archway can be seen on the east side of the room.", exits = { { direction = "east", leaveMessage = " steps into the void and disappears.", roomId = "limbo:black", }, ...
-- Custom.lua -- @Author : Dencer (tdaddon@163.com) -- @Link : https://dengsir.github.io -- @Date : 9/1/2019, 12:50:23 AM ---@type ns local ns = select(2, ...) local Search = ns.Search ---- LUA local ipairs, type = ipairs, type local tinsert, wipe = table.insert, table.wipe local format, tostring = string.format,...
--[[ # wavedrom.lua # Note | Link (content, target[, title[, attr] ]) | [content](target){.class-1 .class-2 attr=alpha attr=beta #lst:list} | | | | k v k v | | | | classes | | attributes | identifier | .listingtable type=plain...
local extend = require("iron.util.tables").extend local fthelper = { functions = {}, types = {} } fthelper.functions.format = function(repldef, lines) assert(type(lines) == "table", "Supplied lines is not a table") local new if repldef.format then return repldef.format(lines) elseif #lines == 1 then ...
-- Copyright 2022 SmartThings -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in ...
-- Input parameters -- oltp-tables-count - number of tables to create -- oltp-secondary - use secondary key instead PRIMARY key for id column -- -- function create_insert(table_id) local index_name local i local j local query if (oltp_secondary) then index_name = "KEY xid" else index_name...
print("loading data/scripts/UI/* files") UI={} --интерфейс пользователя local Folder="data/scripts/UI" dofile(Folder.."/CreateWinRectStyle.lua") dofile(Folder.."/CreateWinRect.lua") dofile(Folder.."/CreateTextStyle.lua") dofile(Folder.."/CreateWinStyle.lua") dofile(Folder.."/Control_Methods.l...
----------------------------------------------------------------------------------------- -- Decorators -- Repeater -- Repeat the child either x times or until it returns the specified status, or forever ----------------------------------------------------------------------------------------- local Repeater = bt.Cla...
local mod_gui = require 'mod-gui' local util = require 'util' if not gui then gui = {} end function gui.build_toggle_button(player) local button_flow = mod_gui.get_button_flow(player) if not button_flow[lrm.gui.toggle_button] then button_flow.add { type = "sprite-button", name = lrm.gui.toggle_button, spr...
character_skill_level_to_ancillaries_junctions_tables = { SCHEMA = {"granted_ancillary", "skill", "level"}, KEY = {"skill", "UNIQUE"}, DATA = { {"wh2_dlc09_anc_mount_tmb_tomb_prince_skeletal_steed", "wh2_dlc09_skill_tmb_champion_unique_tomb_prince_skeletal_steed", "1"}, {"wh2_dlc09_anc_mount_tmb_to...
local awful = require('awful') local gears = require('gears') local wibox = require('wibox') local lunaconf = { dpi = require('lunaconf.dpi'), icons = require('lunaconf.icons'), screens = require('lunaconf.screens'), theme = require('lunaconf.theme') } local theme = lunaconf.theme.get() local base = {} local las...
-- initialize and setup plugin manager local install_path = vim.fn.stdpath("data") .. "/site/pack/packer/start/packer.nvim" if vim.fn.empty(vim.fn.glob(install_path)) > 0 then vim.fn.execute("!git clone https://github.com/wbthomason/packer.nvim " .. install_path) end vim.api.nvim_exec( [[ augroup Packer autocmd...
local _M = {} _M.projects = { q = { type = "string", minLength = 1, maxLength = 50, } } _M.routers = { q = { type = "string", minLength = 1, maxLength = 50, } } return _M
-- simple test pattern for 256-color support for r=0,255,32 do for g=0,255,32 do for b=0,255,32 do io.write('\x1B[38;2;'..r..';'..g..';'..b..'m@') end io.write ' ' end io.write('\n') end
--[[--ldoc desc @module paixing_1569_4 @author WahidZhang Date 2018-01-09 19:35:02 Last Modified by JansonHuang Last Modified time 2018-01-31 12:27:41 ]] local LineBase2 = import("..base.LineBase2") local M = class(LineBase2) M.description = [[ 功能描述说明: 牌型:连对(升级类) 特征:牌点 “大小” 相邻的两组牌,每组都由两张相同牌点和相...
local HttpService = game:GetService("HttpService") local CollectionService = game:GetService("CollectionService") local Signal = require(script.Parent:WaitForChild("Signal")) local StringMatcher = require(script.Parent:WaitForChild("StringMatcher")) local Converter = {} Converter.ClassName = "Converter" Converter.__i...
-- sdl-instead specific methods local std = stead local instead = std.obj { nam = '@instead'; version_table = {3, 3, 2}; ini = function(s) -- after reset always do fade s.need_fading(true) end; } -- luacheck: read globals instead_clipboard -- luacheck: read globals instead_wait_use -- luacheck: read globals ...
----------------------------------------- -- ID: 4296 -- Item: serving_of_green_curry -- Food Effect: 180Min, All Races ----------------------------------------- -- Agility 2 -- Vitality 1 -- Health Regen While Healing 2 -- Magic Regen While Healing 1 -- Defense +9% (cap 160) -- Ranged ACC +5% (cap 25) -- Sleep Resist ...
--- --- Generated by EmmyLua(https://github.com/EmmyLua) --- Created by eric. --- DateTime: 2021/4/17 11:37 上午 --- local json = require "cjson" local args = ngx.req.get_uri_args() local headers = ngx.req.get_headers() local method = ngx.req.get_method() -- post body_data 需要先read ngx.req.read_body() -- 针对 application/...
function load_ids_from_file(file) found_ids = {} local f=io.open(file,"r") if f~=nil then io.close(f) else return found_ids end for line in io.lines(file) do if not (line == '' or line == 'personId|startDate|durationDays|countryXName|countryYName') then i = string.find(line, "|") ...
local AddOn, Engine = ... Engine[1] = {} -- F, Functions Engine[2] = {} -- C, Constants/Config Engine[3] = {} -- L, Localisation _G[AddOn] = Engine FreeUIGlobalConfig, FreeUIConfig = {}, {} local F, C, L = unpack(Engine) local pairs, next, tinsert = pairs, next, table.insert local events = {} local host = Creat...
#!/usr/bin/env lua -- Stalling commands with user events local cl = require('mooncl') local glfw = require('moonglfw') -- just for the sleep() function -- cl.trace_objects(true) local function printf(...) io.write(string.format(...)) end local source = [[ kernel void change_sign(global float4 *v) { *v *= -1.0f; ...
--------------------------------------------------------------------------------------------- -- In case -- SDL transfers *RPC with own timeout from mobile app to HMI (please see list with impacted *RPCs below) -- and HMI does NOT respond during <DefaultTimeout> + <*RPCs_own_timeout> (please see APPLINK-27495) -- SDL m...
slot0 = class("BattleGateChallenge") ys.Battle.BattleGateChallenge = slot0 slot0.__name = "BattleGateChallenge" slot0.Entrance = function (slot0, slot1) slot3 = slot0.actID slot4 = getProxy(PlayerProxy) slot5 = getProxy(BayProxy) slot8 = pg.battle_cost_template[SYSTEM_CHALLENGE].oil_cost > 0 slot9 = {} slot10 = ...
local Action = require(script.Parent.Action) return Action("StampScaleSet", function(min) return { min = min } end)
----------------------------------------------------------------------------------------- -- -- main.lua -- ----------------------------------------------------------------------------------------- local centerX = display.contentWidth/2 local centerY = display.contentHeight/2 -- drawing myRectangle = display.newRect(c...
return function(self) assert_table(self.data_struc) local result = self.data_struc if self.keep_comments then self:move_comments() end self:align_nodes(result) self:restruc_nodes(result) if not self.keep_unparsed_tail then result.unparsed_tail = nil end return result...
local genAlg = { --Default Parameters populationSize = 100, generations = 10, genomeSize = 3, geneDomain = { -1, 2 }, --{ x, width } mutationRate = 0.05, --min: 0, max: 1 mutationStdDev = 0.01, mutationShrink = 0.8, --min: 0, max: 1 selectionType = "linear_ranked", --optio...
function love.load() CursorImg = love.graphics.newImage("Data/UI/Cursor.png") ClickButton1 = ConstructButton("Fight me", {UICX, UICY}, 10, "TestButton1", 0) ClickButton1.mouseButtonLClick:connect(function() Timer.tween(1, ClickButton1.backgroundColor, {1, 0, 0, 1}) end) end function love.update(DT) GUIUpd...
spaces = {} function spaces:init() local spaces = {'servers', 'users', 'sessions'} for _, space in pairs(spaces) do if not box.space[space] then log.info('space[%s] do not exist, creating space and indexes', space) s = box.schema.create_space(space) if 'servers' == space then s:create_index('ip', {uni...