content stringlengths 5 1.05M |
|---|
local Groups = assert(foundation.com.Groups)
local RollingRegistry = foundation.com.Class:extends("RollingRegistry")
local ic = RollingRegistry.instance_class
function ic:initialize()
ic._super.initialize(self)
end
function ic:find_roller_recipe(item_stack)
local itemdef = item_stack:get_definition()
if Groups... |
local typedefs = require "kong.db.schema.typedefs"
return {
name = "kong-auth-signature",
fields = {
{ run_on = typedefs.run_on_first },
{ protocols = typedefs.protocols_http },
{ config = {
type = "record",
fields = {
{header_key = {
... |
if onServer() then
Player():addScriptOnce("buffs.lua")
end |
if data.raw['map-gen-presets'].default then
local map_settings = data.raw['map-gen-presets'].default
-- Rail World
if map_settings['rail-world'] then
for _, resource in pairs(data.raw.resource) do
if not map_settings['rail-world'].basic_settings.autoplace_controls[resource.name] then
map_setting... |
surface.CreateFont("Arial16Bold", {
font = "Arial",
size = 16,
weight = 700,
blursize = 0,
scanlines = 0,
antialias = true,
underline = false,
italic = false,
strikeout = false,
symbol = false,
rotary = false,
shadow = false,
additive = false,
outlin... |
if not GameSetup and Holo:ShouldModify("Menu", "ColoredBackground") then
if Holo:ShouldModify("Menu", "PlayerProfile") then
Holo:Post(MenuSceneManager, "_set_up_templates", function(self)
self._scene_templates.standard.character_pos = Vector3(-32, 10.66, -137)
end)
end
function MenuSceneManager:HoloUpdate()
... |
-----------------------------------------
-- ID: 4722
-- Scroll of Enfire II
-- Teaches the white magic Enfire II
-----------------------------------------
function onItemCheck(target)
return target:canLearnSpell(312)
end
function onItemUse(target)
target:addSpell(312)
end |
local utils = require('util')
local assert = require('assert')
local tap = require('util/tap')
local sdp = require('rtsp/sdp')
describe("test sdp decode 1", function()
local sdpString = [[v=0
o=- 1453271342214497 1 IN IP4 10.10.42.66
s=MPEG Transport Stream, streamed by the LIVE555 Media Server
i=hd.ts
t=0 0
... |
---@meta
---@class ccs.BaseData :cc.Ref
local BaseData={ }
ccs.BaseData=BaseData
---*
---@return color4b_table
function BaseData:getColor () end
---*
---@param color color4b_table
---@return self
function BaseData:setColor (color) end
---*
---@return self
function BaseData:create () end
---* js ctor
---@return ... |
local Settings = {}
function Settings.new(object, base)
local inst = {
_object = object;
_base = base;
}
return setmetatable(inst, Settings)
end
function Settings:__index(key)
local result = self._object:GetAttribute(key)
local base = self._base
if base ~= nil then
base = base[key]
if typeof(result... |
--[[
Window management.
Includes window switching, movement and resizing.
Usage:
The window management key (shift+control+escape by default) activates window management.
A red box will be drawn arond the selected window, which starts off as the focus window.
This box can be moved to other windows, by default with cur... |
local defaultSettings = {
{ "notes", "Este é seu bloco de notas." },
{ "usersettings_usecustomradio", "true" },
{ "usersettings_usecustomhud", "false" },
{ "usersettings_usecustomvehiclenames", "true" },
{ "usersettings_showspeedgraph", "false" },
{ "usersettings_showspeedmeter", "false" },
... |
data:extend(
{
{
type = "item",
name = "timer-combinator",
icon = "__UsefulCombinators__/graphics/icons/timer-combinator.png",
flags = { "goes-to-quickbar" },
subgroup = "circuit-network",
place_result="timer-combinator",
order = "b[combinators]-u[timer-combinator]",
stack_s... |
local BB = require("breadboard")
local log = require("log")
local Entity = BB.class()
function Entity:on(evtName, func)
local ls = self:_getListeners(evtName)
table.insert(ls, func)
end
function Entity:off(evtName, func)
local ls = self:_getListeners(evtName)
local a = {}
for i, l in ipairs(ls) do
if n... |
-----------------------------------
-- Area: Ru'Lude Gardens
-- NPC: Audience Chamber
-- Involved in Mission: Magicite
-- !pos 0 -5 66 243
-----------------------------------
require("scripts/globals/keyitems");
require("scripts/globals/settings");
require("scripts/globals/titles");
require("scripts/globals/missions")... |
local noteController = {}
-- Modules
local composer = require "composer"
local crudController = require "src.controller.crudController"
local note = require "src.model.note"
function noteController.new(logger, notecard)
local l = logger
local this = crudController.new(l, "note", "text")
this.itemToDelet... |
-- It's a simple sprite package warpper, use your own asset format instead.
local ejoy2d = require "ejoy2d"
local ppm = require "ejoy2d.ppm"
--local pack = require "ejoy2d.spritepack"
local pack = require "quick.lua.SpritePack"
local sprite = require "ejoy2d.sprite"
local png = require "ejoy2d.png"
local jpg = requir... |
NPC.Class = ""
NPC.Name = ""
NPC.Description = ""
NPC.Icon = ""
NPC.SortIndex = 0
NPC.Health = 0
NPC.Flag = 0
NPC.Cost = 0
NPC.PopCost = 0
NPC.Hidden = true
NPC.DelaySetModel = false
NPC.Model = "models/zombie/zm_classic.mdl"
NPC.SkinNum = 3
function NPC:SetupModel(npc)
if not self.Model then return end
... |
function OnResourceChanged(player, resource, value)
local playerData = Storage.GetPlayerData(player)
if type(playerData.resources) ~= "table" then
playerData.resources = {}
end
playerData.resources[resource] = value
Storage.SetPlayerData(player, playerData)
end
function NeverShowTutorial(player)
player:Se... |
-- Copyright (c) 2021 Trevor Redfern
--
-- This software is released under the MIT License.
-- https://opensource.org/licenses/MIT
local tables = require "moonpie.tables"
local ImageManager = require "game.rules.graphics.image_manager"
local Animator = require "game.rules.graphics.animator"
local World = req... |
local area = require("__flib__.area")
local gui = require("__flib__.gui")
local math = require("__flib__.math")
local table = require("__flib__.table")
local constants = require("constants")
local formatter = require("scripts.formatter")
local recipe_book = require("scripts.recipe-book")
local gui_util = {}
-- The ... |
---------------------------------
--! @file CORBA_RTCUtil.lua
--! @brief RTC操作関数定義
---------------------------------
--[[
Copyright (c) 2017 Nobuhiko Miyamoto
]]
local CORBA_RTCUtil = {}
--_G["openrtm.CORBA_RTCUtil"] = CORBA_RTCUtil
local oil = require "oil"
local RTObject = require "openrtm.RTObject"
local NVUtil =... |
uranium_basic_belt_animation_set =
{
animation_set =
{
filename = "__uraniumlogistics__/graphics/entity/uranium-transport-belt/uranium-transport-belt.png",
priority = "extra-high",
width = 64,
height = 64,
frame_count = 16,
direction_count = 20,
hr_version =
{
filename = "__ura... |
local module = {}
module.new = function(Parent: Instance)
local Comp = Instance.new("UIPadding")
local t = {
["Left"] = UDim.new(0, 0),
["Right"] = UDim.new(0, 0),
["Top"] = UDim.new(0, 0),
["Bottom"] = UDim.new(0, 0),
["Parent"] = Parent
}
local function cook()
for i,v in pairs(t) do
if typeof(v) ... |
local t = require 'torch'
local nn = require 'nn'
local autograd = require 'autograd'
local util = require 'util.util'
local _ = require 'moses'
function getMatchingNet(opt)
local model = {}
-- load and functionalize cosine-similarity layer
local cosineSim = autograd.functionalize(nn.CosineDistance())
... |
CurrentEditRow = false
GUIEditor = {
label = {},
button = {},
window = {},
gridlist = {},
memo = {}
}
addEventHandler("onClientResourceStart", resourceRoot,
function()
local screenW, screenH = guiGetScreenSize()
GUIEditor.window[1] = guiCreateWindow((screenW - 555) / 2, (screenH - 439)... |
local map = require('helper').map
vim.opt.completeopt = {'menuone', 'noselect'}
require'compe'.setup {
enabled = true,
autocomplete = true,
debug = false,
min_length = 1,
preselect = 'enable',
throttle_time = 80,
source_timeout = 200,
resolve_timeout = 800,
incomplete_delay = 400,
... |
local gumbo = require "gumbo"
local document = assert(gumbo.parse [[
<!DOCTYPE html>
<!-- Comment #1 -->
<!-- Comment #2 -->
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<meta charset="utf-8"/>
<title>lua-gumbo</title>
</head>
<body>
<h1>Document.serialize Test</h1>
</body>
</... |
data.raw["gui-style"].default["blueprintstring_button_style"] =
{
type = "button_style",
font = "default-button",
default_font_color={r=1, g=1, b=1},
align = "center",
default_graphical_set =
{
type = "composition",
filename = "__core__/graphics/gui.png",
priority = "extra-high-no-scale",
corner_size = {3... |
HUD = {}
HUD.Name = "No hud"
function HUD:Init()
end
function HUD:DrawHud(vel, rev, gear, fuel, turbo, speed, scar, ply, isWideScreen, kilometersOrMiles)
end
function HUD:MenuElements(Panel)
end
SCarHudHandler:RegisterHUD(HUD) |
local Prop = {}
Prop.Name = "Jail"
Prop.Government = true
Prop.Doors = {
{ Pos = Vector( -8463, 10425, -720 ), Locked = true },
{ Pos = Vector( -8463, 10519, -720 ), Locked = true },
{ Pos = Vector( -8135, 10425, -720 ), Locked = true },
{ Pos = Vector( -8135, 10519, -720 ), Locked = true },
{ Pos =... |
--
-- Created by IntelliJ IDEA.
-- User: bking
-- Date: 1/12/17
-- Time: 9:44 AM
-- To change this template use File | Settings | File Templates.
--
-- allows local imports
package.path = ';/Users/bking/IdeaProjects/LanguageModelRNN/?.lua;'..package.path
-- While unrelated to language modeling, this is a simple step ... |
-------------
-- LSP config
-------------
-- See ~/.dotfiles/vim/plugins.vim for the Plug directives
local lspconfig = require('lspconfig')
-- lsp_signature
-- https://github.com/ray-x/lsp_signature.nvim#full-configuration-with-default-values
local on_attach_lsp_signature = function(client, bufnr)
require('lsp_sign... |
-- Copyright 2021 - Deviap (deviap.com)
-- Author(s): Sanjay-B(Sanjay)
-- Creates an text component.
local newBaseComponent = require("devgit:source/libraries/UI/components/baseComponent.lua")
return function(props)
--[[
@description
Creates a base component
@parameter
table, props
@returns
table, comp... |
return {'waoer','wao','waoers'} |
local NPC = {};
NPC.Name = "Bartender";
NPC.ID = 23;
NPC.Model = Model("models/humans/suits2/male_04.mdl");
NPC.Invisible = false; // Used for ATM Machines, Casino Tables, etc.
NPC.Location = Vector(-7189.0312, -14183.5, 72.0313);
NPC.Angles = Angle(0,0,0);
NPC.ShowChatBubble = "Normal";
NPC.Sequence = 228;
// ... |
return {
summary = 'Get a new Curve from a slice of an existing one.',
description = [[
Returns a new Curve created by slicing the Curve at the specified start and end points.
]],
arguments = {
{
name = 't1',
type = 'number',
description = 'The starting point to slice at.'
},
{... |
--[[Author: Pizzalol
Date: 1.1.2015.
Applies flesh heap modifiers according to the kills and assists before the ability was leveled up]]
function FleshHeap( keys )
local caster = keys.caster
local ability = keys.ability
local fleshHeapModifier = "modifier_flesh_heap_bonus_datadriven"
local fleshHeapStackModifier ... |
-- ===========================================================================
-- Base File
-- ===========================================================================
include("PartialScreenHooks_Expansion2");
include("partialscreenhooks_CQUI.lua"); |
local playsession = {
{"Kiwicake", {14042}},
{"neuro666", {675139}},
{"GuidoCram", {52302}},
{"kalenmonster", {280703}},
{"rbirk", {650975}},
{"gamechanger", {354430}},
{"qwerin", {649178}},
{"Xspex", {220393}},
{"__init__", {606616}},
{"tykak", {588343}},
{"Weizenbrot", {1473}},
{"ManuelG", {25739}},
{"Pu... |
local engine, ns = ...
Logger.Information("Engine.Name=",engine.Name,", Engine.Title=",engine.Title)
-- Setup engine
engine:AddProcessName("DOOMx64")
engine:AddProcessName("DOOMx64vk")
-- Setup settings
local setting = EngineSettingFolderBrowser()
setting.CanAutoDetect = true
setting.Name = "SourceFolder"
settin... |
-- https://github.com/akinsho/bufferline.nvim
require('bufferline').setup {
options = {
diagnostics = "nvim_lsp",
diagnostics_update_in_insert = false,
diagnostics_indicator = function(count, level, diagnostics_dict, context)
local s = " "
for e, n in pairs(diagnostic... |
RegisterServerEvent("SaveCoords")
AddEventHandler("SaveCoords", function(name, x, y, z, h, text)
local src = source
file = io.open(name .. "-Coords.txt", "a")
if file then
file:write("vector4(" .. x .. ", " .. y .. ", " .. z .. ", " .. h .. "),\n")
end
file:close()
TriggerClientEvent... |
----------------------------------------------------------------------------------------------------
--
-- All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-- its licensors.
--
-- For complete copyright and license terms please see the LICENSE at the root of this
-- distribution (the "Li... |
--------------------------------------------------------------------------------
local _ = require "lib.underscore"
local class = require "lib.middleclass"
--------------------------------------------------------------------------------
local Model = class("Model")
function Model:initialize(db, tableName, attribu... |
--test_sd-id128.lua
package.path = package.path..";../src/?.lua"
local ffi = require("ffi")
local sd_id128 = require("sd-id128")
local sd_messages = require("sd-messages")
local id1 = sd_id128();
print("Default: ",id1)
print(" isNull: ", id1:isNull())
local coreDump = sd_messages.SD_MESSAGE_COREDUMP;
print(" ... |
-- utilities.lua
-- Functions shared among plugins.
local utilities = {}
local HTTP = require('socket.http')
local ltn12 = require('ltn12')
local HTTPS = require('ssl.https')
local URL = require('socket.url')
local JSON = require('dkjson')
local bindings = require('bindings')
-- get the indexed word in a string
fun... |
return
function(cat9, root, builtins, suggest)
function builtins.trigger(job, action, cmd, oflow)
if not job then
cat9.add_message("trigger >job< ... - job missing")
return
end
if type(job) ~= "table" or job.hidden then
cat9.add_message("trigger >job< ... - wrong type or state for job")
return
end
if no... |
local nvim_cmd = vim.api.nvim_command
-- leave vim if nerdtree is the only open buffer left
nvim_cmd('autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif')
|
--[[
Given an "atlas" (a texture with multiple sprites), as well as a
width and a height for the tiles therein, split the texture into
all of the quads by simply dividing it evenly.
]]
function GenerateQuads(atlas, tilewidth, tileheight)
local sheetWidth = atlas:getWidth() / tilewidth
local sheetHeight = at... |
-- Copyright 2021 Frank Uhlig
--
-- 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 ... |
-- luacheck: globals prefs
local std = stead
local preferences = std.obj {
nam = '@prefs',
load = function(_)
local name = std.savepath() .. '/prefs';
local f, err = std.loadfile(name);
if not f then
return false, err
end
local strict = std.nostrict; std.nostrict = true
f();
std.nostrict = strict
... |
//________________________________
//
// NS2 Single-Player Mod
// Made by JimWest, 2012
//
//________________________________
local originalGetPointBlocksAttachEntities = GetPointBlocksAttachEntities
function GetPointBlocksAttachEntities(origin)
// y the nobuild area is blocking us
if Pathing.GetIsFlag... |
local miniGameName = "glutton";
local miniGamePath = "miniGames/glutton/";
--utils:log(miniGameName, "Loaded");
local miniGameBase = require("miniGames.miniGameBase");
local scene = miniGameBase:newMiniGameScene(miniGameName);
-- Game instructions.
scene.instructions =
"It must be a vegetarian snake: eat space carro... |
--- Utilities for loading images.
--
-- The (single-frame) image readers come from Sean Barrett's [stb](https://github.com/nothings/stb).
--
-- Animated GIF support builds upon STB, using urraka's [xload](https://gist.githubusercontent.com/urraka/685d9a6340b26b830d49/raw/91eee495eeefb2d60abc73a1a9d83949fe6a4882/stb.c).... |
-- This is a modified version of VGG network in
-- https://github.com/szagoruyko/cifar.torch
-- Modifications:
-- * removed dropout
-- * last nn.Linear layers substituted with convolutional layers
-- and avg-pooling
require 'nn'
local utils = paths.dofile'utils.lua'
require 'cudnnorn'
local nOrientation = 8
local ... |
slot0 = class("WorldTaskProxy", import("....BaseEntity"))
slot0.Fields = {
list = "table",
itemListenerList = "table",
taskFinishCount = "number",
mapList = "table",
mapListenerList = "table"
}
slot0.EventUpdateTask = "WorldTaskProxy.EventUpdateTask"
slot0.Build = function (slot0)
slot0.list = {}
slot0.itemList... |
// ============================================================================================ //
/*
* Wildfire Servers - Portal RP - Base Addon
* File description: Hook serverside script file
* Copyright (C) 2022 KiwifruitDev
* Licensed under the MIT License.
*/
// ==============================================... |
local NumEntries = 13
local RowHeight = 24
local SetEntryText = function(rank, name, score, date, actor)
if actor == nil then return end
actor:GetChild("Rank"):settext(rank)
actor:GetChild("Name"):settext(name)
actor:GetChild("Score"):settext(score)
actor:GetChild("Date"):settext(date)
end
local SetLeaderboardF... |
local K, C, L, _ = select(2, ...):unpack()
if C["Nameplate"].enable ~= true then return end
local GetSpellInfo = GetSpellInfo
----------------------------------------------------------------------------------------
-- The best way to add or delete spell is to go at http://wotlk.openwow.com search for a spell.
-- Examp... |
require("gameData/gameData")
local CommunityKnowListData = class(GameData);
CommunityKnowListData.Delegate = {
onGetKnowListCallBack = "onGetKnowListCallBack";
onGetMaybeFamiliarCallBack = "onGetMaybeFamiliarCallBack";
}
CommunityKnowListData.ctor = function(self)
ImSdkHelper.getInstance():setO... |
-- https://wowpedia.fandom.com/wiki/API_GetGameMessageInfo
local eb = KethoEditBox
function KethoWowpedia:GameError()
local enums = {}
for k, v in pairs(_G) do
if k:find("^LE_GAME_ERR") then
tinsert(enums, {k, v})
end
end
sort(enums, function(a, b)
return a[2] < b[2]
end)
eb:Show()
eb:InsertLine('{| c... |
local mod = get_mod("RerollImprovements") -- luacheck: ignore get_mod
-- luacheck: globals CraftPageRollProperties Managers UIUtils Managers UIWidgets
-- luacheck: globals UIWidget Colors UISettings WeaponTraits CraftPageRollTrait
-- luacheck: globals Localize
UISettings.crafting_progress_time = 0.01
mod.last_bac... |
local ASL = LibStub("AceLocale-3.0"):NewLocale("AddOnSkins", "ptBR")
if not ASL then return end
ASL["About/Help"] = true
ASL["AddOn Skins"] = true
ASL["Attach CoolLine to action bar"] = true
ASL["Attach SexyCD to action bar"] = true
ASL["Auction House"] = true
ASL["Available Skins / Skin Requests"] = true
ASL["BigWigs... |
--[[ File
@description:
This class is for generating different datasets.
@version: V0.02
@author: Fangyi Zhang email:gzzhangfangyi@gmail.com
@acknowledgement:
ARC Centre of Excellence for Robotic Vision (ACRV)
Queensland Univsersity of Technology (QUT)
@history:
V0.00 07/06/2017 developed the first... |
--[[
Copyright (c) 2019 igor725, scaledteam
released under The MIT license http://opensource.org/licenses/MIT
]]
return function(player, id, x, y, z, yaw, pitch)
player:setPos(x / 32, y / 32 - 0.6875, z / 32)
player:setEyePos((yaw / 255) * 360, (pitch / 255) * 360)
if player:isSupported('HeldBlock')then
if not... |
--UI configure
this.UiManager.drawerHeaderSecondaryTextView.typeface=Typeface.SERIF
this.UiManager.appBarLayout.getChildAt(0).getChildAt(0).getChildAt(0).getChildAt(1).getChildAt(1).typeface=Typeface.SERIF
--Layouts for components
item={LinearLayout,
layout_width="match",
layout_height="wrap",
padding="8dp",
... |
-- Use of this source code is governed by the Apache 2.0 license; see COPYING.
module(..., package.seeall)
local common = require("program.config.common")
local lib = require("core.lib")
function show_usage(command, status, err_msg)
if err_msg then print('error: '..err_msg) end
print(require("program.alarms.pur... |
MidwayCheckupStory = Story:extend()
function MidwayCheckupStory:new()
MidwayCheckupStory.super.new(self)
self.lines = {
"#bg gfx/bg1.png",
"3016.UC",
"12.31 1200 HOME",
"#bg gfx/bg7.png",
"#music bgm/Lazy Marine - 91 T1.wav",
"It's around noon and {girl} happene... |
--Made with Skyyyr's Wrench Tool
object_tangible_tcg_shared_booster = SharedTangibleObjectTemplate:new {
clientTemplateFileName = "object/tangible/tcg/shared_booster.iff"
}
ObjectTemplates:addClientTemplate(object_tangible_tcg_shared_booster, "object/tangible/tcg/shared_booster.iff")
--Made with Skyyyr's Wrench To... |
--[[
shared.lua
Options menu class with API shared among all panels
--]]
local CONFIG = ...
local L = LibStub('AceLocale-3.0'):GetLocale(CONFIG)
local ADDON, Addon = CONFIG:match('[^_]+'), _G[CONFIG:match('[^_]+')]
local Group = Addon:NewModule('OptionsGroup', LibStub('Sushi-3.1').OptionsGroup:NewClass())
--[[ Gr... |
--- Handles complex sets.
--
-- @usage
-- > properset = require 'properset'
-- > Set = properset.Set
-- > a = Set{1, 2, 2, 3, 3, 3}
-- > a
-- {1, 2, 3}
--
-- @module properset
-- @author Odin Kroeger
-- @copyright 2018 Odin Kroeger
-- @license MIT
-- @release 0.3b-1
-- Boilerplate
-- ========... |
nssm:register_mob("nssm:sandworm", "Sandworm", {
type = "monster",
hp_max = 40,
hp_min = 25,
collisionbox = {-0.4, -0.2, -0.4, 0.4, 1.90, 0.4},
visual = "mesh",
mesh = "sandworm.x",
textures = {{"sandworm.png"}},
visual_size = {x=4, y=4},
makes_footstep_sound = false,
view_range ... |
require("vehicle")
require("universe")
local logger = require("logger")
require("toml")
local pitch = 0.0
local yaw = 0.0
local roll = 0.0
local engines = nil
function init()
engines = load_engines(machine.init_toml)
end
local function in_axis(axis, value)
if axis == "Pitch" then
pitch = value
elseif axi... |
{{"Hips", {"__userdata", "vector3", -0.000244, -0.060314, 0.003814, }, }, {"RightUpLeg", {"__userdata", "vector3", 0.002881, -0.211344, 0.001913, }, }, {"RightLeg", {"__userdata", "vector3", 0.008425, -0.188373, -0.021467, }, }, {"RightFoot", {"__userdata", "vector3", -0.000749, -0.029563, 0.048132, }, }, {"RightToes",... |
function onCreate()
-- Whitback
makeAnimatedLuaSprite('stage','BallisticBackground', -470, -160)
addAnimationByPrefix('stage','BallisticBackgroundGo','Background Whitty Startup',24,false);
addAnimationByPrefix('stage','BallisticBackgroundStart','Background Whitty Start0',24,true);
addAnimat... |
-- Fills free disk space with zeroes.
local partition = "/dev/sda1" -- partition to check free space on
local f = "./zfs_fill.dat" -- temporary file name
os.execute("df \"" .. partition .. "\" > \"".. f .. "\"")
local df = io.open(f, "r")
::no_temp_file::
if df == nil then
... |
Locales['es'] = {
['shop'] = 'Tienda',
['shops'] = 'Tiendas',
['press_menu'] = 'Presiona ~INPUT_CONTEXT~ para acceder a la tienda.',
['bought'] = 'Has comprado ~b~1 ',
['not_enough'] = 'No tienes ~r~suficiente ~s~ dinero.',
}
|
-- Copyright 2016 krunkathos
--
-- 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 t... |
local Game = require "me.strangepan.games.mazerino.common.Game"
local assert_that = require "me.strangepan.libs.truth.v1.assert_that"
local ConnectionManager = require "me.strangepan.games.mazerino.common.networking.ConnectionManager"
local NetworkedEntityManager = require "me.strangepan.games.mazerino.common.networkin... |
local type = type
local tonumber = tonumber
local print = print
local os_time = os.time
local os_date = os.date
local format = string.format
local band = bit.band
local rshift = bit.rshift
local ffi = require 'ffi'
local MZ = ...
local C = ffi.C
-- @param cdata.zip_fileinfo zi
-- XXX 该结构与旧版不同,... |
local modpath = minetest.get_modpath("main")
dofile(modpath.."/nodes.lua")
dofile(modpath.."/craftitems.lua")
dofile(modpath.."/mapgen.lua")
dofile(modpath.."/tools.lua")
minetest.register_on_joinplayer(function(player)
player:hud_set_hotbar_image("gui_hotbar.png")
player:hud_set_hotbar_selected_image("gui_hotbar_s... |
-- Diese Datei wird beim starten des Spiels als drittes und letztes geladen. Hier ändert man Mods ab
if mods["AtomicArtillery"] then --definiert ob die Mod AtomicArtillery aktiviert ist und ändert dann die Nuklear Artillery ab
local sounds = require("__base__.prototypes.entity.demo-sounds")
require("__... |
-- droning
--
-- play a drone!
-- we will define the engine
-- "engine" is a special variable
-- engine.name="X" will look for Engine_X.scd in all the folders
engine.name="Droning" -- this will look for Engine_Droning.scd
-- we will import the "musicutil" library
-- https://monome.org/docs/norns/api/modules/lib.Music... |
--
-- created with TexturePacker (http://www.codeandweb.com/texturepacker)
--
-- $TexturePacker:SmartUpdate:d833aa572faaf89b7a2c32008b6199c0:175ddf34b7043fb629e19a554f892254:51eadd9eb612090d216e3ba3d4272adf$
--
-- local sheetInfo = require("mysheet")
-- local myImageSheet = graphics.newImageSheet( "mysheet.png", sheetI... |
local table = require('__stdlib__/stdlib/utils/table')
local equipment = {}
for _, v in pairs(data.raw['night-vision-equipment']) do
local t = table.deepcopy(v)
-- Keep the same localised name if none is specified
t.localised_name = {'disabled-equipment.disabled', t.localised_name or {'equipment-name.' ..... |
require'colorizer'.setup({
'*';
css = { css = true; css_fn = true; };
scss = { css = true; css_fn = true; };
javascript = { css = true; css_fn = true; };
javascriptreact = { css = true; css_fn = true; };
})
|
local join_sub_sup
local ascii = {}
local function utf8len(str)
return vim.str_utfindex(str)
end
local grid = require("nabla.ascii.grid")
local unicode = require("nabla.ascii.unicode")
local style = unicode.style
local frac_set = unicode.frac_set
local sub_letters = unicode.sub_letters
local sup_letters = unico... |
--[[**********************************
*
* Multi Theft Auto - Admin Panel
*
* gui\admin_performance.lua
*
* Original File by lil_Toady
*
**************************************]]
aPerformanceForm = nil
function aPerformance ()
if ( aPerformanceForm == nil ) then
local x, y = guiGetScreenSize()
aPerformanceForm = ... |
--[[--------------------------------------------------------------------------
--
-- File: UATagThenShoot.Ui.RoundLoop.lua
-- Copyright (c) Ubisoft Entertainment. All rights reserved.
--
-- Project: Ubitoys.Tag
-- Date: September 23, 2010
--
---------------------... |
local Vectors = {}
Vectors.__index = Vectors
---Divides the vector by the given number.
---@param vector3D table vector {x,y,z} to divide.
---@param divisor number the number to divide by.
---@return table dividedVector {x,y,z} divided vector.
function Vectors.DivideByNumber(vector3D, divisor)
if divisor == 0 the... |
------------------------ C/C++ GCC DRIVER ------------------------
function DriverGCC_Get(exe, cache_name, flags_name)
return function(label, output, input, settings)
local cache = settings.cc[cache_name]
if settings.invoke_count ~= cache.nr then
cache.nr = settings.invoke_count
local cc = settings.cc
lo... |
--[[ PLAYER SPAWN POINT LIST
revive_point(<map_id>, <x_pos>, <y_pos>);
start_point(<map_id>, <x_pos>, <y_pos>);
respawn_point(<map_id>, <x_pos>, <y_pos>);
--]]
start_point(8, 5525.87, 4546.56);
respawn_point(8, 5520.16, 4558.11);
|
local Path = require "plenary.path"
local Job = require "plenary.job"
local f = require "plenary.functional"
local log = require "plenary.log"
local win_float = require "plenary.window.float"
local headless = require("plenary.nvim_meta").is_headless
local harness = {}
local print_output = vim.schedule_wrap(function... |
-- TÖVE Demo: Procedural form and color animation.
-- (C) 2018 Bernhard Liebl, MIT license.
local tove = require "tove"
require "assets/tovedemo"
local function newHeart()
-- taken from: https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial/Drawing_shapes
local g = tove.newGraphics()
g:setLineWidth(... |
loadstring(game:HttpGet('https://pastebin.com/raw/XxQTD0FP', true))() |
local hi = require "as.highlights"
local M = {}
M.nm = require("as.plugins.gui._colhelper").theme
M.custom_hi = function()
local colorcolumn = hi.get_hl("ColorColumn", "bg")
local colnormal = hi.get_hl("Normal", "bg")
if colnormal == "" then
colnormal = "#333"
end
local colfolded = hi.g... |
------------------------------------------------------------------------------
-- dwv-simplistic (medical viewer using DWV) lua script
-- for integration in a Conquest PACS server.
--
-- Usage:
-- 1. copy this file onto your web server
-- 2. in the 'dicom.ini' of your web server, create the dwv-simplistic viewer:
-- ... |
local SortingUtilities = {}
ECS.SortingUtilities = SortingUtilities
function SortingUtilities.InsertSorted( data, length, newValue )
while (length > 1 and newValue < data[length - 1]) do
data[length] = data[length - 1]
length = length - 1
end
data[length] = newValue
end
return SortingUtiliti... |
require 'math'
local SignedSquareRoot, parent = torch.class('nn.SignedSquareRoot', 'nn.Module')
function SignedSquareRoot:__init(args)
parent.__init(self)
self.module = nn.Sequential()
:add(nn.Abs())
:add(nn.Sqrt())
end
function SignedSquareRoot:updateOutput(input)
self.output = self.outpu... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.