User Tools

Site Tools


arma2:missions:random-mission-design

ArmA 2 Random Mission Design

ArmA 2 Forum, ArmA 2 Home, ArmA 2 Config, ArmA 2 File Formats, ArmA 2 Missions, ArmA 2 3D Modeling, ArmA 2 Scripting, ArmA 2 Terrain, ArmA 2 Texturing, ArmA 2 Tools

This is bit incoherent rambling type page, but it has some good info while its not a tutorial by any means.

How do you setup your random missions, here are some issues, solutions and thoughts etc.

CfgWorlds Class Names / Locations

class names is used to extract location data from the terrain config to be used in mission.

All terrains should have class names setup (locations), but some idiot modders do not include them. Then there are of course the very rare cases which do not have any location names, like desert_e in Operation Arrowhead, but I don't really think many people are doing missions for it anyways.

CenterPosition

class CenterPosition is used to extract terrain's center location (ie size) location data from the terrain config to be used in mission.

CenterPosition should be what it says, center position of the terrain.

All terrains have this but it is no way certain that it actually is the center position, many modders just leave it to what ever they copy pasted the config or put it to some “nice” location on terrain.

Config Problem

If you rely on getting information from class names or class centerposition, then you might run out of luck very quickly. If terrain has been configured properly with both of these then great, you're all set for easy mission making, however as said often the case either one of these is unusable due class names missing or centerposition in totally wrong coordinates.

Mission Editor Design

Place playable units and respawn_ markers into top-right corner which is the furthest place in the terrain.

Then use scripts to determine the terrain area by looking the player coordinates as the maximum coordinates.

Pros:

  • choosing starting locations for each side. easy, just place gamelogic or whatever you choose to mark them
  • getting terrain size is easy, just check playable (player) unit coordinate which is the max

Cons:

  • somewhat hardcoded method
  • mission cannot be copied easily to different sized terrains as it requires mission editor work
  • gamelogic's as position markers is very lame method, especially on large terrains with 100's of gamelogics used

Script Only Design

Place playable units and respawn_ markers into lower left corner close to [0,0,0] position.

Then use script <ctrlMapAnimAdd> system to get terrain area. Check out arma2 missions find terrain size page for details.

Pros:

  • mission can be copied easily to other terrains, just rename file name and you're done, no mission editor work required
  • no need for 100's of gamelogic's for position markers

Cons:

  • choosing starting locations for each side
arma2/missions/random-mission-design.txt · Last modified: 2024/08/01 21:30 by snakeman

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki

All PMC web site download services are temporarily suspended until web site yearly fees have been recovered, want to download addons/mods? Then Support PMC.

If you are grateful for all the work PMC has done in the past 25 years, use Support PMC page.