content stringlengths 5 1.05M |
|---|
local sep = GetPathSeparator()
local function makeUnique(exeditor)
local docs = {}
for id, doc in pairs(ide:GetDocuments()) do
if doc:GetEditor() ~= exeditor and doc:GetFileName() and doc:GetFilePath() then
local fn = doc:GetFileName()
local fpath = doc:GetFilePath()
local uniquepath = true
... |
local clusterio_api = require("modules/clusterio/api")
local serialize = require("modules/clusterio/serialize")
local inventories = require("modules/inventory_sync/define_player_inventories")
local save_crafts = require("modules/inventory_sync/save_crafts")
local player_stat_keys = require("modules/inventory_sync/defin... |
local LineCollider, super = Class(Collider)
function LineCollider:init(parent, x1, y1, x2, y2, mode)
super:init(self, parent, x1, y1, mode)
self.x2 = x2
self.y2 = y2
end
function LineCollider:collidesWith(other, symmetrical)
other = self:getOtherCollider(other)
if not self:collidableCheck(other) ... |
--[[
#### Title: Weaponry - Realistic Gunplay
#### Description: FiveM Script that adds Recoil to weapons, ability to toggle the reticle
#### and removes ammo from the hud
####
#### URL: https://forum.fivem.net/t/weaponry-realistic-gunplay-recoil-no-ammo-hud-no-reticle/
#### Author: ... |
local composer = require("composer")
local display = require("display")
local native = require("native")
local audio = require("audio")
local scene = composer.newScene()
-- -----------------------------------------------------------------------------------
-- Code outside of the scene event functions below will only... |
-- Lua module loader for gnumake (luaload) is intended to assist with modular
-- table definitions, mutations, and namespace management. Definition of
-- build rules and templates will still be done within makefiles.
-- Actual templates are defined in makefiles
executable = compose { templates = exe_template }
bin... |
project "freeimage-libpng"
kind "StaticLib"
language "C"
systemversion "latest"
targetdir (binLocationOverride.."bin/" .. outputdir .. "/%{prj.name}")
objdir (binLocationOverride.."bin-int/" .. outputdir .. "/%{prj.name}")
files
{
"*.c",
"*.h",
}
includedirs
{
"../../../zlib/include/",--/Hazel/vendo... |
--[[
The MIT License (MIT)
Copyright (c) 2016 olueiro <github.com/olueiro>
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,... |
-----------------------------------
-- Area: Arrapago Reef
-- Mob: Lamia No.19
-----------------------------------
mixins = {require("scripts/mixins/weapon_break")}
function onMobEngaged(mob,target)
local mobId = mob:getID();
SpawnMob(mobId+1):updateEnmity(target);
SpawnMob(mobId+2):updateEnmity(target);
... |
dofile('../../include.lua')
local util = require'util'
local xbox360 = require 'xbox360'
xbox360.open()
while 1 do
local ret = xbox360.read()
print(unpack(ret.dpad))
print(unpack(ret.buttons))
print("LS:",unpack(ret.lstick))
print("RS:",unpack(ret.rstick))
print("TR:",unpack(ret.trigger))
--
-- print('Buttons:... |
function display(message, level)
local n = require("notify")
if n == nil then
return
end
n.setup({
stages = "slide",
})
n(message, level, {
title = "cprl.nvim",
timeout = 2000,
})
end
local modes = {}
modes["branch"] = function()
return shellexec("git rev-p... |
project "OpenCV"
kind "StaticLib"
language "C++"
cppdialect "C++17"
staticruntime "off"
targetdir ("bin/" .. outputdir)
objdir ("bin-obj/" .. outputdir)
files
{
"include/**.h",
"include/**.hpp"
}
includedirs
{
"include"
}
filter "system:linux"
systemversion "latest"
filter "system:windows"... |
-- ========== THIS IS AN AUTOMATICALLY GENERATED FILE! ==========
PlaceObj('StoryBit', {
ActivationEffects = {
PlaceObj('CauseFault', {
'Grid', "electricity",
}),
},
Effects = {},
Enables = {
"Boost19_BadStirlingGenerator_FaultGenerator",
},
Prerequisites = {
PlaceObj('CheckObjectCount', {
'Label',... |
select(2, ...) 'Utility.Functions'
-- Imports
local utf8 = require 'Shared.UTF8'
------------------------------------------
-- Constants
------------------------------------------
local addonName = select(1, ...)
------------------------------------------
-- Exports
------------------------------------------
-- Re... |
if SERVER then
AddCSLuaFile("shared.lua")
SWEP.Weight = 5
SWEP.AutoSwitchTo = true
SWEP.AutoSwitchFrom = true
end
if ( CLIENT ) then
SWEP.ViewModelFOV = 62
SWEP.ViewModelFlip = false
SWEP.CSMuzzleFlashes = false
SWEP.Slot = 1
SWEP.SlotPos = 1
SWEP.PrintName = "Hands"
SWEP.DrawAmmo = false... |
-- Copyright (c) 2022 Ratheesh <ratheeshreddy@gmail.com>
-- Author: Ratheesh S
--
-- 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 righ... |
-- =============================================================
-- Copyright Roaming Gamer, LLC. 2009-2015
-- =============================================================
-- Behavior - Mover: Drag-n-Drop with Callback on Drop
-- =============================================================
-- License
--... |
local color_gamma = require('polarmutex.colorschemes.utils').color_gamma
local config = require('polarmutex.colorschemes.config')
local colors = {
black = '#06080A',
bg0 = '#11121D',
bg1 = '#1A1B2A',
bg2 = '#212234',
bg3 = '#392B41',
bg4 = '#4A5057',
bg5 = '#282c34',
bg_red = '#FE6D85',... |
---------------------------------------------------------------------------------------------------
---target.lua
---date: 2021.7.15
---reference: -x/data/THlib/player/player.lua
---desc: This file defines functions that find target(s) for movement/attack
----------------------------------------------------------------... |
local S, L, O, U, D, E = unpack(select(2, ...));
local Module = S:NewModule('CastingBar');
-- WoW API
local GetSpellCooldown, UnitCanAttack = GetSpellCooldown, UnitCanAttack;
local UnitCastingInfo, UnitChannelInfo = UnitCastingInfo, UnitChannelInfo;
local GetTime = GetTime;
-- Libraries
local LCG = S.Libraries.LCG;
... |
utils = dofile('utils.lua')
s0 = box.schema.space.create('tweedledum')
i0 = s0:create_index('primary', { type = 'tree', parts = {1, 'unsigned'}, unique = true })
bsize = i0:bsize()
-- integer keys
s0:insert{1, 'tuple'}
box.snapshot()
s0:insert{2, 'tuple 2'}
box.snapshot()
i0:bsize() > bsize
s0:insert{3, 'tuple 3'}... |
local CrimeType = {
ActiveSummon = "ActiveSummon",
Assault = "Assault",
AttackAnimal = "AttackAnimal",
Diseased = "Diseased",
EmptyPocketNoticed = "EmptyPocketNoticed",
IncapacitatedAssault = "IncapacitatedAssault",
ItemDestroy = "ItemDestroy",
KilledAnimal = "KilledAnimal",
LoudContinuousNoise = "LoudContinuo... |
local function load_wordmatrix()
local filename = 'data/wordmatrix_movie_25000'
local file = torch.DiskFile(filename):binary()
local obj = file:readObject()
file:close()
return obj
end
local wordmatrix = load_wordmatrix()
print('size():', wordmatrix:size())
print('[1]:', wordmatrix[1])
return word... |
function os_url(url)
return "https://dl.dropboxusercontent.com/u/30677896/ComputerCraft/Trains2/" .. url
end
STATUS_HAS_TRAIN = 1;
STATUS_NO_TRAIN = 0;
MESSAGE_RELEASE_TRAIN = "free_train"
MESSAGE_STATUS = "status"
MESSAGE_REBOOT = "reboot"
MESSAGE_HELLO = "hello"
MESSAGE_CONTROL_ANNOUNCE = "control_pu... |
--[[
Use enUS.lua to translate from...
]]
NeP.Locale['koKR'] = {} |
return {
version = "1.1",
luaversion = "5.1",
orientation = "orthogonal",
width = 41,
height = 25,
tilewidth = 32,
tileheight = 32,
properties = {},
tilesets = {
{
name = "box1-32px",
firstgid = 1,
tilewidth = 32,
tileheight = 32,
spacing = 0,
margin = 0,
... |
-- Copyright (c) 2019 Redfern, Trevor <trevorredfern@gmail.com>
--
-- This software is released under the MIT License.
-- https://opensource.org/licenses/MIT
describe("Keyboard", function()
local keyboard = require "moonpie.keyboard"
local mock_love = require "moonpie.test_helpers.mock_love"
after_each(function... |
local gears = require("gears")
local awful = require("awful")
local beautiful = require("beautiful")
local function set_wallpaper(s)
-- Wallpaper
if beautiful.wallpaper then
local wallpaper = beautiful.wallpaper
-- If wallpaper is a function, call it with the screen
if type(wallpaper) == "function" the... |
-----------------------------------------------------------------------------
-- Name: tree.wx.lua
-- Purpose: wxTreeCtrl wxLua sample
-- Author: J Winwood
-- Modified by:
-- Created: 16/11/2001
-- RCS-ID:
-- Copyright: (c) 2001 J Winwood. All rights reserved.
-- Licence: wxWidgets licence
---... |
local E, C, L = select(2, ...):unpack()
if not C.stats.enable or not C.stats.config.Gold.enable then return end
----------------------------------------------------------------------------------------
-- Gold of DataText (modified from ShestakUI)
-----------------------------------------------------------------------... |
--- @ignore
CLGAMEMODESUBMENU.base = "base_gamemodesubmenu"
CLGAMEMODESUBMENU.priority = 99
CLGAMEMODESUBMENU.title = "submenu_gameplay_avoidroles_title"
function CLGAMEMODESUBMENU:Populate(parent)
local form = vgui.CreateTTT2Form(parent, "header_roleselection")
local roles = roles.GetList()
for i = 1, #roles d... |
local stringx = require('pl.stringx')
local cmd = torch.CmdLine()
cmd:option("-params_file","../../Atten/save_t_given_s/params","")
cmd:option("-model_file","../../Atten/save_t_given_s/model1","")
cmd:option("-batch_size",128,"")
cmd:option("-gpu_index",1,"")
cmd:option("-save_model_path","save","")
cmd:option("-alpha"... |
require( 'mysqloo' )
local function initULibSync()
ULibSync.initBanSync()
ULibSync.initUsersSync()
ULibSync.initGroupsSync()
end
local function initMySQLOO()
ULibSync.mysql = mysqloo.connect(ULibSync.ip, ULibSync.username, ULibSync.password, ULibSync.database, ULibSync.port)
function ULibSync.mysq... |
local Save_Event = Game_Event:extend("Save_Event")
function Save_Event.prototype:setupProps()
self._characterName = 'save_point'
self._standAnim = true
self.__animDelay = 0.3
self.light = {
radius = 16,
red = 1,
green = 1,
blue = 1,
alpha = 0.5,
offset = Point(8, 8)
}
end
function Sa... |
local ThreatLib = LibStub and LibStub("ThreatClassic-1.0", true)
if not ThreatLib then return end
local SHAZZRAH_ID = 12264
local GATE_ID = 23138
ThreatLib:GetModule("NPCCore"):RegisterModule(SHAZZRAH_ID, function(Shazzrah)
function Shazzrah:Init()
self:RegisterCombatant(SHAZZRAH_ID, true)
self:RegisterSpellHand... |
---@module fimbul.v35.artifact_template
local artifact_template = {}
function artifact_template:new(y)
local neu = y or {}
setmetatable(neu, self)
self.__index = self
neu.templatetype = "artifact"
return neu
end
return artifact_template
|
----
-- @file WorldFactory
---- Brief description.
-- <#Description#>
-- @param object <#object description#>
-- @return <#return value description#>
function WorldFactory:has(object)
end
---- Brief description.
-- <#Description#>
-- @return <#return value description#>
function WorldFactory:destroyAll()
end
---- ... |
-- Part of BioLua by SweetPalma, 2017. All rights reserved.
-- Main BioLua Shell caller:
local L_loaded, L = pcall(require, 'linenoise')
local biolua = require 'biolua.init'
local demo = require 'biolua.shell.demo'
-- Internal: Read line (using wrapped Linenoise or default IO) and return result:
local function readl... |
-----------------------------------
-- Area: Al'Taieu
-- NPC: ??? (Jailer of Justice Spawn)
-- Allows players to spawn the Jailer of Justice by trading the Second Virtue, Deed of Moderation, and HQ Xzomit Organ to a ???.
-- !pos , -278 0 -463
-----------------------------------
local ID = require("scripts/zones/AlTaie... |
--Worm scale
behemoth_worm_scale = 1.5
experimental_worm_scale = 5
--Spiter scale
smallspitterscale = 0.5
mediumspitterscale = 0.8
bigspitterscale = 1.2
behemothspitterscale = 1.7
expspitterscale = 7
--Biter scale
smallbitterscale = 0.5
mediumbitterscale = 0.8
bigbitterscale = 1.2
behemothbitterscale = 1.7
expbitters... |
local Rect = class('Rect');
function Rect:initialize(x, y, w, h)
self.x = x
self.y = y
self.w = w
self.h = h
end
|
return {
name = "Tailwind CSS",
language_server = {
name = "tailwindcss",
},
}
|
-- Fast, linear fuzzy matcher used with match_dialogue.lua
-- i.e. will match gce to /G/oogle /C/hrom/e/.
local function fuzzy_match(needle, haystack)
local needle_idx = 1
local needle_char = needle[needle_idx]
local last_needle_char
local match_indexes = {}
for i = 1, #haystack do
local h... |
_VERSION = '5.1.0'
ESX.WhiteList = {
-- nima
'steam:11000013ff94da8',
}
RegisterServerEvent('updateLoadout')
AddEventHandler('updateLoadout', function(loadout)
local Source = source
if(Users[Source])then
Users[Source].set("loadout", loadout)
end
end)
RegisterServerEvent('printUsers')
AddEventHandler('printUser... |
local LAM2 = LibStub:GetLibrary("LibAddonMenu-2.0")
CrownCustomizer = {}
CrownCustomizer.name = "CrownCustomizer"
CrownCustomizer.version = "-"
CrownCustomizer.author = "@triase"
CrownCustomizer.Default = {
IconSize = 64,
IconName = "Default"
}
CrownCustomizer.SelectIcons = {
{ name = "Default", path = ... |
local msg = {}
local s = ""
uart.setup(0, 115200, 8, uart.PAR_NONE, uart.STOP_1)
uart.setup(uart.ATC, 0, 0, uart.PAR_NONE, uart.STOP_1)
uart.write(0, "start test lua app.\r\n")
-- assert debug
-- uart.write(uart.ATC, "at*exassert=1\r\n")
while true do
msg = rtos.receive(rtos.INF_TIMEOUT)
if... |
function start (song)
changeDadCharacter("trolio")
changeDadCharacter("troil")
end
function stepHit (step)
if step == 1344 then
changeDadCharacter("trolio")
end
end |
--=========== Copyright © 2019, Planimeter, All rights reserved. ===========--
--
-- Purpose: Advanced Keyboard Options Frame class
--
--==========================================================================--
class "gui.keyboardoptionsadvancedframe" ( "gui.frame" )
local keyboardoptionsadvancedframe = gui.keyboa... |
local skynet = require "skynet"
local player_mgr = require "player_mgr"
local room = {}
function room.create_room(fd, request)
request.room_conf = {card_counts = 48}
local player = player_mgr:get_by_fd(fd)
local roomInfo = skynet.call("room_mgr", "lua", "create_room", request.game_id,
{base_app =... |
if SERVER then
include "jac/init.lua"
AddCSLuaFile "jac/cl_init.lua"
else
include "jac/cl_init.lua"
end |
local http = require "http"
local nmap = require "nmap"
local shortport = require "shortport"
local stdnse = require "stdnse"
description = [[
Retrieves information from an Apache Hadoop TaskTracker HTTP status page.
Information gathered:
* Hadoop version
* Hadoop Compile date
* Log directory (relative to http://h... |
Credits to DarcyHotDog
----------------------
RoXploits Instructions:
1) Swap the name of "PETNAMEHERE" to a pet of your choice
2) Execute the script and you're done.
3) Enjoy!
local A_1 = "PETNAMEHERE"
local A_2 = -2000000000000000000
local Event = game:GetService("ReplicatedStorage").PetEvents.requestDelete
Event:Fi... |
return {
-- Display name of the tame birds
TAMETALLBIRD_NAME = "재배된 큰 새",
TAMETALLBIRD_DESCRIBE = {
-- Birds are friendly when well fed
FULL = "잘 먹었을 때 친절 함.",
-- Generic inspect string for the bird
GENERIC = "매우 크고 매우 충성.",
-- Bird is hungry and needs food
HU... |
ground_tile_1 = 0
ground_tile_2 = 1
OFFSET_X = 128
OFFSET_Y = - 96
GRID_SIZE = 32
mapSizeX = 10
mapSizeY = 6
map = { }
function awake( )
package.path = ""
--dofile("test1.lua")
end
local topTable = { }
function start( )
local temp = {
sprite = Sprite.new( ),
priority = 0,
}
temp.sprite:newSprite(0, 0... |
local streamcsv, name = {}, ...
streamcsv.read = require(name .. ".read")
streamcsv.write = require(name .. ".write")
function streamcsv.header(record, header)
for position, name in ipairs(header) do
record[header[position]] = record[position]
record[0] = header
end
end
local function nextrecord(state, counter... |
if a and b or c(x == y or a or 5) and z then
print("hello")
end
|
local colors = require('lunarized').colors
return {
normal = {
a = { fg = colors.base03.hex, bg = colors.blue.hex, gui = 'bold' },
b = { fg = colors.base1.hex, bg = colors.base02.hex },
c = { fg = colors.base1.hex, bg = colors.base02.hex },
},
insert = { a = { fg = colors.base03.hex, bg = colors.gree... |
local ArkadiusTradeToolsSalesData = {}
local ArkadiusTradeToolsSales = ArkadiusTradeTools.Modules.Sales
ArkadiusTradeToolsSalesData.NAME = ArkadiusTradeToolsSales.NAME .. "Data15"
ArkadiusTradeToolsSalesData.VERSION = ArkadiusTradeToolsSales.VERSION
ArkadiusTradeToolsSalesData.AUTHOR = ArkadiusTradeToolsSales.AUTHOR
l... |
-- build script
workspace ("Vision")
architecture ("x64")
systemversion ("latest")
startproject ("EagleEye")
configurations
{
"Debug",
"Release",
"Dist"
}
flags
{
"MultiProcessorCompile"
}
filter ("system:windows")
defines
{
"VN_PLATFORM_DESKTOP"
}
filter ("system:linux")
defines
... |
--[[ Render an image series to a grid in frontal view
--
-- Run this using meshup model.lua animation.lua -s [outname="series"]
--
-- Renders the given models and animations to an image which contains a
-- series of snapshots of the animations from a frontal view. The resulting
-- file will be called "montage_[outname]... |
local ObjAttackHitbox = require "objects.ObjAttackHitbox"
local ObjDamageHitbox = Class.create("ObjDamageHitbox", ObjAttackHitbox)
util.transient(ObjDamageHitbox)
function ObjDamageHitbox:init(creator, damage, stun,
refresh, forceX, forceY, element, ignoreType)
self.attacker = creator
self.damage = damage
self.st... |
ITEM.name = "Нога снорка"
ITEM.desc = "В ноге снорка содержится большое число сверхэластичных сухожилий. Именно это и объясняет способность мутанта совершать такие высокие и затяжные прыжки. Ученые до сих пор пытаются найти применение этим сухожилиям и будут весьма благодарны за каждый принесенный им образец. \n\nХАРА... |
local nimh_tint = {r = .75, b = .5, g = .5, a = 1}
local li_tint = {r = 0, b = 1, g = 0, a = 1}
--////////////////////////////////////////
--NiMH Battery section
--////////////////////////////////////////
local item_nimh = table.deepcopy(data.raw.item["accumulator"])
item_nimh.icon = nil
item_nimh.icons = {
{
icon ... |
--------------------------------------
-- IO device identifier
--------------------------------------
IO_IIDXIO_IDENTIFIER = "iidxio"
--------------------------------------
-- Analog input states
--------------------------------------
IO_IIDXIO_AI_TT_P1 = 0
IO_IIDXIO_AI_TT_P2 = 1
IO_IIDXIO_AI_SLIDER_1 = 2
IO_IIDXIO_AI... |
local skynet = require "skynet"
local snax = require "skynet.snax"
local socket = require "skynet.socket"
local crypt = require 'skynet.crypt'
local websocket = require "http.websocket"
local ioe = require 'ioe'
local cjson = require 'cjson.safe'
local sysinfo = require 'utils.sysinfo'
local restful = require 'http.re... |
local moon = require("moon")
local redis = require("moon.db.redis")
local HOST = "127.0.0.1"
local PORT = 6379
local function run_example()
local n = 0
local timerid = moon.repeated(1000,-1,function ()
print("per sec ",n)
n = 0
end)
moon.async(function()
local db,err = redis.... |
object_tangible_tcg_series1_structure_deed_barn = object_tangible_tcg_series1_shared_structure_deed_barn:new {
templateType = STRUCTUREDEED,
placeStructureComponent = "PlaceStructureComponent",
generatedObjectTemplate = "object/building/player/city/barn_no_planet_restriction.iff",
}
ObjectTemplates:addTemplate(objec... |
myTable = {"element1","element2","element3"}
print( myTable [ 1 ] ) -- prints: element1
print( myTable [ 2 ] ) -- prints: element2
print( myTable [ 3 ] ) -- prints: element2 |
local fio = require('fio')
local t = require('luatest')
local g = t.group('integration.zones')
local helpers = require('test.helper')
g.before_all(function()
g.cluster = helpers.Cluster:new({
datadir = fio.tempdir(),
use_vshard = true,
server_command = helpers.entrypoint('srv_basic'),
... |
function printf(...) print(string.format(...)) end
function clear(array) local n = #array ; for i = 1, n do array[i] = nil end end
function push(stack, value) stack[#stack + 1] = value end
local values, window_size = {}, 25
local part_one, part_two = nil, nil
do -- Load input file
local input_file = io.open... |
--[[
The MIT License (MIT)
Copyright (c) 2014 Socialz (+ soc-i-alz GitHub organization)
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 ... |
-- // ------------------------------------------------------------------- // --
-- // // --
-- // A T O M A G I C A L Y G E N E R A T E D F I L E // --
-- // - D O N O T E D I T - // ... |
local rep = string.rep
do --- smoke
assert(("p"):rep(0) == "")
assert(("a"):rep(3) == "aaa")
assert(("x\0z"):rep(4) == "x\0zx\0zx\0zx\0z")
end
do --- versus concat
local s = ""
for i = 1, 75 do
s = s .. "{}"
assert(s == ("{}"):rep(i))
end
end
do --- misc
local y
for i=1,100 do y = rep("a", 10... |
--傀海兽影-兽
local m=14000147
local cm=_G["c"..m]
cm.named_with_Unchurted=1
function cm.initial_effect(c)
c:SetSPSummonOnce(m)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
... |
require "SvgWriter"
require "vmath"
require "Viewport"
require "SubImage"
local subImageSize = 350;
local subImages = SubImage.SubImage(1, 1, subImageSize, subImageSize, 50, 50);
--Gives a [-1, 1] range.
local coordSize = 2;
local vp = Viewport.Viewport(subImages:SubSize(), {0, 0}, coordSize)
local trans2 = Viewpor... |
-- Key Manager plugin. Written by Tyler "Scuba Steve 9.0/Khalitz/Kavec/etc" Gibbons
-- Key distribution function written by Ben "Waffles" Lawrence
-- Some key selection code stolen from Slime's quickJump plugin
-- Bear with me, the comments are going to get weird. I am/was a bit loopy on minocycline when I wrote this.
... |
module(... or '', package.seeall)
-- Add the required paths
cwd = '.';
uname = io.popen('uname -s')
system = uname:read();
package.cpath = cwd.."/?.so;"..package.cpath;
package.cpath = cwd.."/../../../UPennDev/Player/Lib/?.so;"..package.cpath;
package.path = cwd.."/../../../UPennDev/Player/Util/?.lua;"..package.pat... |
local siteurl = ''
function Meta (meta) siteurl = meta.siteurl end
function fix_link (url) return url:sub(1,1) == '/' and siteurl .. url or url end
function Link (link) link.target = fix_link(link.target); return link end
function Image (img) img.src = fix_link(img.src); return src end
return {{Meta = Meta}, {Link = Li... |
-- A solution contains projects, and defines the available configurations
solution "lowrezjam"
configurations { "Debug", "Release" }
includedirs { "./", "./glcommon", "/usr/local/include" }
-- stuff up here common to all projects
kind "ConsoleApp"
language "C++"
--location "build"
--targetdir "build"
locatio... |
-- 方向入力に従ってキャラクターを移動させる
-- 移動速度
local MOVESPEED = 10.0
-- DxChara.x での走りアニメーションの番号
local ANIM_RUN = 1
-- DxChara.x での待機アニメーションの番号
local ANIM_NEUTRAL = 4
-- 斜め入力用の各軸の倍率( sin( 45°) )
local VECTOR_SCALING = 0.70710678118
local ModelHandle;
local AnimTotalTime;
local AnimNowTime;
local AnimAttachIndex;
local RunFlag;
... |
local logString, logBoolean, logKey, logTable, getPrintableValue
local function getPadding(amount)
return string.rep(' ', amount)
end
logString = function(value)
return "'" .. value .. "'"
end
logBoolean = function(bool)
return bool and 'true' or 'false'
end
logKey = function(key, value)
return key .. ' = '... |
local M = {}
M.disabled = {
n = {
["gi"] = "",
},
}
M.general = {
i = {
-- go to beginning and end
["<C-b>"] = { "<ESC>^i", "論 beginning of line" },
["<C-e>"] = { "<End>", "壟 end of line" },
},
n = {
["<leader>q"] = { ":q<cr>", "quit" },
["H"] = { "^", "^" },
["L"] = { "$", "$" },
["<C-d>"] =... |
http = require('socket.http')
json = require('json')
function readLocalWeather()
data, status = http.request('http://192.168.1.105/api/weather')
if status == 200 then
last20 = json.decode(data)
weather = {
temperature = string.format("%.2f", last20[1].temperature),
pressure = string.format("%.2f", last2... |
require("test_tools")
local LJTokensEnum = {"TK_and", "TK_break", "TK_do", "TK_else", "TK_elseif", "TK_end", "TK_false", "TK_for", "TK_function", "TK_goto", "TK_if", "TK_in", "TK_local", "TK_nil", "TK_not", "TK_or", "TK_repeat", "TK_return", "TK_then", "TK_true", "TK_until", "TK_while", "TK_concat", "TK_dots", "TK_eq"... |
#!/usr/bin/env lua
function parsestrings(output)
return end
if not arg then
print("Must be called from the command line")
return 1
end
if #arg < 1 then
print("Usage: " .. arg[0] .. " <infile> [outfile]")
return 1
end
local i = arg[1] == "-" and io.stdin or io.open(arg[1])
if not i then
print("Could not open fil... |
local change = require('change')
describe('change', function()
it('should generate the correct change when there is only one type of coin', function()
assert.same({ 5 }, change(5, { 1 }))
end)
it('should generate the correct change when there are multiple coin types', function()
assert.same({ 5, 0 }, ch... |
ITEM.name = "Artifact"
ITEM.width = 1
ITEM.height = 1
ITEM.category = "Artifacts"
ITEM.description = "An artifact. Valuable."
ITEM.longdesc = "Longer description here."
ITEM.equipIcon = Material("materials/vgui/ui/stalker/misc/equip.png")
ITEM.price = 1
function ITEM:GetDescription()
local quant = self:GetData("qu... |
-- an example of adding child nodes to an app node
-- this app node manages a moving tiled layer as a background effect
-- note that lt.display_list will batch contigious renders from the same texture
-- copyright 2016 Samuel Baird MIT Licence
local class = require('core.class')
local app_node = require('lt.app_node')... |
local Class = require("lib.class")
local Vec3 = require("lib.vec3")
local World = require("src.world")
local Entity = Class("Entity")
Entity.isEntity = true
Entity.isAlive = true
function Entity:initialize(position, rotation, velocity)
self.position = position or Vec3(0, 0, 0)
self.rotation = rotation or 0
... |
-- Aerial is a code browser for Neovim that provides great integration with
-- Neovim's built-in LSP client.
require("aerial").setup(
{
-- Enum: prefer_right, prefer_left, right, left
-- Determines the default direction to open the aerial window. The 'prefer'
-- options will open the window in the other d... |
if SERVER then
AddCSLuaFile()
end
SWEP.HoldType = "ar2"
if CLIENT then
SWEP.PrintName = "M16"
SWEP.Slot = 2
SWEP.ViewModelFlip = false
SWEP.ViewModelFOV = 64
SWEP.Icon = "vgui/ttt/icon_m16"
SWEP.IconLetter = "w"
end
SWEP.Base = "weapon_tttbase"
SWEP.Kind = WEAPON_HEAVY
SWEP.WeaponID = AMMO_M16
SWEP.spawnTy... |
--[[
This file is part of halimede. It is subject to the licence terms in the COPYRIGHT file found in the top-level directory of this distribution and at https://raw.githubusercontent.com/pallene/halimede/master/COPYRIGHT. No part of halimede, including this file, may be copied, modified, propagated, or distributed exc... |
--!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... |
object_tangible_painting_painting_wod_scene_02 = object_tangible_painting_shared_painting_wod_scene_02:new {
}
ObjectTemplates:addTemplate(object_tangible_painting_painting_wod_scene_02, "object/tangible/painting/painting_wod_scene_02.iff")
|
--[[
Name: "cl_inventory.lua".
Product: "kuroScript".
--]]
local PANEL = {};
-- Called when the panel is initialized.
function PANEL:Init()
self:SetSize(kuroScript.menu.width, kuroScript.menu.height);
-- Set some information.
self.panelList = vgui.Create("DPanelList", self);
self.panelList:SetPadding(2);
sel... |
--
-- Copyright (c) 2016-present, Facebook, Inc.
-- All rights reserved.
--
-- This source code is licensed under the BSD-style license found in the
-- LICENSE file in the root directory of this source tree. An additional grant
-- of patent rights can be found in the PATENTS file in the same directory.
--
-- Default... |
local M = {}
local ListView = require('guihua.listview')
local TextView = require('guihua.textview')
local util = require('guihua.util')
local log = require('guihua.log').info
local trace = require('guihua.log').trace
local api = vim.api
local top_center = require('guihua.location').top_center
-- local path_sep = req... |
require("engine/test/bustedhelper")
require("engine/render/sprite")
describe('spr_r', function ()
-- it's a bit hard to do a display simulation with 128x128
-- so just work on 16x16; not quite enough to contain any rotated sprite of 8x16,
-- but with the right pivot you can make it fit somewhat
-- note that... |
--- See also:
--- <https://microsoft.github.io/language-server-protocol/specifications/specification-3-17/#textDocument_signatureHelp>
local M = require('dotfiles.autoload')('dotfiles.lsp.signature_help')
local lsp = require('vim.lsp')
local lsp_utils = require('dotfiles.lsp.utils')
local lsp_global_settings = require... |
local logger = hs.logger.new("custom.lua", 'debug')
-- Specify Spoons which will be loaded
hspoon_list = {
-- "AClock",
-- "BingDaily",
-- "Calendar",
-- "CircleClock",
-- "ClipShow",
"CountDown",
-- "FnMate",
-- "HCalendar",
-- "HSaria2",
"HSearch",
-- "KSheet",
-- "Spee... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.