Sleipnir wrote: ↑Take a look at
GDI01 for setting up the gunboat like you want.
The GDI02 / NOD01 / NOD03 missions have also been scripted in lua, and can be found one directory up from there.
You can set initial stances, and also specify specific activities like hunt from within the map script.
Can you provide a bit of code as an example? From GDI01 I could only find a simple script where the gunboat spawned, moved to the edge, dissapeared and came back for another run - it seems to involve two scripts. I need something really simple:
- an actor, say Actor01: 3tnk needs to patrol between Waipoint01 and Waypoint02. It moves from one point to another. See below:
Here is a picture of Nod Mission 02:
I also attached the Mission to this post... details are below:
Briefing
Brother, the prophet Kane has tasked you with the capture of the Voroshilov weapons research and production facility. With this asset, the Brotherhood will be able to stage attacks all through Europe, and fulfill our leader's vision. Locate the base and capture the Forward Command Center.
You will be deployed near a small town servicing the facility. "Persuade" the civilians to "relocate" by any means available, and establish a base at that location. Our newest experimental weapon, the Devil's Tongue flame tank will be made available to you during this mission.
For the Brotherhood!
What I need scripted:
- Mission briefing displayed before mission starts
- Mission accomplished: Capture FCOM (forward command centre)
- Mission failed: Destroy the above mentioned buildings / lose your base.
- Soviet AI will deploy attacks at 4 minute intervals, consisting of three 3tnk, two E4 and three E1.
- Soviet AI must attempt to rebuild destroyed base defences and buildings.
- Soviet units patrol the area like shown in the picture above.
if anyone could provide a bit of code for these functions, I will be forever in your debt (an of course, you will be mentioned in the credits )
Could you please provide some traits for a given actor in the map script? So far, I only got:
Actor Name: Actor type (from rules.ini)
Location: x,y
Owner:
Health:
Facing:
SubCell:
What can I add to this to make a unit guard an area (it moves to attack an enemy unit it detects) - because so far they just stay there. They will attack if you are in range, but they will not pursue, and if you attack with a unit that has a longer weapon range, it will just sit there with it's turret pointed at the attacker
Also, the AI in campaign mode seems to do NOTHING. How can I get it to start building units, replace destroyed buildings and stuff like that? Can I assign a multiplayer hacky@ai to it?[/img]
After looking trought Allies03 mission, I noticed it has a 'MissionObjectivesPanel". Also found a reference to that trait in the Traits page for openra, but no arguments / instructions on how to use it. Where do I add the mission briefing? How do I use the MissionObjectivesPanel?