From a356d60b2bea3b3c864a1168214dbd0987fd7583 Mon Sep 17 00:00:00 2001 From: Lorenzo Torres Date: Sat, 30 Aug 2025 18:52:06 +0200 Subject: first commit --- content/_index.html | 6 +- content/community.md | 5 -- content/development.md | 45 ----------- content/docs.md | 9 --- content/docs/modding.md | 62 -------------- content/faq.md | 1 + content/projects.md | 1 + layout/feed.xml | 2 +- layout/item.html | 4 +- layout/list.html | 4 +- layout/page.html | 28 ++----- layout/post.html | 2 +- makesite.py | 13 +-- pull | 2 +- static/css/style.css | 209 +++++++++--------------------------------------- 15 files changed, 55 insertions(+), 338 deletions(-) delete mode 100644 content/community.md delete mode 100644 content/development.md delete mode 100644 content/docs.md delete mode 100644 content/docs/modding.md create mode 100644 content/faq.md create mode 100644 content/projects.md diff --git a/content/_index.html b/content/_index.html index 4d4634f..ec6d28f 100644 --- a/content/_index.html +++ b/content/_index.html @@ -1,5 +1 @@ - -

Sideros

-

-Sideros is a real-time strategy game set in ancient history. -

+ diff --git a/content/community.md b/content/community.md deleted file mode 100644 index 6053898..0000000 --- a/content/community.md +++ /dev/null @@ -1,5 +0,0 @@ - - -# Community - -## TODO diff --git a/content/development.md b/content/development.md deleted file mode 100644 index 9b02f7b..0000000 --- a/content/development.md +++ /dev/null @@ -1,45 +0,0 @@ - - -# Development - -Sideros development is email-driven, as contributions, discussions and logs all take place on specific automated mailing lists. - -## Mailing lists - -Mailing lists are automated, to subscribe just send an email to -``` -list-name at lists.sideros.org -``` -putting `subscribe` in the mail body. -Please note that some clients usually send emails with html by default, you should ensure to send plain-text emails instead, otherwise commands will not be parsed correctly. - - -Here is a list of the development related mailing lists: - - - - - - - - - - - - -
List nameDescription
patchSend git patch files, see Contributing for more info.
git(Read-only) commit logs are automatically sent here.
- -## Contributing - -Documentation for contributors is available in the source tree, under the [`documentation/`](https://git.sideros.org/sideros/tree/documentation) directory. Once you got a modification you want to send, create a commit using git and generate a patch file with the following command: -``` -$ git format-patch -M origin/master -``` -and when you have the patch file send it to the `patch` mailing list, possibly using `git send-email` like this: -``` -$ git send-email *.patch -``` - -## Bugs - -We use [Bugzilla](https://bugs.sideros.org) to track issues and feature requests. You can create an account there and subscribe to specific bugs to get emails with updates. diff --git a/content/docs.md b/content/docs.md deleted file mode 100644 index aeac7f5..0000000 --- a/content/docs.md +++ /dev/null @@ -1,9 +0,0 @@ - - -# Documentation - -## Table of contents - diff --git a/content/docs/modding.md b/content/docs/modding.md deleted file mode 100644 index 2f07d4b..0000000 --- a/content/docs/modding.md +++ /dev/null @@ -1,62 +0,0 @@ - - -# Modding - -A mod is a special plugin that can do things that alter the experience of the game. - -## Making your own - -Any mods that need to be compiled for a 32 bit WASM freestanding environment. - -### Mod exported functions - -A mod **MUST** provide atleast 2 functions: `init` and `deinit` -The signatures are: -- `uint64_t init(uint32_t modID)` -- `uint64_t deinit()` -The return values of `init` and `deinit` are results. Any non zero result will abort `sideros` and have the exit code of the result -This `modID` parameter in `init` is used in some engine functions. (See [engine functions](#engine-functions) for more) - -#### init -The `init` function is the first function called in a mod and is used for setting up variables, initializing a memory manager and defining [systems](#systems). - -#### update -There's no formal definition of an `update` function but you can emulate an update function by hooking on `render` (See [hooking](#hooking) for more info on how to do this) - -#### deinit -The `deinit` function is the last function called in a mod and is used for deleting the defined memory managers and deleting the defined systems - -### Engine functions - -There are a couple of functions you can use. (All of them have to be defined with the IA32 Cdecl + [system-V (Subsection 3.2.3)](https://refspecs.linuxbase.org/elf/x86_64-abi-0.99.pdf) calling convention): -#### Logging -- `void logDebug(const uint8_t* string, uint64_t length)` -- `void logInfo(const uint8_t* string, uint64_t length)` -- `void logWarn(const uint8_t* string, uint64_t length)` -- `void logErr(const uint8_t* string, uint64_t length)` - -The `logDebug` function is only executed if the `sideros` binary **AND** the mod itself are compiled in debug mode. - -Each of these logging functions will print either until a null character has been found, or the length is exhausted. -They will also print a special identifier in front of them with their logging level (So [DEBUG] for logDebug, [INFO] for logInfo, ...) - -#### Hooking functions -- `void hook(uint32_t modID, uint32_t functionID)` - -### Systems - -TODO - -### Hooks - -Hooks are special in a way that they can latch on to a function in the engine and be executed when that function is called. -See [this](#hooking-functions) for function signatures. - -#### Special information -All hooks have a special parameter refered to internally as `deltatime` this is just the time how long it took between the previous call and this call. -As modders you must make sure there is a `main.zig` file in the tar root, otherwise the mod will be marked as invalid and will crash sideros. - -## Installing mods - -Installing mods can be done by copying the produced and/or downloaded .tar file to the $SIDEROS_PATH/assets/mods directory. -All .tar files in that directory will be loaded and ran. \ No newline at end of file diff --git a/content/faq.md b/content/faq.md new file mode 100644 index 0000000..075e196 --- /dev/null +++ b/content/faq.md @@ -0,0 +1 @@ + diff --git a/content/projects.md b/content/projects.md new file mode 100644 index 0000000..5a9c5cb --- /dev/null +++ b/content/projects.md @@ -0,0 +1 @@ + diff --git a/layout/feed.xml b/layout/feed.xml index 3c9e4b0..89cf8c9 100644 --- a/layout/feed.xml +++ b/layout/feed.xml @@ -4,7 +4,7 @@ {{ title }} {{ site_url }}/ -Real-time strategy game set in ancient history +Lorenzo Torres' personal website {{ content }} diff --git a/layout/item.html b/layout/item.html index 0a1b712..4fb8500 100644 --- a/layout/item.html +++ b/layout/item.html @@ -1,10 +1,10 @@ diff --git a/layout/list.html b/layout/list.html index 79a6aab..552fb35 100644 --- a/layout/list.html +++ b/layout/list.html @@ -1,5 +1,5 @@ -

