Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the SDK scripts + Example mod to the upcoming OpenRA release #198

Draft
wants to merge 19 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
824 changes: 584 additions & 240 deletions .editorconfig

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ jobs:

steps:
- name: Clone Repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install .NET 6.0
uses: actions/setup-dotnet@v3
uses: actions/setup-dotnet@v4
with:
dotnet-version: '6.0.x'

Expand All @@ -43,7 +43,7 @@ jobs:

steps:
- name: Clone Repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Prepare Environment
run: |
Expand All @@ -67,10 +67,10 @@ jobs:

steps:
- name: Clone Repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install .NET 6.0
uses: actions/setup-dotnet@v3
uses: actions/setup-dotnet@v4
with:
dotnet-version: '6.0.x'

Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/packaging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ jobs:
runs-on: ubuntu-22.04
steps:
- name: Clone Repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install .NET 6.0
uses: actions/setup-dotnet@v3
uses: actions/setup-dotnet@v4
with:
dotnet-version: '6.0.x'

Expand All @@ -28,7 +28,7 @@ jobs:
run: |
make engine
mkdir -p build/linux
sudo apt install libfuse2
sudo apt-get install -y desktop-file-utils
./packaging/linux/buildpackage.sh "${GIT_TAG}" "${PWD}/build/linux"

- name: Upload Packages
Expand All @@ -42,13 +42,13 @@ jobs:

macos:
name: macOS Disk Image
runs-on: macos-11
runs-on: macos-13
steps:
- name: Clone Repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install .NET 6.0
uses: actions/setup-dotnet@v3
uses: actions/setup-dotnet@v4
with:
dotnet-version: '6.0.x'

Expand Down Expand Up @@ -81,10 +81,10 @@ jobs:
runs-on: ubuntu-22.04
steps:
- name: Clone Repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install .NET 6.0
uses: actions/setup-dotnet@v3
uses: actions/setup-dotnet@v4
with:
dotnet-version: '6.0.x'

