Skip to content

Instantly share code, notes, and snippets.

View williamhammond's full-sized avatar

William Hammond williamhammond

View GitHub Profile
using System;
using System.Collections;
using Gameplay;
using NSubstitute;
using NUnit.Framework;
using UnityEditor;
using UnityEngine;
using UnityEngine.TestTools;
using Object = UnityEngine.Object;
using System;
using System.Collections;
using Gameplay;
using NSubstitute;
using NUnit.Framework;
using UnityEditor;
using UnityEngine;
using UnityEngine.TestTools;
using Object = UnityEngine.Object;
name: Test
on:
workflow_call:
secrets:
UNITY_LICENSE:
required: true
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
--[[
EXAMPLE GAME MODE SCRIPT
This script demonstrates how to use an assortment of SCAR (Scripting at Relic) functions to create a Game Mode for Age of Empires IV.
We demonstrate how to setup a simple win condition that awards victory to the first player who constructs 5 houses and covers an assortment of topics like building/unit spawning, event tracking, and much more.
Search for the following topic titles (e.g. OPTIONS, RULES, etc.) in this script to see examples of their usage.
- OPTIONS allow you to add buttons to the Skirmish/Custom lobby when your Game Mode is selected and trigger functions based on what the host has selected. The buttons are added in the Options section of the Win Condition .rdo file and their functionality is driven by this script.
function party {
if ! command -v figlet; then
if ! command -v brew; then
echo Requires figlet or brew to be installed
return 1
fi
brew install figlet
fi
if [ -z "$1" ]; then