content stringlengths 5 1.05M |
|---|
--[[
******************************************************************
* _____ ___ _ *
* ( _ ) ( _`\ _ ( )_ *
* | (_) | _ __ ___ | (_(_) ___ _ __ (_) _ _ | ,_) *
* | _ |( '__)/'___)`\__ \ /'___)( '__... |
TweakModifyModule = TweakModifyModule or BeardLib:ModuleClass("TweakModify", ItemModuleBase)
TweakModifyModule.type_name = "TweakModify"
TweakModifyModule.required_params = {}
function TweakModifyModule:RegisterHook()
local use_clbk = self._config.use_clbk and self._mod:StringToCallback(self._config.use_clbk) or nil
... |
--[[
© 2020 TERRANOVA do not share, re-distribute or modify
without permission of its author.
--]]
ITEM.name = "Jakey's Lager";
ITEM.model = "models/mark2580/gtav/barstuff/Beer_Jakey.mdl";
ITEM.width = 1;
ITEM.height = 2;
ITEM.description = "A strong, very cold pale ale with a tolerable taste. A taste that you can o... |
-------------------------------------------------------------------------------------------------------------------------------------------------------------
-- VEAF assets functions for DCS World
-- By zip (2019)
--
-- Features:
-- ---------
-- * manage the assets that roam the map (tankers, awacs, ...)
-- * Works wit... |
object_tangible_item_beast_converted_peko_peko_decoration = object_tangible_item_beast_shared_converted_peko_peko_decoration:new {
}
ObjectTemplates:addTemplate(object_tangible_item_beast_converted_peko_peko_decoration, "object/tangible/item/beast/converted_peko_peko_decoration.iff")
|
data:extend({
{
type = "technology",
name = "trade",
icon = "__5dim_trade__/graphics/icon/trader.png",
icon_size = 128,
effects =
{
{
type = "unlock-recipe",
recipe = "5d-coin"
},
{
type = "unlock-recipe",
recipe = "5d-trader"
},
{
type = "unlock-recipe",
recipe = "5d... |
module 'mock'
--[[
each InputScript will hold a listener to responding input sensor
filter [ mouse, keyboard, touch, joystick ]
]]
---------------------------------------------------------------------
CLASS: InputListenerCategory ()
function InputListenerCategory:__init()
self.active = true
self.muted = false
s... |
local S, L, O, U, D, E = unpack(select(2, ...));
local Module = S:NewModule('Options_Categories_Auras');
local LSM = S.Libraries.LSM;
O.frame.Left.Auras, O.frame.Right.Auras = O.CreateCategory(string.upper(L['OPTIONS_CATEGORY_AURAS']), 'auras', 6);
local button = O.frame.Left.Auras;
local panel = O.frame.Right.Auras;... |
--
-- Single village generation
--
local mp = minetest.get_modpath("village")
village.villages = {}
village.chunkdefs = {}
village.chunkdefs["livestock_pen"] = {
entities = {
["mobs:sheep"] = 3,
["mobs:boar"] = 1,
},
}
village.chunkdefs["lamppost"] = { -- not road because of road height limit of 1... |
--[=========================================================================[
Lunity v0.10.1 by Gavin Kistner
See http://github.com/Phrogz/Lunity for usage documentation.
Licensed under Creative Commons Attribution 3.0 United States License.
See http://creativecommons.org/licenses/by/3.0/us/ for details.
--... |
--[[
The Basic Decorelated Batch normalization version, in which:
(1) use ZCA to whitening the activation
(2) include train mode and test mode. in training mode, we train the module
(3) only for 2D input in MLP architecture and running on CPU
Author: Lei Huang
mail: huanglei@nlsde.buaa.edu.cn
]]--... |
module(..., package.seeall)
local bt = require("apps.lwaftr.binding_table")
local constants = require("apps.lwaftr.constants")
local icmp = require("apps.lwaftr.icmp")
local lwcounter = require("apps.lwaftr.lwcounter")
local lwdebug = require("apps.lwaftr.lwdebug")
local lwheader = require("apps.lwaftr.lwheader")
loca... |
-- Clever Ads Solution plugin
local Library = require "CoronaLibrary"
-- Create library
local lib = Library:new{ name="plugin.cas", publisherId="com.cleveradssolution", version=11 }
-------------------------------------------------------------------------------
-- BEGIN
----------------------------------------------... |
local SanctumRaid = LibStub("AceAddon-3.0"):GetAddon("BestInSlotRedux"):NewModule("SanctumRaid")
local Sanctum = "Sanctum"
local playername, realm = UnitFullName("player")
local realm = GetNormalizedRealmName()
function SanctumRaid:OnEnable()
--local L = LibStub("AceLocale-3.0"):GetLocale("BestInSlotRedux")
local sa... |
local status, _ = pcall(require, 'lsp-status')
if not status then return end
local diagnostics = require('lsp-status/diagnostics')
local messages = require('lsp-status/messaging').messages
local aliases = {pyls_ms = 'MPLS'}
local hi = require'vim_ext'.hi
hi('LualineDiagnosticError', { guifg = '#c94f6d', guibg = "#131a... |
--[[
Upbit Open API
## REST API for Upbit Exchange - Base URL: [https://api.upbit.com] - Official Upbit API Documents: [https://docs.upbit.com] - Official Support email: [open-api@upbit.com]
OpenAPI spec version: 1.0.0
Contact: ujhin942@gmail.com
Generated by: https://github.com/swagger-api/swagger-codeg... |
AIDuration = 0.2
VisualRange = 20
local player
local lastAITime = 0
function active()
--startCoroutine(chase)
console.log("active")
player = scene.entity("Player")
startCoroutine(bossAI)
end
function update(dt)
end
function bossAI()
repeat
console.log(player.position)
... |
local recentRobs = {}
Citizen.CreateThread(function()
while true do
Wait(1)
aiming, ent = GetEntityPlayerIsFreeAimingAt(PlayerId())
if aiming then
local pedCrds = GetEntityCoords(PlayerPedId())
local entCrds = GetEntityCoords(ent)
local pedType = GetPedTy... |
--Detect the state
-- Define the signals we will use
RGB = {
[settings.global["sstn-rgb-red-signal"].value] = "r",
[settings.global["sstn-rgb-green-signal"].value] = "g",
[settings.global["sstn-rgb-blue-signal"].value] = "b",
[settings.global["sstn-rgb-alpha-signal"].value] = "a"
}
-- The icon used for our al... |
return function(box, text, onClick, bgColour, textColour, disabled)
local button = {}
button.box = box
button.text = text
button.onClick = onClick
button.bgColour = bgColour or {r = 0.5, g = 0.5, b = 0.5}
button.textColour = textColour or {r = 1, g = 1, b = 1}
button.disabled = disabled
... |
function exists_in_table( tTable, value )
for i,v in ipairs(tTable) do
if ( value == v ) then
return true;
end
end
return false;
end
-- //Esta funcion es parecida al operador ternario de PHP.
function op_ter( c, v, f )
if( c ~= false or c ~= nil ) then
if ( not v ) then v = false end
if( type(v) == "fun... |
local NPC = {};
NPC.Name = "Road Crew";
NPC.ID = 21;
NPC.Model = Model("models/players/perp2/m_2_06.mdl");
NPC.Invisible = false; // Used for ATM Machines, Casino Tables, etc.
NPC.Location = Vector(612.140015, 4471.735840, 74);
NPC.Angles = Angle(0, 90, 0);
NPC.ShowChatBubble = "Normal";
NPC.Sequence = 8
// This... |
if SL.Global.GameMode == "Casual" then return end
-- only show TestInput pane in EventMode; public arcades probably don't want random
-- players attempting to diagnose the pads...
if not GAMESTATE:IsEventMode() then return end
-- DedicatedMenu buttons are necessary here to prevent players from getting stuck in this pa... |
return function()
local PlayerGui = game:GetService("Players").LocalPlayer.PlayerGui
local Roact = require(game.ReplicatedStorage.Roact)
local BindingExample = Roact.Component:extend("BindingExample")
function BindingExample:init()
self.binding, self.updateBinding = Roact.createBinding(0)
end
function Bindi... |
---
--- plugins' handler execute priority definition
--- Created by jacobs Lei.
--- DateTime: 2018/5/9 上午11:41
---
return {
global_access_control = 3000,
global_rate_limit = 2000,
property_rate_limit = 1999,
waf = 1998,
group_rate_limit = 1997,
anti_sql_injection=1996,
api_router = 1995,
... |
Players = {}
C3 = Color3.new
UD = UDim2.new
V2 = Vector2.new
Themes = {
{Name = "Default", Colors = {Main = C3(0.75, 0.8, 0.9), Main2 = C3(0.8, 0.9, 0.9)}},
}
Classes = {"Frame", "TextBox", "ImageLabel", "ImageButton", "TextLabel", "TextButton"}
function Make(Class, Par, Size, Pos, Color, Trans, Border, Borderc, Tx... |
bas = {}
local tickande = {}
local signaler = {}
local grafik = {}
local scheman = {}
local tid = 0
-- Kör alla signaler som har kommit in sen senast
function bas.hanteraSignaler()
repeat
for signal, meddelande in pairs(signaler) do
-- print(signaler[meddelande])
signal(unpack(medd... |
-----------------------------------
-- Area: Aht Urhgan Whitegate
-- NPC: Ulamaal
-- Type: Standard NPC
-- !pos 93.512 -7.5 -128.530 50
-----------------------------------
require("scripts/globals/quests")
require("scripts/globals/settings")
require("scripts/globals/keyitems")
require("scripts/globals/npc_util")
local... |
course_proto = Proto("lingi1341", "LINGI1341 Transmission Protocol")
function course_proto.dissector(buffer,pinfo,tree)
pinfo.cols.protocol = "LINGI1341"
local subtree = tree:add(course_proto,buffer(),
"LINGI1341 Transmission Protocol Data")
if (buffer:len() < 11) then
subtree:add(buffe... |
---@meta
---@class sp.SkeletonAnimation :sp.SkeletonRenderer
local SkeletonAnimation={ }
sp.SkeletonAnimation=SkeletonAnimation
---*
---@param entry spTrackEntry
---@param listener function
---@return self
function SkeletonAnimation:setTrackCompleteListener (entry,listener) end
---*
---@param name string
---@ret... |
--######################################################### Constructor
function SplitBarClass.New(name)
local this=setmetatable({},SplitBarClass)
SplitBarCount=SplitBarCount+1;
this.name=name;
this.xmin=2;
this.ymin=0;
this.xmax=10;
this.ymax=500;
this.gripWidth=10;
this.sizeC... |
--MAXIME
function savePerms(thePlayer, forumPerms)
if not thePlayer or not isElement(thePlayer) or not forumPerms then
return false
end
return setStaffLevel(thePlayer, forumPerms)
end
function getPermissions(userID)
return false, false
end
function setStaffLevel(thePlayer, forumPerms)
setElementData(thePlayer... |
function onCreatePost()
makeLuaText('note hits', 'Note hits:' ..hits.. '', 200, 20, 255);
makeLuaText('combo', 'Combos:' .. getProperty('combo'), 200, 20, 275);
makeLuaText('sicks', 'Sicks:' .. getProperty('sicks'), 200, 20, 295);
makeLuaText('goods', 'Goods:' .. getProperty('goods'), 200, 20, 315);
makeLuaTe... |
BigWigs:AddSounds("Amalgam of Souls", {
[194956] = "Warning",
[196587] = {"Alert","Warning"},
})
BigWigs:AddSounds("Illysanna Ravencrest", {
[197797] = "Alarm",
[197974] = "Alarm",
})
BigWigs:AddSounds("Smashspite", {
[198073] = "Info",
[198079] = "Warning",
[198245] = "Alarm",
[198446] = "Alert",
})
BigWig... |
local camera = require "camera"
local player = require "player"
local input = require "input"
local draw = require "draw"
local map = require "map"
local dr = draw.new()
local cam = camera.new()
local world = love.physics.newWorld(0, -1000, true)
local map = map.new(world)
local inp = input.new()
local pl = player.new... |
local actum = require('actum')
local lovebind = {}
lovebind.swipe = {}
lovebind.down = {}
-- Mouse events
lovebind.mousepressed = actum:event()
function love.mousepressed(...)
lovebind.mousepressed:trigger(...)
lovebind:startswipe(...)
end
lovebind.mousereleased = actum:event()
function love.mousereleased(...)... |
local Component = import("..Component")
local EventProtocol = class("EventProtocol", Component)
function EventProtocol:ctor()
EventProtocol.super.ctor(self, "EventProtocol")
self.listeners_ = {}
self.listenerHandleIndex_ = 0
self.debug_ = false
end
function EventProtocol:addEventListener(eventName, l... |
--[[
© 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
--]]
local Clockwork = Clockwork;
local COMMAND = Clockwork.command:New("CfgSetVar");
... |
--用户模块
--Copyright (C) Yuanlun He.
--[[如果是数据库表格,可以如下:
return require('ActiveRecord'){
tableName = function()
return 'userinfos'
end
}
]]
local require = require
local tonumber = tonumber
local util = require("vendor.Util")
local _M = require("vendor.Model"):new{_version='0.0.1'}
local userinfo... |
-- Token moderation
-- This module looks for a field on incoming JWT tokens called "moderator".
-- If it is true the user is added to the room as a moderator, otherwise they are set to a normal user.
local is_admin = require "core.usermanager".is_admin;
local jid_split = require "util.jid".split;
local jid_bare = requi... |
---
-- @classmod FABRIKBone
local UNIT_NZ = Vector3.new(0, 0, -1)
local function getRotationBetween(u, v, axis)
local dot, uxv = u:Dot(v), u:Cross(v)
if (dot < -0.99999) then return CFrame.fromAxisAngle(axis, math.pi) end
return CFrame.new(0, 0, 0, uxv.x, uxv.y, uxv.z, 1 + dot)
end
local FABRIKBone = {}
FABRIKBon... |
OtherUI = {
ValidTypes = {
"ElevatorFloorTerminal",
-- "RoadBlock"
},
States = {
CityLights = "Default",
Police = "Default"
},
HeaderLabel = "OTHER",
HeaderCitywideLabel = "CITY WIDE"
}
local Theme = require("ui/theme")
local Util = require("hacks/modules/utilit... |
local Class = _G.StopwatchMod.Settings
local Mod = _G.StopwatchMod.Mod
local Util = _G.StopwatchMod.Util
Class.SETTINGS_FILE = SavePath .. "StopwatchSettings.json"
Class.data = {}
function Class:get(key)
if self.data[key] ~= nil then
return self.data[key]
end
return nil
end
function Class:set(ke... |
--[=[
Left grip
@class IKLeftGrip
]=]
local IKGripBase = require(script.Parent.IKGripBase)
local IKLeftGrip = setmetatable({}, IKGripBase)
IKLeftGrip.ClassName = "IKLeftGrip"
IKLeftGrip.__index = IKLeftGrip
function IKLeftGrip.new(ObjectValue: ObjectValue)
local self = setmetatable(IKGripBase.new(ObjectValue), IK... |
--------------------------------------------------------------------------------
------------------------------ ##### ## ------------------------------
------------------------------ ## ## # ## ------------------------------
------------------------------ ## ## ## ## ---------------------------... |
function onCreate()
-- background shit
makeLuaSprite('stageback', 'nothappy_sky', -280, -80);
setScrollFactor('stageback', 0.1, 0.1);
scaleObject('stageback', 1.2, 1.2);
makeLuaSprite('stagefront', 'nothappy_ground', -537, -250);
setScrollFactor('stagefront', 0.9, 0.9);
makeLuaSprite('stagecurtains',... |
Paused = Object:extend()
function Paused:new(stage)
self.stage = stage
self.font = fonts.Anonymous_8
self.resume = true
fadeVolume('music', 1, 0.05)
end
function Paused:update(dt)
if input:pressed('left') or input:pressed('right') then self.resume = not self.resume end
if input:pressed('return... |
return Device {
strManufacture = "TeenyUSB",
strProduct = "TeenyUSB Custom HID",
strSerial = "TUSB123456",
idVendor = 0x0483,
idProduct = 0x0004,
prefix = "HID",
Config {
USB_HID{
ReadEp = EndPoint(IN(1), Interrupt, 64),
WriteEp = EndPoint(OUT(1), Interrupt, ... |
minetest.register_craft({
output = "default:obsidian_shard 14",
recipe = {
{"mystical_agriculture:water_essence","mystical_agriculture:fire_essence","mystical_agriculture:water_essence"},
{"mystical_agriculture:fire_essence","default:cobble","mystical_agriculture:fire_essence"},
{"mystical_agriculture:water_ess... |
----------------------------------
print("Weezl Mod Lob - ModHelper")
---------------------------------- |
local filesystem = require("filesystem")
local shell = require("shell")
local args = {...}
shell.setPath(shell.getPath() .. ":/mnt/"..args[1].address:sub(1,3).."/bin/")
|
GM.Name = "Trouble in Terrorist Town"
GM.Author = "Bad King Urgrain"
GM.Website = "ttt.badking.net"
GM.Version = "2019-03-03"
GM.Customized = false
-- Round status consts
ROUND_WAIT = 1
ROUND_PREP = 2
ROUND_ACTIVE = 3
ROUND_POST = 4
-- Player roles
ROLE_INNOCENT = 0
ROLE_TRAITOR = 1
ROLE_DETECTIVE = 2
ROLE_MERCENARY... |
local M = {}
function M.send_client_request(client_name, ...)
for _, client in pairs(vim.lsp.get_active_clients()) do
if client.name == client_name then
client.request(...)
end
end
end
return M
|
--
-- Created by IntelliJ IDEA.
-- User: renan.silva
-- Date: 09/05/2020
-- Time: 14:28
-- To change this template use File | Settings | File Templates.
--
Board = Class{}
function Board:init(sizeX, sizeY)
self.sizeX = sizeX
self.sizeY = sizeY
self.bricks = {}
self.initialX = 32
self.initialY = 32
... |
local filename,text = ...
print(filename)
local file = io.open(filename, 'w')
file:close()
local _,err = file:write(text)
--print(err)
return err
|
vim.wo.foldmethod = "expr"
vim.wo.foldexpr = "nvim_treesitter#foldexpr()"
local select = {
enable = true,
keymaps = {
-- You can use the capture groups defined in textobjects.scm
["af"] = "@function.outer",
["if"] = "@function.inner",
["ac"] = "@class.outer",
["ic"] = "@class.inner",
},
}
local swap = {
... |
local Modules = script.Parent.Parent.Parent.Parent
local Roact = require(Modules.Roact)
local function BoxAdorn(props)
if props.Adornee.ClassName == "Attachment" then
return Roact.createElement("BoxHandleAdornment", {
Adornee = props.Adornee.Parent,
CFrame = props.Adornee.CFrame,
Size = Vector3.new(1.2, 1.... |
arealist = {length = 0, lastid = 0}
function area_make(x1,y1,z1,x2,y2,z2,player,data)
arealist.lastid = arealist.lastid + 1
return {
x1 = x1, y1 = y1, z1 = z1,
x2 = x2, y2 = y2, z2 = z2,
hook_block = function (area,x,y,z,player,bidx,sockfd) return 0 end,
hook_tick = function (area) end,
hook_playerin = fun... |
-- Copyright 2019 - 2020 kvedder@seas.upenn.edu
-- School of Engineering and Applied Sciences,
-- University of Pennsylvania
--
-- 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 rest... |
class "C4Spawner"
C4Spawner.MaxC4 = 10
C4Spawner.SpawnDelay = 1
function C4Spawner:__init()
self.timer = Timer()
self.playerData = {}
Events:Subscribe( "ModuleLoad", self, self.ModuleLoad )
Events:Subscribe( "PlayerJoin", self, self.PlayerJoin )
Events:Subscribe( "PlayerQuit", self, self.PlayerQuit )... |
local tmux = {}
local apps = require "apps"
-- TODO: Use python to script iTerm2: https://iterm2.com/python-api/
-- Executes a shell command and returns the result (without trailing whitespace)
function exec(cmd)
-- TODO use hs.task
local handle = io.popen(cmd, "r")
local output = handle:read("*a")
handle:cl... |
--Notes here
local memory, bit, memory2, input, callback, movie, utime = memory, bit, memory2, input, callback, movie, utime
local base = string.gsub(@@LUA_SCRIPT_FILENAME@@, "(.*[/\\])(.*)", "%1")
local Promise = nil
local util = nil
local mathFunctions = dofile(base.."/mathFunctions.lua")
local config = dofile(bas... |
return {
base = {rect={0,0,45,60}, origin={17,45}}
}
|
-- ========== THIS IS AN AUTOMATICALLY GENERATED FILE! ==========
PlaceObj('XTemplate', {
__is_kind_of = "XLayer",
group = "Layers",
id = "DurangoActivePlayer",
PlaceObj('XTemplateWindow', {
'__class', "XLayer",
}, {
PlaceObj('XTemplateFunc', {
'name', "Open",
'func', function (self, ...)
XLayer.Ope... |
local Guardian = {
name = "Guardian",
id = "Hc00"
}
function SpawnGuardians()
local m_CreatedUnit = nil
local i = 0
while i < 4 do
m_CreatedUnit = CreateUnit(Player(i), FourCC(Guardian.id), -260 + i * 200, -160, 90)
-- Print Stats:
print(BlzGetUnitMaxH... |
return {'tezamen','tezelfdertijd','tezen'} |
--------------------------------------------------------------------------------
-- Module declaration
--
local mod, CL = BigWigs:NewBoss("Vizier Jin'bak", 1011, 693)
if not mod then return end
mod:RegisterEnableMob(61567)
mod.engageId = 1465
mod.respawnTime = 30
-----------------------------------------------------... |
----------------------------
--版权:
--作者: liubo (564773807@qq.com)
--时间: 2016-04-30 22:13:15
--作用: 蓝牙模块接口管理
--备注:
----------------------------
local BleManager = {}
local bleManager = NetworkManagerFactory:produceBleManager()
function BleManager.searchBleAndConnect()
bleManager:searchBleAndConnect()
end
function... |
require("util")
--offset from train stop to first cart
local offset = {}
offset[defines.direction.north] = {x = -2, y = 3}
offset[defines.direction.east] = {x = -3, y = -2}
offset[defines.direction.south] = {x = 2, y = -3}
offset[defines.direction.west] = {x = 3, y = 2}
--return the train that could be at th... |
-- module: Battery notifications
local m = {}
local utime = require('utils.time')
local isCharged = hs.battery.isCharged()
local percentage = hs.battery.percentage()
local powerSource = hs.battery.powerSource()
local notifiedAt = {
[20] = false,
[15] = false,
[10] = false,
[5] = false,
}
-- send a notif... |
local config = require "config"
local site = require "controller.site"
local user = require "controller.user"
local sign = require "controller.sign"
local static = require "controller.static"
local topic = require "controller.topic"
local reply = require "controller.reply"
local system = require "controller.sys... |
local http = require("socket.http")
local ltn12 = require("ltn12")
-- The Request Bin test URL: http://requestb.in/12j0kaq1
function sendRequest()
local path = "http://requestb.in/12j0kaq1?param_1=one¶m_2=two¶m_3=three"
local payload = [[ {"key":"My Key","name":"My Name","description":"The description","stat... |
local solution = {}
function solution.sayHello(name)
return "Hello, " .. name
end
return solution |
local base_controller = require "kong.api.routes.base_controller"
local spec_helper = require "spec.spec_helpers"
local env = spec_helper.get_env()
describe("Base Controller", function()
it("should not parse params with empty values", function()
local result = base_controller.parse_params(env.dao_factory.consu... |
print("\27[31m SDL crushes with DCHECK. Some tests are commented. After resolving uncomment tests!\27[0m")
---------------------------------------------------------------------------------------------
-- CRQ: APPLINK-25200: [GENIVI] VehicleInfo interface: SDL behavior in case HMI does not
-- res... |
local guid = 'D2F36B62-A470-418D-83A3-ED7A3710E5B5';
local guid_main_menu = "45453CAC-499D-4B37-82B8-0A77F7BD087C";
Macro {
area = "Editor";
key = "AltL";
flags = "";
description = "Editor: List of types";
action = function()
Plugin.Call(guid, 1);
-- universal workaround for Far3 > 4242 and betwee... |
-----------------------------------
-- Area: Beadeaux (254)
-- Mob: Zircon Quadav
-- Note: PH for Zo'Khu Blackcloud
-----------------------------------
local ID = require("scripts/zones/Beadeaux/IDs")
require("scripts/globals/mobs")
function onMobDeath(mob, player, isKiller)
end
function onMobDespawn(mob)
tpz.mo... |
util = require('util')
rs_1_1 = util.replicasets[1]
rs_1_2 = util.replicasets[2]
rs_2_1 = util.replicasets[3]
rs_2_2 = util.replicasets[4]
local cfg_1 = {replication_connect_quorum = 0}
cfg_1.sharding = {
[rs_1_1] = {
replicas = {
[util.name_to_uuid.storage_1_1_a] = {
uri = 'st... |
--[[
_______ ______ ______ _____ _ _ _______ ______ ______ _____ _ _
| |______ |_____] |_____/ | |____/ |_____| |_____] |_____/ | | |____/
|_____ |______ |_____] | \_ __|__ | \_ | | |_____] | \_ |_____| | \_
... |
ITEM.name = "Meatchunk"
ITEM.model ="models/nasca/etherealsrp_artifacts/meatchunk.mdl"
ITEM.description = "Looks like flayed skin. Artifact."
ITEM.longdesc = "This artifact has soft, porous, skin-like texture and is said to be able to compress. It resembles and acts like a sponge in this regard, but reveals its special... |
TURBO_SSL = true -- Enable SSL since we are querying a https:// url.
local turbo = require("turbo")
local turboredis = require("turboredis")
local yield = coroutine.yield
local GITHUB_URL = "https://api.github.com/users/%s/repos"
-- Create a new connection to Redis
local redis = turboredis.Connection:new({host="127.0.... |
--
-- Licensed to the Apache Software Foundation (ASF) under one or more
-- contributor license agreements. See the NOTICE file distributed with
-- this work for additional information regarding copyright ownership.
-- The ASF licenses this file to You under the Apache License, Version 2.0
-- (the "License"); you may ... |
---@tag telescope-file-browser.actions
--@module telescope-file-browser.actions
---@brief [[
--- The file browser actions are functions enable file system operations from within the file browser picker.
--- In particular, the actions include creation, deletion, renaming, and moving of files and folders.
---
--- You c... |
local reminds = {};
RegisterCommand('remindme', function(source, args, rawCommand)
if source > 0 then
if args[1] ~= nil then
if not string.find(args[1], ':') or string.find(args[1], '60') then
TriggerClientEvent('chat:addMessage', source, {
color={255, 0, 0},
args={'System', 'You need to us... |
--[[
===============================================================================
** Troop v1.0 **
By Lysferd (C) 2015
===============================================================================
--]]
Troop = { }
Troop.__index = Troop
--------------------------------------------------------------------------... |
local function makeassetlist()
return {
Asset("ANIM", "anim/phonograph.zip"),
}
end
local WORLD_UNLOCK_DB_RECORD = "d9ney"
local function makefn(name, frame, description)
local function fn(Sim)
local inst = CreateEntity()
local trans = inst.entity:AddTransform()
local anim = inst.entity:AddAnimSta... |
return function()
local World = require(script.Parent)
local T = require(script.Parent.Parent.Core.T)
describe("getReactor", function()
it("should not error when given withUpdated", function()
local world = World.new({
{
name = "MyComponent",
type = T.table,
},
})
local MyComponent = w... |
core:import("CoreMissionScriptElement")
ElementCustomSound = ElementCustomSound or class(CoreMissionScriptElement.MissionScriptElement)
-- CustomSound Element
-- Creator: Nepgearsy
-- How it Works
-- PRIMARY CHANNEL : Used for dynamic custom musics. Do not use any of the other channels to use that one.
-- SECON... |
local txt = core.construct("guiTextBox", {
parent = core.interface,
size = guiCoord(0, 200, 0, 20),
position = guiCoord(0.5, -100, 0.75, -10),
text = "Use [Q] and [E] to rotate camera",
textAlign = "middle"
})
spawn(function()
sleep(5)
core.tween:begin(txt, 2, {
backgroundAlpha = 0... |
InEditorOptions = InEditorOptions or class(EditorPart)
local Options = InEditorOptions
function Options:init(parent, menu)
self.super.init(self, parent, menu, "Options")
self._wanted_elements = {}
end
--TODO: cleanup
function Options:build_default()
local groups_opt = {offset = {8, 4}}
local main ... |
g_Worlds = {}
function LoadConfig(a_Path)
local ConfigContent = cFile:ReadWholeFile(a_Path)
local CfgLoader, Err = loadstring("return {" .. ConfigContent .. "}")
if (not CfgLoader) then
return false, "Error while loading config: " .. Err
end
local Succes, Result = pcall(CfgLoader)
if (not Succes) th... |
ESX = nil
TriggerEvent('esx:getSharedObject', function(obj)
ESX = obj
end)
RegisterServerEvent('esx_gym:checkChip')
AddEventHandler('esx_gym:checkChip', function()
local _source = source
local xPlayer = ESX.GetPlayerFromId(_source)
local oneQuantity = xPlayer.getInventoryItem('gym_membership').count
if oneQu... |
#!/usr/bin/env lua
-- MoonSndFile example: hello.lua
sf = require('moonsndfile')
NFRAMES = 64 -- no. of frames requested at each read
CHANNEL_GAIN = { 0.5, 0.8, 0.1, 0.4, 0.4, 0.9 }
MAX_CHANNELS = #CHANNEL_GAIN
function process_data(data, channels)
-- Unpack the data binary string to a table of doubles:
local ... |
local M = {}
local Z = {}
function M.init(use)
use {
'ggandor/lightspeed.nvim'
}
return Z;
end
function Z.setup()
local ok, lib = pcall(require, 'lightspeed')
if not ok then
return;
end
lib.setup({
ignore_case = false,
exit_after_idle_msecs = { unlabeled = 1000, labeled = nil },
--... |
local E, C, L = select(2, ...):unpack()
if not C.misc.socialtabs.enable then return end
----------------------------------------------------------------------------------------
-- SoicalTabs
----------------------------------------------------------------------------------------
local cfg = C.misc.socialtabs
local ... |
local mock_loop = require 'spec.mock_loop'
local function not_empty(t)
assert.not_same({}, t)
end
describe("textDocument/didOpen", function()
it("triggers", function()
mock_loop(function(rpc, s_rpc)
spy.on(s_rpc, "notify")
local methods = require 'tarantool-lsp.methods'
local opened = spy.on(methods, "te... |
return {
corsbomb = {
acceleration = 0.03594,
blocking = false,
brakerate = 0.015,
buildcostenergy = 121336,
buildcostmetal = 3307,
builder = false,
buildpic = "corsbomb.dds",
buildtime = 85000,
canattack = true,
cancloak = true,
canfly = true,
canguard = true,
canmove = true,
... |
vim.cmd [[packadd! plenary.nvim]]
vim.cmd [[packadd! popup.nvim]]
vim.cmd [[packadd! telescope.nvim]]
local finders = require('telescope.finders')
local previewers = require('telescope.previewers')
local pickers = require('telescope.pickers')
local sorters = require('telescope.sorters')
local utils = require('telescop... |
Vector2 = Object:extend()
function Vector2:new(x, y)
self.x = x
self.y = y
end
function Vector2:normal()
return Vector2(self.x / self:length(), self.y / self:length())
end
function Vector2:length()
return math.sqrt((self.x * self.x) + (self.y * self.y))
end
function Vector2:resize(length)
local ... |
Script.Load("lua/ExtraEntitiesMod/eem_Shared.lua") |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.