Skip to content

Commit

Permalink
Merge branch 'MT-CTF:master' into bullet-ricochet
Browse files Browse the repository at this point in the history
  • Loading branch information
a-blob authored Nov 23, 2023
2 parents 7125719 + d534180 commit c0d5326
Show file tree
Hide file tree
Showing 168 changed files with 2,726 additions and 994 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,6 @@ debug.txt
/mods/ctf/ctf_map/textures/*Back.*
/mods/ctf/ctf_map/textures/*Left.*
/mods/ctf/ctf_map/textures/*Right.*
/mods/ctf/ctf_map/textures/*_screenshot.png
/mods/ctf/ctf_map/textures/*_screenshot.png

*.blend1
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ Note that this version may be slightly behind the git version, but it will be a

## Development

* ### [WIP CTF API DOCS](docs/ctf-api.md)
* If you use Visual Studio Code we recommend these extensions:
* https://marketplace.visualstudio.com/items?itemName=sumneko.lua
* https://marketplace.visualstudio.com/items?itemName=dwenegar.vscode-luacheck
Expand All @@ -51,15 +52,14 @@ Created by [rubenwardy](https://rubenwardy.com/).
Developed by [LandarVargan](https://github.com/LoneWolfHT).
Previous Developers: [savilli](https://github.com/savilli).

Check out [mods/](mods/) to see all the installed mods and their respective licenses.

Licenses where not specified:
Code: LGPLv2.1+
Textures: CC-BY-SA 3.0

### Textures

* [Header](menu/header.png): CC BY-SA 4.0 by xenonca
* [Background Image](menu/background.png): CC0 (where applicable) by Apelta (Uses [Minetest Game](https://github.com/minetest/minetest_game) textures, the majority of which are licensed CC-BY-SA 3.0). The player skin used is licensed CC-BY-SA 3.0

### Mods

Check out [mods/](mods/) to see all the installed mods and their respective licenses.
* [Header](menu/header.png): CC-BY-3.0 by [SuddenSFD](https://github.com/SuddenSFD)
* [Background Image](menu/background.png): CC BY-SA 4.0 (where applicable) by [GreenBlob](https://github.com/a-blob) (Uses [Minetest Game](https://github.com/minetest/minetest_game) textures, the majority of which are licensed CC-BY-SA 3.0). The player skins used are licensed CC-BY-SA 3.0
* [Icon](menu/icon.png): CC-BY-3.0 by [SuddenSFD](https://github.com/SuddenSFD)
56 changes: 56 additions & 0 deletions docs/ctf-api.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
CaptureTheFlag Lua API Reference
==================================

# Code Style
* Use tabs for indentation.

# mods/apis/
This folder contains a collection of mods with the main goal of providing an API

## ctf_settings
This mod adds a 'Settings' tab to the player's inventory.
Mods can use the ctf_settings API to add buttons/fields to the Settings tab that can be used to customize the mod's functionality per-player.

### `ctf_settings.register(name, def)`
* `name` *string*: Name of setting to register
* `def` *table*: Setting properties, see below
```lua
ctf_settings.register("my_setting", {
type = "bool" || "list",
label = "Setting name/label", -- not used for list
description = "Text in tooltip",
list = {i1, i2, i3, i4}, -- used for list, remember to formspec escape contents
default = "default value/index",
on_change = function(player, new_value)
<...>
end
})
```

### `ctf_settings.set(player, setting, value)`
* `player` *PlayerObj*: The player whos setting you want to set
* `settings` *string*: The name of the setting you want to set
* `value` *(bool | list index) as string*: The value you want to set, dependent on what the setting's type is

### `ctf_settings.get(player, setting)`
* `player` *PlayerObj*: The player whos setting you want to get
* `setting` *string*: The name of the setting you want to get
- **returns** *(bool | list index) as string*: Returns the player's current setting value, the default given at setting registration, or if both are unset, an empty string: `""`

---
# mods/ctf/
TODO

---
# mods/mtg/
TODO

---
# mods/other/
TODO

---
# mods/pvp/
TODO

---
52 changes: 0 additions & 52 deletions docs/doc_data.md

This file was deleted.

70 changes: 0 additions & 70 deletions docs/doc_project_overview.md

This file was deleted.

60 changes: 0 additions & 60 deletions docs/doc_settings.md

This file was deleted.

Binary file modified menu/background.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified menu/header.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified menu/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions mods/apis/ctf_gui/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ do
end
end

minetest.log("action", "[ctf_gui] unpacking: "..dump(l))
return format(base, unpck(l))
end

Expand Down
Loading

0 comments on commit c0d5326

Please sign in to comment.