content
stringlengths
5
1.05M
-- Use of this source code is governed by the Apache 2.0 license; see COPYING. -- The shmem base class provides a simple IPC mechanism to exchange -- arbitrary cdata objects with other processes through a file-backed -- shared memeory region, referred to as the "data file". The memory -- layout of such a region is de...
local MODULE = PAW_MODULE('lib') local Chat = MODULE.Config.Chat or {} if CLIENT then local function RecieveMessage() local MSG_TYPE = net.ReadInt(8) or -1 local args = net.ReadTable(512) local toPrint = {} -- if !table.HasValue(Prefixes, MSG_TYPE) then -- table.inser...
--[[ Implements an index that can be used to efficiently search for items that share similar characteristics. This implementation is based on MinHash (which is used quickly identify similar items and estimate the Jaccard similarity of their characteristic sets) but this implementation extends the typical design to ad...
--[[ © 2015 Novabox.org do not share, re-distribute or modify without permission of its author (dragonfabledonnny@gmail.com). --]] local PLUGIN = PLUGIN PLUGIN.definitions = PLUGIN.definitions or {} PLUGIN.ContainerRefreshRate = 600; -- How long it will take for containers to refresh in seconds. PLUGIN.ContainerPr...
DevMode(false) Citizen.CreateThread(function() StartESX() CreateLoop(function() local founded = false for k,v in pairs(Config.Jobs) do if xPlayer.job.name == k then founded = true local vehicle = GetClosestVehicle(GetEntityCoords(Pl...
--- -- @module IngameCombatMenu -- -- ------------------------------------------------ -- Required Modules -- ------------------------------------------------ local Screen = require( 'src.ui.screens.Screen' ) local ScreenManager = require( 'lib.screenmanager.ScreenManager' ) local SaveHandler = require( 'src.SaveHand...
IncludeDir("tools")
----------------------------------- -- Area: Quicksand Caves -- NM: Centurio X-I ----------------------------------- mixins = {require("scripts/mixins/job_special")}; require("scripts/globals/status"); ----------------------------------- function onMobInitialize(mob) mob:setMobMod(tpz.mobMod.ALWAYS_AGGRO, 1); en...
local h = require("null-ls.helpers") local methods = require("null-ls.methods") local FORMATTING = methods.internal.FORMATTING return h.make_builtin({ name = "goimports", meta = { url = "https://pkg.go.dev/golang.org/x/tools/cmd/goimports", description = "Updates your Go import lines, adding m...
---@class CS.FairyEditor.ComponentAsset : CS.FairyEditor.AssetBase ---@field public extension string ---@field public xml CS.FairyGUI.Utils.XML ---@field public displayList CS.System.Collections.Generic.List_CS.FairyEditor.ComponentAsset.DisplayListItem ---@type CS.FairyEditor.ComponentAsset CS.FairyEditor.ComponentAs...
pfDB["units"]["enUS"] = { [3] = "Flesh Eater", [6] = "Kobold Vermin", [30] = "Forest Spider", [36] = "Harvest Golem", [38] = "Defias Thug", [40] = "Kobold Miner", [43] = "Mine Spider", [46] = "Murloc Forager", [48] = "Skeletal Warrior", [54] = "Corina Steele", [60] = "Ruklar the Trapper", [61] =...
return function(scene, dt) for event in pairs(scene:entities_with('event', 'jumped_on')) do if event.jumped_on.jumpee.damaged_when_jumped_on then local jumpee = event.jumped_on.jumpee if jumpee.life then jumpee.life = jumpee.life - event.jumped_on.damage end if jumpee.life == nil...
-- Implements the CrossEntropy criterion for logistic regression as a forward layer -- to allow robust kernel learning as a function of the imagewise CrossEntropy loss. require 'nn' local ElemwiseCrossEntropy, parent = torch.class('nn.ElemwiseCrossEntropy','nn.Module') -- Effectively we've just transmuted CrossEntro...
-- assets.lua : Images and sounds for the game local log = require('log') local assets = { images = {}, sounds = {}, fonts = {}, } function assets.load() log.debug('assets.init: loading tilesets') -- tileset stuff here local tileset = { terrain = love.graphics.newImage('assets/images...
--[[ test = require "testmod2" test.info(1,2,"a",{a=100}) ]] local print = print local type = type local tostring = tostring local pairs = pairs module('testmod2') _VERSION = '1.00' local function debug(args) for k, v in pairs(args) do print(tostring(k)..":["..tostring(v).."] type of "..type(v)) end...
local Hit = {} function Hit.new(timePos:number, chord:number) local hit = {} hit.TimePos = timePos hit.Chord = chord return hit end return Hit
paradeSlot("kpr_mover",{ -1253.229, -200, 0, },{ 0, 0, 1, },{ 1, 0, 0, },0) paradeSlot("misc",{ 3275, 168, -3352, },{ 0, 0, 1, },{ 1, 0, 0, },0)
-- // Name: getRoleInformation.lua -- // Description: Get rank info -- // Author: @Jumpathy return { authentication_required = false, call = function(client,api,endpoints,cookie,groupId,rankId) return api.promiseModule.async(function(resolve,reject) api:request("get_group_rankId",nil,nil,groupId):andThen(functi...
object_tangible_quest_corellia_corellia_39_experimental_weapon_02 = object_tangible_quest_corellia_shared_corellia_39_experimental_weapon_02:new { } ObjectTemplates:addTemplate(object_tangible_quest_corellia_corellia_39_experimental_weapon_02, "object/tangible/quest/corellia/corellia_39_experimental_weapon_02.iff")
function EOT_InsertDonations() -- Iterate over all mail items for currentInboxIndex = 1, GetInboxNumItems() do local donationSender, donationDate, donationDescription, donationItemValue local _, _, sender, subject, money, CODAmount, daysLeft, hasItem, wasRead = GetInboxHeaderInfo(currentInboxIndex...
--- -- @module Factions -- -- ------------------------------------------------ -- Required Modules -- ------------------------------------------------ local Class = require( 'lib.Middleclass' ) local Node = require( 'src.util.Node' ) local Log = require( 'src.util.Log' ) -- ------------------------------------------...
NeP.Commands = {} local Commands = NeP.Commands function Commands.Register(name, func, ...) SlashCmdList[name] = func local command = '' for i = 1, select('#', ...) do command = select(i, ...) if strsub(command, 1, 1) ~= '/' then command = '/' .. command end _G['...
package("filament") set_homepage("https://google.github.io/filament/") set_description("Filament is a real-time physically-based renderer written in C++.") set_license("Apache-2.0") add_urls("https://github.com/google/filament/archive/refs/tags/$(version).tar.gz", "https://github.com/goog...
require('Utilities'); function Server_GameCustomMessage(game, playerID, payload, setReturnTable) if (payload.Message == "Propose") then --Create a proposal local proposal = {}; proposal.ID = NewIdentity(); proposal.PlayerOne = playerID; proposal.PlayerTwo = payload.TargetPlayerID; proposal.NumTurns = p...
local fightModule = require "module.fightModule" local ItemHelper = require "utils.ItemHelper" local ItemModule = require "module.ItemModule" local battle = require "config.battle" local goCheckpoint = {} function goCheckpoint:Start(data) DispatchEvent("LOCAL_SELECTMAP_PUSH_GOCHECKPOINT") self:initData(data) ...
math.exp(1) math.pi math.sqrt(x) math.log(x) math.log10(x) math.exp(x) math.abs(x) math.floor(x) math.ceil(x) x^y
object_tangible_wearables_jacket_jacket_ace_rebel_craft = object_tangible_wearables_jacket_shared_jacket_ace_rebel_craft:new { } ObjectTemplates:addTemplate(object_tangible_wearables_jacket_jacket_ace_rebel_craft, "object/tangible/wearables/jacket/jacket_ace_rebel_craft.iff")
slot0 = class("LinkLinkMediator", import("..base.ContextMediator")) slot0.EVENT_OPERATION = "event operation" slot0.register = function (slot0) slot0:bind(slot0.EVENT_OPERATION, function (slot0, slot1) slot0:sendNotification(GAME.ACTIVITY_OPERATION, slot1) end) slot0.SetActivityData(slot0) slot0:SetPlayerData() ...
if(GetRealmName() == "Faerlina")then WP_Database = { ["Nineteenxx"] = "ST:807/99%SB:841/99%EM:923/94%", ["Heezy"] = "ST:801/99%SB:850/99%SM:1117/99%", ["Sñakeeater"] = "LT:784/98%SB:852/99%SM:1132/99%", ["Pork"] = "ET:742/94%SB:815/99%SM:1104/99%", ["Bigdank"] = "LT:752/95%SB:838/99%SM:1147/99%", ["Chemistry"] = "ST:79...
local asset = require('asset') local assets = {} love.update = function() assets = { font = asset.font('examples/asset/fixtures/font.ttf', 26), shader = asset('examples/asset/fixtures/shader.glsl'), image = asset('examples/asset/fixtures/image.jpg') } end love.draw = function() if assets.font then love.gr...
smtp = require("socket.smtp"); msg = smtp.message({ headers = { to = "fzammetti@etherient.com", subject = "Corona rocks!" }, body = "Yeah, so, that was fun." }); r, e = smtp.send({ from = "fzammetti@omnytex.com", rcpt = "fzammetti@etherient.com", source = msg, server = "zammetti.com", por...
-- getRolagemAsString(rolagem): recebe um objeto Rolagem do SDK e retorna uma string descrevendo a rolagem -- da mesma maneira que é mostrado no RRPG function getRolagemAsString(rolagem) local total = 0; local lastTipoOp = "soma"; -- local modif = 0; -- local dices = "{"; local diceString = "{"; for i,op in ipairs(...
-- -- User: pat -- Date: 9/17/15 -- require 'torch' --[[ Takes a tac candidate file and exports a candidtate file to outfile with subtrings between entities extracted ]]-- local cmd = torch.CmdLine() cmd:option('-candidates', '', 'input candidate file') cmd:option('-outFile', '', 'scored candidate out file') cm...
vim.g.copilot_filetypes = { ["*"] = false, } vim.cmd [[ imap <silent><script><expr> <C-A> copilot#Accept("\<CR>") let g:copilot_no_tab_map = v:true ]]
-- ===================================================================================== -- Name: wifi.lua -- Author: Gurpreet Singh -- Url: https://github.com/ffs97/awesome-config/themes/apocalypse/widgets ... -- ... controlpanel/wifi.lua -- License: The MIT License (MIT) -- -...
-- Lua script of item bass_gem. -- This script is executed only once for the whole game. -- Feel free to modify the code below. -- You can add more events and remove the ones you don't need. -- See the Solarus Lua API documentation for the full specification -- of types, events and methods: -- http://www.solarus-game...
local h = require("null-ls.helpers") local methods = require("null-ls.methods") local DIAGNOSTICS = methods.internal.DIAGNOSTICS local handle_rubocop_output = function(params) if params.output and params.output.files then local file = params.output.files[1] if file and file.offenses then ...
--===========================================================================-- -- -- -- System.Net.Protocol.Modbus-TCP -- -- -- ...
seanContactConvoTemplate = ConvoTemplate:new { initialScreen = "", templateType = "Lua", luaClassHandler = "sean_contact_conv_handler", screens = {} } sean_notinOffice = ConvoScreen:new { id = "sean_notinOffice", leftDialog = "@conversation/sean_contact:s_f1baf7f", --Elections, Sand People raids, museums! So man...
local Plugins = require("kong.db.dao.plugins") local Entity = require("kong.db.schema.entity") local Errors = require("kong.db.errors") require("spec.helpers") -- add spec/fixtures/custom_plugins to package.path describe("kong.db.dao.plugins", function() local self lazy_setup(function() assert(Entity.new(req...
--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell <cornernote@gmail.com> Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- minetest.log('action', ' __ __ __ __ ') minetest.log('action', ' _____/ /____ __/ /_ / /___ _____/ /__...
return {'copartnership','copernicaans','copieus','copiloot','coprocessor','coproducent','coproduceren','coproductie','copromotor','copulatie','copuleren','copyright','copyrightpagina','copyrightvermelding','copyshop','copywriter','copywriting','copycard','copyrighthouder','coproductiefonds','coppens','copland','copier'...
require "System_Reflection" System.Reflection.MemberFilter = System.Delegate:new()
--- -- @classmod CancelToken -- @author Quenty local require = require(script.Parent.loader).load(script) local Promise = require("Promise") local Signal = require("Signal") local CancelToken = {} CancelToken.ClassName = "CancelToken" CancelToken.__index = CancelToken function CancelToken.new(executor) local self ...
--!A cross-platform build utility based on Lua -- -- 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...
phoneProp = 0 local phoneModel = `prop_npc_phone_02` local currentStatus = 'out' local lastDict = nil local lastAnim = nil local lastIsFreeze = false local ANIMS = { ['cellphone@'] = { ['out'] = { ['text'] = 'cellphone_text_in', ['call'] = 'cellphone_call_listen_base', }, ['text'] = { ['out'] = 'cellp...
local damage_sprites = args[1] local hp = args[2] local max_hp = hp function update(obj) local i = #damage_sprites - math.floor((hp / max_hp) * #damage_sprites) obj:set_sprite(damage_sprites[math.max(1, math.min(#damage_sprites, i))]) if hp < 0 then obj:delete() end end function collision_postSolve(collision) ...
local Library = require "CoronaLibrary" -- Create stub library for simulator local lib = Library:new{ name='plugin.perk', publisherId='com.coronalabs' } -- Default implementations local function defaultFunction() print( "WARNING: The '" .. lib.name .. "' library is not available on this platform." ) end lib.init = ...
--List of files to load dofile("tableSave.lua") math.randomseed(os.time()) commands = {} allCommands = {} local stepcount=0 local cmdcount = 0 local function infhook() stepcount = stepcount+1 if stepcount>100000 then stepcount=0 debug.sethook() error("Break INF LOOP") else return end end function add_cmd(f,...
Button = {} Import("Core.Trigger"); Import("Core.Dialog"); Import("Core.Animation.Animator"); GetHook("TriggerDatabase"); GetHook("TextDisplay"); This:useLocalTrigger("Init"); This:useLocalTrigger("Click"); function Local.Init() selfTrGrp = Hook.TriggerDatabase:createTriggerGroup(Private, "Button") ...
modifier_phantom_extra_slashes = class({})
object_tangible_wearables_armor_invisible_invisible_padded_helmet = object_tangible_wearables_armor_invisible_shared_invisible_padded_helmet:new { } ObjectTemplates:addTemplate(object_tangible_wearables_armor_invisible_invisible_padded_helmet, "object/tangible/wearables/armor/invisible/invisible_padded_helmet.iff")
object_static_worldbuilding_terminal_floor_console_sectional_04 = object_static_worldbuilding_terminal_shared_floor_console_sectional_04:new { } ObjectTemplates:addTemplate(object_static_worldbuilding_terminal_floor_console_sectional_04, "object/static/worldbuilding/terminal/floor_console_sectional_04.iff")
return { Properties = { ["Name"] = "Spacemacs"; ["ImageId"] = "rbxassetid://2919668248"; }, Settings = { ["Background Color"] = Color3.fromRGB(40, 45, 45); ["Built-in Function Color"] = Color3.fromRGB(190, 110, 195); ["Comment Color"] = Color3.fromRGB(90, 95, 95); ["Error Color"] = Color3.fromRG...
#!/usr/bin/env lua -- A general bitonic sort local cl = require('mooncl') -- cl.trace_objects(true) local function printf(...) io.write(string.format(...)) end -- Create device, context, and command queue local platform = cl.get_platform_ids()[1] local device = cl.get_device_ids(platform, cl.DEVICE_TYPE_ALL)[1] local...
-- mSave.lua -- one-func does all menu handler. app:service{ name="Re-save (RGB files) destructively", async=true, main=function( call ) call:initStats{ 'totalTargets', 'ripeTargets', 'processed', 'okAlready', 'videoSkipped', 'missingSkipped', 'virtualCopySkipped', 'notWritableSkipped', 'dngSkipped', 'rawSkipped'...
timerAgain = {} mapQueue = {} _mapState = { state = true, count = 0 } function getServerMaps(player) if player then local info = {} for i,resource in pairs(getResources()) do if getResourceInfo(resource,"type") == "map" and getResourceInfo(resource,"gamemodes") == "race" then local mapName = getR...
--- Factory for creating states. -- The factory creates a state and adds a factory property to the new state -- so new states can easily create other states. local Factory = {} --- Creates a state -- @param state Type of state to create. -- @param ... Additional arguments to pass to the new state. function Factory.cr...
PLUGIN.name = "Some defence" PLUGIN.author = "DrodA x Kek1ch x Petrenko" PLUGIN.desc = "Antibackdoor & Cleans up items" nut.util.include("sv_plugin.lua")
fx_version 'cerulean' game 'gta5' server_script { "src/s_perms.js", } client_script { "src/c_perms.js" } author 'SpaceTheDev & Petrikov' description 'Real time discord based permissions' version '1.0.0'
local Ease3D = require(script:GetCustomProperty("Ease3D")) local Spline = require(script:GetCustomProperty("Spline")) local EasingEquations = require(script:GetCustomProperty("EasingEquations")) local RootGroup = script:GetCustomProperty("RootGroup"):WaitForObject() local KeyframesGroup = script:GetCustomProperty("Ke...
local K, C, L, _ = select(2, ...):unpack() local _G = _G local unpack, pairs, print = unpack, pairs, print local InCombatLockdown = InCombatLockdown local CreateFrame, UIParent = CreateFrame, UIParent -- Movement Function(by Allez) K.MoverFrames = { AchievementAnchor, ActionBarAnchor, BuffsAnchor, COOLDOWN_Anchor...
require("import") -- the import fn import("primitive_ref") -- import code pr=primitive_ref --alias assert(pr.ref_int(3)==3) assert(pr.ref_uint(3) == 3) assert(pr.ref_short(3) == 3) assert(pr.ref_ushort(3) == 3) assert(pr.ref_long(3) == 3) assert(pr.ref_ulong(3) == 3) assert(pr.ref_schar(3) == 3) assert(pr.ref_u...
local luaunit = require 'luaunit' local class = require 'pl.class' local decoder = require 'krpc.decoder' local platform = require 'krpc.platform' local schema = require 'krpc.schema.KRPC' local Types = require 'krpc.types' local TestDecoder = class() local types = Types() function TestDecoder:test_decode_message() ...
fastScreenshotButton = nil local fastScreenshotDirName = "/fast_screenshots" local fastScreenshotDir = g_resources.getWriteDir()..fastScreenshotDirName function init() fastScreenshotButton = modules.client_topmenu.addLeftButton('fastScreenshotButton', tr('Fast Screenshot'), '/client_fastscreenshot/img_client_fastsc...
local function DARKe(msg) local text = msg.content_.text_ if text then tdcli_function({ID = "GetUser",user_id_ = msg.sender_user_id_},function(arg,data) if data.id_ then if data.id_ ~= bot_id then local DARKChengName = database:get(bot_id.."DARK:Cheng:Name"..data.id_) if not data.first_name_ then if DARKChen...
--[[ TheNexusAvenger Class representing a "cut" frame, but with mutliple colors able to be done horizontally. The BackgroundColor3 can be a Color3 or a ColorSequence. --]] local RootModule = script.Parent.Parent local Gui = RootModule:WaitForChild("Gui") local CutFrame = require(Gui:WaitForChild("CutFrame")) local ...
--[[ Copyright 2014 The Luvit 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.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
require "brains/slurtlebrain" require "stategraphs/SGslurper" local assets = { Asset("ANIM", "anim/slurper_basic.zip"), Asset("ANIM", "anim/hat_slurper.zip"), Asset("SOUND", "sound/slurper.fsb"), } local prefabs = { "slurper_pelt" } local freq = 750 local slurp_channels = { "set_music", "set_ambience", "se...
local log = require 'lnlog' local brick = require "brick" local player = require "player" local MAP_Width = 300 local MAP_Height = 300 local Brick_Count = 20 local game = {} function game:init( users,notifyAllFunc ) -- body self.notifyAll=notifyAllFunc self.map = require "map" self.map:init(MAP_Width,MAP_Height...
local window = require 'window' local camera = require 'camera' local fonts = require 'fonts' local HUD = {} HUD.__index = HUD local lens = love.graphics.newImage('images/hud/lens.png') local chevron = love.graphics.newImage('images/hud/chevron.png') local energy = love.graphics.newImage('images/hud/energy.png') len...
local Event = require("api.Event") local Chara = require("api.Chara") local Title = require("mod.titles.api.Title") local function proc_title_earned_kill_chara(victim, params) if params.attacker then -- >>>>>>>> oomSEST/src/dmg.hsp:1063 gosub *label_1177 ... Title.check_earned(params.attacker) ...
local menu = require "Scripts/PlayerAccount/menu" local confirmsignupmenu = menu:new{canvasName = "ConfirmSignUp"} function confirmsignupmenu:OnAfterShow() if self.context.username then self:SetText("UsernameText", self.context.username) end end function confirmsignupmenu:OnAction(entityId, actionNam...
---Adds event handling to an class. -- The EventEmitter mixin is a simple implementation of the Observer pattern. Any instance of EventEmitter can call emit() with an ID that represents an event. Other objects can register event handler functions to a specific event ID, which will be called immediately (in the order t...
--[[ ingameUI.lua Copyright (C) 2016 Kano Computing Ltd. License: http://www.gnu.org/licenses/gpl-2.0.txt GNU GPLv2 ]]-- local UiDialog = require 'game.ui.HUD.characterDialog' local SignDialog = require 'game.ui.HUD.signDialog' local plaqueDialog = require 'game.ui.HUD.plaqueDialog' local TerminalDialog = require '...
local Fib = require("Fibonacci")
local autoAssemblyScript = [[ [ENABLE] aobscanmodule(INJECT,TestDriveUnlimited.exe,F3 0F 11 48 58 F3 0F 11 87) alloc(newmem,$1000) globalalloc(odo_copied, 4) label(code) label(return) newmem: code: mov [odo_copied], eax movss ...
-- shortcuts local lg = love.graphics -- bundled draw functions local draw = {} -- draw cursor function draw.cursor(x,y) lg.draw(arc.img.cursor,x,y) end -- draw text function draw.text(s,x,y,c) local c = c or arc.col.white if arc.cfg.msg_txt_shdw then lg.setColor(arc.col.shadow) lg.print(...
local ADDON, Addon = ... local Util = Addon.Util HereticHistory = { histories = { HereticList:New("default") } } function HereticHistory:GetItemListForInstanceID(instanceName, instanceDifficultyID, instanceID) local match_i, match_history, noid_i, noid_history for i,history in ipairs(HereticHistory.histories) ...
local appname = "ssr_mudb_server" local jsonc = require "luci.jsonc" a = Map(appname, translate("ShadowsocksR MuDB Server")) t = a:section(TypedSection, "global", translate("Global Settings")) t.anonymous = true t.addremove = false t:append(Template(appname .. "/status")) e = t:option(Flag, "enable", translate("Ena...
--[[ // FileName: LocalScript.lua // Written by: Jake Baxter // Version: v0.0.0-alpha.3 // Description: NWSpacek Local Rod System Modified For RBLX-train-driving-system // Contributors: NWSpacek (Not officially) --]] local loco = script:WaitForChild("loco").Value local Gears = loco task.wait(1) if not l...
--[[ Copyright (c) 2019 Optera * Part of Ghost Scanner * * See LICENSE.md in the project directory for license information. --]] -- local logger = require("__OpteraLib__.script.logger") -- logger.settings.read_all_properties = false -- logger.settings.max_depth = 6 -- logger.settings.class_dictionary.Lua...
-- モジュール用テーブル local KeyConfig = {} -- 入力情報タイプ KeyConfig.KEYCONFIG_INPUT_LEFT = (1) -- 方向入力左 KeyConfig.KEYCONFIG_INPUT_RIGHT = (2) -- 方向入力右 KeyConfig.KEYCONFIG_INPUT_UP = (3) -- 方向入力上 KeyConfig.KEYCONFIG_INPUT_DOWN = (4) -- 方向入力下 KeyConfig.KEYCONFIG_INPUT_CAMERA_LEFT = (5) -- カメラ用方向入力左 KeyConfig.KEYCONFIG_INPUT_CAMERA_...
redis.replicate_commands() local zset = KEYS[1] local ttl = tonumber(ARGV[1]) local time = redis.call('TIME')[1] return redis.call('ZRANGEBYSCORE', zset, time, time + ttl)
local followchars = true; local xx = 920.95; local yy = 2560; local xx2 = 1700.9; local yy2 = 2600; local ofs = 50; local del = 0; local del2 = 0; function onCreate() makeLuaSprite('dark', 'jenny/darkroom', 100,1620); addLuaSprite('dark', false); end function onUpdate() if del > 0 then del = del - 1 end if del2...
-- Oxypanel Core -- File: app/object.lua -- Desc: generic object handler (mapped to <module>_<object-type> in db) --Localize local ngx = ngx local database, user, request = luawa.database, luawa.user, luawa.request -- Oxy.object local object = {} -- Oxy setup function object:setup() ngx.ctx.objects = {} end --...
local Constants = require(script.Parent.Parent.Constants) local Util = require(script.Parent.Parent.Parent.Shared.Util) local Comparators = {} function Comparators.reference(a, b) return a ~= b end function Comparators.value(a, b) return not Util.deepEquals(a, b) end function Comparators.within(epsilon) return f...
local PowerUp = Entity:new() local function utf8char( ... ) local buf = {} for k, v in ipairs { ... } do if v < 0 or v > 0x10FFFF then error( "bad argument #" .. k .. " to char (out of range)", 2 ) end local b1, b2, b3, b4 = nil, nil, nil, nil if v < 0x80 then -- S...
require 'nn' require 'image' require 'csvigo' require 'math' -- load image -- local im = image.rgb2y( image.load(arg[1], 1) ) local im = image.load(arg[1], 1) local num_patches = tonumber(arg[3]) local batch_size = 100 local num_batches = math.ceil(num_patches/batch_size) -- must be [0,255] im = im:mul(255) -- inpu...
canoid_pack_leader = Creature:new { objectName = "@mob/creature_names:canoid_pack_leader", socialGroup = "canoid", faction = "", level = 18, chanceHit = 0.32, damageMin = 160, damageMax = 170, baseXp = 1426, baseHAM = 3500, baseHAMmax = 4300, armor = 0, resists = {115,120,5,5,5,5,5,-1,-1}, meatType = "meat...
-- -- YATM Data To Mesecon -- -- Adds additional nodes for transforming from mesecon signals to data messages and vice versa local mod = foundation.new_module("yatm_data_to_mesecon", "1.0.0") mod:require("nodes.lua")
--[[ -- added by wsh @ 2017-01-08 -- 图集管理:为逻辑层透明化图集路径和图集资源加载等底层操作 -- 注意: -- 1、只提供异步操作,为的是不需要逻辑层取操心图集AB是否已经加载的问题 -- 2、图集管理器不做资源缓存 -- 3、图片名称带后缀 --]] ---@class AtlasManager:Singleton local AtlasManager = BaseClass("AtlasManager", Singleton) local sprite_type = typeof(CS.UnityEngine.Sprite) local atlas_type = typeof(CS.Uni...
--- -- Network server and client classes. -- -- @module radio.utilities.network_utils local ffi = require('ffi') local platform = require('radio.core.platform') local class = require('radio.core.class') local debug = require('radio.core.debug') if platform.os == "Linux" then ffi.cdef[[ typedef uint16_t s...
-- SignalService type --[=[ @class SignalService ]=] local SignalService = {} --[=[ Creates a new signal ```lua local Signal = SignalService.new() ``` @return Signal ]=] function SignalService.new() end --[=[ Returns whether a class is a signal ```lua local boolean = SignalServic...
local M = {} function M.setup(cfg) require("git.config").setup(cfg) cfg = require("git.config").config local options = { noremap = true, silent = true, expr = false, } vim.api.nvim_set_keymap("n", cfg.keymaps.blame, "<CMD>lua require('git.blame').blame()<CR>", options) vim.api.nvim_set_keymap(...
require("lib/core") local numbers = {} -- Create a tables -- Tables can have variables numbers.pi = 3.1415 numbers.one_fifth = 1 / 5 num = numbers assert(1/5, numbers.one_fifth) print("Pi is " .. num.pi) print("1/5 is " .. num.one_fifth) -- tables can have functions! local std_math = {} function std_math.double(...
vim.g.mapleader = "," require("general") require("plugins") require("utils") require("lsp") -- TODO: some plugins reset those values vim.o.signcolumn = "yes"
local has_config, formatter = pcall(require, 'formatter') if not has_config then return end local utils = require '_.utils' local M = {} local function prettier() local local_prettier = 'yarn' local prettier_exe = 'prettier'; if vim.fn.executable(local_prettier) > 0 then prettier_exe = 'yarn prettier' end r...
--------------------------------- --! @file LocalServiceBase.lua --! @brief ローカルサービス基底クラス定義 --------------------------------- --[[ Copyright (c) 2017 Nobuhiko Miyamoto ]] local LocalServiceBase= {} --_G["openrtm.LocalServiceBase"] = LocalServiceBase LocalServiceBase.new = function() local obj = {} return obj end ...
local diamondShopMessage = require(ViewPath.."hall/diamondShop/diamondShopMessage"); require("hall/diamondShop/widget/diamondShopResult"); require("common/commonGameLayer"); require("hall/diamondShop/logic/diamondShopLogic"); require("hall/diamondShop/data/diamondShopConstants"); local DiamondShopMessage = class...