block_league/init.lua

126 lines
3.0 KiB
Lua
Raw Permalink Normal View History

2020-10-27 10:13:15 -07:00
local S = minetest.get_translator("block_league")
2020-10-29 10:33:44 -07:00
local modpath = minetest.get_modpath("block_league")
2021-02-28 02:34:57 -08:00
local srcpath = modpath .. "/src"
2022-05-29 15:58:38 -07:00
local version = "0.7.0-dev"
2020-10-27 10:13:15 -07:00
2021-02-28 02:34:57 -08:00
block_league = {}
2020-10-29 10:33:44 -07:00
dofile(modpath .. "/GLOBALS.lua")
2020-10-27 10:13:15 -07:00
arena_lib.register_minigame("block_league", {
2022-06-26 15:15:42 -07:00
name = "Block League",
prefix = "[Block League] ",
2022-08-17 14:24:02 -07:00
icon = "bl_pixelgun.png",
teams = { S("orange"), S("blue") },
teams_color_overlay = { "orange", "blue"},
camera_offset = {
nil,
{x=8, y=4, z=-1}
},
2020-11-05 09:38:24 -08:00
hotbar = {
slots = 4,
background_image = "bl_gui_hotbar.png"
},
2021-02-11 13:50:08 -08:00
time_mode = "decremental",
2020-11-07 12:32:23 -08:00
2020-10-27 10:13:15 -07:00
join_while_in_progress = true,
load_time = 6,
2020-10-27 10:13:15 -07:00
celebration_time = 5,
in_game_physics = {
speed = block_league.SPEED,
jump = 1.5,
gravity = 1.15,
sneak_glitch = true,
new_move = true
2020-10-27 10:13:15 -07:00
},
2020-11-06 14:35:31 -08:00
disabled_damage_types = {"fall", "punch"},
2020-10-27 10:13:15 -07:00
properties = {
-- 1 = Touchdown
-- 2 = Deathmatch
2020-11-25 14:50:28 -08:00
mode = 1,
2020-12-06 09:22:12 -08:00
score_cap = 5,
2020-10-27 10:13:15 -07:00
immunity_time = 6,
goal_orange = {},
2020-10-28 08:55:35 -07:00
goal_blue = {},
waiting_room_orange = {},
waiting_room_blue = {},
2020-10-28 08:55:35 -07:00
ball_spawn = {},
min_y = 0
2020-10-27 10:13:15 -07:00
},
temp_properties = {
2020-10-29 15:06:24 -07:00
weapons_disabled = true,
2020-10-27 10:13:15 -07:00
},
team_properties = {
TDs = 0,
kills = 0,
deaths = 0
},
player_properties = {
energy = 100,
TDs = 0,
points = 0,
2021-03-01 07:19:49 -08:00
entering_time = 0,
weapons_magazine = {}
2020-10-27 10:13:15 -07:00
}
})
2020-10-27 10:13:15 -07:00
-- load other scripts
2021-02-28 02:34:57 -08:00
dofile(srcpath .. "/chatcmdbuilder.lua")
dofile(srcpath .. "/commands.lua")
dofile(srcpath .. "/database_manager.lua")
dofile(srcpath .. "/input_manager.lua")
dofile(srcpath .. "/player_manager.lua")
dofile(srcpath .. "/privs.lua")
dofile(srcpath .. "/utils.lua")
2020-10-27 10:13:15 -07:00
-- arena_lib
2021-02-28 02:34:57 -08:00
dofile(srcpath .. "/arena_lib/arena_manager.lua")
dofile(srcpath .. "/arena_lib/arena_timer.lua")
2020-10-29 10:33:44 -07:00
-- debug
2021-02-28 02:34:57 -08:00
dofile(srcpath .. "/debug/testkit.lua")
2020-10-27 10:13:15 -07:00
-- HUD
2021-02-28 02:34:57 -08:00
dofile(srcpath .. "/HUD/hud_achievements.lua")
dofile(srcpath .. "/HUD/hud_broadcast.lua")
dofile(srcpath .. "/HUD/hud_critical.lua")
2021-02-28 02:34:57 -08:00
dofile(srcpath .. "/HUD/hud_energy.lua")
dofile(srcpath .. "/HUD/hud_info_panel.lua")
dofile(srcpath .. "/HUD/hud_inputs.lua")
dofile(srcpath .. "/HUD/hud_log.lua")
dofile(srcpath .. "/HUD/hud_scoreboard.lua")
dofile(srcpath .. "/HUD/hud_spectate.lua")
dofile(srcpath .. "/HUD/hud_weapons.lua")
-- misc
dofile(srcpath .. "/misc/energy.lua")
dofile(srcpath .. "/misc/fall.lua")
dofile(srcpath .. "/misc/immunity.lua")
-- modes
dofile(srcpath .. "/modes/game_main.lua")
dofile(srcpath .. "/modes/TD/ball.lua")
-- player
dofile(srcpath .. "/player/achievements.lua")
dofile(srcpath .. "/player/equip.lua")
dofile(srcpath .. "/player/exp.lua")
2020-10-27 10:13:15 -07:00
-- abstract weapons
2021-02-28 02:34:57 -08:00
dofile(srcpath .. "/weapons/bullets.lua")
dofile(srcpath .. "/weapons/weapons.lua")
dofile(srcpath .. "/weapons/weapons_utils.lua")
2020-10-27 10:13:15 -07:00
-- weapons
2021-02-28 02:34:57 -08:00
dofile(srcpath .. "/weapons/bouncer.lua")
dofile(srcpath .. "/weapons/grenade_launcher.lua")
dofile(srcpath .. "/weapons/pixelgun.lua")
dofile(srcpath .. "/weapons/rocket_launcher.lua")
dofile(srcpath .. "/weapons/sword.lua")
dofile(srcpath .. "/weapons/smg.lua")
2020-11-03 07:25:41 -08:00
minetest.log("action", "[BLOCK_LEAGUE] Mod initialised, running version " .. version)