content stringlengths 5 1.05M |
|---|
local spec = require('cmp.utils.spec')
local matcher = require('cmp.matcher')
describe('matcher', function()
before_each(spec.before)
it('match', function()
assert.is.truthy(matcher.match('', 'a') >= 1)
assert.is.truthy(matcher.match('a', 'a') >= 1)
assert.is.truthy(matcher.match('ab', 'a') == 0)
... |
-- listen port
local port = 8888
-- power level in the json array from lightshowpi to turn on
local turnon = .4
-- channels 1-4 in the json array
local chans = {1,2,3,4}
-- pins to opperate the relays
local pins = {4,3,2,1}
-- map the channels to pins in a lua table
local chan_to_pin = {}
for idx, chan in ipairs(c... |
local me = ...
local M = { }
local name1 = "module"
local name2 = "path"
local TK = require("PackageToolkit")
M.chop = function(path)
if (string.match(path, "[/%.]")) == nil then
return ""
else
return string.match(path, "(.-)[/%.]?[^%./]+$")
end
end
M.run = function(msg)
if msg == nil then
msg = ""
... |
add_rules("mode.debug", "mode.release")
-- generate PTX code for the virtual architecture to guarantee compatibility
add_cugencodes("compute_35")
target("bin")
set_kind("binary")
add_cuflags("-rdc=true")
add_includedirs("inc")
add_files("src/*.cu")
|
local moses = require 'moses'
local say = require 'say'
local registerAsserts = function(assert)
-----------------------------------------------------------------------------
say:set('assertion.contains.positive', 'Expected %s to contain %s')
say:set('assertion.contains.negative', 'Expected %s to not contain %s... |
local comm = require "comm"
local nmap = require "nmap"
local shortport = require "shortport"
local stdnse = require "stdnse"
description = [[
Gathers information from an IRC server.
It uses STATS, LUSERS, and other queries to obtain this information.
]]
---
-- @output
-- 6665/tcp open irc
-- | irc-info:
-- | ... |
--- [PolyTree](http://www.angusj.com/delphi/clipper/documentation/Docs/Units/ClipperLib/Classes/PolyTree/_Body.htm) is intended as a
-- **read-only** data structure that should only be used to receive _solutions_ from clipping and offsetting operations.
--
-- (Follow the link for a nice visual example.)
--
-- It's an a... |
--マイルド・ターキー
function c47558785.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
--scale change
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(47558785,0))
e1:SetCategory(CATEGORY_DICE)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_PZONE)
e1:SetCountLimit(1)
e1:SetTarg... |
--ハーピィズペット竜-セイント・ファイアー・ギガ
--Script by XyLeN
function c100200200.initial_effect(c)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(100200200,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,100200200)
e1:Set... |
function managerGpio(a)local b=tonumber(a.trh)if a.rh>=b and a.rt>=a.dp-2 then setGpioPin(2,gpio.OUTPUT,gpio.LOW)elseif a.rh>=b and a.rt<=a.dp-2 then setGpioPin(2,gpio.OUTPUT,gpio.HIGH)elseif a.rh<b-2 then setGpioPin(2,gpio.OUTPUT,gpio.HIGH)end;b,a=nil,nil;node.egc.setmode(node.egc.ALWAYS)end;function setGpioPin(c,d,e)... |
require("utils/lib_loader")
LOG_ENABLED = true
ALLOWED_AP_OPTIONS = {
"AP50",
"APMAX"
}
ALLOWED_TICKET_OPTIONS = {
"CHARLOT",
"MARYUS",
"DEFROT",
"MAURICE"
}
ALLOW_RP_POTIONS = true
if LOG_ENABLED then
log("\n\n\nbegin script logging:")
end
--[[
while not match_all_colors(HORTENSIA.LOADING.RUNNING.COLO... |
local PANEL = {}
function PANEL:Init()
self:SetSize(300, 400)
self:MakePopup()
self:Center()
self:SetTitle("Note")
self.controls = self:Add("DPanel")
self.controls:Dock(BOTTOM)
self.controls:SetTall(30)
self.controls:DockMargin(0, 5, 0, 0)
self.contents = self:Add("DTextEntry")
self.contents:Dock(FILL)
s... |
object_draft_schematic_space_shields_elite_shields = object_draft_schematic_space_shields_shared_elite_shields:new {
}
ObjectTemplates:addTemplate(object_draft_schematic_space_shields_elite_shields, "object/draft_schematic/space/shields/elite_shields.iff")
|
-----------------------------------
-- Area: Northern San d'Oria
-- NPC: Andecia
-- Starts and Finishes Quest: Grave Concerns
-- !pos 167 0 45 230
-----------------------------------
local ID = require("scripts/zones/Southern_San_dOria/IDs");
require("scripts/globals/settings");
require("scripts/globals/quests");
requ... |
room_recruitView=
{
name="room_recruitView",type=0,typeName="View",time=0,report=0,x=0,y=0,width=1280,height=720,visible=1,fillParentWidth=0,fillParentHeight=0,nodeAlign=kAlignTopLeft,
{
name="recruitView",type=0,typeName="View",time=107384673,x=0,y=0,width=307,height=153,nodeAlign=kAlignTopLeft,visible=1,fillParen... |
local AmmoTypes = {}
--
-- Called by modders to add a new ammo type.
-- Ammo types aren't something you can add on the fly. You have one
-- opportunity during loadtime. The ammo types should also be IDENTICAL on
-- server and client.
-- If they're not you will receive errors and maybe even crashes.
--
--
-- game.A... |
local gauntlet_data = require "gauntlet_data"
local deepcopy = require "deepcopy"
local GAUNTLET_DEFS = require "defs.gauntlet_defs"
local TopTier = {
NAME = "Top-Tier",
--REMOVE_AFTER_ACTIVATION = 1,
DOUBLE_RARITY = 1
}
local TOP_TIER_CHANCE_INCREASE = 10
function TopTier:activate(current_round)
ga... |
-- URI parsing and formatting in Lua.
-- Written by Cosmin Apreutesei. Public Domain.
--[[
TODO: absolute path from base path + relative path (RFC 2396)
TODO: absolute uri from base uri + relative path + args override
TODO: add authority and userinfo fields like luasocket.url?
TODO: add params for each path segments?... |
local TableUtils = require('utils.class')
local Vector2 = require('geometry.vector2')
local DiskObstacle = require('geometry.disk')
local SegSeqObstacle = require('geometry.segseq')
local Obstacle = require('core.obstacle')
local Vehicle = require('core.vehicle')
local Seek = require... |
-- Dialogue for NPC "npc_mona"
loadDialogue = function(DL)
if (not DL:isConditionFulfilled("npc_mona", "talked")) then
DL:setRoot(1)
else
DL:setRoot(2)
end
if (not DL:isConditionFulfilled("npc_mona", "talked")) then
DL:createNPCNode(1, 3, "DL_Mona_Hi") -- Oh, a new guest. Welcome to the Red Pearl.
... |
--local propVFX = script:GetCustomProperty("VFX"):WaitForObject()
local player = nil
local propVFX = script:GetCustomProperty("VFX"):WaitForObject()
local VFXon = false
function handleOverlap(trigger, object)
if object ~= nil and object:IsA("Player") then
VFXon = true
print("you have entered the zone")
prop... |
local math = require('math')
local io = require('io')
local os = require('os')
local meta = require("levee.meta")
local _ = require("levee._")
--
-- some local functions
local function trim(s)
return (s:gsub("^%s*(.-)%s*$", "%1"))
end
local Source_mt = {}
Source_mt.__index = Source_mt
function Source_mt:lines(s,... |
local player = ...
local pn = ToEnumShortString(player)
local mods = SL[pn].ActiveModifiers
-- don't allow MeasureCounter to appear in Casual gamemode via profile settings
if SL.Global.GameMode == "Casual"
or not mods.MeasureCounter
or mods.MeasureCounter == "None" then
return
end
-- --------------------------------... |
local gamemode = ScriptedGamemode()
|
local Anti_Raid = {
running = true,
Blacklisted_Users = {
--If text in here is in a members username, then they will be banned
{ u1 = "tokens", u2 = "gg/", u3 = "gg /" },
{ u1 = "raid", u2 = "bot ", u3 = "join gg"},
},
}
---Turns on the anti raid. Its on by default.
functi... |
object_draft_schematic_space_engine_collection_reward_engine_01_mk3 = object_draft_schematic_space_engine_shared_collection_reward_engine_01_mk3:new {
}
ObjectTemplates:addTemplate(object_draft_schematic_space_engine_collection_reward_engine_01_mk3, "object/draft_schematic/space/engine/collection_reward_engine_01_mk3... |
#!/usr/bin/env luajit
package.path = "../luacs/?.lua;" .. package.path
require("test.test-libxml2")
require("test.test-xml")
require("test.test-html")
require("test.test-html-sax-parser")
require("test.test-xml-sax-parser")
require("test.test-xml-stream-sax-parser")
require("test.test-serialize")
require("test.test-s... |
local M = {
is_ready = false;
is_loading = false;
should_sort = false;
should_title = true;
store_file = require'projection.utils'.default_project_store_path();
}
local management = require'projection.management'
local store = require'projection.store'
local utils = require'projection.utils'
local workspace =... |
function equalToOr(test, ...)
for k, v in ipairs(args) do
if v == test then
return true
end
end
return false
end
function validColor(c)
return equalToOr(c, 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096, 8192, 16384, 32768)
end
function createNewViewport()
retu... |
local rx = require"rx"
local Observable = rx.Observable
local Observer = rx.Observer
local Subscription = rx.Subscription
--- Shorthand for creating an Observer and passing it to this Observable's subscription function.
-- @arg {table} self - Observable object
-- @arg {function} onNext - Called when the Observable pro... |
theme_park_marauder_ewok_holy = Creature:new {
objectName = "@npc_name:ewok_base_male",
customName = "Ewok Holy One",
socialGroup = "gondula_tribe",
faction = "gondula_tribe",
level = 34,
chanceHit = 0.35,
damageMin = 400,
damageMax = 550,
baseXp = 4000,
baseHAM = 9000,
baseHAMmax = 11000,
armor = 0,
resis... |
-- ============================================================
-- STRING FUNCTIONS
-- ============================================================
-- $1.. $9 -> replaces with func parameters
-- $champ1..$champ4 -> replaces with name of champion of slot x
-- $CHAMP1..$CHAMP4 -> replaces with name of champion in ordin... |
local Image = require "graphics.image"
local Canvas = require "core.graphics.canvas"
function poti.load()
cc = Canvas(160, 95)
img = Image("player.png")
end
function poti.update(dt)
end
function poti.draw()
cc:set()
poti.clear(255)
img:draw()
cc:unset()
cc:draw(0, 0, 0, 4, 4)
end
|
local hc = require 'hc'
hc.control:addConsole('ScummVM', {
onConsoleLoaded = function()
local path = hc.config:getCoresPath() .. 'scummvm_libretro.' .. hc.soExtension
hc.control:loadCore(path)
end,
onCoreLoaded = function()
hc.config:setCoreOption('scummvm_mouse_speed', '1.0')
... |
-- $Name: Штурман$
-- $Version: 0.6.4$
-- $Autor: kerbal$
-- $Info: Ремейк игры "Штурман" Олега Шамшуры для MSX. Большое спасибо gl00my, Minoru и spline за помощь в создании ремейка. Огромное спасибо Олегу Шамшуре за то, что придумал эту замечательную игру!$
require "sprite"
require "keys"
require "click"
require "fon... |
-- This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild
--
-- This file is compatible with Lua 5.3
local class = require("class")
require("kaitaistruct")
--
-- STL files are used to represent simple 3D models, defined using
-- triangular 3D faces.
--
-- Initially it was i... |
---------------------------------------------------------------------------------------------------
-- Common module
---------------------------------------------------------------------------------------------------
--[[ Required Shared libraries ]]
local actions = require("user_modules/sequences/actions")
local ssl =... |
return PlaceObj("ModDef", {
"title", "Applicants Age",
"id", "ChoGGi_ApplicantsAge",
"steam_id", "2427034032",
"pops_any_uuid", "94298e32-b112-4fbb-98c0-47005af1f4b6",
"lua_revision", 1007000, -- Picard
"version", 2,
"version_major", 0,
"version_minor", 2,
"image", "Preview.jpg",
"author", "ChoGGi",
"code", ... |
Dog = {} -- 1.
function Dog:new() -- 2.
newObj = {sound = 'woof'} -- 3.
self.__index = self -- 4.
return setmetatable(newObj, self) -- 5.
end
function Dog:makeSound() -- 6.
print('I say ' .. ... |
-----------------------------------
-- Ability: Dark Seal
-- Enhances the accuracy of your next dark magic spell.
-- Obtained: Dark Knight Level 75
-- Recast Time: 0:05:00
-- Duration: 1 Spell or 60 seconds, whichever occurs first.
-----------------------------------
require("scripts/globals/settings")
require("scripts... |
#!/usr/bin/env lua
x = 10
local i = 1
while i <= x do
local x = i * 2
print(x)
i = i + 1
end
if i > 20 then
local x
x = 20
print(x + 2)
else
print(x)
end
print(x)
|
--[[
© 2020 TERRANOVA do not share, re-distribute or modify
without permission of its author.
--]]
ITEM.name = "Water Bottle";
ITEM.model = "models/warz/consumables/water_l.mdl";
ITEM.width = 1;
ITEM.height = 1;
ITEM.description = "A bottle of old water. Better than what Breen has, atleast.";
ITEM.permit = "consumab... |
local frame = vgui.Create( "DFrame" )
frame:SetSize( ScrW() - 100, ScrH() - 100 )
frame:Center()
frame:MakePopup()
local palette = vgui.Create( "DColorPalette", frame )
palette:Dock( FILL )
function palette:OnValueChanged( newcol )
PrintTable( newcol )
end
|
local skiplist = require("libs.skiplist")
local __NULL__ = function () end
local counter = util.counter()
local lessThan = function(a,b)
if a.z < b.z then return true
elseif a.z==b.z and a.id < b.id then return true
else return false
end
end
local MakeNode = function (obj)
-- the id field is necessary because, o... |
#! /usr/bin/lua
-- ----------------------------------------------------
-- sqlite3_read.lua
--
-- Oct/29/2014
-- ----------------------------------------------------
require ("luasql.sqlite3")
require ("sql_manipulate")
-- ----------------------------------------------------
print ("*** 開始 ***")
local file_db=arg[1... |
local y = 1
local b = 2
assert(y ~= b)
local function f(x)
require('resty.repl').start()
print('x arg: ' .. tostring(x))
end
f(123)
|
---
--- ColaFramework
--- Copyright © 2018-2049 ColaFramework 马三小伙儿
--- 用于控制卡牌显示的模块
---
---用于控制卡牌显示的类
---@class CardSprite
local CardSprite = Class("CardSprite")
local CharacterType = LandlordEnum.CharacterType
local vector3 = UnityEngine.Vector3
---构造器
function CardSprite:initialize()... |
function Betrayer(Unit, event, miscUnit, misc)
Unit:RegisterEvent("Betrayer_Healing", 5000, 0)
Unit:RegisterEvent("Betrayer_Earth", 7000, 0)
Unit:RegisterEvent("Betrayer_Stoneskin", 8000, 0)
Unit:RegisterEvent("Betrayer_Fire_Totem", 10000, 0)
Unit:RegisterEvent("Betrayer_Light_Bolt", 11000, 0)
end
function Betray... |
-- This software is copyright Kong Inc. and its licensors.
-- Use of the software is subject to the agreement between your organization
-- and Kong Inc. If there is no such agreement, use is governed by and
-- subject to the terms of the Kong Master Software License Agreement found
-- at https://konghq.com/enterpriseso... |
default.ui = {}
default.ui.core = {}
default.ui.core.colors = "listcolors[#00000000;#00000010;#00000000;#68B259;#FFF]"
default.ui.core.bg = "bgcolor[#00000000;false]"
function default.ui.get_itemslot_bg(x, y, w, h)
local out = ""
for i = 0, w - 1, 1 do
for j = 0, h - 1, 1 do
out = out .."image["..x+i..... |
--[[
< CATHERINE > - A free role-playing framework for Garry's Mod.
Development and design by L7D.
Catherine is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) an... |
includeFile("mandalore/BoorkaTheHutt.lua")
includeFile("mandalore/BralorClanMercenary.lua")
includeFile("mandalore/CaridClanExplorer.lua")
includeFile("mandalore/DarthCaedus.lua")
includeFile("mandalore/DarthCaedusFollower.lua")
includeFile("mandalore/DextonClanHunter.lua")
includeFile("mandalore/LomPyke.lua")
includeF... |
--[[--
slot.reset_all{
except = except -- Reset all slots, except slots named in this list
}
Calling this function resets all slots to be empty. An exclusion list may be passed to the function as named argument.
--]]--
local data_metatable = {}
function data_metatable:__index(key)
self[key] = { string_fragment... |
local composer = require( "composer" )
local scene = composer.newScene()
local widget = require( "widget" )
-- -----------------------------------------------------------------------------------
-- Code outside of the scene event functions below will only be executed ONCE unless
-- the scene is removed entirely (not r... |
-- Copyright (c) 2021 Trevor Redfern
--
-- This software is released under the MIT License.
-- https://opensource.org/licenses/MIT
describe("game.ui.widgets.sprite_image", function()
local SpriteImage = require "game.ui.widgets.sprite_image"
it("takes a sprite and draws that sprite to the screen when rend... |
local html = require("lapis.html")
local ErrorPage
do
local _parent_0 = html.Widget
local _base_0 = {
style = function(self)
return style({
type = "text/css"
}, function()
return raw([[ body {
color: #222;
background: #ddd;
font-family: sans-serif... |
local Class, Table, getters, setters, newFunc = _Inherit(require("Blox2D.Classes.layercollector"), "ScreenGui")
function setters:DisplayOrder(value)
Check("Set(DisplayOrder)", "number", value, "value")
self:Set("DisplayOrder", value)
end
function setters:IgnoreGuiInset(value)
Check("Set(IgnoreGuiInset)", "... |
require('vimp')
local assert = require("vimp.util.assert")
local log = require("vimp.util.log")
local helpers = require("vimp.testing.helpers")
local TestKeys1 = '<F4>'
local TestKeys2 = '<F5>'
local Tester
do
local _class_0
local _base_0 = {
test_buffer_block = function(self)
helpers.unlet('foo')
l... |
-- This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild
--
-- This file is compatible with Lua 5.3
local class = require("class")
require("kaitaistruct")
local str_decode = require("string_decode")
--
-- GENMIDI.OP2 is a sound bank file used by players based on DMX sound
-... |
local options =
{
frames =
{
{x=128,y=0,width=128,height=128,}, -- frame 1
}
}
return options
|
local policyModule = require('abtesting.adapter.policy')
local redisModule = require('abtesting.utils.redis')
local systemConf = require('abtesting.utils.init')
local handler = require('abtesting.error.handler').handler
local utils = require('abtesting.utils.utils')
local ERRORINFO = require('ab... |
cflags{
'-I $outdir',
'-I $outdir/include',
}
build('cat', '$outdir/jconfigint.h', {
'$builddir/probe/HAVE___BUILTIN_CTZL',
'$dir/jconfigint.h',
})
pkg.deps = {
'$dir/headers',
'$outdir/jconfigint.h',
}
lib('libjpeg-turbo.a', [[
jcapimin.c jcapistd.c jccoefct.c jccolor.c jcdctmgr.c jchuff.c
jcicc.c jcinit.c ... |
#!/usr/bin/env lua
function and_or(a, b, c)
if a then
return b
else
return c
end
end
|
Plot = require('itorch.Plot')
local showData = function(samples, lables)
local l0_x = {}
local l0_y = {}
local l1_x = {}
local l1_y = {}
for i=1, #samples do
if ( lables[i][1] == 0) then
table.insert(l0_x, samples[i][1])
table.insert(l0_y, samples[i][2])
else
table.insert(l1_x,... |
object_intangible_beast_bm_kaadu = object_intangible_beast_shared_bm_kaadu:new {
}
ObjectTemplates:addTemplate(object_intangible_beast_bm_kaadu, "object/intangible/beast/bm_kaadu.iff")
|
------------------------------------------------------------------------------------------------------------
-- State - Terrain rendering and setup
--
-- Decription: Generates procedurally generated terrain with icons on it.
-- Allplies scrolling and clipping for display in cairo
--------------------... |
local settings = require('gfold.settings')
local utils = require('gfold.utils')
local update_settings = function(user_opts)
utils.recursive_tbl_update(settings, user_opts)
end
local setup = function(user_opts)
update_settings(user_opts)
if settings.status.enable then
require('gfold.status').update_summary()... |
local core = require "sys.core"
local np = require "sys.netpacket"
local pairs = pairs
local assert = assert
local type = type
local msg = {}
local msgserver = {}
local msgclient = {}
local queue = np.create()
local function gc(obj)
if not obj.fd then
return
end
if obj.fd < 0 then
return
end
core.close(obj.fd... |
--[[
-- 作者:左笑林
-- 日期:2017-03-31
-- 文件名:sendMsg.lua
-- 功能:发送聊天室消息
-- 版权说明:南京正溯网络科技有限公司.版权所有©copy right.
-- 往聊天室内发消息
--]]
-- 参数说明
-- 参数 类型 必须 说明
-- roomid long 是 聊天室id
-- msgId String 是 客户端消息id,使用uuid等随机串,msgId相同的消息会被客户端去重
-- fromAccid String 是 消息发出者的账号accid
-- msgType int 是 消息类型:
-- 0: 表示文本消息,... |
--! rocketlerp
--@ commonstargets commonsweapons commons eventdriver firstrun weapontypes lookuptable secant
-- Linear interpolation-based rocket turret predictor
Main = EventDriver.new()
TrainingSets = {}
TrainingSamplesCaptured = 0
DistanceTable = nil
AddFirstRun(function (_)
Main:Schedule(0, RocketC... |
-- automatically generated file. Do not edit (see /usr/share/doc/menu/html)
module("debian.menu")
Debian_menu = {}
Debian_menu["Debian_Applications_Accessibility"] = {
{"Xmag","xmag"},
}
Debian_menu["Debian_Applications_Data_Management"] = {
{"pgAdmin III","/usr/bin/pgadmin3","/usr/share/pixmaps/pgadmin3.xpm"},
}
... |
--ffi/bitmask: bitmask encoding and decoding.
--Written by Cosmin Apreutesei. Public Domain.
local yui_path = (...):match('(.-)[^%.]+$')
setfenv(1, require(yui_path .. 'namespace'))
require(yui_path .. 'util')
local bitmask_class = {}
local bitmask_meta = {__index = bitmask_class}
function bitmask(fields)
return s... |
--# Main
-- Xile Asteroids
--Xile Main Template
setup = Xile.setup(function(engine)
local x = Xile
local Assets = x.Assets
local Image = x.Image
local assets = Assets("Space Art")
assets:asset(Image,CENTER)
:add("ship","Red Ship")
:add("asteroids","Asteroid Large","Asteroid ... |
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_HOLYDAMAGE)
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_HOLYAREA)
setAttackFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 4, 6)
local area = createCombatArea(AREA_CIRCLE3X3)
setCombatArea(combat, area)
function onCastSpe... |
--- libdas: DENG asset management library
--- licence: Apache, see LICENCE file
--- file: SubstringSearchTest.lua - SubstringSearchTest test program build configuration
--- author: Karl-Mihkel Ott
local SubstringSearchTest = {}
function SubstringSearchTest.build()
project "SubstringSearchTest"
kind "Conso... |
local DefaultAuctionTime = 24 --1 Day
local CleanUpTime = 168 --1 Week
PANEL = {}
function PANEL:Init()
self.AuctionsList = CreateGenericList(self, 3, false, true)
self:LoadAuctions()
end
function PANEL:PerformLayout()
self.AuctionsList:SetSize(self:GetWide(), self:GetTall())
end
function PANEL:LoadAuctions()
se... |
local Iterator = require(script.Parent.Parent.Iterator)
local Skip = setmetatable({}, Iterator)
Skip.__index = Skip
Skip.__call = Iterator.__call
function Skip.new(iterator, amount)
return setmetatable({
iterator = iterator,
amount = amount,
}, Skip)
end
function Skip:after()
return self.iterato... |
function onCreate()
--PRECACHE
--addCharacterToList('twilight-p', 'dad');
addCharacterToList('twilight-pL', 'dad');
addCharacterToList('twilight-pS', 'dad');
--addCharacterToList('twilight-p', 'bf-p');
addCharacterToList('bf-pD', 'boyfriend');
addCharacte... |
local Chara = require("api.Chara")
local Item = require("api.Item")
local Log = require("api.Log")
local Pos = require("api.Pos")
local VisualAIEditor = require("mod.visual_ai.api.gui.VisualAIEditor")
local MapObject = require("api.MapObject")
local VisualAIPlan = require("mod.visual_ai.api.plan.VisualAIPlan")
local IC... |
--[[ ******************************************************************
Burst by KOP
******************************************************************* ]]
return function(pg, of, sw, sh)
local pc, cx, cy = math.abs(of/pg.width), pg.width/2, pg.height/2
-- target distance
local tg = pg.width
local fnum... |
object_intangible_ship_assaultship_pcd = object_intangible_ship_shared_assaultship_pcd:new {
}
ObjectTemplates:addTemplate(object_intangible_ship_assaultship_pcd, "object/intangible/ship/assaultship_pcd.iff")
|
-- auto install packer
local execute = vim.api.nvim_command
local fn = vim.fn
local install_path = fn.stdpath("data") .. "/site/pack/packer/start/packer.nvim"
if fn.empty(fn.glob(install_path)) > 0 then
execute("!git clone https://github.com/wbthomason/packer.nvim " ..
install_path)
end
-- auto compile... |
--[[
Inventory turtle methods
]]--
local sys, metadata = require("sys"), require("metadata")
local inventory = {}
local fuelAmount, fuelSafetyThreshold, fuel, invStart, invEnd, ladder = nil, 256, 16, 1, 14, 15
if turtle.getItemCount(fuel) == 0 then
sys.log("No fuel found running on " .. tostring(turtle.getFuelLev... |
local helpers = require "spec.helpers"
local cjson = require "cjson"
local meta = require "kong.meta"
local exists = helpers.path.exists
local join = helpers.path.join
local function get_kong_workers()
local workers
helpers.wait_until(function()
local pok, admin_client = pcall(helpers.admin_client)
if n... |
--!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... |
module(..., package.seeall)
--[[
Sends emails with optional attachments.
]]
function send_email_socket(action)
-- Load the smtp support and its friends.
local smtp = require("socket.smtp")
local mime = require("mime")
local ltn12 = require("ltn12")
require "jester.support.string"
local to = action.to
... |
local Prompt = require 'prompt'
local Timer = require 'vendor/timer'
local sound = require 'vendor/TEsound'
local Gamestate = require 'vendor/gamestate'
local Quest = require 'quest'
local quests = require 'npcs/quests/telescopejuanquest'
return {
width = 48,
height = 48,
greeting = 'My name is {{red_light}}Ju... |
--[[
This file was extracted by 'EsoLuaGenerator' at '2021-09-04 16:42:26' using the latest game version.
NOTE: This file should only be used as IDE support; it should NOT be distributed with addons!
****************************************************************************
CONTENTS OF THIS FILE IS COPYRI... |
TEST [[
---@class <!A!>
---@class B : <?A?>
]]
TEST [[
---@class <!A!>
---@type B|<?A?>
]]
TEST [[
---@class A
local mt = {}
function mt:<!cast!>()
end
---@type A
local obj
obj:<?cast?>()
]]
TEST [[
---@class A
local <!mt!> = {}
function mt:cast()
end
---@type A
local <!obj!>
<?obj?>:cast()
]]
TEST [[
---@type A
... |
ITEM.name = "Freedom Cassette Tape"
ITEM.description = "Green Cassette Tape"
ITEM.longdesc = "This green cassette tape features songs that you can relax to."
ITEM.price = 4424
ITEM.model = "models/kek1ch/cassette_red1.mdl"
ITEM.cassette_options = {}
ITEM.cassette_options['radio/freedm_r_1.ogg'] = {dur = 290}
ITEM.cas... |
local MIXTURE = {}
MIXTURE.ID = 41;
MIXTURE.Results = "item_stim_pack";
MIXTURE.Ingredients = {'item_paper_towels', 'item_chunk_plastic'};
MIXTURE.Requires = {
{GENE_INTELLIGENCE, 1},
{GENE_STRENGTH, 2},
{SKILL_CRAFTINESS, 4},
};
MIXTURE.Free = true;
MIXTURE.RequiresHeatSource = true... |
local mod = { sequenceInProgress = false }
-- Release both Tab and Alt keys to end the Alt+Tab sequence (or another similar sequence)
function mod:stopSequence()
if self.sequenceInProgress
then
if self.isAdvanceKeyDown
then
ReleaseKey(self.advanceKey)
end
if self.isReverseKeyDown
then
ReleaseKey... |
CodexDB["objects"]["deDE"]={[4]="Bonfire Damage",[31]="Alte Löwenstatue",[32]="Versunkene Truhe",[33]="Verschlossene Truhe",[34]="Alter Henkelkrug",[35]="Schließkiste des Kapitäns",[36]="Zerbrochenes Fass",[37]="Eliza\'s Tombstone",[38]="Captain Sanders Chest",[41]="Spind des Botschafters",[47]="GESUCHT: Leutnant Fango... |
-- ITS - In The Shadows
-- Copyright (C) 2015, 2016, 2017 James Niemira
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later ve... |
require "/file_io"
require "/blog_data"
require "/article_parser"
local http = require('http');
local url = require('url');
local path = require('path')
local fs = require('fs')
local items = {};
-- see Node.js_in_action.pdf : page 89 (110 of 417)
-- Simple BLog based on VR!
-- VR 1.0
local mimes = {
png = "image/p... |
-- Copyright (C) by Yichun Zhang (agentzh)
local ffi = require "ffi"
local ffi_new = ffi.new
local ffi_str = ffi.string
local C = ffi.C
--local setmetatable = setmetatable
--local error = error
local tonumber = tonumber
local _M = { _VERSION = '0.14' }
ffi.cdef[[
typedef unsigned char u_char;
u_char * ngx_hex_du... |
local _M = function(url,args,method)
local loc = '/proxy/' .. url
local res = ngx.location.capture(loc,
{
method = method or ngx.HTTP_GET,
args = args
}
)
if 200 ~= res.status then
return false,"http errror code " .. res.status
end
return true,res.body
end
return _M |
local ui_messagebox = class("ui_messagebox", ui_session)
function ui_messagebox.show(args)
local ui_manager = fw_facade:instance():get_mgr(mgr_name.UI_MGR)
if ui_manager ~= nil then
ui_manager:instance():show_popup(ui_messagebox(ui_session_data(ui_session_type.POPUP, ui_session_id.UI_MESSAGEBOX)), true... |
function onCreate()
-- background shit
makeLuaSprite('lightsoutmirafloor', 'lightsoutmirafloor', -1500, 500);
scaleObject('lightsoutmirafloor', 1.1, 0.9);
makeLuaSprite('lightsoutmira', 'lightsoutmira', -500, -30);
scaleObject('lightsoutmira', 0.65, 0.65);
makeLuaSprite('lightsouttables', 'lightsouttabl... |
function main()
do
local a= Test();
print(a);
print(a.X);
a:Foo();
cl=a:Clone2();
print(cl.X);
cl2=a:Clone3();
print(cl2.X);
end
end
main()
d={}
d[3]=2
a={}
a.b={}
a.b['str']={}
a.b['str'][2]={}
a.b['str'][2].c=555
function foo()
print("foo");
end
function add(a, b)
return a + b
end
function sum_and_dif... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.