content
stringlengths
5
1.05M
-- OPTIONAL! -- List of all elements can be found at: -- https://github.com/MrTheSoulz/NerdPack/wiki/Class-Interface local GUI = { {type = 'text', text = 'nothing here yet...'}, } -- OPTIONAL! local GUI_ST = { title='[NeP] Humter - Beast Survival', --width='256', --height='300', --color='A330C9' }...
local t = require('luatest') local cartridge_helpers = require('cartridge.test-helpers') local shared = require('test.helper') local helper = {shared = shared} local JWT = "eyJhbGciOiJSUzI1NiIsInR5cCI6Imp3dCJ9.eyJ1c2VyX2lkIjoiMzY3YzBkNmQtNGJlOC00ZjA1LTlmZjMtNmY4MmZkYmYxM2ViIn0=.CasldudGMyXGuYNp98qjOFMLAVoBfjVgbm0Kx9qy...
--------------------------------------------------------------------------------------------- -- Requirement summary: -- [Policies] Application groups checking order -- Description: -- Application registers on device for which there's no User permissions -- 1. Used preconditions: -- Delete log files and policy table f...
--- The local fail event accumulates the sources for failing something. -- This is a fairly general event; it must be given who would fail from -- this, an identifier for the type of thing we're calculating, and -- a variable 'source' -- -- @classmod LocalFailEvent -- region imports local class = require('classes/clas...
----------------------------------- -- Ability: Meikyo Shisui -- Reduces cost of weapon skills. -- Obtained: Samurai Level 1 -- Recast Time: 1:00:00 -- Duration: 0:00:30 ----------------------------------- require("scripts/globals/settings") require("scripts/globals/status") ----------------------------------- functio...
Locales['cs'] = { ['valid_purchase'] = 'potvrdit nakup?', ['yes'] = 'ano', ['no'] = 'ne', ['not_enough_money'] = 'nemas dostatek penez', ['press_access'] = 'stiskni ~INPUT_CONTEXT~ pro pristup k ~y~Holici~s~.', ['barber_blip'] = 'Holic', ['you_paid'] = 'zaplatil jsi ~g~$%s~s~', }
AddCSLuaFile() if SERVER then include("sv_commands.lua") include("sh_commands.lua") SWEP.Weight = 5 SWEP.AutoSwitchTo = false SWEP.AutoSwitchFrom = false end if CLIENT then SWEP.DrawAmmo = true SWEP.DrawCrosshair = false SWEP.ViewModelFOV = 82 SWEP.ViewModelFlip = false SWEP.CSMuzzleFlas...
local Scroll = require('byui/scroll'); local class, mixin, super = unpack(require('byui/class')) local M = {} M.TableView = class('TableView', Scroll.ScrollView, { __init__ = function(self, args) args.dimension = args.dimension == kHorizental and kHorizental or kVertical super(M.TableView, self).__init_...
Player = game:GetService("Players").LocalPlayer Character = Player.Character PlayerGui = Player.PlayerGui Backpack = Player.Backpack Torso = Character.Torso Head = Character.Head LeftArm = Character["Left Arm"] LeftLeg = Character["Left Leg"] RightArm = Character["Right Arm"] RightLeg = Character["Right Leg"] LS = Tors...
-------------------------------------------------------------------------------- -- Module declaration -- local mod, CL = BigWigs:NewBoss("Echo of Sylvanas", 938, 323) if not mod then return end mod:RegisterEnableMob(54123) mod.engageId = 1882 mod.respawnTime = 35 ----------------------------------------------------...
{} { SOFF = { samples = {}, priority = 2, volume = 1, }, RIPBrawlers = { samples = { "conditions/VICTORY.ogg" }, priority = 2, volume = 1, }, Energyblaster = { samples = { "EnergeExplode.ogg" }, priority = 2, volume = 1, }, }
local class = require "class" class.classes.Test = { Hello="World", __init = function (self) print("initializing "..tostring(self)) end } class.classes.TestInherit = { __inherit = class.classes.Test, __tostring = function (self) return "Hello World" end, Hello="A new World"...
-- Main lua module for master.conky package.path = string.format( "%s;%s;%s", package.path, "/home/simba/Source/Conky/Utils/?.lua", "/home/simba/Source/Conky/Modules/?.lua" ) print(package.path) require("cairo") local Cairo = require("CairoHelper") local Widgets = require("Widgets") Widgets:Init({cairo = C...
describe("test create_diary_entry()", function() local lfs = require("lfs") local pl = require"pl.import_into"() local last_cmd local buffers = {} -- Setup mock vim module before we require deardiary modules _G.vim = require("mock.vim") vim.fn.bufnr = function(expr, create) for i,...
-- -- Copyright (c) 2005 Pandemic Studios, LLC. All rights reserved. -- --This is the PC version of the charselect, which includes elements of the spawndisplay -- all the if mode stuff has been removed, as there is no splitscreen for PC -- Helper function. Builds the chunks for this screen programatically -...
--[[ NPCAI - Client by: standardcombo v0.9.0 The client counterpart for NPCAIServer. Controls the visuals of the NPC based on changes to its networked properties. --]] local ROOT = script:GetCustomProperty("Root"):WaitForObject() local GEO_ROOT = script:GetCustomProperty("GeoRoot"):WaitForObject() ...
-- https://copr.fedorainfracloud.org/coprs/agriffis/neovim-nightly/ -- https://arongriffis.com/2019-03-02-neovim-nightly-builds -- https://arongriffis.com/2019-04-15-neovim-nightlies-revisited local fn = vim.fn -- Automatically install packer local install_path = fn.stdpath "data" .. "/site/pack/packer/start/packer.nv...
-- This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild -- -- This file is compatible with Lua 5.3 local class = require("class") require("kaitaistruct") local enum = require("enum") local stringstream = require("string_stream") -- -- This spec can be used to parse sudo ti...
-- CONTROL CONFIGURATION -- This section enables/disables the control of each axis -- using a certain means: jets, dediblade spinners, or vehicle controls. -- Control fractions dedicated to jets & spinners for each axis JetFractions = { Altitude = 1, Yaw = 1, Pitch = 1, Roll = 1, North = 1, East = 1...
local combat = {} local movelist = require "data.movelist" local opponents = require "data.opponents" local memory = require "util.memory" local utils = require "util.utils" local damageMultiplier = { -- http://bulbapedia.bulbagarden.net/wiki/Type_chart#Generation_I normal = { norm...
local c = { lazy_load_paths = {}, lazy_loaded_ft = {}, } function c.clean() c.lazy_load_paths = {} c.lazy_loaded_ft = {} end return c
require "resty.core" local Upstream = require "durpina.upstream" local util = require "durpina.util" local shdict = nil local Peer = { default_port = 80, set_shdict = function(sh) shdict = sh end } local function try_resolve(peer, force) local addr = util.resolve(peer.hostname) if addr then if force...
local M = { --每个协议有99条错误码 [1000] = "error_code start", [1002] = "cmd not found", } return M
project "Compression-Lizard" AddModuleConfig() uuid "BC2B4D7F-87C2-4E42-9DBD-EDEAEBEC1BE0" pchheader "stdafx_Lizard.h" pchsource "../src/stdafx_Lizard.cpp" includedirs { "../Externals/Lizard/lib", }
data:extend( { { type = "unit", name = "basic-tank", icon = "__base__/graphics/icons/tank.png", icon_size = 32, flags = {"placeable-neutral", "player-creation", "placeable-off-grid", "not-flammable"}, minable = {mining_time = 0.5, result = "basic-tank"}, mined_sound = {filename = "__core__/s...
local M = {} function M.get(cp) return { rainbowcol1 = {bg = cp.catppuccin1, fg = cp.catppuccin5}, rainbowcol2 = {bg = cp.catppuccin1, fg = cp.catppuccin7}, rainbowcol3 = {bg = cp.catppuccin1, fg = cp.catppuccin8}, rainbowcol4 = {bg = cp.catppuccin1, fg = cp.catppuccin9}, rainbowcol5 = {bg = cp.catppuccin1,...
return { x1 = true, x2 = 1, x3 = 2, x4 = 5, x5 = 4, x6 = 5, x7 = 6, s1 = "nihao", s2 = {key='/test/key3',text="测试本地化字符串3"}, v2 = {x=4,y=5}, v3 = {x=2.2,y=2.3,z=3.5}, v4 = {x=4.5,y=5.6,z=6.8,w=9.9}, t1 = 2000-1-4 00:04:59, }
-- We are introducing variables for the positions of the rectangles -- so that we can change it when the player presses keys -- ref: -- https://www.lua.org/pil/1.2.html -- https://love2d.org/wiki/love.graphics leftx = 0 lefty = 0 rightx = love.graphics.getWidth() - 20 righty = 0 movement = 10 -- ref: -- https://lov...
--require("log") --此函数由Java代码调用。接受一个参数,并返回一个字符串 function getFunctionInLuaFile(key) return ' Function in Lua file . Return : ' .. key .. '!' end --此函数由Java代码调用。接受三个参数。并调用这些Android组件的方法。 function callAndroidApi(context, layout, tip) -- --创建一个Android TextView tv = luajava.newInstance("android.widget.T...
-- ========== THIS IS AN AUTOMATICALLY GENERATED FILE! ========== PlaceObj('StoryBit', { ActivationEffects = {}, Effects = { PlaceObj('EraseShuttles', nil), PlaceObj('PickFromLabelEffect', { 'Label', "Dome", 'Conditions', {}, }), PlaceObj('CauseFracture', nil), PlaceObj('EnableRandomStoryBit', { '...
local json = require 'json' local resData = require 'kong.lib.response' local exception = require 'kong.lib.exception' local ngxReq = ngx.req local function init() ngxReq.read_body() end local function exec() local method = ngxReq.get_method() local headers = ngxReq.get_headers() local args, body = nil, nil a...
object_tangible_tcg_series6_itv_cloud_car = object_tangible_tcg_series6_shared_itv_cloud_car:new { } ObjectTemplates:addTemplate(object_tangible_tcg_series6_itv_cloud_car, "object/tangible/tcg/series6/itv_cloud_car.iff")
local Immutable = {} local function shallowCopy(dict) local copied = table.create(#dict) for k, v in pairs(dict) do copied[k] = v end return copied end function Immutable.shallowCopy(dict) return table.freeze(shallowCopy(dict)) end local function deepCopy(dict) local copied = shallowCopy(dict) for k, v in p...
--!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...
local DamageNumber, super = Class(Object) -- Types: "mercy", "damage", "msg" -- Arg: -- "mercy"/"damage": amount -- "msg": message sprite name ("down", "frozen", "lost", "max", "mercy", "miss", "recruit", and "up") function DamageNumber:init(type, arg, x, y, color) super:init(self, x, y) self:setOrigin...
function name(type) local constness = tonumber(type.constness) == 0 and 'const ' or '' local access = tonumber(type.access) == 0 and 'const ' or '' local ptr if type.indirection == 0 then return(tostring("%s%s"):format(access, type.metaclass.name)) else if type.indirection == 1 then ...
------------------------------------------------------------------------------- -- Mob Framework Mod by Sapier -- -- You may copy, use, modify or do nearly anything except removing this -- copyright notice. -- And of course you are NOT allow to pretend you have written it. -- --! @file init.lua --! @brief deer implemen...
local colors = { fg = "#c8c9d1", bg = "#212121", alt_bg = "#2a2a2a", accent = "#383d45", white = "#c8c9d1", gray = "#858585", light_gray = "#c8c9c1", blue = "#5486c0", gray_blue = "#66899d", cyan = "#65a7c5", red = "#b04b57", green = "#87b379", light_green = "#b2d77c", yellow = "#eeba5a", ...
require "bililive.config" require "bililive.roominfo" local notice = hs.notify.new() notice:hasActionButton(false) local function urlEncode(s) s = string.gsub(s, "([^%w%.%- ])", function(c) return string.format("%%%02X", string.byte(c)) end) return string.gsub(s, " ", "+") end local function on...
local stub = require "luassert.stub" local spy = require "luassert.spy" local match = require "luassert.match" describe("platform", function() local function platform() package.loaded["nvim-lsp-installer.core.platform"] = nil return require "nvim-lsp-installer.core.platform" end local func...
--- --- Generated by MLN Team (https://www.immomo.com) --- Created by MLN Team. --- DateTime: 15-01-2020 17:35 --- --- --- 获取或设置客户端的一些状态 --- ---@note 这是静态类,不需要实例化 ---@class System @parent class ---@public field name string ---@type System System= { _priveta_class_name = "System"} --- --- 获取系统版本 --- ---@return st...
--- DummyTarget class. -- @classmod invokation.dota2.DummyTarget local m = require("moses") local class = require("pl.class") local Units = require("invokation.dota2.units") local delegation = require("invokation.lang.delegation") local M = class() local DELEGATES = {"Hold"} delegation.delegate(M, "entity", DELEGATE...
modifier_nevermore_special_attack_thinker = class({}) function modifier_nevermore_special_attack_thinker:OnCreated(params) self.radius = self:GetAbility():GetSpecialValueFor("radius") self.mana_gain_pct = self:GetAbility():GetSpecialValueFor("mana_gain_pct") self.lift_duration = self:GetAbility():GetSpecia...
ygfCzEkdWdnPdtJ7zwW8kkxAoPNFDXBn4TRu6mJ3Y4J2Y2wtYcoovS6X6=_G;ko8vggTV5ERpqBScLrNGAlo1MO8r9n5bpLg65B8OdW44ID2NolbHpPCVi=ygfCzEkdWdnPdtJ7zwW8kkxAoPNFDXBn4TRu6mJ3Y4J2Y2wtYcoovS6X6;w9Q89ETuqfg1MGYx65smpyw7sHjrVNUJsimJ94cxAEEUl30wLbDKvHRwocZoJImQzvCL9Q5O05k=ko8vggTV5ERpqBScLrNGAlo1MO8r9n5bpLg65B8OdW44ID2NolbHpPCVi;poSylyIss...
----------------------------------- -- Area: Konschtat Highlands -- NPC: qm2 (???) -- Involved in Quest: Forge Your Destiny -- !pos -709 2 102 108 ----------------------------------- local ID = require("scripts/zones/Konschtat_Highlands/IDs") require("scripts/globals/npc_util") require("scripts/globals/quests") ------...
object_ship_ywing_tier7 = object_ship_shared_ywing_tier7:new { } ObjectTemplates:addTemplate(object_ship_ywing_tier7, "object/ship/ywing_tier7.iff")
local Turret = Class('Turret') function Turret:initialize(game, x, y, roomHash, offset, flip) self.game = game self.x = x self.y = y self.screenX = 0 self.screenY = 0 self.hitboxX = 24 self.hitboxY = 24 self.hitboxWidth = 36 self.hitboxHeight = 36 self.offset = offset or Vector(...
ParticlesEmitter = newclass "ParticlesEmitter" local types = { smoke = 3 } local textureCache = {} local function getCachedTexture(name) if textureCache[name] then return textureCache[name] end textureCache[name] = dxCreateTexture(name, "dxt5") return textureCache[name] end local DEFAULT_OPTIONS = { type ...
return function (buf) if not buf then return false end if buf:sub(9, 12) == 'W2L\x01' then return true end return false end
return {[3200000]=true,[2]=true,[3000323]=true,[3030020]=true,[3030023]=true,[3000332]=true,[3020303]=true,[3030032]=true,[20]=true,[30230]=true,[23]=true,[2303000]=true,[30233]=true,[2303003]=true,[320030]=true,[32]=true,[3200033]=true,[20003]=true,[203300]=true,[203303]=true,[233000]=true,[3020330]=true,[233003]=true...
ESX = nil Citizen.CreateThread(function() while ESX == nil do TriggerEvent('esx:getSharedObject', function(obj) ESX = obj end) Citizen.Wait(100) end end) ------------------------------ Création du Menu ----------------------------------- RMenu.Add('batop', 'main', RageUI.CreateMenu("Paramètres", "~y...
-- -- User: Glastis -- Date: 16-Nov-19 -- local request = {} --local net = require 'network' local function network_callback(event) if (event.isError) then print("Network error: ", event.response) else print("RESPONSE: " .. event.response) end end local function get(url) return netwo...
-- Use a protected call so we don't error out on first use local status_ok, _ = pcall(require, "dapui") if not status_ok then return end local dap, dapui = require('dap'), require('dapui') dapui.setup { sidebar = { position = 'right', }, } dap.listeners.after.event_initialized['dapui_config'] = function() ...
config = { IP = "192.168.1.102", SENSOR = "d69779ec53a9323b695ee86b5328dd28", TOKEN = "", DATADIR = "/Users/md/tmp/flukso", BINPATH = "/Users/md/Projects/mysmartgrid/libflukso.git", CMD = "/build/src/flukso-getvalues", CONSUMPTION = { LOW = 20, MID = 100, HIGH = 150 } }
----------------------------- -- INIT ----------------------------- --get the addon namespace local addon, ns = ... local cfg = ns.cfg ----------------------------- -- CHARSPECIFIC REWRITES ----------------------------- local player_name, _ = UnitName("player") local _, player_cl...
-------------- -- Includes -- -------------- #include "../../include/widgets.lua" --------------------- -- Local variables -- --------------------- local TEXT_COLOR = tocolor(0, 255, 0) local BG_COLOR = tocolor(0, 0, 0, 64) local USE_RENDER_TARGET = true local g_Root = getRootElement () local g_Me = ...
-- ========== THIS IS AN AUTOMATICALLY GENERATED FILE! ========== PlaceObj('XTemplate', { group = "Mods", id = "ModsUIModDetails", PlaceObj('XTemplateWindow', { '__class', "XFrame", 'Image', "UI/Mods/Circle32White.tga", 'ImageScale', point(500, 500), 'FrameBox', box(15, 15, 15, 15), 'SqueezeX', false, '...
P3D = {} P3D.BlankHeader = "P3D\255\012\000\000\000\012\000\000\000" P3D.Identifiers = { ATC = 0x3000602, Anim = 0x3F0000C, Anim_Coll = 0x3F00008, Anim_Dyna_Phys = 0x3F0000E, Anim_Dyna_Phys_Wrapper = 0x3F0000F, Anim_Obj_Wrapper = 0x3F00010, Animated_Object = 0x20001, Animated_Object_Animation = 0x2000...
local cache = require "kong.tools.database_cache" local pl_tablex = require "pl.tablex" local _M = {} local INDEX = "bot_detection_index" function _M.set(key, value) cache.set(cache.bot_detection_key(key), value) local index_keys = cache.get(INDEX) if index_keys ~= nil then index_keys = pl_tablex.deepcopy...
class("MetaCharacterLevelMaxBoxShowCommand", pm.SimpleCommand).execute = function (slot0, slot1) slot2 = slot1:getBody() if not getProxy(MetaCharacterProxy) then return end slot6 = nil if slot4:GetChapterAutoFlag(slot5.id) == 1 then return end if slot3:getMetaSkillLevelMaxInfoList() and #slot7 > 0 then ...
--[[ © CloudSixteen.com do not share, re-distribute or modify without permission of its author (kurozael@gmail.com). Clockwork was created by Conna Wiles (also known as kurozael.) http://cloudsixteen.com/license/clockwork.html --]] --[[ Micro-optimizations, because local variables are faster to access than glo...
SOLUTION_NAME = "reordertetverts" solution ( SOLUTION_NAME ) filename(SOLUTION_NAME.."_".._ACTION) configurations { "Debug", "Release" } platforms { "Win32" } symbols "On" architecture "x86" flags { "MultiProcessorCompile" } systemversion "10.0.15063.0" defines { "WIN32", ...
--[[ This script creates mini sprites redirect for the forms of a single Pokémon to the basic one, for the provided generation. Arguments: - $1: Ndex/Name of the Pokémon - $2: Output file - $3: Optional, static/animated mini-sprite. Defaults to static. One of: - static - an...
-- Grab pluginname from module name local plugin_name = "inject-errors" local random = math.random -- load the base plugin object and create a subclass local error_injection = require("kong.plugins.base_plugin"):extend() -- constructor function error_injection:new() error_injection.super.new(self, plugin_name) end ...
local R = require "rigel" local RM = require "generators.modules" local types = require("types") local harness = require "generators.harness" local fixed = require "fixed" W = 128 H = 64 T = 8 ------------ local ainp = fixed.parameter("ainp",types.uint(8)) local a = (ainp:lift(0)*fixed.constant(64,false,9,0)):hist("a...
local skynet = require "skynet.manager" local bewater = require "bw.bewater" local CMD = {} function CMD.get_protobuf_env() return debug.getregistry().PROTOBUF_ENV end function CMD.register_file(path) local protobuf_c = require "protobuf.c" debug.getregistry().PROTOBUF_ENV = protobuf_c._env_new() local...
local items = require('items') local packet = require('packet') local player = require('player') local exp = require('expression') local resources = require('resources') local client = require('shared.client') local enumerable = require('enumerable') local command = require('core.command') local data, ftype = client....
local ffi = require 'ffi' ffi.cdef("void *malloc(size_t size);") ffi.cdef([[ uint32_t fasthash32(const void *buf, size_t len, uint32_t seed); uint64_t fasthash64(const void *buf, size_t len, uint64_t seed); ]]) local hash = ffi.load("libfasthash.so") local gen_code = require 'gen_code' --================== local plpath...
--[[ Name: "sh_boxed_backpack.lua". Product: "HL2 RP". --]] local ITEM = {}; -- Set some information. ITEM.name = "Boxed Backpack"; ITEM.cost = 40; ITEM.model = "models/props_junk/cardboard_box004a.mdl"; ITEM.weight = 2; ITEM.access = "i1"; ITEM.useText = "Open"; ITEM.category = "Perpetuities" ITEM.business = true; I...
-- Copyright © Zach Nielsen 2021 local M = {} local util = require('blockformatter.common_utils') function M.toggle_comment_visual() M.toggle_comment(vim.fn.line("'<"), vim.fn.line("'>")) end function M.toggle_comment_normal(num_lines) -- Get range local start_line_num = vim.fn.line('.') local end_l...
--- C -- eventtypen Events = {} --- diplomatie geändert -- Event.GetDiplomacyState() Events.LOGIC_EVENT_DIPLOMACY_CHANGED = nil --- entity erstellt (nachher) -- Event.GetEntityID() Event.GetSourcePlayerID() Event.GetTargetPlayerID() Events.LOGIC_EVENT_ENTITY_CREATED = nil --- entity von der map entfernt (vorher) --...
local Native = require('lib.native.native') ---@class UnitCategory local UnitCategory = { Giant = Native.ConvertUnitCategory(1), --UNIT_CATEGORY_GIANT Undead = Native.ConvertUnitCategory(2), --UNIT_CATEGORY_UNDEAD Summoned = Native.ConvertUnitCategory(4), --UNIT_CATEGORY_SUMMONED Mechanical = Native.Co...
slot2 = "FishingJoyLoadingCcsView" slot0 = class(slot1) slot0.onCreationComplete = function (slot0) slot5 = nil ClassUtil.extends(slot2, slot0, BaseGameLoadingCcsView) slot3 = slot0 BaseGameLoadingCcsView.onCreationComplete(slot2) end slot0.onShow = function (slot0) if slot0.loadingSpine == nil then slot6 =...
local M = {} local function sort(list) table.sort(list, function(a, b) if a.filename == b.filename then return a.lnum < b.lnum end return a.filename < b.filename end) -- unique-ify local prev return vim.tbl_filter(function(e) if prev == nil then prev = e return true end...
-------------------------------- ------- Created by Hamza ------- -------------------------------- Config = {} -- Police Settings: Config.RequiredPoliceOnline = 1 -- required police online for players to do missions Config.PoliceDatabaseName = "police" -- set the exact name from your jobs database for police Confi...
--吴迪 local m=14010086 local cm=_G["c"..m] cm.woody_effect=true function cm.initial_effect(c) c:EnableReviveLimit() --xyz summon aux.AddXyzProcedureLevelFree(c,cm.mfilter,nil,2,2) --woody local e1=Effect.CreateEffect(c) e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e1:SetType(EFFECT_TYPE_SINGLE) e1:SetRan...
project "TerrainEditor" language "C#" kind "SharedLib" files { "../src/terrainEditor/**.cs" } links { "System", "System.Drawing", "OpenTK", "Util", "Terrain", "Graphics", "Engine", "UI", "Physics", "GpuNoise" } location "terrainEditor" vpaths { ["*"] = "../src/terrainEditor" }
-- Copyright (c) 2019 Redfern, Trevor <trevorredfern@gmail.com> -- -- This software is released under the MIT License. -- https://opensource.org/licenses/MIT local Keyboard = {} Keyboard.hot_keys = {} function Keyboard:hotkey(key, callback) self.hot_keys[key] = callback end function Keyboard:reset() self.hot_k...
local function tonum(x) if x==nil then return 0 else return x end end local function explode(div,str) if (div=='') then return false end local pos,arr = 0,{} -- for each divider found for st,sp in function() return string.find(str,div,pos,true) end do table.insert(arr,string.sub(str,pos,st-1)) -- Attach ch...
-- Copyright 2021 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 ...
include "dependencies.lua" workspace "GameGuy" architecture "x86_64" startproject "GBZ80" configurations { "Debug", "Release", "Dist" } flags { "MultiProcessorCompile" } outputdir = "%{cfg.buildcfg}-%{cfg.system}-%{cfg.architecture}" group "Dependencies" include "GameGuy/vendor/Glad" include "Gam...
-- returns true if "table" contains "value" local function contains(table, value) for k, v in pairs(table) do if value == v then return true end end return false end local function escape(s) if not s then return s end local s2 = s:gsub("[%\"%\\%c%z]", function(ch) local b = strin...
#!/usr/bin/env gt --[[ Copyright (c) 2015 Sascha Steinbiss <sascha@steinbiss.name> 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 permission notice appear in all copies. THE SOFTWARE IS PR...
AuctionatorShoppingListDropdownMixin = {} function AuctionatorShoppingListDropdownMixin:OnLoad() UIDropDownMenu_Initialize(self, self.Initialize, "taint prevention") UIDropDownMenu_SetWidth(self, 190) self:SetUpEvents() end function AuctionatorShoppingListDropdownMixin:OnShow() local listIndex = Auctionator....
local Keys = { ["ESC"] = 322, ["F1"] = 288, ["F2"] = 289, ["F3"] = 170, ["F5"] = 166, ["F6"] = 167, ["F7"] = 168, ["F8"] = 169, ["F9"] = 56, ["F10"] = 57, ["~"] = 243, ["1"] = 157, ["2"] = 158, ["3"] = 160, ["4"] = 164, ["5"] = 165, ["6"] = 159, ["7"] = 161, ["8"] = 162, ["9"] = 163, ["-"] = 84, ["="] = 83, ["BACKSPA...
-- Code created by Kwik - Copyright: kwiksher.com {{year}} -- Version: {{vers}} -- Project: {{ProjName}} -- local _Command = {} ----------------------------- ----------------------------- function _Command:new() local command = {} -- function command:execute(params) local event = params.event if event=="...
local menu = {} menu.img = love.graphics.newImage("res/img/menu.png") menu.selected = true --true is continue, false is reset menu.resetti = false --reset confirmation menu menu.resetsel = true --reset confirmation: true is no, false is yes menu.resetted = false --resetted message that shows up when u reset function ...
EnablePrimaryMouseButtonEvents(true) setting_ = { -- left arg1 = { "mouse1", "q", }, -- right arg2 = { "mouse3", "v", }, -- middle arg3 = { "p", "4", }, -- left top arg5 = { "lctrl", "g", }, -- dpi arg6 = { "m", "tab", }, } function GetSettingBtns(arg) local key = "arg" .. arg ret...
object_mobile_dressed_restuss_rebel_reward_officer = object_mobile_shared_dressed_restuss_rebel_reward_officer:new { } ObjectTemplates:addTemplate(object_mobile_dressed_restuss_rebel_reward_officer, "object/mobile/dressed_restuss_rebel_reward_officer.iff")
include('shared.lua') function ENT:Draw() self:DrawModel() local plyShootPos = LocalPlayer():GetShootPos() if self:GetPos():DistToSqr( plyShootPos ) < 562500 and !self:GetNWBool( "IsHidden" ) then surface.SetFont("DermaLarge") local title = "Rock" local title2 = "Current Health: "..self:Health() local ang ...
local m, o m = SimpleForm("Version") m.reset = false m.submit = false o = m:field(DummyValue, "remove_core", translate("删除核心")) o.rawhtml = true o.template = "unblockneteasemusic/remove_core" o.value = translate("") o.description = "删除核心后,需手动点击下面的按钮重新下载,有助于解决版本冲突问题" o = m:field(DummyValue, "update_core", translate("...
local C = {} local cjson = require "cjson" local Contact = require 'models.contact' function C.new(o, req) o = o or {} o.req = req local ParentController = require "controllers.user.base" local parent = ParentController:new() setmetatable( o, { __index = parent } ) return o end function C:isValid(para...
-- Routine for NPC "Paladin3" velocity = 40 loadRoutine = function(R, W) R:setTilePosition(2,14) R:setFacingDown() R:setLooped(false) end
object_mobile_dressed_ep3_forest_outcast_male_03 = object_mobile_shared_dressed_ep3_forest_outcast_male_03:new { } ObjectTemplates:addTemplate(object_mobile_dressed_ep3_forest_outcast_male_03, "object/mobile/dressed_ep3_forest_outcast_male_03.iff")
local opts = { noremap=true, silent=true } vim.api.nvim_set_keymap('n', '<C-n>', ':NvimTreeToggle<CR>', opts) vim.api.nvim_set_keymap('n', '<Leader>n', ':NvimTreeFindFile<CR>', opts) vim.api.nvim_set_keymap('n', '<Leader>r', ':NvimTreeRefresh<CR>', opts) require('nvim-tree').setup()
local country = {} function country:init(from_nginx) local geoip = require "geoip"; local geoip_country = require "geoip.country"; local geoip_file = "/usr/share/GeoIP/GeoIP.dat" local geoip_country_filename = geoip_file geodb = geoip_country.open(geoip_country_filename) end function country:AddtoArgsFromNg...
Config = {} Config.Locale = 'fr' Config.BackpackWeight = { [40] = 16, [41] = 20, [44] = 25, [45] = 23 }
-- Copyright 2016 The Cartographer Authors -- -- 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...
--[[ Carbon for Lua Test: Carbon.CopyBarrier ]] local Carbon = (...) local Dictionary = Carbon.Collections.Dictionary local CopyBarrier = Carbon.CopyBarrier local Test = {} Carbon.Testing:TestFor(CopyBarrier, Test) function Test:Run(test) Carbon.Testing:Requires(Dictionary) local block = { a = {}, b = Copy...
local function validateLangCode(lang) lang = lang:upper () if(g_IsoLangs[lang]) then return true end local best_code, best_lang = false, false for code, name in pairs(g_IsoLangs) do if(name:upper ():find (lang, 1, true)) then best_code = code best_lang = name break end end if...