DESCRIPTION
This gamerule iterates through a list of ships, comparing the performance of
one ship versus the performance of another. Using this method, one can gauge to
some degree of accuracy the relative combat strength of each ship versus the
others.

INSTALLATION
Extract the ZIP archive and copy the "DataPlayBalancingHWRM" folder to your
"Homeworld Remastered" directory. You will also need to edit your command line
in order to get the mod to work properly. This is described in a later section.

INSTRUCTIONS
This mod is a singleplayer campaign made up of only one level. The game starts
with one aggressive CPU player attacking a completely passive CPU opponent. You
then iterate through all of Player 2's ships until they all have been defeated.
Next, you iterate to Player 1's next ship and reset Player 2 to his first ship,
repeating the cycle. When all of Player 1's ship have defeated all of Player
2's ships, the game ends and the results are printed to the log, or to another
file on the disk.

The goal is to compare the time it takes for Player 1's ship to defeat Player
2's ship with the time it took for Player 2's ship to defeat Player 1's ship.
The less time it takes, the more powerful the ship. Some ships don't have any
weapons at all and are skipped.

A value of "NoAttack" means that one or both ships have no offensive weapon and
therefore cannot attack. A value of "TimedOut" means that one or both ships ran
out of time before killing all of the opponent's ships. Currently the timeout
value is 1 hour. A value of "SameShip" means that the Left and Top Ships are
identical, and therefore equal in strength. A value of "Failed" means the
calculation has gone wrong somewhere and needs to be fixed.

You're going to have to modify your command-line in order to get the mod to
run. See the section, below, for an example command-line. Note, that Players 1
and 2 will be doing the actual fighting. You (Player 0) will merely be playing
the part of observer. Simply let the game run until it is finished, and it will
exit by itself. If you run out of memory first, or if the game should stall for
some other reason, just quit the game and modify the configuration settings in
"PlayBalancing_Config.lua" so that you can start right where you left off. Make
sure to check "HwRM.log" for the results of the previous tests so that you can
copy them to somewhere safe. Otherwise, they will be overriden and you will
have to start over from scratch.

IN-GAME TEXT
While running the game you will see some text on the screen:

• Index: the place in the global ShipList table that each ship occupies.
• Count: the place in the current processing queue that each ship occupies.
• Alive: the number of alive ships belonging to Player 1 and Player 2.
• Health: the health of each player's fleet as a percentage of full health.
• Ships: Player 1 and Player 2's ship types.
• Research1: Player 1's researches.
• Research2: Player 2's researches.
• Round Time: the elapsed time in the current mini-battle.
• Game Time: the elapsed time since the start of game according to the game.
• World Time: the elapsed time since the start of game in real time.
• Display Text: a custom message set in "PlayBalancing_Config.lua".
• Script Version: the current version of the Play Balancing script.

Game Time and World Time will be different from each other if you start the
game with the -superTurbo command line switch enabled. Otherwise, they should
be identical.

OUTPUT LOG FILE
The script outputs the results of each mini-battle to a new line in "HwRM.log".
At the end of the game, it also outputs all the cumulative stats to a file
called "PBAL_Results.txt" in your player profile directory. If you exit the
game early, or if the game crashes, this output file will not be written and
you will need to piece together what happened by examining the individual lines
in "HwRM.log".

Here are what the individual fields in the generated output mean:

• P1_ShipNumber: the index number of player 1's ship in ShipList.
• P1_ShipsLeft: the number of player 1's ships left over at the end of a round.
• P1_AvgHealth: the average health of player 1's ships (including dead ones) at
the end of a round.
• P1_ShipType: the type of player 1's ship.
• P1_ResearchList: any research items applied to player 1's ships.
• P2_ShipNumber: the index number of player 2's ship in ShipList.
• P2_ShipsLeft: the number of player 2's ships left over at the end of a round.
• P2_AvgHealth: the average health of player 2's ships (including dead ones) at
the end of a round.
• P2_ShipType: the type of player 2's ship.
• P2_ResearchList: any research items applied to player 2's ships.
• RoundTime: the duration of the battle between player 1 and player 2's ships.
Or a flag indicating why the duration of the battle was not recorded.
• ExtraTime: the amount of time it *would* take (probably) for Player 1 to kill
Player 2 if time were allowed to continue past "TimeOutValue". If none of
Player 2's ships are left alive, or if all of Player 2's ships are at 100%
health, then "ExtraTime" will equal "RoundTime".

