Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 407 408 [409]

Author Topic: Future of the Fortress  (Read 3154326 times)

astix

  • Escaped Lunatic
    • View Profile
Re: Future of the Fortress
« Reply #6120 on: December 04, 2024, 03:06:32 am »

Congrats Toady! I Wish you and your beloved many happy memories together.

After that, for even some basic things I want to do with magic, I require multi-step scripts that can refer back to variables and so forth, and it was just looking like I needed to make a scripting language.  And that would be too much, when scripting languages exist when a history of use in games, which also solve the forgotten beast problem.  So we arrived here.  The happy world of scripts generating scripts using a standard scripting language.
[..]
As long as it remains performant, we'll just keep expanding over time, and try to make new features compliant immediately if large problems don't arise, etc.  Currently optimistic!

1. Raws generation for the initial release, but it gives us the opportunity for run-time use down the road, since it's already in the system.
[..]
One-based indexing is absolutely hideous, maximum engineer-brain, and much of the code I've written so far demonstrates its ugliness fantastically
[..]
4. Which ones? The Lua systems you see here are already old systems rewritten to use Lua, the code included in the game is all code that used to be in C++.


I thought I'd just leave this here, in case the option was not known:


https://root.cern/cling/ :
Quote
Cling is an interactive C++ interpreter, built on the top of LLVM and Clang libraries.
https://github.com/root-project/root/tree/master/interpreter/cling :
Quote
Cling implements the read-eval-print loop (REPL) concept, in order to leverage rapid application development. Implemented as a small extension to LLVM and Clang, the interpreter reuses their strengths such as the praised concise and expressive compiler diagnostics.

I believe Cling is the fastest interpreter available - faster than LUA? - as Cling is used by CERN as a faster alternative to the old CINT of the Root project. Cling is no doubt stress tested on algorithmic-y code, similar to procedural generation algorithms.

Cling is licensed under LGPL by CERN. This means it can be used in DF:
https://github.com/root-project/root/blob/master/interpreter/cling/LICENSE.TXT

The original Clang is licensed under the permissive Apache 2.0 license these days which is also fine for use in DF: https://github.com/llvm-mirror/clang/blob/master/LICENSE.TXT

Use of Cling/Clang basically allows embedding a interpreter/compiler within DF. It should allow scripts to generate code which are then compiled to DLLs to get the fastest performance. For example, this could allow scripts during world generation to create compiled code that runs when the game is played. All in C/C++.

There are LUA to C++ machine translators, if there's code that's been moved to LUA and improved for the magic system already.

These tools might also be good for "rapid application development" in DF, as advertised - think quickly copying a function from compiled space into scripting space, then rapidly iterating on procedural algorithms without recompiling and restarting each time - then copying code back with no changes needed. Unlike when using LUA.

Just in case you find Cling useful.

As long as it remains performant, we'll just keep expanding over time [..]

As for being performant - I think the limit of scripts creating compiled DLLs might be reduced benefit from whole program optimisation aka Link Time Optimisation. It shouldn't matter that much. With JIT compiled scripts that run during gameplay, performance will be slower.

One impact of performance on general development that is easily overlooked, is if something slows down the time for the testing loop: start the game and test out a change in-game, close, make a change to code or data, then restart and get back into the game. It's something seemingly insignificant, but could make a large impact on development. If the testing loop takes too long people also lose track of their thoughts. This applies even be when iterating on something simple like texture - which could be avoided by having a debug menu to reload assets/scripts. But even testing bugs and saves involves restarting a lot. If world generation is being tested then slowdown due to scripting would be impactful.


Q1: Healing Magic. Will healing magic need substantial rules constraining use in fighting, for the usage to be plausible with what people would do if that magic was available in real life?

