content
stringlengths
5
1.05M
-- Created by Elfansoer --[[ Ability checklist (erase if done/checked): - Scepter Upgrade - Break behavior - Linken/Reflect behavior - Spell Immune/Invulnerable/Invisible behavior - Illusion behavior - Stolen behavior ]] -------------------------------------------------------------------------------- viper_nethertoxin_...
--[[ load MNIST dataset for processing. includes options for configuring the CNN limited preprocessing is done to normalize the dataset to have a mean of zero outputs a metatable of examples ]]-- require 'torch' require 'paths' mnist = {} mnist.path_remote = 'https://s3.amazonaws.com/torch7/data/mnist.t7.tgz' m...
---@class Camera Camera = setmetatable({}, Camera) Camera.__index = Camera Camera.__call = function() return "Camera" end function Camera.new(handle) local _Camera = { Handle = handle } return setmetatable(_Camera, Camera) end ---@param position Vector3 ---@return Vector3 function Camera:Po...
local helpers = require "spec.helpers" local redis = require "resty.redis" local pretty = require "pl.pretty" for _, strategy in helpers.each_strategy() do describe("Proxy Cache: (access) [#" .. strategy .. "]", function() local proxy_client local red = redis:new() setup(function() local bp = he...
local server = require "nvim-lsp-installer.server" local pip3 = require "nvim-lsp-installer.installers.pip3" local root_dir = server.get_server_root_path "jedi_language_server" return server.Server:new { name = "jedi_language_server", root_dir = root_dir, installer = pip3.packages { "jedi-language-server"...
pcall(require, "plug-config.floaterm.mappings") local config = { cmd = {"FloatermNew", "FloatermToggle", "FloatermNext", "FloatermPrev"}, config = function() require("plug-config.floaterm.settings") end, } return config
require("mod-gui") ui_util = { mod_gui = {}, context = {}, switch = {} } -- ** GUI utilities ** -- Properly centers the given frame (need width/height parameters cause no API-read exists) function ui_util.properly_center_frame(player, frame, width, height) local resolution = player.display_resolution...
-- Copyright (C) 2014-2017 Jian Chang <aa65535@live.com> -- Licensed to the public under the GNU General Public License v3. module("luci.controller.shadowsocks", package.seeall) function index() if not nixio.fs.access("/etc/config/shadowsocks") then return end entry({"admin", "services", "shadowsocks"}, alias...
local lmprof = require"lmprof" lmprof.start() dofile("resources/complex.lua") xmin=-2 xmax=2 ymin=-2 ymax=2 --sky --N=256 N=16 function print(...) local arg = table.pack(...) for i=1,arg.n do io.write(arg[i]," ") end io.write("\n") end function level(x,y) local c=complex(x,y) local l=0 local z=c repeat...
if nil ~= require then require "fritomod/OOP"; require "fritomod/Log"; require "fritomod/Callbacks-Timing"; require "fritomod/ToggleDispatcher"; end; Mixins = Mixins or {}; -- A complex object may have state that is expensive to calculate (e.g. laying -- out a complex view). As a result, it's common ...
Config = {} Config.Locale = 'en' Config.Visible = false
slot0 = ClassLoader:aquireClass("BaseNode") slot1 = ClassLoader:aquireClass("Tools") slot2 = ClassLoader:aquireClass("Timer") slot3 = class_C("TimeLine", function () return slot0:create() end) slot3.ctor = function (slot0) slot0._timer = slot0:create() slot0._timer:addScheme(slot1:thisCall(slot2.scheduler, slot0),...
local class = require 'stuart.class' local DStream = class.new() function DStream:_init(ssc) self.ssc = ssc self.inputs = {} self.outputs = {} end function DStream:_notify(validTime, rdd) for _, dstream in ipairs(self.inputs) do rdd = dstream:_notify(validTime, rdd) end for _, dstream in ipairs(self....
--[[ by Klen_list ^=v=^ mew! ]] if not DrGBase then MsgN"[WPutin Nextbot] DrGBase not exist! Abort load..." return end ENT.Base = "drgbase_nextbot" ENT.Type = "nextbot" ENT.PrintName = "Wide Putin" ENT.Category = "Memes" ENT.Models = {"models/player/putin.mdl"} ENT.CollisionBounds = Vector(20, 20, 63) ENT.Ragd...
return { objects = { {name="hallway", x=0, y=0, noquads=true}, {name="me", x=10, y=17, controlled=true} }, events = { }, intro = "day2", right = "2-1-b" }
local inlinedError = require(script.Parent.Parent.Shared.inlinedError) local EntityQuery = {} EntityQuery.__index = EntityQuery function EntityQuery.new(world) assert(world, "Tried to create query without a world!") local self = setmetatable({ withComponents = {}, withoutComponents = {}, world = world, }, En...
target("memory_test") add_files("memory_test.cpp") add_deps("memory_manager", "test_utils") set_group("test/core") target("memory_benchmark") add_files("memory_benchmark.cpp") add_deps("memory_manager", "test_utils") set_group("test/core") target("file_io_manager_test") add_files("file_io_...
-- Settings.lua -- This file provides settings that may be modified by server admins to customize their plugin -- It shouldn't be normally necessary to edit this file, but it may be helpful in case of conflicts with other plugins or with a different pre-existing architecture --- The file from which the galleries...
local helpers = require("test.functional.helpers")(after_each) local exec_lua, feed, exec = helpers.exec_lua, helpers.feed, helpers.exec local ls_helpers = require("helpers") local Screen = require("test.functional.ui.screen") local assert = require("luassert") local loaders = { ["vscode(rtp)"] = function() exec( ...
-- This file is subject to copyright - contact swampservers@gmail.com for more information. -- INSTALL: CINEMA function string.hash(str) local bytes = {string.byte(str, 0, string.len(str))} local hash = 0 --0x07FFFFFF --It is a sequrence of 31 "1". --If it was a sequence of 32 "1", it would not b...
local fn = vim.fn local fmt = string.format local pack_path = fn.stdpath("data") .. "/site/pack" local function ensure(user, repo) local install_path = fmt("%s/packer/start/%s", pack_path, repo) if fn.empty(fn.glob(install_path)) > 0 then vim.cmd(fmt("!git clone https://github.com/%s/%s %s", user, repo, inst...
--[[ LuCI - Lua Configuration Interface Copyright 2019 lisaac <lisaac.cn@gmail.com> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 $Id$ ]]-- if nixio.fs.a...
-- -- Autogenerated by Thrift -- -- DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING -- @generated -- require 'Thrift' require 'rpc_ttypes' RpcServiceClient = __TObject.new(__TClient, { __type = 'RpcServiceClient' }) function RpcServiceClient:funCall(argStruct, argByte, argI16, argI32, argI64, arg...
local a = {} a.load = function(utils) a.name = "Living-After" a.background = love.graphics.newImage("img/living-after.png") a.debrisImg = love.graphics.newImage("img/items/debris.png") a.manager = utils.manager a.cleared = false local function enterRoom() utils.manager.setScene("Bedroo...
--[[--ldoc desc @module object @author YuchengMo Date 2018-04-25 15:13:29 Last Modified by YuchengMo Last Modified time 2018-04-25 15:14:16 ]] --通过判断类型 --返回值顺序 table, boolean, string --总的有如下N种情况 --1) super, autoConstructSuper, name --1) super, name, autoConstructSuper --2) name, super, autoConstructSuper --3) na...
-- Tester: local _ = require 'moses' local totem = require 'totem' local nnfunc = require 'nnfunc' local tester = totem.Tester() -- List of tests: local tests = { Tanh = function() -- Simple module: local layer = nnfunc.nn.Tanh() -- Fprop: local res = layer({input = torch.randn(10)}) ...
---- -- Selected entity tags data. -- -- Includes selected entity tags in data sidebar. -- -- **Source Code:** [https://github.com/dstmodders/mod-dev-tools](https://github.com/dstmodders/mod-dev-tools) -- -- @classmod data.SelectedTagsData -- @see data.Data -- -- @author [Depressed DST Modders](https://github.com/dstmo...
local env = environment() local N = Const("N") local P = Const("P") env = add_decl(env, mk_var_decl("N", Type)) env = add_decl(env, mk_var_decl("P", mk_arrow(N, Prop))) local a = Local("a", N) local H = Local("H", P(a)) local t = Pi(H, Prop) print(env:infer_type(t)) local m = mk_metavar("m", mk_arrow(N, N, ...
--[[ "title": "Auto Deconstruct", "author": "mindmix", "description": "This mod marks drills that have no more resources to mine for deconstruction." --]] local Event = require('__stdlib__/stdlib/event/event') local Entity = require('__stdlib__/stdlib/entity/entity') local table = require('__stdlib__/stdlib...
-- ########################################### -- KEYBINDINGS AND OTHER SETTINGS -- ########################################### -- General Vim settings vim.opt.number = true vim.opt.wrap = true vim.opt.encoding = "utf-8" vim.opt.wildmenu = true vim.opt.lazyredraw = true vim.opt.ruler = true vim.opt.tabstop = 4 vim.opt...
--- Pcall -- @classmod Pcall -- @usage -- Pcall(function() -- -- code to try -- end):pass(function() -- print("Passed!") -- end):fail(function() -- print("Failed!") -- end) local Pcall = {} Pcall.__index = Pcall --- Create a Pcall -- @tparam table t Check function -- @tparam function check Check funct...
local S = cannabis.S local path = cannabis.path local Color_list = { { "hemp", "c"}, { "u_style", "u"}, { "red_hemp", "cr"}, { "ice_hemp", "ci"}, { "fabric_hemp", "t"}, { "jamaican", "jam"} } local craftitem ={ --{"cape"}, {"skullcap"}, {"glove_right"}, {"glove_left"}, {"gloves"}, {"shirt"}, {"sho...
--------------------------------------------- -- Dynamis Statue (Regain MP) -- -- Description: Regain MP for party members within area of effect. -- --------------------------------------------- require("scripts/globals/msg") --------------------------------------------- function onMobSkillCheck(target, mob, skill) ...
local skynet = require "skynet" local memory = require "skynet.memory" memory.dumpinfo() --memory.dump() local info = memory.info() for k,v in pairs(info) do print(string.format(":%08x %gK",k,v/1024)) end print("Total memory:", memory.total()) print("Total block:", memory.block()) skynet.start(function...
local F, G = unpack(select(2, ...)) -- TinyMainbarInfo -- by Bastian Pflieger <wb@illogical.de> local FORMAT_NETSTATS = "%.2f KB/S" local FORMAT_MEMORY_USAGE = "%.3f MB" local FORMAT_FPS local FORMAT_LAG = "" local onlineTime = 0; local timer = 0; local doScan, loaded; local function TinyMainbarInfo_OnLoad(self) ...
-- The MIT License (MIT) -- Copyright (c) 2015 Eugene Aksenov (e.aksenov@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...
Dest = Class(function(self, inst, world_offset) self.inst = inst self.world_offset = world_offset end) local PATHFIND_PERIOD = 1 local PATHFIND_MAX_RANGE = 40 local STATUS_CALCULATING = 0 local STATUS_FOUNDPATH = 1 local STATUS_NOPATH = 2 local NO_ISLAND = 127 local ARRIVE_STEP = .15 function Dest:IsValid(...
return { "neovim/nvim-lspconfig", config = function() -- MARK: Diagnostic Settings: diable virtual text vim.diagnostic.config({ virtual_text = false, float = { scope = "line", -- "buffer", "line", or "cursor" source = true, -- true, "if_mnay", or false } }) -- M...
local plugin_name = "xml2json-advanced" local helpers = require "spec.helpers" for _, strategy in helpers.each_strategy() do describe("XML2JSON Advanced", function() local bp = helpers.get_db_utils(strategy) setup(function() local xml_service = bp.services:insert { name = "XMLService", ...
--------------------------------------------------------------------------------- -- -- Prat - A framework for World of Warcraft chat mods -- -- Copyright (C) 2006-2018 Prat Development Team -- -- This program is free software; you can redistribute it and/or -- modify it under the terms of the GNU General Public Licen...
PROJECT_NAME = path.getname(os.getcwd()) minko.project.library("minko-plugin-" .. PROJECT_NAME) files { "lib/**.hpp", "lib/**.h", "lib/**.cpp", "lib/**.c", "src/**.cpp", "include/**.hpp" } includedirs { "include", "src", "lib/lodepng/src" } configuration { "windows" } defines { "_CRT_SEC...
local util = require 'utility' local guide = require 'parser.guide' local collector = require 'core.collector' local files = require 'files' local tostring = tostring local error = error local ipairs = ipairs local type = type local next = next local log = log local ssub = string.sub...
local Groups = require("luat_groups") return {--问问题 check = function (data) return data.msg:find("群发") == 1 and LuaEnvName == "private" and XmlApi.Get("adminList",tostring(data.qq)) == "admin" end, run = function (data,sendMessage) sys.taskInit(function() sendMessage("开始发送到"..#Groups.."个群。。") ...
local _M = {} _M.code = require 'modbus.code' _M.pdu = require "modbus.pdu" _M.apdu_tcp = require "modbus.apdu_tcp" _M.apdu_rtu = require "modbus.apdu_rtu" _M.encode = require 'modbus.encode' _M.decode = require 'modbus.decode' _M.client = require 'modbus.client' return _M
ITEM.name = "Латы темерского рыцаря" ITEM.desc = "Тяжелый доспех, который носят темерские рыцари." ITEM.category = "Armor" ITEM.model = "models/container2.mdl" ITEM.width = 3 ITEM.height = 2 ITEM.SetModel = "models/got/gotknight5.mdl" ITEM.price = 1750 ITEM.mass = 70 ITEM.armorType = 3 ITEM.armorclass = "vest" ITEM.r...
local string_find = string.find local string_sub = string.sub local string_gsub = string.gsub local string_len = string.len local string_upper = string.upper local table_insert = table.insert function string.split(input, delimiter) input = tostring(input) delimiter = tostrin...
local filetype = require "filetype" filetype.setup {}
object_tangible_quest_menagerie_terminal_21 = object_tangible_quest_shared_menagerie_terminal_21:new { } ObjectTemplates:addTemplate(object_tangible_quest_menagerie_terminal_21, "object/tangible/quest/menagerie_terminal_21.iff")
local msgpack = require 'MessagePack' -- constants -- common local GREETING_SIZE = 128 local GREETING_SALT_OFFSET = 64 local GREETING_SALT_SIZE = 44 -- packet codes local OK = 0x00 local SELECT = 0x01 local INSERT = 0x02 local REPLACE = 0x03 local UPDATE = 0x04 local DELETE ...
function love.load() blip_sound = love.audio.newSource("sounds/blip.wav", "static") blip_sound:setVolume(0.8) blip_sound:setPitch(1.5) music = love.audio.newSource("sounds/nature.ogg", "stream") music:play() end function love.mousepressed(x,y,b,istouch) blip_sound:play() end function love.key...
--[[-- Java Native Interface (JNI) wrapper. @module android ]] -- Attempt to grab the full maxmcode region in one go on startup, -- to avoid mcode_alloc failures later on at runtime... -- c.f., https://www.freelists.org/post/luajit/Android-performance-drop-moving-from-LuaJIT201-LuaJIT202 -- For optimal behavior, this...
slide_Command("Line Delete|delSelLines|Ctrl+Shift+l") local find = string.find local match=string.match local gsub = string.gsub local insert = table.insert local sub=string.sub --typical locals local tdum,tdee,swp --tweedles, swapped local tsline,tslpos --thisline thislineposition local tpath --this pat...
-- Disabling space to move forward vim.api.nvim_set_keymap('n','<space>','<NOP>',{noremap = true, silent = true}) -- Making space mapleader vim.g.mapleader = ' ' -- Making leader-H remove highlights vim.api.nvim_set_keymap('n', '<leader>H', ':set hlsearch!<CR>',{ noremap = true, silent = true}) -- making leader-e o...
local invisible_combinator = copyPrototype("programmable-speaker", "programmable-speaker", "invisible-combinator") invisible_combinator.icon = MOD_NAME.."/graphics/invisible-combinator-item.png" invisible_combinator.icon_size = 32 invisible_combinator.energy_usage_per_tick = "1kW" invisible_combinator.sprite = { ...
local DROPDOWN_IMG_PATH = GUI_IMAGES_PATH.."/elements/dropdown.png" local ButtonComboBox = {} function ButtonComboBox.createButton(button) local height = guiGetHeight(button, false) local specialButton = guiCreateButton(0, 0, height, height, "", false, button) guiSetHeight(specialButton, 1, true) guiSetHorizon...
-- Base neovim configuration -- Configure neovim options require('configuration.options') -- Enable custom statusline require('configuration.statusline') -- Enable custom autocommands (nvim >= 0.7) require('configuration.autocommands') -- Set custom keymaps (nvim >= 0.7) require('configuration.keymaps')
--[[-------------------------------------------------------- -- Dragoon Framework - A Framework for Lua -- -- Copyright (c) 2014-2015 TsT worldmaster.fr -- --]]-------------------------------------------------------- local calledpath = (... or "") local path = (calledpath):gsub("%.init$", "") -- /!\ DO NOT USE "new...
-- Generated by CSharp.lua Compiler local System = System local SlipeSharedPeds System.import(function (out) SlipeSharedPeds = Slipe.Shared.Peds end) System.namespace("Slipe.Client.Peds.Events", function (namespace) namespace.class("OnQuitEventArgs", function (namespace) local __ctor__ __ctor__ = function (...
stategameover = {} function stategameover:load() end function stategameover:keypressed(key) end function stategameover:keyreleased(key) if key == 'space' then state = "MENU" return end end function stategameover:update() end function stategameover:draw() fw = font:get...
object_tangible_storyteller_prop_pr_palette_supply_04 = object_tangible_storyteller_prop_shared_pr_palette_supply_04:new { } ObjectTemplates:addTemplate(object_tangible_storyteller_prop_pr_palette_supply_04, "object/tangible/storyteller/prop/pr_palette_supply_04.iff")
require 'networks/mc-models/fast' require('networks/modules/Normalize2') local resmatch = require 'networks/mc-models/resmatch/components' local ResmatchFast, parent = torch.class('ResmatchFast','FastNetwork') function ResmatchFast:__init(self, opt, dataset) parent.__init(parent, self, opt, dataset) self.inne...
print('ntp_sync ...') local hourCount = 0 local sntpServerIp function startNtpSync() if (hourCount == 0 and appStatus.wifiConnected) then net.dns.resolve(cfg.sntpServerName, function(sk, ip) if (ip) then print('Resolved ' .. cfg.sntpServerName .. ' to ' .. ip) sntpServerIp = ip else ...
TestInterface = {} function TestInterface:testImplements() local a = ImplementsPrintable:New( "Hello" ) lu.assertEquals( lava.implements(a, interfaces.Printable), true ) lu.assertEquals( lava.implements(a, interfaces.Stringable), false ) lu.assertEquals( lava.implements(a, interfaces.Countable), false ) local b ...
-- http://developer.github.com/v3/ local GITHUB_API = { -- OAuth Authorizations { method = "GET", pathname = "/authorizations", }, { method = "GET", pathname = "/authorizations/:id", }, { method = "POST", pathname = "/authorizations", }, { ...
function os.iscygwin() return string.startswith(os.getenv('OSTYPE'), 'CYGWIN') end function path.cygpath(filepath) filepath = path.translate(filepath, '/') if os.iscygwin() then local t = explode(':', filepath) if table.getn(t) == 2 then filepath = '/cygdrive/' .. string.lower(t[1]) .. string.gsub(t[2], '\\...
-------------------------------------------------------------------------------------------------------- --- @alias StandardAnimationEvent fun():void --- @alias BranchingAnimationEvent fun():boolean -------------------------------------------------------------------------------------------------------- ------------...
--[[-- make lag setTimer ( function () for k, thePlayer in pairs ( getElementsByType( "player" ) ) do setPlayerNametagText( thePlayer, getPlayerName( thePlayer ).." (" .. tostring( getPlayerWantedLevel ( thePlayer ) ) .. ")" ) end end, 5000 , 0 ) ]] antiSpam = {} tazerAssists = {} cuffs = {} cuffTimer = {} cuf...
PacManLike = {} function PacManLike:pacManCheck() local x,y = self:getPosition() if(x < -16) then x = 800 end if(x > 816) then x = 0 end if(y < -16) then y = 600 end if(y > 610) then y = 0 end self:setPosition(x,y) end
#! /home/scybzdk/git/skynet/skynet/3rd/lua/lua --[[打印二进制内容 local f = assert(io.open("./src/mylib.c","rb")) local block = 16 while true do local bytes = f:read(block) if not bytes then break end for _,b in ipairs {string.byte(bytes,1,-1)} do io.write(string.format("%02X ",b)) --打印16个字节长的二进制数据 end io.write(s...
local cjson = require "cjson" local cjson2 = cjson.new() local cjson_safe = require "cjson.safe" local json = {} function json.fromJson(t) return cjson.decode(t) end function json.toJson(t) return cjson.encode(t) end function json.loadFile(file) local data = {} local content local f=io.open(file...
--[[ Number.lua Some of these methods are little wonky (and no longer used) - I realized some things after initial coding.. --]] local Number, dbg, dbgf = Object:newClass{ className='Number', register=false } --- Constructor for extending class. -- function Number:newClass( t ) return O...
-- ------ extra functions ------ -- function ruleCheck() -- determine if rule needs a protocol specified local sourcePort = ut.trim(sys.exec("uci -p /var/state get mwan3." .. arg[1] .. ".src_port")) local destPort = ut.trim(sys.exec("uci -p /var/state get mwan3." .. arg[1] .. ".dest_port")) if sourcePort ~= "" or d...
--[[ MIT License Copyright (c) 2022 Michael Wiesendanger 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, mod...
local BCECriterionA, parent = torch.class('nn.BCECriterionA', 'nn.Criterion') local eps = 1e-12 local beta = 0.80 local temp = torch.FloatTensor() function BCECriterionA:__init(weights, sizeAverage) parent.__init(self) if sizeAverage ~= nil then self.sizeAverage = sizeAverage else self.s...
-- IupScanf Example in IupLua -- Shows a dialog with three fields to be filled. -- One receives a string, the other receives a real number and -- the last receives an integer number. -- Note: In Lua, the function does not return the number of successfully read characters. require( "iuplua" ) iup.SetLanguage(...
-- -- -- admin_serverprefs.lua -- -- --------------------------------------------------------------------------- -- -- Prefs -- -- -- --------------------------------------------------------------------------- function cachePrefs() g_Prefs = {} g_Prefs.maxmsgs = getNumber('maxmsgs',99) g_Prefs.band...
--[[ ======================== Duplicate and Blur lines ======================== ==INSTRUCTIONS (SHORT VER.)== Install by putting this script in your Aegisub program files, under "automation\autoload\" This macro will apply to any line in the script that has "bord" in the actor field. Typeset your bordered sign on a...
local lconsole = require'logging.console' local log = lconsole() local lpeg = require'lpeg' local uri_patts = require "lpeg_patterns.uri" local EOF = lpeg.P(-1) local uri_patt = uri_patts.uri * EOF -- RFC 2396, section 1.6, 2.2, 2.3 and 2.4.1. local smartEscape = function(str) local pathOffset = str:match("//[^/]+/()...
ItemFunctions = {} function ItemFunctions.heal(opts) local entity = opts['entity'] local amount = opts['amount'] local results = {} if entity.fighter.hp == entity.fighter.maxHp then table.insert(results, {'consumed', false}) table.insert(results, {'message', Message('You are already at...
vim.cmd("hi clear") vim.opt.termguicolors = true vim.o.background = "dark" vim.cmd("colorscheme gruvbox") -- vim.cmd("colorscheme gruvbox-baby") -- vim.cmd("hi! link Type GruvboxBlue") -- vim.cmd("hi! link juliaType GruvboxBlue") vim.cmd("hi! link juliaSymbol GruvboxPurp...
data:add_type { name = "map_tileset", fields = { { name = "elona_id", indexed = true, type = types.optional(types.uint) }, { name = "tiles", type = types.map(types.data_id("base.map_tile"), types.some(types.data_id("base.map_tile"), types.callback({},...
local awful = require("awful") local beautiful = require("beautiful") local ruled = require("ruled") local gears = require("gears") local dpi = require("beautiful.xresources").apply_dpi local clientkeys = require("config.keys.client") local clientbuttons = require("config.buttons.client") local t...
local preprocessors = { require("scripts.research-progress"), } return preprocessors
do local function Cons(x) return { x, __tag = "Cons" } end local Nil = { __tag = "Nil" } local _greater_greater_equals = bind local pure = pure _greater_greater_equals(Cons({ _1 = 1, _2 = Cons({ _1 = 2, _2 = Cons({ _1 = 3, _2 = Nil }) }) }), function(x) return _greater_greater_equals(Cons({ ...
local expect = {} local function print_line(content, line) print(("%3d: %s"):format(line, content[line])) end local function print_snippet(content, line) if line ~= 1 then if line ~= 2 then print " ..." else print " FILE BEGIN" end print_line(content, line - 1) else print...
return { -- generic website options title = "webls", description = "a simple website generator", website = "https://example.org", cname = nil, head = nil, -- add "index.html" to the end of each link pagesuffix = true, -- folder that shall be scanned for content scanpath ...
local numPlayers = GAMESTATE:GetNumPlayersEnabled() local numSides = GAMESTATE:GetNumSidesJoined(); local bDoubles = (numPlayers == 1 and numSides == 2); local bUsingCenter1P = PREFSMAN:GetPreference('Center1Player') local songoptions = GAMESTATE:GetSongOptionsString(); local ratemod = string.match(songoptions, "%d.%...
--[[ Copyright 2014-2015 The Luvit Authors. All Rights Reserved. Copyright 2016-2020 The Node.lua Authors. All Rights Reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apach...
-- Copyright (c) 2019 Trevor Redfern -- -- This software is released under the MIT License. -- https://opensource.org/licenses/MIT local Component = require "moonpie.ui.components.component" local str = require "moonpie.utility.string" local keyboard = require "moonpie.keyboard" local mathext = require "moonpi...
require "lib.classes.class" require "Global.controls" require "Global.application.application" local MenuCtrl = require("Menu.ctrl.MenuCtrl") local DefaultMenuBuilder = require("Menu.model.menues.DefaultMenuBuilder") local SingleActionMenuState = require("Menu.model.menuStates.SingleActionMenuState") ------------------...
-- Not -- local bret = require 'behavior3.behavior_ret' local M = { name = 'Not', type = 'Decorator', desc = '取反', doc = [[ + 将子节点的返回值取反 ]] } function M.run(node, env) local yield = node:resume(env) local r if node:resume(env) then r = env.last_ret else r =...
ccs = ccs or {} ---SceneReader object ---@class SceneReader local SceneReader = {} ccs.SceneReader = SceneReader -------------------------------- -- ---@param selector function ---@return SceneReader function SceneReader:setTarget(selector) end -------------------------------- -- ---@param fileName string ---@param a...
function create(mouse) local checkbox = {} local checkboxes = {} function checkbox.newBox(x, y, text, colour) if not colour then colour = {1, 1, 1} end checkboxes[#checkboxes + 1] = {x=x, y=y, text=text, ticked=false, colour=colour} return #checkboxes end function checkbox.updateHaveBeenChecked(de...
Main = { funcs = {}, lastRagdoll = 0, } --[[ Functions: Main ]]-- function Main:Init() end function Main:UpdateFrame() Ped = PlayerPedId() Player = PlayerId() IsRagdoll = IsPedRagdoll(Ped) self:UpdateMelee() -- Variables. local isArmedExplosives = IsPedArmed(Ped, 2) local isArmedMelee = IsPedArmed(Ped, 1) ...
object_draft_schematic_dance_prop_prop_double_ribbon_l_s05 = object_draft_schematic_dance_prop_shared_prop_double_ribbon_l_s05:new { } ObjectTemplates:addTemplate(object_draft_schematic_dance_prop_prop_double_ribbon_l_s05, "object/draft_schematic/dance_prop/prop_double_ribbon_l_s05.iff")
local CONF = require "conf" local Trainer = {} local Trainer_mt = { __index = Trainer } function Trainer.new(population, world, input) local o = { world = world; player = world.player; input = input; population = population; population_step = nil; after_inputs_func = nil; generation_step_func = nil; ...
createObject(6965,1479.6610107422,-1639.5512695313,16.043619155884,0,0,0,0,0) createObject(3515,1479.2797851563,-1629.6237792969,12.134548187256,17,0,0,0,0) createObject(3515,1469.3880615234,-1639.6300048828,12.134548187256,0,17,0,0,0) createObject(3515,1479.5280761719,-1649.1407470703,12.13454818725...
local mod = DBM:NewMod("BrawlRare1", "DBM-Brawlers") local L = mod:GetLocalizedStrings() mod:SetRevision(("$Revision: 14030 $"):sub(12, -3)) mod:SetModelID(46265) mod:SetZone() mod:RegisterEvents( "SPELL_AURA_APPLIED 129888 133286 141396 141401", "SPELL_AURA_APPLIED_DOSE 141396 141401", "SPELL_CAST_STAR...
-- Pool Setup config = { pool_id = "mysql_test", size = 5, user = "vmq_test_user", password = "vmq_test_password", database = "vmq_test_database", host = "localhost", port = 3306 } assert(mysql.ensure_pool(config)) -- Drop test table assert(mysql.execute("mysql_test", "DROP TABLE IF EXISTS ...
#!/usr/bin/sblua package.path="/etc/sblua/?.lua;/usr/share/sblua-5.2/?/init.lua;/usr/share/sblua-5.2/?.lua"; package.cpath="/usr/lib/sblua-5.2/?.so"; -- Dash2 project configuration config=require("config"); dash=require("dash"); processes = { "ui", "event-server", "rfcom", "analytics", "behavior_tree", "map", "workou...