content stringlengths 5 1.05M |
|---|
--[[lit-meta
name = "creationix/websocket-client"
version = "3.0.1"
description = "A coroutine based client for Websockets"
tags = {"coro", "websocket"}
license = "MIT"
author = { name = "Tim Caswell" }
homepage = "https://github.com/creationix/redis-luvit"
dependencies = {
"luvit/http-codec@2.0.0",... |
--[[
Name: "cl_init.lua".
Product: "nexus".
--]]
include("sh_init.lua")
-- Called when the target ID HUD should be painted.
function ENT:HUDPaintTargetID(x, y, alpha)
local colorTargetID = nexus.schema.GetColor("target_id");
local colorWhite = nexus.schema.GetColor("white");
local amount = self:GetSharedVar("sh_Am... |
-- Copyright (c) 2016 Thermo Fisher Scientific
--
-- 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, modify,
-- merge, ... |
project "Calc"
if not _OPTIONS["shared_calc"] then
kind "StaticLib"
defines {"CALC_STATIC_LIBRARY"}
if os.is("linux") then
buildoptions "-std=c++11 -fPIC"
os.execute("rm -rf obj")
elseif os.is("macosx") then
buildoptions "-std=c++11 -stdlib=libc++... |
--
-- from src/whrnd.c
--
-- void init_rnd(int, int, int) to whrnd; :init
-- double rnd(void) to whrnd; :rnd
--
local M = require 'whrnd'
local whrnd = M.whrnd
function p(m, n, wh)
for _=1,n do
for _=1,m do
io.write(("%10.7f"):format(wh:rnd()))
end
io.write("\n")
end
end
do
print("-------- whrnd: 123... |
--=============================================================================
-- 2019.4 XAVIER
--=============================================================================
local TestView = class("TestView",LuaBehaviour)
--===== 初始化流程:注意Awake方法不要重写 =====
function TestView:BindUI()
self.Button1 = self:Find(... |
---@meta
---@class ccui.ImageView :ccui.Widget@all parent class: Widget,BlendProtocol
local ImageView={ }
ccui.ImageView=ImageView
---* Returns the blending function that is currently being used.<br>
---* return A BlendFunc structure with source and destination factor which specified pixel arithmetic.<br>
---* js ... |
local M = {}
---Reset any startup cache files used by Packer and Impatient
---Tip: Useful for clearing any outdated settings
function M.reset_cache()
_G.__luacache.clear_cache()
require("plugin-loader"):cache_reset()
end
return M
|
local blankvec = Vector(0,0,0)
local AddVel = Vector()
local dif = Vector(0,0,0)
local ang
function EFFECT:Init( data )
self.WeaponEnt = data:GetEntity()
if !IsValid(self.WeaponEnt) then return end
self.Attachment = data:GetAttachment()
self.Position = self:GetTracerShootPos( data:GetOrigin(), self.WeaponEnt, ... |
#!/usr/bin/env lua
-- MoonFLTK example: twowin.lua
--
-- Derived from the FLTK test/twowin.cxx example (http://www.fltk.org)
--
fl = require("moonfltk")
function cb1() b2:take_focus() end
function cb2() b1:take_focus() end
win1 = fl.double_window(200, 200)
bb1 = fl.button(10, 10, 100, 100, "b1")
bb1:callback(cb1)
b1... |
local M = {}
local function override_delete_and_change_bindings()
local bindings = {
{ "c", '"_c', "nx" },
{ "cc", '"_S', "n" },
{ "C", '"_C', "nx" },
{ "s", '"_s', "nx" },
{ "S", '"_S', "nx" },
{ "d", '"_d', "nx" },
{ "dd", '"_dd', "n" },
{ "D", '"_D', "nx" },
{ "x", '"_x', "n" }... |
-- signatures, used by
-- both pure FFI and FFI-inside-C
local signatures = {
['sodium_init'] = [[
int %s(void)
]],
['sodium_memzero'] = [[
void %s(void * const pnt, const size_t len)
]],
['malloc'] = [[
void * (%s)(const size_t len)
]],
['free'] = [[
void (%s)(void *ptr)
]],
}
local fu... |
local Logger = require("__DedLib__/modules/logger").create{modName = "DedLib"}
local Position = require("__DedLib__/modules/position")
local Area = {} -- TODO -- docs
function Area.area_of_entity(entity)
Logger:trace("Finding area of an entity")
if entity and entity.valid and entity.bounding_box then
... |
--[[
This file was extracted by 'EsoLuaGenerator' at '2021-09-04 16:42:29' 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... |
local function inputs(event)
local pn= event.PlayerNumber
local button = event.button
-- If the PlayerNumber isn't set, the button isn't mapped. Ignore it.
--Also we only want it to activate when they're NOT selecting the difficulty.
--if not pn or not SCREENMAN:get_input_redirected(pn) then return end
-- If ... |
local url_value
url_value = function(value)
return value and (value:match("^https?://") or value:match("^//")) and true
end
local mailto_value
mailto_value = function(value)
return value and value:match("^mailto:") and true
end
local tags = {
{
title = true,
dir = true,
lang = true
},
a = {
hr... |
--[[
module: ServerLocatorTest
author: DylanYang
time: 2021-02-24 13:05:29
idea:
advance:
]]
local ServiceLocator = require("patterns.j2ee.serverLocator.ServiceLocator")
local super = require("patterns.BaseTest")
local _M = Class("ServerLocatorTest", super)
local public = _M.public
function _M... |
-- Copyright 2006-2015 Mitchell mitchell.att.foicica.com. See LICENSE.
-- ASP LPeg lexer.
local l = require('lexer')
local token, word_match = l.token, l.word_match
local P, R, S = lpeg.P, lpeg.R, lpeg.S
local M = {_NAME = 'asp'}
-- Embedded in HTML.
local html = l.load('html')
-- Embedded VB.
local vb = l.load('vb... |
local InstancedMap = require("api.InstancedMap")
local Chara = require("api.Chara")
local Assert = require("api.test.Assert")
local Item = require("api.Item")
local IMapObject = require("api.IMapObject")
function test_IMapObject_set_pos()
local map = InstancedMap:new(10, 10)
map:clear("elona.cobble")
Assert.... |
local get_local_player, get_screen_size, get_local_player_index, get_index_by_userid = entitylist.get_local_player, engine.get_screen_size, engine.get_local_player, engine.get_player_for_user_id
local min, sqrt, floor, sin, cos, rad, ceil = math.min, math.sqrt, math.floor, math.sin, math.cos, math.rad, math.ceil
local ... |
--[[ MyGame.Example.AnyAmbiguousAliases
Automatically generated by the FlatBuffers compiler, do not modify.
Or modify. I'm a message, not a cop.
flatc version: 2.0.5
Declared by : //monster_test.fbs
Rooting type : MyGame.Example.Monster (//monster_test.fbs)
--]]
local AnyAmbiguousAliases = {
NONE = 0,... |
function for_loop(a, b, f)
local i = a
while i <= b do
f()
i = i + 1
end
end
for_loop(1, 5, function ()
print('Execute')
end)
|
local Root = script.Parent.Parent.Parent
local CorePackages = game:GetService("CorePackages")
local PurchasePromptDeps = require(CorePackages.PurchasePromptDeps)
local Roact = PurchasePromptDeps.Roact
local PromptState = require(Root.Enums.PromptState)
local PurchaseError = require(Root.Enums.PurchaseError)
local Lo... |
PrintBuildConfiguration()
-----------------------------------------------------------------
-- define Home-Directories
----------------------------------------------------------------
ug4_home = ug_get_root_path().."/"
--common_scripts = app_home.."scripts/"
--geom_home = app_home.."geometry/"
--------... |
-- Use of this source code is governed by the Apache 2.0 license; see COPYING.
module(..., package.seeall)
local engine = require("core.app")
local config = require("core.config")
local timer = require("core.timer")
local pci = require("lib.hardware.pci")
local main = require("core.main")
local S... |
-- NOTICE:
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTOR... |
local vim = vim
local autocmd = {}
function autocmd.nvim_create_augroups(definitions)
for group_name, definition in pairs(definitions) do
vim.api.nvim_command("augroup " .. group_name)
vim.api.nvim_command("autocmd!")
for _, def in ipairs(definition) do
local command = table.concat(vim.tbl_flatten({ "autocmd... |
mtechs = {}
local m = mtechs
--[[
order of registration is
1. actions
2. components
3. systems
4. entities (after server startup)
]]--
m.actions = {
a_mt_entity_add = {
name = 'a_mt_entity_add'
},
a_mt_item_add = {
name = 'a_mt_item_add'
},
a_mt_node_level_ad = {
name =... |
-- lua实现ip和整数 互相转化
-- ip to int
function ipToInt( str )
local num = 0
if str and type(str)=="string" then
local o1,o2,o3,o4 = str:match("(%d+)%.(%d+)%.(%d+)%.(%d+)" )
num = 2^24*o1 + 2^16*o2 + 2^8*o3 + o4
end
return num
end
print(ipToInt("127.0.0.1"))
-... |
--[[
Copyright (c) 2019, Vsevolod Stakhov <vsevolod@highsecure.ru>
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 ... |
math.randomseed(os.time())
newCharacter = Character:NewCharacter();
newCharacter:SetLocation(
2500 + math.random() * -5000,
2500 + math.random() * -5000,
0
)
newCharacter:SetRotation(
0,
math.random() * -5000,
0
) |
local nvim_lsp = require('lspconfig')
-- Use an on_attach function to only map the following keys
-- after the language server attaches to the current buffer
local on_attach = function(client, bufnr)
local function buf_set_keymap(...) vim.api.nvim_buf_set_keymap(bufnr, ...) end
local function buf_set_option(...) v... |
require "/FTLE/breakpoint" --breakpoint & putMessage in Run & Debug mode
print "HTTP/1.1 200 OK"
print ""
print "Hello World"
putMessage("START")
for i=1 , 3 do
fa.pio(0xE,0xE)
sleep(500)
fa.pio(0xE,0x0)
sleep(500)
breakpoint() --Catch Break(F8) signal
putMessage(i) --Put message to GetMsg... |
moves = require("move")
if arg[2] == nil
then
arg[2] = 1
end
arg[2] = tonumber(arg[2])
for n = 1,arg[2],1
do
if arg[1] == "up"
then
tryUp()
elseif arg[1] == "down"
then
tryDown()
elseif arg[1] == "forward"
then
tryForward()
elseif arg[1] == "backward"
then
tryBackward()
else
print("Invalid movement... |
-- tl_ops_balance
-- en : balance core api
-- zn : 负载均衡对外接口
-- @author iamtsm
-- @email 1905333456@qq.com
local tl_ops_balance_core = require("balance.tl_ops_balance_core");
local _M = {}
function _M:init( )
-- 启动路由
local balance = tl_ops_balance_core:new();
balance:tl_ops_balance_core_balance()
end
... |
function EFFECT:Init( data )
local o = data:GetOrigin();
if( GAMEMODE.Emitter2D ) then
for i = 0, 5, 0.02 do
timer.Simple( i, function()
local d = math.Rand( 0, 360 );
local x = math.cos( d );
local y = math.sin( d );
local v = Vector( math.random( 0, 500 ) * x, math.random( 0, 50... |
-----------------------------------
-- Area: Bastok Mines
-- NPC: Black Mud
-- Starts & Finishes Quest: Drachenfall
-----------------------------------
require("scripts/globals/quests")
require("scripts/globals/settings")
require("scripts/globals/titles")
local ID = require("scripts/zones/Bastok_Mines/IDs")
----------... |
if not _G.BrazilianLoc then
_G.BrazilianLoc = _G.BrazilianLoc or {}
BrazilianLocGlobal.replacement = BrazilianLocGlobal:GetPath() or ModPath
end
function BrazilianLocGlobal:extras()
end
Hooks:Add("LocalizationManagerPostInit", "BrazilianLoc_loc", function(...)
LocalizationManager:add_localized_strings({
["Brazil... |
-- service script, try save selected profile to "build" global var
build=profiles[profile]
assert(type(build) == "table", "build profile is incorrect")
assert(type(build.src) == "table", "src value is missing or invalid")
assert(type(build.src.link) == "string", "src_link value is missing or invalid")
assert(type(bui... |
--=========== Copyright © 2018, Planimeter, All rights reserved. ===========--
--
-- Purpose: Extends the graphics module
--
--==========================================================================--
require( "love.graphics" )
local newImage = love.graphics.newImage
local function getHighResolutionVariant( filen... |
-- Dialogue for NPC "npc_koray3"
loadDialogue = function(DL)
if (not DL:isConditionFulfilled("npc_koray3", "talked")) then
DL:setRoot(1)
else
DL:setRoot(2)
end
if (not DL:isConditionFulfilled("npc_koray3", "talked")) then
DL:createNPCNode(1, 3, "DL_Koray_Fight") -- Well, what can I say.
DL:addCond... |
local modpath, prettypath, fullpath, configdir, docstringspath, hasinitfile, autoload_extensions = ...
package.path=configdir.."/?.lua"..";"..configdir.."/?/init.lua"..";"..configdir.."/Spoons/?.spoon/init.lua"..";"..package.path..";"..modpath.."/?.lua"..";"..modpath.."/?/init.lua"
package.cpath=configdir.."/?.so"..";... |
local _M = {
VERSION = '0.0.1'
}
local ngx_now = ngx.now
local sub = string.sub
local find = string.find
local insert = table.insert
local open = io.open
local execute = os.execute
local tmpname = os.tmpname
local unpack = unpack
function _M.timer(name, fun, ...)
local start = ngx_now()
ngx.log(ngx.INFO, 'ben... |
return function(A)
local dim = A:dim()
local m, n = dim:unpack()
local sum = require 'symmath.Constant'(0)
for i=1,math.min(m,n) do
sum = sum + A[i][i]
end
return sum()
end
|
HpBar = {}
HpBar.image = StillImage.new("heart.png", 0, 0, 0.5, 0.5)
HpBar.y = 20
HpBar.x = 20
HpBar.dist = 25
function HpBar.draw(player_hp)
if player_hp > 0 then
for i=1,player_hp do
local x = HpBar.x + (i-1)*HpBar.dist
HpBar.image.x = x
HpBar.image.y = HpBar.y
... |
local Entity = require "entity"
local Hero = class.class(
Entity, {
methods = {
Collide = function(self, e)
self.game:Log("You hit a monster for 10 damage.")
e:SetHealth(e:Health() - 10)
end,
SetHealth = function(self, h)
self.game:Log(string.format('Your health is now ... |
object_mobile_dressed_meatlump_merkie_howzat = object_mobile_shared_dressed_meatlump_merkie_howzat:new {
}
ObjectTemplates:addTemplate(object_mobile_dressed_meatlump_merkie_howzat, "object/mobile/dressed_meatlump_merkie_howzat.iff")
|
pl = nil;
-- create a server
sv=net.createServer(net.TCP, 10)
-- server listen on 80
sv:listen(80,function(conn)
conn:on("receive", function(conn, pl)
payload = pl;
print(pl.."\n")
------------------------------------------------------------------------
if string.sub(pl, 0, 11) == "**co... |
resource_manifest_version '44febabe-d386-4d18-afbe-5e627f4af937'
description 'tbr_onlinegroups - See how many users online by group set.'
repository 'https://github.com/tabarra/fivem-scripts'
version '0.1'
dependency {
'vrp',
'pNotify'
}
server_scripts {
'@vrp/lib/utils.lua',
'config.lua',
'server.lua'
}
client_... |
-----------------------------------------------------------------------------------
-- Apply.lua
-- Enrique García ( enrique.garcia.cota [AT] gmail [DOT] com ) - 4 Mar 2010
-- Makes possible to treat all instances of a class
-----------------------------------------------------------------------------------
assert(Obj... |
--[[
desc: Roar, a state of tauAssaulter.
author: SkyFvcker
since: 2018-9-7
alter: 2019-5-16
]]--
local _MAP = require("map.init")
local _SOUND = require("lib.sound")
local _FACTORY = require("actor.factory")
local _ASPECT = require("actor.service.aspect")
local _STATE = require("actor.service.state")
local _BUFF ... |
menuvis = oapi.get_mainmenuvisibilitymode()
if menuvis == 0 then
oapi.set_mainmenuvisibilitymode(2)
end
h = oapi.create_annotation()
h:set_pos(0.04,0.8,0.4,1)
h:set_size(1.0)
h:set_colour({r=0.9,g=1,b=0.9})
t1 = oapi.get_simtime()
t0 = t1
dt = 0
function tstep()
proc.skip()
t1 = oapi.get_simtime()
dt = t1-t0
t0... |
--------------------------------------------------------------------------
-- Moonshine - a Lua virtual machine.
--
-- Email: moonshine@gamesys.co.uk
-- http://moonshinejs.org
--
-- Copyright (c) 2013-2015 Gamesys Limited. All rights reserved.
--
-- Permission is hereby granted, free of charge, to any person obtaining
... |
local qr = require "qr"
local text = "https://cfadmin.cn"
qr.toPNG("1.png", text)
qr.toBMP("1.bmp", text)
qr.toSVG("1.svg", text)
qr.toJSON("1.JSON", text)
|
--[[----
TDlib made by Threebow.
Coverted to follow basic lua by Trix.
----]]
--// Locals \\--
local blur = Material("pp/blurscreen")
local gradLeft = Material("vgui/gradient-l")
local gradUp = Material("vgui/gradient-u")
local gradRight = Material("vgui/gradient-r")
local gradDown = Material("vgui/gradien... |
pfDB["units"]["enUS-turtle"] = {
[420] = "_", -- remove easter-egg shagu
[3189] = "Kor'ghan",
[3225] = "Corrupted Mottled Boar",
[3226] = "Corrupted Scorpid",
[3227] = "Corrupted Bloodtalon Scythemaw",
[3228] = "Corrupted Surf Crawler",
[3229] = "\"Squealer\" Thornmantle",
[3231] = "Corrupted Dreadmaw C... |
-- Returns whether or a not a string matches.
function nut.util.stringMatches(a, b)
if (a and b) then
local a2, b2 = a:lower(), b:lower()
-- Check if the actual letters match.
if (a == b) then return true end
if (a2 == b2) then return true end
-- Be less strict and search.
if (a:find(b)) then return true... |
return {
version = "1.4",
luaversion = "5.1",
tiledversion = "1.4.3",
orientation = "orthogonal",
renderorder = "right-down",
width = 70,
height = 12,
tilewidth = 32,
tileheight = 32,
nextlayerid = 9,
nextobjectid = 33,
properties = {},
tilesets = {
{
name = "tiles",
... |
require "keybow"
-- Mousekeys --
button_up = false
button_down = false
button_left = false
button_right = false
button_upleft = false
button_upright = false
button_downleft = false
button_downright = false
button_lmb = false
button_mmb = false
button_rmb = false
mouse_speed = 1
-- Key mappings --
function setup(... |
require ("far2.makelang") (
---- 1-st argument
"lf4ed_message.lua",
---- 2-nd argument
{
{ filename = "lf4ed_eng.lng",
line1 = ".Language=English,English",
},
{ filename = "lf4ed_rus.lng",
line1 = ".Language=Russian,Russian (Русский)",
},
-- { filename = "lf4ed_cze.lng",
-- line1 = ".Language=Cz... |
---------------------------------------------------------------------------
-- This class has been moved to `wibox.container.`
--
-- @author Lukáš Hrázký
-- @copyright 2012 Lukáš Hrázký
-- @classmod wibox.layout.constraint
---------------------------------------------------------------------------
local gdebug = requi... |
-- Copyright (c) 2017-present, Facebook, Inc.
-- All rights reserved.
--
-- This source code is licensed under the license found in the
-- LICENSE file in the root directory of this source tree.
--
--[[
--
-- List available scripts.
--
--]]
local dir = require 'pl.dir'
local path = require 'pl.path'
local scriptdir =... |
local fs = require("util.fs")
local love = require("thirdparty.automagic")()
local function check_path(path)
if type(path) == "string" then
-- assert(fs.is_file(path), "File does not exist: " .. path)
end
end
love.graphics.getWidth = function() return 800 end
love.graphics.getHeight = function() return 60... |
for e,l in pairs({(function(l,...)_e7a9b640559fa72e="This file was obfuscated using PSU Obfuscator 4.5.A | https://www.psu.dev/ & discord.gg/psu";local Y=_e7a9b640559fa72e local r=l[((686805699-#("Powered by Raid Shadow Legends")))];local x=l[(748046371)];local B=l[(698013913)];local X=l[((39679011-#("Sonic says: sonic... |
-- This script is to test load_ac.lua
--
-- Some notes:
-- 1. The purpose of this script is not to check if the libac.so work
-- properly, it is to check if there are something stupid in load_ac.lua
--
-- 2. There are bunch of collectgarbage() calls, the purpose is to make
-- sure the shared lib is not un... |
entities.require("entity")
class "machine" ("entity")
function machine:machine()
entity.entity(self)
end
function machine:use(activator, value)
-- return true so derived classes can check if this handles the call
if (construction.check(self, activator)) then return true end
end
function machine:spawn()
entity.s... |
--[[/*
* (C) 2012-2013 Marmalade.
*
* 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, modify, merge, publish,... |
return {
level = 69,
need_exp = 170000,
clothes_attrs = {
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
},
} |
--------------------------------------------------------------------------------
-- This class is an event listener.
-- Framework will be used internally.
--------------------------------------------------------------------------------
local class = require("hp/lang/class")
local Event = require("hp/event/Event")
loc... |
require "common"
local skynet = require "skynet"
local mongo = require "mongo"
local mongo_ip = skynet.getenv("mongo_ip")
local mongo_user = skynet.getenv("mongo_user")
local mongo_passwd = skynet.getenv("mongo_passwd")
local mongo_db = skynet.getenv("mongo_db")
local db = nil
local dbCnt = 0
MongoHelper... |
object_tangible_dance_prop_prop_glowstick_l = object_tangible_dance_prop_shared_prop_glowstick_l:new {
}
ObjectTemplates:addTemplate(object_tangible_dance_prop_prop_glowstick_l, "object/tangible/dance_prop/prop_glowstick_l.iff")
|
object_mobile_dressed_tatooine_larit = object_mobile_shared_dressed_tatooine_larit:new {
}
ObjectTemplates:addTemplate(object_mobile_dressed_tatooine_larit, "object/mobile/dressed_tatooine_larit.iff")
|
-- Write 10 events while offline. An offline events file with 10 events should be written during this test, and then deleted at the end of this test.
test = require 'u-test'
common = require 'common'
function TestOfflineEventsCpp_Handler()
print("TestOfflineEventsCpp_Handler")
SetupEventUploadMock()
Event... |
local cmpu_source = require('cmp_nvim_ultisnips.source')
local cmpu_snippets = require('cmp_nvim_ultisnips.snippets')
local M = {}
local default_config = {
documentation = cmpu_snippets.documentation
}
local user_config = default_config
function M.setup(config)
user_config = vim.tbl_deep_extend('force', default_... |
local ViewBase = require("games/common2/module/viewBase");
local MatchWaitTableView = class(ViewBase,false);
MatchWaitTableView.s_controls = {
waitingView = 1;
waitingLoading = 2;
loading_1 = 3;
loading_2 = 4;
loading_3 = 5;
}
MatchWaitTableView.ctor = function ( self,seat,viewConfig)
su... |
-- Extension functions for Lua string.
laia = laia or {}
-- Return a list of the words in the input string, separated by whitespace
-- characters (space, tab, newline, etc). The optional argument pattern
-- can be used to separate the words using other delimiters.
--
-- Examples:
-- laia.strsplit('hello my friend')
--... |
object_draft_schematic_instrument_instrument_xantha = object_draft_schematic_instrument_shared_instrument_xantha:new {
}
ObjectTemplates:addTemplate(object_draft_schematic_instrument_instrument_xantha, "object/draft_schematic/instrument/instrument_xantha.iff")
|
local _, private = ...
--[[ Lua Globals ]]
-- luacheck: globals
--[[ Core ]]
local Aurora = private.Aurora
local Base, Hook, Skin = Aurora.Base, Aurora.Hook, Aurora.Skin
local Color = Aurora.Color
local keyColor = Color.Create(0.7254, 0.5490, 0.2235, 0.75)
do --[[ FrameXML\ContainerFrame.lua ]]
local BAG_FILTER_... |
MobileX = Core.class(Sprite)
function MobileX:init(xhero)
-- local variables
local alpha = 0.25
-- buttons
local btnB = ButtonOleg.new("B", 0xffffff, 16, 14, alpha) -- UP (B)
btnB:setPosition(btnB:getWidth() + 4, myappheight - 24)
self:addChild(btnB)
local btnA = ButtonOleg.new("A", 0xffffff, 16, 14, alpha) --... |
local data = {}
-- Auto-require modules in ./lua/lspservers/servers/
local script_dir = debug.getinfo(1, 'S').source:match '@?(.*)/'
for filename in io.popen('ls -1 ' .. script_dir):lines() do
if filename ~= 'init.lua' then
local server_name = string.match(filename, '(.+).lua')
data[server_name] = require('... |
object_tangible_collection_beetle_piranha = object_tangible_collection_shared_beetle_piranha:new {
gameObjectType = 8211,}
ObjectTemplates:addTemplate(object_tangible_collection_beetle_piranha, "object/tangible/collection/beetle_piranha.iff") |
local ffi = require'ffi'
local bit = require'bit'
local core = require'ljusb_ffi_core'
local sched = require'lumen.sched'
local bor, band, lshift, rshift = bit.bor, bit.band, bit.lshift, bit.rshift
local new, typeof, metatype = ffi.new, ffi.typeof, ffi.metatype
local cast, C = ffi.cast, ffi.C
--need those for buffer ... |
scale_width = self.getScale().x
scale_height = self.getScale().y
scale_length = self.getScale().z
function onLoad()
self.createButton({
function_owner = self,
click_function = 'end_turn',
label = 'End Turn',
position = {0, 0.5, 0},
scale = {1/sca... |
-- Copyright (c) 2016 Thermo Fisher Scientific
--
-- 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, modify,
-- merge, ... |
-- Load wiremod tools in /lua/wire/stools/
-- Note: If this tool is ever removed, be sure to put this in another stool!
local OLD_TOOL = TOOL
TOOL = nil
include( "wire/tool_loader.lua" )
TOOL = OLD_TOOL
TOOL.Mode = "wire"
TOOL.Category = "Tools"
TOOL.Name = "Wire (Legacy)"
TOOL.Tab = "Wire"
if CLIENT then
la... |
local template = [[# Zenbones Alacritty Colors
colors:
# Default colors
primary:
background: '${bg}'
foreground: '${fg}'
# Normal colors
normal:
black: '${color0}'
red: '${color1}'
green: '${color2}'
yellow: '${color3}'
blue: '${color4}'
magenta: '${color5}'
cyan:... |
--
-- Created by IntelliJ IDEA.
-- User: shahzheeb
-- Date: 2019-04-13
-- Time: 16:46
-- To change this template use File | Settings | File Templates.
--
local _M = {
_VERSION = "1.0"
}
local logger = require("logger"):new()
local utils = require("utils")
local account_shared_cache = ngx.shared.account_info_cache... |
--[[
扫描分析 Lua 文件, 按 UTF-8 字读入, 逐字分析
分为几种状态
* 无状态
* 单行注释
* 多行注释
* 单行字符串
* 多行字符串
* 标识符
* 空格
]]
local Scanner = {}
local Define = require("lua.Define")
local Util = require("Util")
local STATE_NONE = 0 -- 无状态
local STATE_ANNO_SINGLE = 1 -- 单行注释
l... |
local helper = require'helper'
local ok, uv = pcall(require,'luv')
if not ok then uv = nil end
TestSSL = {}
local LUA = arg[-1]
if uv then
local function set_timeout(timeout, callback)
local timer = uv.new_timer()
local function ontimeout()
uv.timer_stop(timer)
uv.close(timer)
... |
local Class = require("facto.class")
--- Manage the game objects and resources.
-- @classmod GameManager
local GameManager = Class.create()
local services
local config
function GameManager:__constructor(cfg)
services = {}
config = cfg
end
--- Setup game manager.
function GameManager:setup()
--- modules nee... |
local env = {
assert = assert,
type = type,
tonumber = tonumber,
tostring = tostring,
require = require,
error = error,
getmetatable = getmetatable,
setmetatable = setmetatable,
string = string,
table = table,
love = love,
jit = jit,
}
setfenv(1, env)
local path = (...):... |
s = Procedural.Shape():addPoint(0, 0):addPoint(-0.5, -1.0):addPoint(-0.75, 1):addPoint(0, 0.5)
tests:addShape(s) |
require('quest')
require('constants')
-- Sun Gem quest details
local function sun_gem_start_fn()
add_message_with_pause("PLOUGHMAN_SUNGEM_QUEST_START_SID")
add_message_with_pause("PLOUGHMAN_SUNGEM_QUEST_START2_SID")
clear_and_add_message("PLOUGHMAN_SUNGEM_QUEST_START3_SID")
end
-- Don't allow the ploughman's qu... |
function disableGunfire ()
setAmbientSoundEnabled("gunfire", false)
end
addEventHandler ("onClientResourceStart", getRootElement(), disableGunfire) |
local config = {
-- be aware that each config should be followed by a comma
-- the side length of the crossbreeding farm
-- the recommend value is 9 because it's crop-matron's working area size.
farmSize = 6,
-- the side length of the new crop storage farm
-- the recommend value is 13 because i... |
type Dictionary<Value> = {[string]: Value}
type DescribeFunction = (Dictionary<any>?) -> nil
type Expectation = {
never: {
to: {
be: {
a: (string) -> Expectation,
an: (string) -> Expectation,
near: (number, number?) -> Expectation,
ok: () -> Expectation,
},
equal: (any) -> Expectation,
... |
------------
-- Lua module for generating .ninja files.
-- @module ninja_syntax
-- @author Charles Grunwald (Juntalis) <ch@rles.rocks>
----
-- Store used packages in locals
local io, bit = io, bit
-- Cached globals
local _s, _t = string, table
local _len = function(o) return #o end
local strmatch, strfind = _s.match,... |
--------------------------------
-- @module SoundData
-- @parent_module audio
---@class audio.SoundData
local SoundData = {}
audio.SoundData = SoundData
--------------------------------
---
---@return audio.SoundData
function SoundData:clone()
end
--------------------------------
---
---@return number
function So... |
--lmake.lua
local lstdfs = require('lstdfs')
local ldir = lstdfs.dir
local lstem = lstdfs.stem
local lappend = lstdfs.append
local lconcat = lstdfs.concat
local labsolute = lstdfs.absolute
local lextension = lstdfs.extension
local lcurdir = lstdfs.current_path
local lre... |
local npcConfig = require "config.npcConfig"
local QuestModule = require "module.QuestModule"
local DataBoxModule = require "module.DataBoxModule"
local ItemHelper = require "utils.ItemHelper"
local ParameterConf = require "config.ParameterShowInfo";
local HeroBuffModule = require "hero.HeroBuffModule"
local UserDefaul... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.