content stringlengths 5 1.05M |
|---|
-- vim: set foldmethod=marker foldenable:
-- General Options {{{
vim.g.mapleader = " "
vim.opt.backup = false
vim.opt.colorcolumn = '+1'
vim.opt.completeopt = { 'menuone', 'noinsert' }
vim.opt.foldenable = false
vim.opt.foldmethod = 'syntax'
vim.opt.formatoptions:remove { 'o' }
vim.opt.hidden = true
vim.opt.incsearch... |
-- Created by Elfansoer
--[[
Ability checklist (erase if done/checked):
- Scepter Upgrade
- Break behavior
- Linken/Reflect behavior
- Spell Immune/Invulnerable/Invisible behavior
- Illusion behavior
- Stolen behavior
]]
--------------------------------------------------------------------------------
modifier_red_trans... |
ITEM.name = "Droplet"
ITEM.model ="models/lostsignalproject/items/artefacts/drop.mdl"
ITEM.description = "A slim, black, teardrop-shaped artifact."
ITEM.longdesc = "The surface is hot to the touch, as if something is heating it up from the inside. The surface has a luster to it, almost obsidian-like in quality. These t... |
local enemy = {}
function enemy:new(x, y, speed, image)
local enemy = {}
enemy.image = image
enemy.x = x
enemy.y = y
enemy.speed = speed
enemy.dead = false
return enemy
end
function reset()
-- remove all enemies from screen
enemies = {}
-- reset timers
createEnemyTimer = crea... |
local help_message = [[
This is a module file for the container quay.io/biocontainers/emirge:0.61.1--py27h355e19c_2, which exposes the
following programs:
- bcftools
- bowtie
- bowtie-align-l
- bowtie-align-s
- bowtie-build
- bowtie-build-l
- bowtie-build-s
- bowtie-inspect
- bowtie-inspect-l
- bowtie-inspec... |
local CorePackages = game:GetService("CorePackages")
local CoreGui = game:GetService("CoreGui").RobloxGui
local Roact = require(CorePackages.Roact)
local Constants = require(script.Parent.Parent.Constants)
local ENTRY_HEIGHT = Constants.GeneralFormatting.DropDownEntryHeight
local ARROW_SIZE = Constants.GeneralFormatt... |
if modifier_tidebringer_ff == nil then
modifier_tidebringer_ff = class({})
end
function modifier_tidebringer_ff:IsHidden()
return true
end
function modifier_tidebringer_ff:IsPurgable()
return false
end
function modifier_tidebringer_ff:IsDebuff()
return false
end
function modifier_tidebringer_ff:RemoveOnDeath()
... |
Tools = dofile(global:getCurrentDirectory() .. "\\YayaTools\\Module\\Tools.lua")
Movement = Tools.movement
Zone = Tools.zone
Packet = Tools.packet
Character = Tools.character
MyScript = Tools.object() -- On créer un object nommé MyScript, un object c'est comme une table mais vous aurez accès a la fonction HasPropertie... |
-- Created by Elfansoer
--[[
Ability checklist (erase if done/checked):
- Scepter Upgrade
- Break behavior
- Linken/Reflect behavior
- Spell Immune/Invulnerable/Invisible behavior
- Illusion behavior
- Stolen behavior
]]
--------------------------------------------------------------------------------
timbersaw_whirling... |
object_draft_schematic_space_cargo_hold_crg_mining_small = object_draft_schematic_space_cargo_hold_shared_crg_mining_small:new {
}
ObjectTemplates:addTemplate(object_draft_schematic_space_cargo_hold_crg_mining_small, "object/draft_schematic/space/cargo_hold/crg_mining_small.iff")
|
local screenWidth, screenHeight = guiGetScreenSize()
local relativeScale, relativeFontScale = math.min(math.max(screenWidth/1600, 0.5), 1), math.min(math.max(screenWidth/1600, 0.85), 1)
local deathlist = {}
deathlist.messages = {}
deathlist.offset = 5
deathlist.padding = 5
deathlist.fontScale = 1
deathlist.font = dxCre... |
--------------------------------------------------------------------------------------------
-- 0.01 Matt Page 18/05/2020 - first version.
-- 0.02 Matt Page 20/05/2020 - Added output for Ride on count.
-- 0.03 Matt Page 21/05/2020 - Changed log file directory parameter to Path selector.
-- 0.04 Matt Page 22/05/2020... |
title_font = love.graphics.newFont(18)
text_font = love.graphics.newFont(14)
Window = Class {
init = function(self, x, y, w, h, winImg, parent)
--appearence
self.pos = vector.new(x or 0, y or 0)
self.w = w or screen.w; self.h = h or screen.h
self.winImg = winImg or Window.img.defaul... |
---
-- Test queries against scope hierarchies.
---
local premake = require('premake')
local State = require('state')
local StateSelectTests = test.declare('StateSelectTests', 'state')
local _global
function StateSelectTests.setup()
defines 'GLOB'
configurations { 'Debug', 'Release' }
platforms { 'macOS', 'iOS'... |
function Initialize()
variablesFile = SKIN:GetVariable('@') .. "variables.inc"
settingsFile = SKIN:GetVariable('settingsPath') .. "rainmeter.ini"
rootConfig = SKIN:GetVariable('RootConfig')
--SKIN:Bang('!Log', variablesFile, 'Debug')
end
function Update()
-- capture = {home, settings, pictures, music, videos, game... |
local function init()
for _,job in pairs(pzCore.jobs) do
if job.createBlip ~= nil then job.createBlip() end
end
local job = ESX.PlayerData.job.name
if pzCore.jobs[job] ~= nil then
pzCore.jobs[job].init()
end
end
local function changed()
for k,v in pairs(pzCore.jobs) do if v.... |
--[[ DUMPED USING COMPOSER DEVIL ]]--
ESX = nil
local timing, isPlayerWhitelisted = math.ceil(Config.Timer * 60000), false
local streetName, playerGender
Citizen.CreateThread(function()
while ESX == nil do
TriggerEvent('esx:getSharedObject', function(obj) ESX = obj end)
Citizen.Wait(0)
end
while ESX.GetPlayer... |
object_mobile_dressed_trig_longo = object_mobile_shared_dressed_trig_longo:new {
}
ObjectTemplates:addTemplate(object_mobile_dressed_trig_longo, "object/mobile/dressed_trig_longo.iff")
|
dofile("region/en.lua")
dofile("region/xx.lua")
print_translations(en["Countries"], xx["Countries"], 1)
print_translations(en["Countries_variant"], xx["Countries_variant"], 1)
print_translations(en["CountriesShort"], xx["CountriesShort"], 1)
|
------------------------------------ tests -------------------------------------
_test = {}
if turtle then
_test.move = markIO("_test.move")(mkIO(function()
return savePosp(move.go(L * 2))()
end))
_test.move2 = markIO("_test.move2")(mkIO(function()
return savePosp(move.go(F + L))()
end))
_test.move3 = mark... |
-- =============================================================
-- Copyright Roaming Gamer, LLC. 2009-2015
-- =============================================================
-- License
-- =============================================================
--[[
> SSK is free to use.
> SSK is free to edit.
> ... |
local status_ok, lspconfig = pcall(require, "lspconfig")
if not status_ok then
return
end
local M = {}
M.setup = function(on_attach, capabilities)
lspconfig.pyright.setup({
on_attach = on_attach,
capabilities = capabilities,
})
end
return M
|
local L = LibStub("AceLocale-3.0"):NewLocale("LibEncounters", "esES")
if not L then return end
--- Encounter Names ---
L["Razorgore the Untamed"] = "Sangrevaja el Indomable"
L["Vaelastrasz the Corrupt"] = "Vaelastrasz el Corrupto"
L["Broodlord Lashlayer"] = "Señor de prole Capazote"
L["Firemaw"] = "Faucefogo"
L["Ebonr... |
--[[-------------------------------------------------------------------------
Point and click
---------------------------------------------------------------------------]]
AddCSLuaFile( "cl_init.lua" )
AddCSLuaFile( "shared.lua" )
include("shared.lua")
SWEP.AutoSwitchTo = true
SWEP.AutoSwitchFrom = true
... |
return Command 'ping'
:setDesc 'Returns "Pong!" and the arguments provided.'
:setCategory 'Fun'
:setAliases { 'beep' }
:run(function(msg, args)
msg.channel:send 'Pong!'
end); |
--[[
# Copyright 2001-2014 Cisco Systems, Inc. and/or its affiliates. All rights
# reserved.
#
# This file contains proprietary Detector Content created by Cisco Systems,
# Inc. or its affiliates ("Cisco") and is distributed under the GNU General
# Public License, v2 (the "GPL"). This file may also include Detector Co... |
dofile("test_setup.lua")
LuaReload.SetUseOldFileOnError(false)
local file1 = [=[
return function()
return 5
end
]=]
local file2 = [=[
return function()
syntax error is here!!!
end
]=]
local func = DoFileString(file1)
assert(func() == 5)
WriteFileString(file2)
print("BELOW ERROR is ... |
local M = {}
local function au(x)
vim.cmd("augroup " .. x.group)
for _, au in ipairs(x) do
vim.cmd("au " .. au[1] .. " " .. au[2] .. " " .. au[3])
end
vim.cmd("augroup END")
end
-- Dont Show Line numbers in Terminal
au({
group = "terminal",
{ "TermOpen", "*", "setlocal nonumber" },
})
-- Open quick fix windo... |
local undotree = {}
local if_nil = vim.F.if_nil
local actions = require('undotree.actions')
-- node = {seq='number', time='number', save='number', b='table'}
function undotree:new()
local newObj = {}
newObj.undotreeName = 'undotree_tree_buf'
newObj.undotreeFloatName = 'undotree_float_diff_buf'
newObj.bufnr = -... |
return Def.ActorFrame{
OffCommand=function(self)
self:sleep(0.333)
end
}
|
require("firecast.lua");
local __o_rrpgObjs = require("rrpgObjs.lua");
require("rrpgGUI.lua");
require("rrpgDialogs.lua");
require("rrpgLFM.lua");
require("ndb.lua");
require("locale.lua");
local __o_Utils = require("utils.lua");
local function constructNew_frmQualities()
local obj = GUI.fromHandle(_obj_newObject(... |
local player_data = {}
local translation = require("__flib__.translation")
local string_gsub = string.gsub
local string_sub = string.sub
function player_data.init(player, index)
local player_table = {
flags = {
can_open_gui = false,
gui_open = false,
search_open = false,
toggling_search... |
local ADDON_NAME, Mod = ...
local PANDA_FOOD_ID = 120168
local IS_PANDA = false
local promptFrame;
local function SetupPromptFrame(self)
if promptFrame ~= nil then
return;
end
promptFrame = CreateFrame("Frame", "PandaFoodPrompt", UIParent)
promptFrame:SetSize(64,64)
promptFrame:SetPoint(... |
print("Loading config.lua")
dofile("config.lua")
print("Loading init_gpio.lua")
dofile("init_gpio.lua")
print("Running TALLY system")
dofile("tally.lua")
|
yavin4_gackle_bat_giant_neutral_medium_boss_01 = Lair:new {
mobiles = {{"giant_gackle_bat",1}},
bossMobiles = {{"gackle_bat_myrmidon_lord",2},{"ravaging_gackle_bat",3}},
spawnLimit = 15,
buildingsVeryEasy = {"object/tangible/lair/base/poi_all_lair_nest_large_evil_fire_red.iff"},
buildingsEasy = {"object/tangible/l... |
local unit = ...
return unit and unit.guid or nil
|
_G.menup = {}
menup.version = "0.1.5" -- used to check for updates
menup.source = "https://raw.githubusercontent.com/djsime1/menu-plugins-redux/main/lua/menu/menu_plugins.lua" -- link to a file with the version string above
menup.changelog = [[
- Updated the readme.
- Added `menup` console command. (Still needs autoc... |
---
--- render2d.lua
---
--- Copyright (C) 2018 Xrysnow. All rights reserved.
---
---渲染图像
---@param name string @图像资源名
---@param x number @位置
---@param y number @位置
---@param rot number @旋转角度(Deg),默认为0
---@param hscale number @水平缩放,默认为1
---@param vscale number @垂直缩放,默认等于hscale
---@param z number @Z值,默认为0.5
function R... |
---
-- @module CharacterFactory
--
-- ------------------------------------------------
-- Required Modules
-- ------------------------------------------------
local Character = require( 'src.characters.Character' )
local BodyFactory = require( 'src.characters.body.BodyFactory' )
local ItemFactory = require( 'src.item... |
local player = ...
local profile = PROFILEMAN:GetProfile(player)
local playerName = profile:GetLastUsedHighScoreName()
local calories = round(profile:GetCaloriesBurnedToday())
local totalSongs = profile:GetNumTotalSongsPlayed()
local lines = {
ScreenString("LastUsedHighScoreName") .. "\n" .. playerName,
ScreenString... |
function ZOOMY_KEYPRESS(frame)
if keyboard.IsKeyPressed("NEXT") == 1 then
ZOOMY_ZOOM(2, true);
elseif keyboard.IsKeyPressed("PRIOR") == 1 then
ZOOMY_ZOOM(-2, true);
end
if keyboard.IsKeyPressed("LCTRL") == 1 then
if mouse.IsRBtnPressed() == 1 then
ZOOMYPLUS_XY();
end
if keyboard.IsKeyPressed("NEXT") ... |
local _, NS = ...
local Widgets = NS.Widgets
local count = 0
local function OnValueChanged(self, value)
local val = ceil(value)
_G[self:GetName() .. "High"]:SetText(val)
if self.callbackFunc and self.hasRefreshed then
self.callbackFunc(self, val)
end
self.hasRefreshed = true -- only run c... |
client_script "zxclient.lua"
files {
"ui/js/app.js",
"ui/js/zxNotify.min.js",
"ui/index.html",
"ui/css/zxNotify.css"
}
ui_page {
"ui/index.html"
} |
do_addObject = tfm.exec.addShamanObject
do_removeObject = tfm.exec.removeObject
do_addGround = tfm.exec.addPhysicObject
do_removeGround = tfm.exec.removePhysicObject
do_addJoint = tfm.exec.addJoint
do_removeJoint = tfm.exec.removeJoint
do_respawn = tfm.exec.respawnPlayer
do_addExplosion = tfm.exec.explosion
addParticle... |
local MonoImage = mono.MonoImage
MonoImage.mt = {
__index = MonoImage,
__tostring = function(t)
return 'MonoImage '..tostring(t.name)
end
}
local MonoClass = mono.MonoClass
--[[
List names of images, a name can be passed to MonoImage.new()
or MonoImage(name) to create a MonoImage instance.
--]]
func... |
_Engine = Interfaces:GetEngine()
_EntityList = Interfaces:GetEntityList()
_Screen = _Engine:GetScreenSize()
function DrawRadarBackground()
local iCenterX = 300
local iCenterY = 300
local iSize = 100
local x = _Screen.Width / 2
local y = _Screen.Height / 2
DrawManager:DrawFilledRect(iCenterX - iSize, iCenterY... |
fx_version 'adamant'
game 'gta5'
description 'hsn-inventory https://discord.gg/6FQhKDXBJ6'
client_scripts {
'client.lua',
'config.lua'
}
server_scripts {
'server.lua',
'config.lua'
}
ui_page "html/index.html"
files {
'html/index.html',
'html/script.js',
'html/style.css',... |
print("Test") |
return {
_fold = false,
_id = "TableCell1",
_type = "TableCell1",
height = 100,
ignoreAnchor = 1,
width = 480,
anchor = {
x = 0,
y = 0},
_children = { {
_id = "Member",
_type = "cc.LayerColor",
color = "66659bff",
height = "$fill",
ignoreAnchor = 0,
opacity =... |
object_static_particle_pt_campfire_smokeless_s01 = object_static_particle_shared_pt_campfire_smokeless_s01:new {
}
ObjectTemplates:addTemplate(object_static_particle_pt_campfire_smokeless_s01, "object/static/particle/pt_campfire_smokeless_s01.iff") |
object_static_item_item_hoth_camo_net_02 = object_static_item_shared_item_hoth_camo_net_02:new {
}
ObjectTemplates:addTemplate(object_static_item_item_hoth_camo_net_02, "object/static/item/item_hoth_camo_net_02.iff")
|
local lsp = require('lspconfig')
local servers = {
clangd = require('lsp.config.clangd'),
pyright = require('lsp.config.pyright'),
}
for server, config in pairs(servers) do
lsp[server].setup(config)
end
|
--[=[
Lua "assorted lengths of wire" library.
Written by Cosmin Apreutesei. Public domain.
Glue is a collection of "hand tools" necessary in any good dynamic language.
It is compatible with Lua 5.1 with a few functions only available to LuaJIT.
TYPE CHECKING
glue.isstr is st... |
package("libco")
set_homepage("https://github.com/Tencent/libco")
set_description("A coroutine library which is widely used in wechat back-end service.")
set_urls("https://github.com/Tencent/libco.git")
on_install("macosx", "linux", function (package)
os.vrun("make")
os.cp("*.h", pack... |
--[[
Ambush Example
v0.9.0
by: standardcombo
This example of an enemy camp spawns three enemies when the player enters the camp.
The NPCs will chase and attack players as long as there are players within the camp.
When all players exit the camp, the NPCs return to their spawn points, go to sleep
and eventua... |
-----------------------------------------------------------------------------------------------------------------
local dbg_prints = false
GlobalObj("LRManagerInstance", "LRManager")
GlobalVar("StorableResources", false)
GlobalVar("StorableResourcesForSession", false)
function BuildStorableResourcesArray()
if Storabl... |
data:extend({
{
type = "item",
name = "advanced-assembler",
icon = "__expanded-rocket-payloads__/graphic/advanced-assembler-32.png",
icon_size = 32,
flags = {"goes-to-quickbar"},
subgroup = "buildings",
order = "mS",
stack_size = 1,
p... |
local time = ...
assert(time)
return Def.Quad{
InitCommand=cmd(FullScreen;diffuse,HSV(192,1,0.05);diffusebottomedge,HSV(192,0.75,0.125);croptop,1;fadetop,1);
OnCommand=cmd(linear,time;croptop,0;fadetop,0;);
}; |
-- Name: Nightbuddy
-- Description: Minimalist Collection of Dark Colorschemes Written in Lua
-- Author: DilanGMB <Dilan.baron79@gmail.com>
-- Website: https://github.com/DilanGMB/nightbuddy
-- Setup Colorbuddy
local Group = require('colorbuddy.group').Group
local c = require('colorbuddy.color').co... |
local _, private = ...
if private.isClassic then return end
--[[ Lua Globals ]]
-- luacheck: globals pairs hooksecurefunc
--[[ Core ]]
local Aurora = private.Aurora
local Base = Aurora.Base
local Hook, Skin = Aurora.Hook, Aurora.Skin
local Color, Util = Aurora.Color, Aurora.Util
do --[[ FrameXML\LFGFrame.lua ]]
... |
require("lua/tracer")
tracer_clear()
glib_add([=[
uniform sampler2D tex_rand;
uniform usampler3D tex_vox;
uniform float scene_sb_offs;
const vec3[] lcol = vec3[](
vec3(0.5, 0.5, 0.5),
vec3(0.7, 0.4, 0.4),
vec3(0.3, 0.7, 0.3),
vec3(0.45, 0.45, 0.7),
vec3(0.7, 0.1, 0.7)
);
uint voxel_fetch(int layer, ivec3 cell)... |
local skynet = require "skynet"
local socket = require "skynet.socket"
local logger = require "logger"
local json = require "cjson"
local skynet_util = require "skynet_util"
local handler = require "handler"
local command = {}
function command.foobar(uid, data)
logger.debug("on room command.foobar:%s %s", uid, js... |
-- Merge plant stacks in the selected container or stockpile
--[====[
combine-plants
==============
Merge stacks of plants or plant growths in the selected container or stockpile.
]====]
local utils = require 'utils'
validArgs = validArgs or utils.invert({ 'max', 'stockpile', 'container' })
local args = utils.proces... |
include("shared.lua")
function ENT:DrawTranslucent()
self:DrawModel()
end |
enemy = class:new()
function enemy:init()
self.quad = 1
self.x = 100
self.y = math.random()*20+40
self.quadtimer = 0
self.movement = math.random(7)-4
if self.movement > 0 then
self.movement = 1
elseif self.movement < 0 then
self.movement = -1
end
self.speed = math.random(30)+40
self.dead = ... |
--[[
#part of the 3DreamEngine by Luke100000
particlesystem.lua - generates particle meshes based on .mat instructions
--]]
local lib = _3DreamEngine
--add particle system objects
--for every sub object (which is not a particle mesh) with a material with an attached particle systems create a new object (the particles... |
local _, private = ...
if private.isClassic then return end
--[[ Lua Globals ]]
-- luacheck: globals select floor
--[[ Core ]]
local Aurora = private.Aurora
local Base = Aurora.Base
local Hook, Skin = Aurora.Hook, Aurora.Skin
local Color, Util = Aurora.Color, Aurora.Util
local r, g, b = Color.grayLight:GetRGB()
do ... |
local oo = require "oil.oo"
local class = oo.class
local assert = require "oil.assert"
local Exception = require "oil.Exception"
local giop = require "oil.corba.giop" --[[VERBOSE]] local verbose = require "oil.verbose"
local SystemExceptionIDs = giop.SystemExceptionIDs
local... |
-- Additional Plugins
lvim.plugins = {
-- 多光标
{
"mg979/vim-visual-multi",
keys = "<C-n>",
},
-- 编辑只读文件
{
"lambdalisue/suda.vim",
cmd = "SudaWrite",
},
-- 自动切换输入法
{
"lilydjwg/fcitx.vim",
keys = { 'i', 'a', 'I', 'A', 'c', 'o', 'O' },
},
-- -- markdown 预览
-- {
-- "iamcco/... |
-- local facebook = require( "plugin.facebook.v4" )
local facebook = require( "facebook" )
-- Aseem Gupta
--This is my API key is must to post on facebook. Since the game is in development mode, so not sure if you can see posts
-- done by your account, hence only developers can see if posted through their account.
loc... |
local api = require("nvimapi")
local function filter_with(lnb1, lnb2, filter)
local lines = api.lines(lnb1, lnb2)
local result = filter(lines)
api.set_lines(lnb1, lnb2, result)
end
return {
filter_with = filter_with
}
|
-- .obj mesh loader
require( "wanderer.cmesh" )
mesh = {}
function mesh.makeVertex( x, y, z )
return {x, y, z}
end
function mesh.makeNormal( x, y, z )
return {x, y, z }
end
function mesh.makeUV( u, v )
return {u, v}
end
function mesh.makeFacePart( v, u, n )
return {v, u, n}
end
mesh.numregex = "%-?%d... |
local util = require("cartographer.util")
local config = {}
config._data = {}
config.set = function(obj)
config._data = util.deep_merge(config._data, obj)
end
config.data = setmetatable({}, {__index = function(_, key)
local result = config._data[key]
if result == nil then
return {}
end
return result
en... |
-- **** Building Changes ****
function OnMsg.ClassesPostprocess()
BuildingTemplates.CoreHeatConvector.electricity_consumption = 80000
BuildingTemplates.CoreHeatConvector.maintenance_resource_amount = 3000
BuildingTemplates.CoreHeatConvector.construction_cost_Metals = 120000
BuildingTemplates.CoreHeatConvector.cons... |
x = arrayX[ITEM]
y = arrayY[ITEM]
type = arrayType[ITEM]
denom = arrayDenom[ITEM]
res = x*y / denom
style["height"] = height * y / x
solution = ""
for i = 0, (x*y-1) do
if i < res then
solution = solution.."solution["..tostring(i).."]=1;"
else
solution = solution.."solution["..tostring(i).."]=0;"
end
e... |
Facet = {}
function Facet:create(entity, o)
o = o or {}
setmetatable(o, self)
self.__index = self
if entity then
o.of = entity
end
return o
end
function Facet:new(entity, o)
return Facet:create(entity, o)
end
function Facet:getId()
return self.id or -1
end
function Facet:isRenderableFacet()
return ... |
local co = require "internal.Co"
local ti = require "timer"
local new_tab = require("sys").new_tab
local type = type
local ti_new = ti.new
local ti_start = ti.start
local ti_stop = ti.stop
local co_new = co.new
local co_wait = co.wait
local co_spawn = co.spawn
local co_wakeup = co.wakeup
local co_self = co.self
loc... |
myclass = setmetatable({
__index = function(z,i) return myclass[i] end, --this makes class variables a possibility
setvar = function(z, n) z.var = n end
}, {
__call = function(z,n) return setmetatable({var = n}, myclass) end
})
instance = myclass(3)
print(instance.var) -->3
instance:setvar(6)
print(instance.var) --... |
-----------------------------------
-- Area: Windurst Waters
-- NPC: Honoi-Gumoi
-- Involved In Quest: Crying Over Onions, Hat in Hand
-- !pos -195 -11 -120 238
-----------------------------------
require("scripts/globals/keyitems")
require("scripts/globals/missions")
require("scripts/globals/npc_util")
require("scrip... |
function set(cell, value)
assert(allocated(cell))
assert(value >= 0)
to(cell)
clear()
inc(value)
end
function move(dst, src)
assert(allocated(src))
assert(allocated(dst))
to(dst)
clear()
to(src)
open()
dec()
to(dst)
inc()
to(src)
close()
to(dst)
end
function copy(dst, src)
assert(allocated(src... |
target("modulemap")
set_kind("binary")
add_files("src/*.swift", "src/*.cpp")
add_scflags("-Xcc -fmodules", "-Xcc -fmodule-map-file=src/module.modulemap")
|
local Ran = false
AddEventHandler("playerSpawned", function ()
if not Ran then
ShutdownLoadingScreenNui()
Ran = true
end
end) |
AddCSLuaFile()
DEFINE_BASECLASS( "weapon_csbasegun" )
CSParseWeaponInfo( SWEP , [[WeaponData
{
"MaxPlayerSpeed" "250"
"WeaponType" "Pistol"
"FullAuto" 0
"WeaponPrice" "800"
"WeaponArmorRatio" "1.05"
"CrosshairMinDistance" "4"
"CrosshairDeltaDistance" "3"
"Team" "TERRORIST"
"BuiltRightHanded... |
--[[
Name: "sv_autorun.lua".
Product: "kuroScript".
--]]
local MOUNT = MOUNT;
-- Include some prefixed files.
kuroScript.frame:IncludePrefixed("sh_autorun.lua");
-- Whether or not to only display typing notices when visible.
kuroScript.config.Add("inflation_scale", 1, true);
-- A function to update the costs for a ... |
if not modules then modules = { } end modules ['math-ren'] = {
version = 1.001,
comment = "companion to math-ren.mkiv",
author = "Hans Hagen, PRAGMA-ADE, Hasselt NL",
copyright = "PRAGMA ADE / ConTeXt Development Team",
license = "see context related readme files"
}
local next = next
local... |
-- Create a table that will contain all of our tests we are setting up.
local M = {}
-- Set up some defaults...
M.isApple = false
M.isAndroid = false
M.isGoogle = false
M.isKindleFire = false
M.isNook = false
M.is_iPad = false
M.isTall = false
M.isSimulator = false
local model = system.getInfo("model"... |
local export = {}
function export.tr(text, lang, sc)
text = require("Cans-translit").tr(text, lang, sc)
local repl = {
["ī"] = "ii",
["ō"] = "uu",
["ā"] = "aa",
["š"] = "sh",
["ð"] = "th",
["e"] = "ai",
["o"] = "u",
["y"] = "j",
["f"] = "v",
["c"] = "g",
}
for char, replacement in pairs(rep... |
-- Clever Coverup --
local cover = CreateSprite("px","BelowBullet")
cover.Scale(640,480)
cover.color = {0,0,0}
--cover.color = {0.5,0.75,0.75}
-- Encounter Starting --
__enemies = enemies
enemies = {}
__es = EncounterStarting
function EncounterStarting()
ModName = GetModName()
-- Set and Replace State
... |
if not modules then modules = { } end modules ['font-pat'] = {
version = 1.001,
comment = "companion to font-ini.mkiv",
author = "Hans Hagen, PRAGMA-ADE, Hasselt NL",
copyright = "PRAGMA ADE / ConTeXt Development Team",
license = "see context related readme files"
}
-- This functiononality... |
-- Method Simple: Add anims and use danceDir
function onCreatePost()
makeAnimatedLuaSprite('gf2', 'characters/GF_assets', 1270, 100)
addAnimationByIndices('gf2', 'danceLeft', 'GF Dancing Beat', '30, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14', 24)
addAnimationByIndices('gf2', 'danceRight', 'GF Dancing Beat',... |
local lu = require("luaunit")
TestHandler = require("test.unit.mockable_case"):extend()
function shallowcopy(orig)
local orig_type = type(orig)
local copy
if orig_type == 'table' then
copy = {}
for orig_key, orig_value in pairs(orig) do
copy[orig_key] = orig_value
end
... |
local group;
local t = Def.ActorFrame{
LoadActor("base")..{
SetMessageCommand=function(self,params)
local pt_text = params.Text;
local group = params.Text;
if params.HasFocus then
self:x(2);
self:y(-6.4);
else
self:x(0);
self:y(-6.4)
end;... |
local lf = love.filesystem
local Hero = require 'lib.hero'
local Serialize = require 'lib.serialize'
local Editor = {}
local function deleteDirectory (item, depth)
depth = depth or 0
if lf.isDirectory(item) then
for _, child in ipairs(lf.getDirectoryItems(item)) do
deleteDirectory(item ..... |
--[[
MIT License
Copyright (c) 2019-2020 Mitchell Davis <coding.jackalope@gmail.com>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
... |
AddCSLuaFile()
--[[
This is a utility to generate icons. You can accomplish some stuff through the console command,
but it's usually easier to just edit the source code.
Frequently used colors
combine 60,115,140
synth 210,150,70
bird 50,86,34
fun 220,0,255 (4th in pallet)
shotgunner 140 84 60
vort mid 2nd ... |
local _ = require "lib.lume"
return {
["black"] = { _.color("#000000") },
["dark-blue"] = { _.color("#1d2b53") },
["dark-purple"] = { _.color("#7e2553") },
["dark-green"] = { _.color("#008751") },
["brown"] = { _.color("#ab5236") },
["dark-grey"] = { _.color("#5f574f") },
["light-grey"] ... |
local StringUtils = {}
setmetatable(
StringUtils,
{
__index = function(table, key)
local lowerFirst = key:sub(1, 1):lower() .. key:sub(2)
if lowerFirst ~= key then
print(
"DEPRECATED: " ..
key ..
" and other capitalized functions in StringUtils are deprecated. Please use the lower-case ... |
local Diff = require("api.test.Diff")
local ansicolors = require("thirdparty.ansicolors")
local Assert = {}
function Assert.is_truthy(actual, msg)
if not actual then
error(("expected truthy, got '%s'"):format(actual), 2)
end
return actual
end
function Assert.is_falsy(actual, msg)
if actual then
... |
-- Example: FPS and delta-time
function load()
local f = love.graphics.newFont(love.default_font, 12)
love.graphics.setFont(f)
end
function draw()
-- Draw the current FPS.
love.graphics.draw("FPS: " .. love.timer.getFPS(), 50, 50)
-- Draw the current delta-time. (The same value
-- i... |
--[[
MIT License
Copyright (c) 2021 Michael Wiesendanger
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, mod... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.