Expand Down
6 changes: 3 additions & 3 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ members of the project's leadership.
## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
available at [http://contributor-covenant.org/version/1/4][version]
available at [https://contributor-covenant.org/version/1/4][version]

[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/
[homepage]: https://contributor-covenant.org
[version]: https://contributor-covenant.org/version/1/4/
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ Please note that this repository is specifically for the scripts and infrastruct
When developing new features, it is important to make sure that they work on all our supported platforms. Right now, this means Windows >= 7 (with PowerShell >= 3), macOS >= 10.7, and Linux. We would like to also support *BSD, but do not currently have a means to test this.

Some issues to be aware of include:
* Use http://www.shellcheck.net/ to confirm POSIX compatibility of *.sh scripts.
* Use https://www.shellcheck.net/ to confirm POSIX compatibility of *.sh scripts.
* Avoid non-standard gnu extensions to common Unix tools (e.g. the `-f` flag from GNU `readlink`)

While your pull-request is in review it will be helpful if you join IRC to discuss the changes.

See also the in-depth guide on [contributing](https://github.com/OpenRA/OpenRA/wiki/Contributing) on the main OpenRA project wiki. Most of the content on this page also applies to the Mod SDK.
See also the in-depth guide on [contributing](https://github.com/OpenRA/OpenRA/wiki/Contributing) on the main OpenRA project wiki. Most of the content on this page also applies to the Mod SDK.
8 changes: 4 additions & 4 deletions COPYING
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007

Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.

Expand Down Expand Up @@ -645,7 +645,7 @@ the "copyright" line and a pointer to where the full notice is found.
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
along with this program. If not, see <https://www.gnu.org/licenses/>.

Also add information on how to contact you by electronic and paper mail.

Expand All @@ -664,11 +664,11 @@ might be different; for a GUI interface, you would use an "about box".
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<http://www.gnu.org/licenses/>.
<https://www.gnu.org/licenses/>.

The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
<https://www.gnu.org/philosophy/why-not-lgpl.html>.
6 changes: 3 additions & 3 deletions mod.config
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
MOD_ID="example"

# The OpenRA engine version to use for this project.
ENGINE_VERSION="release-20231010"
ENGINE_VERSION="playtest-20241116"

##############################################################################
# Packaging
Expand Down Expand Up @@ -40,10 +40,10 @@ PACKAGING_DISPLAY_NAME="Example Mod"
# The URL for the project homepage.
# This is used in:
# - Windows "Add/Remove Programs" list
PACKAGING_WEBSITE_URL="http://openra.net"
PACKAGING_WEBSITE_URL="https://openra.net"

# The URL that is displayed in the crash dialog.
PACKAGING_FAQ_URL="http://wiki.openra.net/FAQ"
PACKAGING_FAQ_URL="https://wiki.openra.net/FAQ"

# The human-readable project authors.
# This is used in:
Expand Down
12 changes: 12 additions & 0 deletions mods/example/chrome/chrome.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -378,3 +378,15 @@ dropdown-separators:

separator:
Inherits: button

# TODO: Fix the random numbers below.
editor:
Inherits: ^Glyphs
Regions:
select: 34, 187, 16, 16
tiles: 0, 187, 16, 16
overlays: 17, 187, 16, 16
actors: 34, 68, 16, 16
tools: 136, 68, 16, 16
history: 136, 51, 16, 16
erase: 50, 187, 16, 16
52 changes: 26 additions & 26 deletions mods/example/chrome/ingame-observer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,41 +5,41 @@ Container@OBSERVER_WIDGETS:
LogicKeyListener@OBSERVER_KEY_LISTENER:
Container@MUTE_INDICATOR:
Logic: MuteIndicatorLogic
X: WINDOW_RIGHT - WIDTH - 260
X: WINDOW_WIDTH - WIDTH - 260
Y: 5
Width: 200
Height: 25
Children:
Image@ICON:
X: PARENT_RIGHT - WIDTH
X: PARENT_WIDTH - WIDTH
Y: 1
Width: 24
Height: 24
ImageCollection: sidebar-bits
ImageName: indicator-muted
Label@LABEL:
Width: PARENT_RIGHT - 30
Width: PARENT_WIDTH - 30
Height: 25
Align: Right
Text: Audio Muted
Text: label-mute-indicator
Contrast: true
MenuButton@OPTIONS_BUTTON:
X: 5
Y: 5
Width: 160
Height: 25
Text: Options (Esc)
Text: button-observer-widgets-options
Font: Bold
Key: escape
DisableWorldSounds: true
Container@GAME_TIMER_BLOCK:
Logic: GameTimerLogic
X: (WINDOW_RIGHT - WIDTH) / 2
X: (WINDOW_WIDTH - WIDTH) / 2
Width: 100
Height: 55
Children:
LabelWithTooltip@GAME_TIMER:
Width: PARENT_RIGHT
Width: PARENT_WIDTH
Height: 30
Align: Center
Font: Title
Expand All @@ -48,31 +48,31 @@ Container@OBSERVER_WIDGETS:
TooltipTemplate: SIMPLE_TOOLTIP
Label@GAME_TIMER_STATUS:
Y: 32
Width: PARENT_RIGHT
Width: PARENT_WIDTH
Height: 15
Align: Center
Font: Bold
Contrast: true
Background@RADAR_BG:
X: WINDOW_RIGHT - 255
X: WINDOW_WIDTH - 255
Y: 5
Width: 250
Height: 250
Children:
Radar@INGAME_RADAR:
X: 10
Y: 10
Width: PARENT_RIGHT - 19
Height: PARENT_BOTTOM - 19
Width: PARENT_WIDTH - 19
Height: PARENT_HEIGHT - 19
WorldInteractionController: INTERACTION_CONTROLLER
VideoPlayer@PLAYER:
X: 10
Y: 10
Width: PARENT_RIGHT - 20
Height: PARENT_BOTTOM - 20
Width: PARENT_WIDTH - 20
Height: PARENT_HEIGHT - 20
Skippable: false
Background@OBSERVER_CONTROL_BG:
X: WINDOW_RIGHT - 255
X: WINDOW_WIDTH - 255
Y: 260
Width: 250
Height: 55
Expand All @@ -95,12 +95,12 @@ Container@OBSERVER_WIDGETS:
Y: 5
Label@LABEL:
X: 34
Width: PARENT_RIGHT
Width: PARENT_WIDTH
Height: 25
Shadow: True
Label@NOFLAG_LABEL:
X: 5
Width: PARENT_RIGHT
Width: PARENT_WIDTH
Height: 25
Shadow: True
Container@REPLAY_PLAYER:
Expand All @@ -116,7 +116,7 @@ Container@OBSERVER_WIDGETS:
Width: 26
Height: 26
Key: Pause
TooltipText: Pause
TooltipText: button-replay-player-pause-tooltip
TooltipContainer: TOOLTIP_CONTAINER
IgnoreChildMouseOver: true
Children:
Expand All @@ -131,7 +131,7 @@ Container@OBSERVER_WIDGETS:
Width: 26
Height: 26
Key: Pause
TooltipText: Play
TooltipText: button-replay-player-play-tooltip
TooltipContainer: TOOLTIP_CONTAINER
IgnoreChildMouseOver: true
Children:
Expand All @@ -146,37 +146,37 @@ Container@OBSERVER_WIDGETS:
Width: 36
Height: 20
Key: ReplaySpeedSlow
TooltipText: Slow speed
TooltipText: button-replay-player-slow.tooltip
TooltipContainer: TOOLTIP_CONTAINER
Text: 50%
Text: button-replay-player-slow.label
Font: TinyBold
Button@BUTTON_REGULAR:
X: 55 + 45
Y: 13
Width: 38
Height: 20
Key: ReplaySpeedRegular
TooltipText: Regular speed
TooltipText: button-replay-player-regular.tooltip
TooltipContainer: TOOLTIP_CONTAINER
Text: 100%
Text: button-replay-player-regular.label
Font: TinyBold
Button@BUTTON_FAST:
X: 55 + 45 * 2
Y: 13
Width: 38
Height: 20
Key: ReplaySpeedFast
TooltipText: Fast speed
TooltipText: button-replay-player-fast.tooltip
TooltipContainer: TOOLTIP_CONTAINER
Text: 200%
Text: button-replay-player-fast.label
Font: TinyBold
Button@BUTTON_MAXIMUM:
X: 55 + 45 * 3
Y: 13
Width: 38
Height: 20
Key: ReplaySpeedMax
TooltipText: Maximum speed
TooltipText: button-replay-player-maximum.tooltip
TooltipContainer: TOOLTIP_CONTAINER
Text: MAX
Text: button-replay-player-maximum.label
Font: TinyBold
23 changes: 21 additions & 2 deletions mods/example/languages/en.ftl → mods/example/fluent/chrome.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,24 @@ dropdown-starting-units =
options-starting-units =
.unlabeled = Unlabeled

options-difficulty =
.normal = Normal
## ingame-observer.yaml
label-mute-indicator = Audio Muted
button-observer-widgets-options = Options (Esc)
button-replay-player-pause-tooltip = Pause
button-replay-player-play-tooltip = Play

button-replay-player-slow =
.tooltip = Slow speed
.label = 50%

button-replay-player-regular =
.tooltip = Regular speed
.label = 100%

button-replay-player-fast =
.tooltip = Fast speed
.label = 200%

button-replay-player-maximum =
.tooltip = Maximum speed
.label = MAX
7 changes: 7 additions & 0 deletions mods/example/fluent/mod.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
## Metadata
mod-title = Example mod
mod-windowtitle = Example

# To silence "Warning: Missing key `loadscreen-loading` in mod ftl files required by `LogoStripeLoadScreen.Loading`"
# Because https://github.com/OpenRA/OpenRA/issues/20693 wasn't fixed.
loadscreen-loading = .
10 changes: 10 additions & 0 deletions mods/example/fluent/rules.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
## world.yaml
faction-random =
.name = Random
.description = Random Faction
A random faction will be chosen when the game starts.

faction-example =
.name = Example
.description = Example Faction
Provide your own faction description here.
Loading
Loading