{{ title }}

+

Blog

{{ content }}
-RSS +rss
diff --git a/layout/page.html b/layout/page.html index 4cbc171..f300dbe 100644 --- a/layout/page.html +++ b/layout/page.html @@ -11,32 +11,18 @@ -
+
{{ content }} -
- - + diff --git a/layout/post.html b/layout/post.html index f0a42be..bd5beb3 100644 --- a/layout/post.html +++ b/layout/post.html @@ -1,5 +1,5 @@

{{ title }}

-

Published on {{ date }} by {{ author }}

+

published on {{ date }}

{{ content }}
diff --git a/makesite.py b/makesite.py index 2a22534..a42a437 100755 --- a/makesite.py +++ b/makesite.py @@ -207,25 +207,14 @@ def main(): blog_posts = make_pages('content/blog/*.md', '_site/blog/{{ slug }}/index.html', post_layout, blog='blog', **params) - news_posts = make_pages('content/news/*.html', - '_site/news/{{ slug }}/index.html', - post_layout, blog='news', **params) - docs = make_pages('content/docs/*.md', - '_site/docs/{{ slug }}/index.html', - page_layout, **params) # Create blog list pages. make_list(blog_posts, '_site/blog/index.html', - list_layout, item_layout, blog='blog', title='Blog', **params) - make_list(news_posts, '_site/news/index.html', - list_layout, item_layout, blog='news', title='News', **params) + list_layout, item_layout, blog='blog', title='Lorenzo Torres | Blog', **params) # Create RSS feeds. make_list(blog_posts, '_site/blog/rss.xml', feed_xml, item_xml, blog='blog', title='Blog', **params) - make_list(news_posts, '_site/news/rss.xml', - feed_xml, item_xml, blog='news', title='News', **params) - # Test parameter to be set temporarily by unit tests. _test = None diff --git a/pull b/pull index cb73aa3..e6c0f94 100755 --- a/pull +++ b/pull @@ -2,4 +2,4 @@ git pull make site -cp -r ./_site/* /var/www/html/ +cp -r ./_site/* /var/www/htdocs/ diff --git a/static/css/style.css b/static/css/style.css index 36f78c0..e900c8c 100644 --- a/static/css/style.css +++ b/static/css/style.css @@ -1,189 +1,54 @@ -:root { - --text: #140100; - --background: #fbf4f4; - --primary: #781212; - --secondary: #eb807a; - --accent: #f74e45; -} - -:root[data-theme="light"] { - --text: #140100; - --background: #fbf4f4; - --primary: #781212; - --secondary: #eb807a; - --accent: #f74e45; -} -:root[data-theme="dark"] { - --text: #ffeceb; - --background: #0b0404; - --primary: #ed8787; - --secondary: #851a14; - --accent: #ba1108; -} - -/* General */ -body { - margin: 0; - line-height: 1.5em; - color: var(--text); - font-family: helvetica, arial, sans-serif; -} - -img { - max-width: 100%; - height: auto; -} - -h1, h2, h3, h4, h5, h6 { - margin-bottom: 0; - line-height: 1.2em; - margin-top: 1em; -} - -a:link, a:visited { - color: var(--text); - text-decoration: underline; -} - -a:hover, a:active { - color: var(--accent); - text-decoration: underline; -} - - -table { - border-collapse: collapse; -} -th, td { - border: 1px solid #ddd; - text-align: center; - padding: 8px; -} -th { - padding-top: 12px; - padding-bottom: 12px; - text-align: left; - background-color: var(--primary); - color: white; -} - -/* Single column layout */ -nav section, header section, main, footer section { - max-width: 40em; - margin-left: auto; - margin-right: auto; - padding: 0 0.5em; -} - - -/* Navigation panel */ -nav { - background: var(--primary); - border-bottom: thin solid #111111; - line-height: 3em; -} - -nav a { - margin-right: 1em; - font-weight: 2em; -} - -nav a:link, nav a:visited { - color: white; - text-decoration: none; -} - -nav a:hover, nav a:active { - color: var(--secondary); - text-decoration: none; - font-weight: 2em; -} +@media (prefers-color-scheme: dark){ + body { + background:#000; + color: white; + } -@media screen and (min-width: 600px) { - nav .links { - float: right; - } + .content a { + color: black; + } } - - -/* Footer */ -footer { - background: var(--primary); - border-top: thin solid #e0e0e0; - margin-top: 2em; - padding: 1em 0; - box-shadow: 0 100vh 0 100vh #f0f0f0; - text-align: center; +body{ + margin: 0; + font:1.2em/1.62 sans-serif } - -footer section p { - font-size: 0.8em; - color: white; +h1,h2,h3 { + line-height:1.2 } - -footer a { - margin-right: 1em; - color: white; +@media print{ + body{ + max-width:none + } } -footer a:last-child { - margin-right: 0; +#menu { + margin: 0; + clear: both; + color: #069; + overflow: hidden; + background-color: #17a; + display: flex; + padding: 0; } - -/* Posts */ -article { - margin-top: 1em; - margin-bottom: 1em; +#menu a { + padding: 0ex 1ex; + color: #fff; + text-decoration: none; } -article h2 a:link, article h2 a:visited, -article h1 a:link, article h1 a:visited, -.more:link, .more:visited { - color: var(--primary); -} - -article h2 a:hover, article h2 a:active, -article h1 a:hover, article h1 a:active, -.more:hover, .more:active { - color: var(--accent); -} - -p.meta { - margin-top: 0; - font-size: 0.8em; - color: #777777; - font-style: italic; -} - -p.summary { - margin-top: 0.25em; - margin-bottom: 0.25em; -} - -div .more { - margin-top: 0; - font-weight: bold; -} - - -/* RSS */ -.rss { - padding: 0.3em 0.35em; - border-radius: 0.25em; - font-size: 0.75em; - font-weight: bold; +#menu a:hover { + background-color: #069; } -.rss:link, .rss:visited, .rss:hover, .rss:active { - color: #ffffff; - text-decoration: none; +.content { + padding: 1ex; } -.rss:link, .rss:visited { - background: #ff6600; +.content a { + color: white; } -.rss:hover, .rss:active { - background: #ff8822; +.content a:hover { + color: #069; } -- cgit v1.2.3