moved files and added compile script

This commit is contained in:
2024-09-28 15:41:18 +02:00
parent b7c21d0349
commit 6329559748
15 changed files with 36 additions and 23 deletions
+5 -4
View File
@@ -7,7 +7,7 @@ on:
- main
jobs:
pushdoc:
buildandpush:
name: push_file
runs-on: ubuntu-latest
env:
@@ -38,9 +38,10 @@ jobs:
- name: mkdir
run: mkdir -p ./$repo/Spearhead
- run: npm i markdown-to-html-cli -g
- run: markdown-to-html --title 'Spearhead' --dark-mode auto --keywords "dcs,spearhead,tdcs,mission,campaign,tactical dcs,tactical" --no-dark-mode --markdown-style-theme dark --source ./spearhead/docs/$sourcefileA.md --output ./$repo/Spearhead/$sourcefileA.html
- run: markdown-to-html --title 'Spearhead' --dark-mode auto --keywords "dcs,spearhead,tdcs,mission,campaign,tactical dcs,tactical" --no-dark-mode --markdown-style-theme dark --source ./spearhead/docs/$sourcefileB.md --output ./$repo/Spearhead/$sourcefileB.html
- run: cp -a ./spearhead/docs/img/. ./$repo/Spearhead/img/
- run: markdown-to-html --title 'Spearhead' --dark-mode auto --keywords "dcs,spearhead,tdcs,mission,campaign,tactical dcs,tactical" --no-dark-mode --markdown-style-theme dark --source ./spearhead/_docs/$sourcefileA.md --output ./$repo/Spearhead/$sourcefileA.html
- run: markdown-to-html --title 'Spearhead' --dark-mode auto --keywords "dcs,spearhead,tdcs,mission,campaign,tactical dcs,tactical" --no-dark-mode --markdown-style-theme dark --source ./spearhead/_docs/$sourcefileB.md --output ./$repo/Spearhead/$sourcefileB.html
- run: python3 ./spearhead/SpearheadCompile.py "./spearhead" "./$repo/Spearhead/spearhead.lua"
- run: cp -a ./spearhead/_docs/img/. ./$repo/Spearhead/img/
- name: ls
run: ls
working-directory: ./dutchie032.github.io
+13 -16
View File
@@ -2,25 +2,22 @@ import os
import sys
import glob
def CreateReadme():
print("TODO")
def compileClasses(root):
for subFolder in [ "capClasses", "stageClasses"]:
path = os.path.join(root, subFolder)
for name in glob.glob(f"{path}/*.lua"):
with open(path, 'r') as file:
def compileClasses(classesPath):
resultString = ""
for name in glob.glob(f"{classesPath}/**/*.lua"):
with open(name, 'r') as file:
resutlString += file.read()
return resultString
def compile(root, target):
classes = compileClasses(root)
compiled = ""
for filename in Order:
path = os.path.join(root, filename)
with open(path,'r') as file:
fileContents = file.read()
compiled += fileContents
print(path)
compiled += classes
mainFileName = os.path.join(root, "main.lua")
with open(mainFileName, 'r') as mainFile:
string = mainFile.read()
compiled += string
with open(target, "w") as targetFile:
targetFile.write(compiled)
+10 -2
View File
@@ -67,8 +67,16 @@ If no CAP route is present the unit will fly a route generated differently per z
If you want to create you own CAP Routes you can! <br/>
For this example I created 2 CAP routes inside of the 2 `_1_` stages. <br/>
As you can see below there's a nice quick you can exploit. As long as the `X` of the zone is inside of the the `CAPROUTE` will be used!
As you can see below there's a nice feature you can exploit. As long as the `X` of the zone is inside of the the `CAPROUTE` will be used for that stage!
![CAP Routes Image](./img/cap_routes.png)
## Setting up the missions
Now all you need to do is start the mission (single player works just fine) and see the AI fly around. <br/>
Tip: Speeding up the simulation speed to 10x or 15x can help you see how the AI will fly and how it will behave. <br/>
Well, nice, we're don setting up the initial CAP effort. <br/>
If you want to change values for the CAP routes please read about how to configure it here: [Cap Config](./Reference.html#cap-config)
## Setting up the Missions
+7
View File
@@ -124,6 +124,13 @@ If a zone is empty it will not be briefed, activated or count towards completion
### CAP
#### CAP Config:
--[[
TODO: CAP CONFIG
]]
Naming: CAP\_\<"A" | B"\>\<Config\>_\<Free form name\>
##### CAP Group Config:
```

Before

Width:  |  Height:  |  Size: 296 KiB

After

Width:  |  Height:  |  Size: 296 KiB

Before

Width:  |  Height:  |  Size: 260 KiB

After

Width:  |  Height:  |  Size: 260 KiB

View File