It seems magic healing would normally promote the use of "high alpha" weapons - ones that are one-hit-kill or do a debilitating amount of damage. People would sacrifice other aspects of warfare for a chance to take out enemies. They'd use overwhelming force whenever possible. They'd target healers as a priority. They'd focus on anything that prevented healers from applying healing, including disruptive magics and substances if they existed. On the flip-side, people would prioritise protection for healers, and focus on fetch squads to bring the injured to protected healing areas. The rich and the powerful would have an army of healers monopolising rarer healing resources.

As a real world example, in warfare, sometimes armies use horrible debilitating but non-lethal weapons to try to overload medics, to slow down advances, and stop medics from being free to patch up minor injuries to get warriors back up.

Fantasy stories tend to just focus on the protagonist's party or side using healing, and handwave that the societies' focus on healing and disrupting healing is balanced everywhere. DF has the problem that the opponents side and technology could be anything - even Dwarves, and the player could be in a lot of the possible situations. Plausibility aside, players will take advantage of tatics abusing healing, even if the AI won't.

Q2:

As I understand it from following DF over the years:


Spoiler (click to show/hide)


Q2: Is it possible to design, from the start, to separate parts of the myth and magic procedural setup from other elements of world generation? Such that people can use a similar flavour of myth and magic setup on different worlds. Maybe have a combination of parameters outlining the general shape of myth and magic setup, and compartmentalise parts of the myth and magic procedural generation using different PRNG seeds players can copy/paste... Or is everything likely to be causally linked, and un-entagleable?. I'm asking now as it may be hard to change in 4+ years..

Players may like to share interesting myth and magic setups - they may want to view some of the hidden spoilery myth and magic output, and re-roll until they get a acceptable result. Sort of like a "re-generate" button during map generation to get different landmass shapes and types with the same advanced world gen parameters - which also would be a nice feature.



Edit:limegreen for questions only
« Last Edit: December 05, 2024, 02:31:04 am by astix »
Logged

DPh Kraken

  • Bay Watcher
  • [PRONOUN:she:her:herself][PRONOUN:it:its:itself]
    • View Profile
Re: Future of the Fortress
« Reply #6121 on: December 04, 2024, 08:53:55 pm »

- Will future updates in addition to new systems also quietly add new "stuff"? As in, not mechanics, but more creatures, minerals, materials etc.

I haven't heard concrete plans to expand the raws, with that energy being focused on generated objects. There's also some issues with the current modding setup that'd have to be sorted out for vanilla to be expanded. Mods have the mods vs installed folder versioning for compatibility, but adding a new object to vanilla right now would break a lot of old saves in a completely preventable manner. I do remember offhand plans for a prehistoric creature pack, at least.

Q2: As I understand it from following DF over the years...
Have you read ThreeToe's Tales Foretold stories? The spoilery, high-power myth stuff is a pretty integral to that setting.
By the way, you might want to just limit the green to the questions you have italicized. The green is more organizational than anything, since all the text here is still part of the discussion.
Logged
[CHEESE_PLANT] and [CHEESE_GRAPHICS] biggest fan
My mods:
Language & symbolsMiscellanyGraphics resourcesPseudo-ASCII

jecowa

  • Bay Watcher
    • View Profile
Re: Future of the Fortress
« Reply #6122 on: December 04, 2024, 10:24:05 pm »

Green text is for the questions for Toady to answer to make it easier to find the questions.
Logged

astix

  • Escaped Lunatic
    • View Profile
Re: Future of the Fortress
« Reply #6123 on: December 05, 2024, 05:26:23 am »

@DPh Kraken: No, I meant to go through the stories on the DF website, but never got around to it.
 
Read the 2 Foretold Tales there just now, thanks :D. The well-realised version of the procedural magic system is going to be amazing!

I can imagine it being combined with the procedural language system.. so ancient knowledge and secrets need research, there are schools of interpretation, and some things get lost in the translation - perhaps deliberately muddled and hidden by those with ulterior motives.
Logged
Pages: 1 ... 407 408 [409]