Op2extra
From OPU Wiki
This library contains a new unit class, that allows the programmer to do more sophisticated AI actions, then with the standard Unit class.
To use the extra functionality download the Op2extra_10.zip (http://www.wiki.outpost-universe.net/images/f/f2/Op2extra_10.zip) libraries and headers.
Using the op2extra library
Op2extra declares a new class called IUnit (for Internal Unit class). Include the header in your source file when you want to use the new units functions:
#include "IUnit.h"
From there on, you can just substitue any occurence of Unit with IUnit. All standard member functions will still work, and you can use the new IUnit as a param for other procedures, such as TethysGame::CreateUnit(...), your code, nor Outpost2 can tell the difference.
- do NOT include commands.h - IUnit.h already includes it;
- make sure IUnit.h can find the Outpost2dll.h > put the path into your project setup for additional headers paths;
- include IUnit.lib into your project as well: either by inserting it in your project settings as an additional library, or by just putting the lib into your source file's list
How to use the new class
For a brief description of all the new member functions go to IUnit.h in the SDK section.
Running missions using IUnit
To run an IUnit-mission you will need op2extra.dll in your main Outpost2-folder. When distributing a mission that utilizes the new IUnit class, be sure to include op2extra.dll into the package, otherwise other people cannot run your mision.
