Comments (10)
A good starting point would be parsing the .rms files which generate the random maps (they can be found in the Random
folder in the original game folder). Most of the commands used there could be extended to infinite maps, though we obviously want normal maps to work as well. I'd like to gradually implement the commands found in the .rms files, and compare the resulting maps with the original game.
We now have a perlin noise generator in python, and the RNG in c++. Where should the map generation itself live? Maybe parse the .rms files in python, and generate the map itself in c++?
Some other points:
- There are some resources on random map generation in AOE2, but that's mainly on the scripting aspect, and not how the game uses these scripts to generate the map. Does anyone know of more documentation on the map generation?
- If we want to extend the random map scripts with new commands, we might want to create our own format for it, but I'm not sure we'd need that. Also, if we get our own format, I'd prefer for the game to be able to still read .rms files, and not forcing the script maker to convert it first somehow, to make it easier for script makers.
- For easy map generation testing, it would be very nice to be able to get a screenshot of the map without starting the game, but this is probably very hard. The original game also has a (kinda bad) full-map-screenshot utility with
Control+F12
.
So, let me recap my main questions:
- Where should the code go? Parsing in python, and generation in c++?
- Any known documentation on AOE2 map generation? (Edit: there's a lot!)
from openage.
keep in mind that system-provided rand() are not portable in a sense that each system can provide it's own (p)rng. implementation of own prng would likely be required. have a look at lcamtuf's paper for inspiration: http://lcamtuf.coredump.cx/oldtcp/tcpseq.html
from openage.
A deterministic random number generator that is synced across all multiplayer clients is absolutely essential, of course. De-syncs were the main issue during age2's development. Map seeds and game session seeds would be an essential step.
from openage.
RNG here #191
from openage.
Maybe we could generate a random map in AoE2, then save the game, and after thta load the terrain data from the savegame. These guys could help us in "decompiling" (I'm not sure if we need this) the running binary so we can get more info about the generation.
from openage.
We don't really need to exactly replicate the original generation, it just has to be at least as good, if not better.
edit: I misunderstood your comment. Yeah, looking at the savegame would help if it wasn't clear what is being generated, but I expect that just looking at the map with fog of war turned off will be enough.
from openage.
http://exupero.org/hazard/post/islands/
https://github.com/exupero/islands
from openage.
https://flafla2.github.io/2014/08/09/perlinnoise.html
from openage.
Pretty interesting stuff how to generate fair map seeds while staying with the so loved randomness of AoE.
Dire Straits is built using a different process than a typical AoE2 map in order to generate unpredictable geography while validating each map with a computer program to keep things fair for both teams. For more information about how to create maps like this, including the source code for all the programs used, see this guide:
Dire Straits & creating random RM maps.pdf
from openage.
Documentation and utilities for writing Age of Empires II: DE random map scripts
https://github.com/hungarian-notation/rms-toolkit
from openage.
Related Issues (20)
- "error: βDictβ is not a member of βnyanβ" during build HOT 7
- Can't build with clang, error: "jthread is supported now, remove custom definition" HOT 4
- Asset conversion issue, AttributeError: 'NoneType' object has no attribute 'readable' HOT 6
- Adding PR/ISSUE Templates for this repo HOT 7
- Asset path type is incorrectly used HOT 5
- error: Couldn't find qml root folder HOT 15
- Test fail when building with GCC 13.2.1 HOT 10
- Error launching game, uncaught exception(s) HOT 25
- openage game: error: the following arguments are required: --modpacks HOT 4
- Running Error on Mac osx 13.4(Macbook M1 Pro ARM architecture) HOT 1
- FATAL: terminate has been called uncaught exception std::exception of type std::__1::system_error: thread::join failed: Invalid argument HOT 2
- Multiple cmake issues when trying to build HOT 4
- Submission to Steam HOT 2
- OpenGL error when launching on Wayland HOT 11
- CMake can't find toml11 on Linux Mint 21.2 HOT 4
- Errors after the new PR merged HOT 3
- Link on website https://openage.sft.mx/ to windows packages is a broken link HOT 2
- Windows Build: Python Command Requiring --modpacks Argument HOT 3
- Asset conversion stalls on media conversion HOT 10
- Fix Ubuntu Dependency installation script HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from openage.