THE COMMAND LINE
You will need to edit your command line settings in order to run this mod. This
mod is a singleplayer mod, not multiplayer, so you will need to set the correct
campaign and starting level in the command line. At the very least, you should
use the following flags:

"%HWRM%\Bin\Release\HomeworldRM.exe" -moddatapath DataPlayBalancingHWRM -campaign PlayBalancing -startingLevel testlevel -overrideBigFile -luaTrace -superTurbo -quickLoad

The -superTurbo switch is probably the most important of these, as it allows
you to speed up the game by a factor of about 50. Without it, this sort of
testing would require unbearably long periods of time. It is also handy to run
teh game in a window using the -windowed switch to make the ALT+TAB between
windows easier.

The -quickLoad switch used to be important when running Homeworld 2 Classic,
but I don't think it works for Homeworld Remastered any more.

Post article RSS Articles

STARTING THE GAME FROM A BATCH FILE

Client Side Coding Tutorial

STARTING THE GAME FROM A BATCH FILE
If, like me, you start running out of space in the "Target" field of your
desktop shortcut, you can start the game from a batch file. Here is what one of
my batch files looks like:

	e:
	cd %HWRM%\Bin\Release
	HomeworldRM.exe -overrideBigFile -luatrace -hardwareCursor -w 800 -h 600 -windowed -ssTGA -moddatapath DataPlayBalancingHWRM -freeMouse -traceHODs  -nosound -noMovies -quickLoad  -campaign playbalancing -startinglevel testlevel -superTurbo -logfilename=%HWRM%\Bin\Release\HwRM_left.log
	pause

The first line switches to the E:\ drive, since that is where I have Homeworld
Remastered installed. The second line switches the current working directory
to the "Release" folder, which contains the game's executable. The game won't
start unless you do this first! The third line actually starts the game using
the command line switches you have selected. I actually use more switches than
you see above, since I run multiple instances of the game, and need the game to
write to separate log files. The last line pauses the command prompt window so
that it doesn't disappear right away. If the game quits and there are error
messages, they will appear in the command prompt window.

Note that %HWRM% is an environmental system variable. You can create these
variables to store frequently used strings of text, such as paths to files and
folders that you work on frequently. Here are some instructions on how to use
and set up environmental variables:

Support.microsoft.com

These instructions should be applicable to most versions of MS Windows.

RUNNING MULTIPLE INSTANCES OF THE MOD

RUNNING MULTIPLE INSTANCES OF THE MOD

Client Side Coding Tutorial

If you have plenty of RAM and a multi-core CPU, then you can run multiple instances of Homeworld Remastered. Here's how.

Add file RSS Files
Play Balancing Mod for HWRM v2.4.0

Play Balancing Mod for HWRM v2.4.0

Full Version

Change log for this version is in the file description.

Play Balancing Mod for HWRM v2.3.0

Play Balancing Mod for HWRM v2.3.0

Full Version

The change log for this version is in the download description page.

Play Balancing Mod for HWRM v2.2.0

Play Balancing Mod for HWRM v2.2.0

Full Version

The change log for this version is in file description.

Play Balancing Mod for HWRM v2.1.1

Play Balancing Mod for HWRM v2.1.1

Full Version

CHANGE LOG 2.1.1 --- 2016/08/07 • Added spaces around commas in research lists. • Created a new variable called "MakeImmobile". Enemy ships will now...

Play Balancing Mod for HWRM v2.1.0

Play Balancing Mod for HWRM v2.1.0

Full Version

2.1.0 --- 2016/08/05 • Added the "DisplayText" variable so now you can print some arbitrary text to the screen to stay organized. • Added an example...

Play Balancing Mod for HWRM v2.0.0

Play Balancing Mod for HWRM v2.0.0

Full Version

This gamerule iterates through a list of ships, comparing the performance of one ship versus the performance of another. Using this method, one can gauge...

Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.

Follow Report Profile
Icon
Homeworld: Remastered
Contact
Send Message
Release date
Mod watch
Follow
Share
Community Rating

Average

-

0 votes submitted.

You Say

-

Ratings closed.

Style
Embed Buttons
Link to Play Balancing Mod for HWRM by selecting a button and using the embed code provided more...
Play Balancing Mod for HWRM
Statistics
Last Update
Watchers
2 members
Files
6
Articles
2