content stringlengths 5 1.05M |
|---|
VFS.Include("luagadgets/gadgets.lua", nil, VFS.BASE) |
TidyPlatesUtility = {}
-------------------------------------------------------------------------------------
-- General Helpers
-------------------------------------------------------------------------------------
local _
local copytable -- Allows self-reference
copytable = function(original)
local... |
-- a Hook is the first weapon of a Hunter
-- it can be used to move around the map like in liero,
-- to fight other Hunters,
-- to grab the Rabbit
-- and to interact with the environment
local CLASS = require('Class')
local Assets = require('Assets')
local World = require('World')
local Entity = require('Entity')
... |
local use_player_monoids = minetest.global_exists("player_monoids")
local storage = minetest.get_mod_storage()
local global_fly_enabled = storage:get_int("global_fly") == 1
local player_can_fly = function(player)
local pos = player:get_pos()
for _, box in pairs(skybox.list) do
local match = false
if box.miny an... |
-- oUF_SimpleConfig: player
-- zork, 2016
-----------------------------
-- Variables
-----------------------------
local A, L = ...
-----------------------------
-- Player Config
-----------------------------
L.C.player = {
enabled = true,
size = {265,26},
point = {"RIGHT",UIParent,"CENTER",-130,-100},
sca... |
exports('GetNorthYanktonObject', function()
return NorthYankton
end)
NorthYankton = {
ipl = {
"prologue01",
"prologue01c",
"prologue01d",
"prologue01e",
"prologue01f",
"prologue01g",
"prologue01h",
"prologue01i",
"prologue01j",
"prologue01k",
"prologue01z",
"prologue02",
"prologue03",
"p... |
require "gliese/web"
require "gliese/redis"
require "bit"
require "Sha1"
local secret = "change-me-please"
local v4_host = "testv6.stdio.be"
local v46_host = "v46.probe-v6.stdio.be"
local v6_host = "v6.probe-v6.stdio.be"
local v6_dns6_host = "v6-probe-for-stdio-be.onlyv6.com"
local script = "/v6.lua/"
--[[
Steps:
0... |
-----------------------------------
-- Area: Ru'Aun Gardens
-- NPC: <this space intentionally left blank>
-- !pos -241 -12 332 130
-----------------------------------
local ID = require("scripts/zones/RuAun_Gardens/IDs")
require("scripts/globals/npc_util")
-----------------------------------
function onTrade(player, ... |
MagBehavior = {}
MagBehavior.e = {}
------------------------------------------------------
-- System events
------------------------------------------------------
function MagBehavior:new()
local u = {}
setmetatable(u, self)
self.__index = self
return u
end
function MagBehavior:onConnect()
-- self.state = ... |
--[[
DDPathfinding
v0.7.4
by: truedarkdev (DarkDev#3167 at discord)
]]--
local DD_PATHFINDING_BASE = require(script:GetCustomProperty("DDPathfindingBase"))
local DD_PRIORITY_QUEUE = require(script:GetCustomProperty("DDPriorityQueue"))
local GREEDINESS = script:GetCustomProperty("Greediness") or ... |
--[[------------------------------------------------
-- Love Frames - A GUI library for LOVE --
-- Copyright (c) 2012-2014 Kenny Shields --
--]]------------------------------------------------
return function(loveframes)
---------- module start ----------
loveframes.objects = {}
--[[------------------------------... |
-- A general purpose 2-dimensional coordinate type.
-- initialized like a class, i.e. Point(x, y)
-- Points are often used as arguments. Library functions should generally not
-- modify input points, and use point:copy().
local point = {}
function point.init (x, y)
return setmetatable({x=x, y=y}, point.mt)
end
f... |
project "esteidcsp"
uuid "DBCD4071-608C-4443-A440-45E15FE05BC3"
location ("../../../build/" .. _ACTION)
language "C++"
kind "SharedLib"
files { "*.h","*.cpp","esteidcsp.rc","csp.def" }
pchheader "precompiled.h"
pchsource "precompiled.cpp"
includedirs {
"../.." -- utility
,"..... |
return {'dixieland','dixit','dixielandmuziek','dix'} |
SILE.hyphenator.languages["nl"] = {}
SILE.hyphenator.languages["nl"].patterns =
{
".a4",
".aan5",
".aarts5",
".aat5",
".ab5l",
".acht5end",
".ac5re",
".adi5",
".af3",
".af5l",
".af5s",
".aftu5re",
".al3ee",
".al3f",
".alk4",
".al5ko",
".alko5v",
".al5ma",
".al3om",
".al4st",
".ana3s",
".an3d2",
".an3en",
".an3gl",
"... |
local M = {}
M.CR = string.char(0x0d)
M.LF = string.char(0x0a)
M.CRLF = string.char(0x0d, 0x0a)
function M.toLF(str)
str = string.gsub(str, M.CRLF, M.LF)
str = string.gsub(str, M.CR, M.LF)
return str
end
return M
|
--- This module provides various utilities that make or operate on tables.
--
-- 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... |
local settings_key_prefix = "a2x1_config_bits" .. "-" .. "player_force" .. "-"
function __settings_global__player_force(data, order)
return data:extend(
{
{
type = "double-setting",
name = settings_key_prefix .. "character_running_speed_modifier",
setting_type = "runtime-global",
... |
BottomMidUI = SimpleClass(BaseUI)
local mainId = 900000010001
--声明成员变量
function BottomMidUI:__init_Self()
self.mp = UIWidget.LImage
self.hp = UIWidget.LImage
self.createPlayerBtn = UIWidget.LButton
self.deleteBtn = UIWidget.LButton
self.createAIBtn = UIWidget.LButton
self.index = 800000010001
self.entityIndex ... |
function Whip:UpdateRootState()
local infested = GetIsPointOnInfestation(self:GetOrigin(), self:GetTeamNumber())
local moveOrdered = self:GetCurrentOrder() and self:GetCurrentOrder():GetType() == kTechId.Move
-- unroot if we have a move order or infestation recedes
if self.rooted and (moveOrdered or n... |
return {
snippet_engine = "luasnip",
languages = {
typescript = {
template = {
annotation_convention = "tsdoc",
},
},
typescriptreact = {
template = {
annotation_convention = "tsdoc",
},
},
},
}
|
local _, C = unpack(select(2, ...))
local _G = _G
local table_insert = _G.table.insert
local hooksecurefunc = _G.hooksecurefunc
table_insert(C.defaultThemes, function()
local StackSplitFrame = _G.StackSplitFrame
StackSplitFrame:StripTextures()
StackSplitFrame:CreateBackdrop('Transparent')
StackSplitFrame.bg1 = ... |
local uv = require 'couv'
local TEST_PORT = 9123
coroutine.wrap(function()
local handle = uv.Udp.new()
handle:bind(uv.SockAddrV4.new('0.0.0.0', TEST_PORT))
handle:startRecv()
local nread, buf, addr
repeat
nread, buf, addr = handle:recv()
print("udp_server recv nread=", nread)
if nread and nread... |
-- Copyright 2019 - present Xlab
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to ... |
id = 'V-38569'
severity = 'low'
weight = 10.0
title = 'The system must require passwords to contain at least one uppercase alphabetic character.'
description = 'Requiring a minimum number of uppercase characters makes password guessing attacks more difficult by ensuring a larger search space.'
fixtext = 'The pam_crackl... |
local SpatialBatchNormalization, parent =
torch.class('cudnn.SpatialBatchNormalization', 'cudnn.BatchNormalization')
SpatialBatchNormalization.mode = 'CUDNN_BATCHNORM_SPATIAL'
SpatialBatchNormalization.nDim = 4
SpatialBatchNormalization.__version = 2
|
--[[
Copyright 2020 Matthew Hesketh <matthew@matthewhesketh.com>
This code is licensed under the MIT. See LICENSE for details.
]]
local game = {}
local mattata = require('mattata')
local socket = require('socket')
local json = require('dkjson')
local redis = require('libs.redis')
local utf8 = utf8 or require('... |
local Components = require "moonpie.ui.components"
local App = require "game.app"
local MainMenu = Components("main_menu", function()
return {
id = "mainMenu",
style = "align-center align-middle",
Components.button { caption = "Start", click = App.newGame, style = "mainMenuButton button-primary" }... |
--- module loader, Re-Dream
-- Global
turbo.Version = 201710.0
-- Variables
local pathRoot = "turbo/"
local pathLoad = { "shared/", "server/", "client/" }
-- Helper functions
local function loadFolder( path, realm )
if realm == 2 and not SERVER then return end
local files = file.Find( pathRoot .. path .. "*.lua"... |
return {
fadeOut = 1.5,
mode = 3,
fadeType = 1,
once = true,
id = "TACT20009",
scripts = {
{
actor = 407010,
side = 2,
nameColor = "#ff0000",
mode = 2,
say = "果然未完成的躯体还是存在缺陷吗…",
shake = {
speed = 1,
number = 3
},
typewriter = {
speed = 0.05,
speedUp = 0.01
},
painti... |
-- FIXME all howing as complete even when some missing
local M = {}
local requests
local count = 0
local variables
local running = false
local update_status_callback
local update_view_callback
function M.async_curl(request)
local curl_args = request:get_curl(variables, false)
-- nil if missing data
if not cur... |
--[[
队列排序
]]
local THIS_MODULE = ...
local Stack = require("app.main.modules.common.Stack")
local QueueSort = class("QueueSort", require("app.main.modules.ui.FrameBase"),
require("app.main.modules.uiwidget.UIWidgetFocusable"))
--[[
构造函数
config
params 额外参数
name 名称
csb csb文件
widgets 组件表
bindings 绑定表... |
---
-- Creates and parses NetBIOS traffic. The primary use for this is to send
-- NetBIOS name requests.
--
-- @author Ron Bowes <ron@skullsecurity.net>
-- @copyright Same as Nmap--See http://nmap.org/book/man-legal.html
local bin = require "bin"
local bit = require "bit"
local dns = require "dns"
local math = require... |
local M = {}
M.rewindLimit = 5 -- time limit expressed in seconds
M.fixedStep = true
M.fps = 60
local properties = {}
local timeFrames = {}
local properties = {}
local tick = 0
local function init(...)
local args = {...}
for i = 1, #args do
if #args[i] == 2
and type(args[i]) == "table"
and type(args[i... |
-----------------------------------
-- Area: Northern San d'Oria
-- NPC: Heruze-Moruze
-- Involved in Mission: 2-3 Windurst
-- !pos -56 -3 36 231
-----------------------------------
require("scripts/globals/missions")
-----------------------------------
function onTrade(player, npc, trade)
end
function onTrigger(pla... |
return {'quirinaal','quiche','quickstep','quidam','quilt','quilten','quinoa','quinquagesima','quinto','quisling','quitte','quiz','quizleider','quizmaster','quizprogramma','quizvraag','quizzen','quietisme','quietist','quietisten','quirina','quirine','quiteen','quiteens','quito','quitoos','quitoer','quin','quincy','quinn... |
require("plugins.null_ls.settings")
|
module("luci.controller.amlogic", package.seeall)
function index()
page = entry({"admin", "system", "amlogic"}, alias("admin", "system", "amlogic", "info"), _("Amlogic Service"), 88)
page.dependent = true
entry({"admin", "system", "amlogic", "info"},cbi("amlogic/amlogic_info"),_("Amlogic Service"), 1).lea... |
Config = {}
Config.cars = {
{spawnCode = "", steamID = {"", ""}, DiscordID = {"", "", ""}, acePerm = {"", "", ""}, DiscordRole = {"", "", ""}, whatToDo = "killengine"},
{spawnCode = "", steamID = {"", ""}, DiscordID = {"", "", ""}, acePerm = {"", "", ""}, DiscordRole = {"", "", ""}, whatToDo = "delete"},
{spaw... |
------------------------------------------
-- Startup Settings handling happens here.
------------------------------------------
if settings.startup["space-locomotive-speed-setting"].value == "238 km/h (Vanilla)" then
data.raw["locomotive"]["space-locomotive"].max_speed = 1.1
data.raw["cargo-wagon"]["space-cargo-wa... |
local orig_BaseNetworkSession = {
check_peer_preferred_character = BaseNetworkSession.check_peer_preferred_character
}
-- Modified to support additional peers.
function BaseNetworkSession:on_network_stopped()
local num_player_slots = BigLobbyGlobals:num_player_slots()
-- Only code changed was replacing hardcoded ... |
--服务进程操作router的相关基础函数
addr_list =
{
["router1"] = {ip="127.0.0.1", port=8000},
--["router2"] = {ip="127.0.0.1", port=8001},
};
routers = routers or {};
--router_name --> socket
connectings = connectings or {};
function select_router()
current_router = nil;
if #routers > 0 then
current_router ... |
local ok, zen = pcall(require, "zen-mode")
if not ok then
return
end
zen.setup {
window = {
backdrop = 0.25,
width = 0.5,
},
}
vim.keymap.nnoremap { "<M-f>", zen.toggle }
vim.keymap.inoremap { "<M-f>", zen.toggle }
|
local tasks = require "lua-asyncio/tasks"
local async = tasks.async
local Lock
do
Lock = {}
local meta = {__index = Lock}
--[[@
@name new
@desc Creates a new instance of Lock
@desc This is an object used to have exclusive access to shared resources.
@desc If a task acquired it, no other task can acquire th... |
local K, _, L = unpack(select(2, ...))
local CopyChat = K:GetModule("Chat")
-- Sourced: ElvUI (Elvz)
local _G = _G
local string_format = _G.string.format
local string_gsub = _G.string.gsub
local string_lower = _G.string.lower
local table_concat = _G.table.concat
local table_insert = _G.table.insert
local AUCTION_CAT... |
local gitsigns_ok, gitsigns = pcall(require, 'gitsigns')
if not gitsigns_ok then
return
end
gitsigns.setup()
|
package.cpath = package.cpath .. ";../../luaclib/?.so"
local ltask = require "ltask"
local c = ...
assert(type(c) == "number")
local taskid = ltask.taskid()
for i=1,10 do
ltask.send(c, i)
print(string.format("task %d send %d", taskid, i))
coroutine.yield()
end
print("producer exit")
|
utilMenu = hs.menubar.new()
local icon = [[
1 . . . . . . . . . . . 3
. # # . . . . . . . # # .
. # # # # . . . # # # # .
. . # # # # 2 # # # # . .
. . # # # # # # # # # . .
. . . # # # # # # # . . .
. . . 8 # # # # # 4 . . .
. . . # # # # # # # . . .
. . # # # # # # # # # . .
. . # # # # 6 # # # # . .
. # # # # . . .... |
-- test.TbExcelFromJsonMultiRow
return
{
[1] =
{
id=1,
x=5,
items=
{
{
x=1,
y=true,
z="abcd",
a=
{
x=10,
y=100,
},
b=
{
1,
3,
5,
},
},
{
x=2,
y=false,
z="abcd",
a=
{
x=22,
y=33,
},
b=
{
4,
5,
},
},
},
},
[2] =
{
... |
local h = _G._bfredl_helmsman or {}
_G._bfredl_helmsman = h
_G.hm = _G._bfredl_helmsman
local curl = require'plenary.curl'
h.API_TOKEN_HUG = os.getenv "hugtoken"
h.API_TOKEN_GOOSE = os.getenv "goosetoken"
function h.doer(url, api_token, input, cb)
local tzero = vim.loop.gettimeofday()
curl.post(url, {
body ... |
local Player ={}
--for now it is advised to not have any variables that are important for work of the script as they will be reset due to issues with save system
Player.DebugInt=0;
function Player:SpawnDebugString()
Player.DebugInt=Player.DebugInt+1;
print("Lua code is exucuted DebugInt is ".. Player.D... |
local Observable = require 'observable'
local util = require 'util'
--- Returns an Observable that only produces values from the original if they are different from
-- the previous value.
-- @arg {function} comparator - A function used to compare 2 values. If unspecified, == is used.
-- @returns {Observable}
function ... |
local LastStation, LastPart, LastPartNum, CurrentAction = nil, nil, nil, nil
local IsHandcuffed, IsDragged, HasAlreadyEnteredMarker = false, false, false
local CurrentActionData, CopPed, CurrentActionMsg = {}, '', 0
ESX = nil
Citizen.CreateThread(function ()
while ESX == nil do
TriggerE... |
require "Apollo"
require "GameLib"
require "Unit"
require "ICComm"
require "ICCommLib"
require "XmlDoc"
local JSON = Apollo.GetPackage("Lib:dkJSON-2.5").tPackage
local GuardWaypointsPackage, GuardWaypointsPackageVersion = "GMM:GuardWaypoints-1.7", 1
local packageTest = Apollo.GetPackage(GuardWaypointsPackage)
-- if th... |
--[[
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... |
Database_DemonHunter = {date="2020-09-05 13:15:08",lookup={["Havoc"] = {[2329] = {}, [2327] = {}, [2334] = {}, [2328] = {}, [2333] = {}, [2335] = {}, [2343] = {}, [2336] = {}, [2331] = {}, [2345] = {}, [2337] = {}, [2344] = {}},["Vengeance"] = {[2329] = {}, [2327] = {}, [2334] = {}, [2328] = {}, [2333] = {}, [2335] = {... |
local _={}
local log=Debug.log
local startsWith=Allen.startsWith
-- example: get("bind=","*") returns: "127.0.0.1" from bind=127.0.0.1 cmd param
_.get=function(prefix,fallback)
for k,currentArg in pairs(arg) do
-- log("processing arg:"..currentArg)
local pos= string.find(currentArg, prefix)
if pos~=nil then
... |
--Structured exceptions for Lua.
--Written by Cosmin Apreutesei. Public Domain.
--prototype-based dynamic inheritance with __call constructor (from glue).
local function object(super, o)
o = o or {}
o.__index = super
o.__call = super and super.__call
o.__tostring = super and super.__tostring
return setmetatable(... |
script_name("ClearChat")
script_version("v1.0")
script_authors("Tim4ukys")
script_dependencies("SA-MP v0.3.7 R1", "SA-MP v0.3.7 R3-1", "SA-MP v0.3.DL R1")
local dl = require( 'SA-MP API.init' )
local ffi = require( 'ffi' )
function ClearEntry(kolvo)
local m_pChat = dl.Get().pChat
for i = 99, 100 ... |
local cjson = require "kafka.gateway.json" --require "resty.libcjson"
local producer = require "resty.kafka.producer"
local config = require "kafka.gateway.config"
local log = ngx.log
local ERR = ngx.ERR
local json_encode = cjson.encode
local msg_list = ngx.ctx.messageList
local... |
object_tangible_component_weapon_new_weapon_enhancement_ranged_slot_two_s03 = object_tangible_component_weapon_new_weapon_shared_enhancement_ranged_slot_two_s03:new {
}
ObjectTemplates:addTemplate(object_tangible_component_weapon_new_weapon_enhancement_ranged_slot_two_s03, "object/tangible/component/weapon/new_weapon... |
local NAME, S = ...
local KCL = KethoCombatLog
local ACD = LibStub("AceConfigDialog-3.0")
local L = S.L
---------------------
--- LibDataBroker ---
---------------------
local dataobject = {
type = "launcher",
text = NAME,
icon = "Interface\\Icons\\INV_Sword_01",
OnClick = function(clickedframe,... |
--[[
This project is created with the Clockwork framework by Cloud Sixteen.
http://cloudsixteen.com
--]]
-- Called when the cinematic intro info is needed.
function Schema:GetCinematicIntroInfo()
return {
credits = "Designed and developed by "..self:GetAuthor()..".",
title = Clockwork.config:Get("intro_text_big... |
-----------------------------------------------------------------------------------------
-- Decorators
-- Guard
-- Protect the decorated child from running if another Guard with the same token is
-- already guarding (Running) that token.\n
-- Guarding is global for all of the agent's Behaviour Trees.
--------------... |
-- Copyright 2022 SmartThings
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in ... |
return {'ftisis'} |
return NOTESKIN:LoadActor("UpLeft","Tap Note")..{
InitCommand=cmd(effectclock,"beat";effectmagnitude,0.5,1,0)
}; |
--Lib for objectives, from here we control the objective entity and shizzless
if SERVER then
hook.Add("Initialize", "reb_objinit", function()
--Add a timer to be sure everything exists in the game world before calling it.
ObjTable = {}
timer.Simple(0.1, function()
for k, v in pairs(ents.FindByClass("reb_... |
require("toggleterm").setup({
-- size can be a number or function which is passed the current terminal
size = function(term)
if term.direction == "horizontal" then
return 15
elseif term.direction == "vertical" then
return vim.o.columns * 0.4
end
end,
open_mapping = [[<c-\>]],
direction... |
#!/usr/bin/env lua
-- Placed in the public domain 2020 Sam Trenholme
-- This is a version of RadioGatun[32] (RG32) which uses bit32. This is
-- faster than the pure LUA 5.1 implementation of RG32, but needs either
-- a Lua 5.1 port of the bit32 library (Roblox and Lunacy have both
-- done this), or Lua 5.2/5.3 (bit3... |
--===========================================================================--
-- --
-- PLoop for Openresty --
-- --
... |
local path = (...):match('(.-)[^%./]+$')
return {
name = 'Transform',
description = 'Object containing a coordinate system transformation.\n\nThe love.graphics module has several functions and function variants which accept Transform objects.',
constructors = {
'newTransform',
},
supertypes... |
dofile "common.lua"
-- cpp
-- //--------------------------------------------------------------------------
function cpp_common()
includedirs(
{
SRC_DIR,
})
end
-- //--------------------------------------------------------------------------
function cpp_solution(solutionName)
local geneeratepa... |
-- Moving character example.
-- This sample demonstrates:
-- - Controlling a humanoid character through physics
-- - Driving animations using the AnimationController component
-- - Manual control of a bone scene node
-- - Implementing 1st and 3rd person cameras, using raycasts to avoid the 3rd pers... |
enabled = false
function onCreate()
math.randomseed(os.time())
end
function onEvent(name, value1, value2)
if name == 'Angy Effect' then
enabled = not enabled
if enabled then
doTweenAlpha('angynesseffectalpha', 'angynesseffect', 1, 0.5, 'linear')
else
... |
return {
player={
frames={
{
{
0,
0,
40,
28
},
duration=100
},
{
{
40,
0,
40,
28
},
duration=100
},
{
{
80,
0,
40,
... |
g_PluginInfo =
{
Name = "sphinx0res",
Date = "2015-2-17",
Description = "An anti-XRay plugin for Cuberite"
}
|
--Copyright (c) 2011-2015 Zhihua Zhang (alacner@gmail.com)
--Flexihash - A simple consistent hashing implementation for Lua.
module('Flexihash', package.seeall)
Flexihash_Crc32Hasher = {
hash = function(string) return ngx.crc32_long(string) end
}
Flexihash_Md5Hasher = {
hash = function(string) local m5 = strin... |
local mod = DBM:NewMod(195, "DBM-Firelands", nil, 78)
local L = mod:GetLocalizedStrings()
local Riplimb = EJ_GetSectionInfo(2581)
local Rageface = EJ_GetSectionInfo(2583)
local sndWOP = mod:SoundMM("SoundWOP")
mod:SetRevision(("$Revision: 79 $"):sub(12, -3))
mod:SetCreatureID(53691)
mod:SetZone()
mod:SetUsed... |
--[[
Copyright (C) 2015 Real-Time Innovations, Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in... |
local t = Def.ActorFrame{}
t[#t+1] = Def.Quad{
InitCommand=cmd(xy,SCREEN_WIDTH,0;halign,1;valign,0;zoomto,capWideScale(get43size(350),350),SCREEN_HEIGHT;diffuse,color("#1E282F99"));
};
-- what is this supposed to be? - mina
t[#t+1] = Def.Quad{
InitCommand=cmd(draworder,-300;xy,10,300-100;zoomto,SCREEN_WIDTH,160;ha... |
NIL = require "NIL"
NIL.Use("Test/ExtendTest.nil")
|
-- map array arr with function fn
function map(fn, arr)
local new_arr = {}
for i,v in ipairs(arr) do
new_arr[i] = fn(v, i)
end
return new_arr
end
-- filter array arr using function fn
function filter(fn, arr)
local new_arr = {}
j = 1
for i,v in ipairs(arr) do
if fn(v) then
... |
local Map = {}
local framework
function Map:init(path, fw)
framework = fw
-- Set tiles, images
local gid = 1
for i, tileset in ipairs(self.tilesets) do
local image = self.formatPath(path .. tileset.image)
tileset.image = framework.newImage(image)
gid = self:setTiles(i, tileset, gid)
end
-- Set layers
... |
local playsession = {
{"anghelnicky", {524569}},
{"Hiero", {756519}},
{"Menander", {1655046}},
{"Origamist", {1536158}},
{"Sakama", {370553}},
{"everLord", {359708}},
{"JJGG", {704}},
{"waxman", {13277}},
{"xxsevenevesxx", {46568}},
{"TCP", {7168}},
{"VB11", {148669}},
{"ksb4145", {186796}},
{"Sikarii", {2... |
util.AddNetworkString("sa_lowcreed")
util.AddNetworkString("sa_domiracle")
util.AddNetworkString("sa.GetMiracleCooldown")
miracles = {}
local stored = {}
--------------------------------------------
-- miracles.Get(unique)
--
-- Returns the given miracle.
--------------------------------------------
f... |
-- 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_dark_will... |
local curstage = GAMESTATE:GetCurrentStage();
local gfxNames = {
Stage_Extra1= "ScreenGameplay stage extra1";
Stage_Extra2= "ScreenGameplay stage extra1";
Stage_Demo= "ScreenGameplay stage Demo";
Stage_Event="ScreenGameplay stage event";
Stage_1st= "ScreenGameplay stage 1";
Stage_2nd= "ScreenGame... |
tallonIntel = {
itemTemplates = { "object/tangible/loot/dungeon/corellian_corvette/rebel_rescue_filler01.iff", "object/tangible/loot/dungeon/corellian_corvette/rebel_rescue_filler02.iff", "object/tangible/loot/dungeon/corellian_corvette/rebel_rescue_intel.iff" },
}
tallonTicketInfo = { depPlanet = "corellia", faction... |
-- ************************************************************************** --
--[[
Dusk Engine Object Prototype: Tile Layer
Handles everything pertaining to tiles.
--]]
-- ************************************************************************** --
local tileLayerPrototype = {}
-- *******************************... |
local common = require 'common'
local include = require 'include'
local vrml = require 'vrml'
function parseBinarySTL(filename)
local stlfile = assert(io.open(filename, 'rb'))
print(fsize(stlfile))
local header = stlfile:read(80)
if header:sub(1, 5) == 'solid' then
error('ASCII STL')
end
local ptr = 80... |
local gamemode = ScriptedGamemode()
gamemode.ScoreboardColumns = { "Name", "Ping" }
gamemode:On("initscoreboard", function (self, scoreboard)
self.Scoreboard = scoreboard
self.ScoreboardColumnIndexes = {}
for _, columnName in pairs(self.ScoreboardColumns) do
self.ScoreboardColumnIndexes[columnName] = scoreboard:... |
return
{
[6] = {code=6,key='EXAMPLE_FLASH',},
[7] = {code=7,key='EXAMPLE_MSGBOX',},
[8] = {code=8,key='EXAMPLE_DLG_OK',},
[9] = {code=9,key='EXAMPLE_DLG_OK_CANCEL',},
[100] = {code=100,key='ROLE_CREATE_NAME_INVALID_CHAR',},
[101] = {code=101,key='ROLE_CREATE_NAME_EMPTY',},
[102] = {code=102,key='ROLE_CREATE_NAME_EXCEE... |
array_of_strings = {
array_of_strings = {
'hello',
'world',
}
}
|
intcore_shield = class({})
LinkLuaModifier( "intcore_shield_modifier", LUA_MODIFIER_MOTION_NONE )
LinkLuaModifier( "intcore_shield_bonus_damage_modifier", LUA_MODIFIER_MOTION_NONE )
function intcore_shield:OnSpellStart()
if IsServer() then
local target = self:GetCaster()
local modifier_keys = {
duration = self... |
local TXT = Localize{
[0] = " ",
[1] = "",
[2] = "Leave Celeste",
[3] = "Chest",
[4] = "Button",
[5] = "Lever",
[6] = "Vault",
[7] = "Cabinet",
[8] = "Switch",
[9] = "House",
[10] = "Bookcase",
[11] = "",
[12] = "",
[13] = "",
[14] = "You Successfully disarm the trap",
[15] = "",
[16] = "Take a Drink",... |
local l101;
local l102;
local vars102;
local limaxctx;
local function connect(vars)
local pvid = vars.pvids[1];
local config = { serverip = "10.137.20.32", serverport = 10000, username = "luatest", token = "123456", platflag = "test", script = vars,
onManagerInitialized = function()
print( pvid, "onMan... |
--[[Parse and lookup a words from a phrase table.
--]]
local PhraseTable = torch.class('PhraseTable')
function PhraseTable:__init(filePath)
local f = assert(io.open(filePath, 'r'))
self.table = {}
for line in f:lines() do
local c = line:split("|||")
assert(#c == 2, 'badly formatted phrase table: ' .. ... |
function love.conf(t)
t.window.width = 300
t.window.height = 388
t.window.title = "Bird"
end
|
do
local a = 6
print(a)
end
print(a) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.