#11
|
|||
|
|||
you misunderstand me..the AI i am talking about are player abandoned air craft not scripted AI
__________________
Gigabyte Z68 Intel 2500K (@4.3 ghz)212 CM Cooler 8GB Ram EVGA 660SC (super clocked) 2GB Vram CORSAIR CMPSU-750TX 750W 64 GB SSD SATA II HD WIN7 UL 64BIT |
#12
|
|||
|
|||
Sample use of triggers to load a new mission into current one.
Quote:
It does not work on static objects completely as intended but works for aircraft I think. File attached |
#13
|
||||
|
||||
Spawn/despawn script is kinda "incomplete" and causes unwanted behavior: plane instantly disappearing on bail out or plane disappearing when single member of crew leaves the plane (i.e. one of bomber gunners leaves the plane) while other members are still inside.
Additionally checking if plane is manned before "killing" it should help with multicrew plane despawns. Bail out despawns probably will be a lot tricker. |
#14
|
|||
|
|||
Attention mission makers! A person from dev team told we can put AA guns on oil tankers at other forums. This means we can have some sea battles going on in the channel )) or coastal airfields attacked from sea.
Can not try it myself yet. Last edited by Ataros; 04-19-2011 at 02:22 PM. |
#15
|
|||
|
|||
Quote:
|
#16
|
||||
|
||||
Script for despawning planes without humans inside. Multicrew friendly.
Code:
using System; using maddox.game; using maddox.game.world; using System.Collections.Generic; public class Mission : AMission { public void _DespawnEmptyPlane(AiActor actor) { if (actor == null) { return;} Player[] Players = GamePlay.gpRemotePlayers(); bool PlaneIsEmpty = true; foreach (Player i in Players) { if ((i.Place() as AiAircraft) == (actor as AiAircraft)) { PlaneIsEmpty = false; break; } } if (PlaneIsEmpty) { (actor as AiAircraft).Destroy(); } } public override void OnPlaceLeave(Player player, AiActor actor, int placeIndex) { base.OnPlaceLeave(player, actor, placeIndex); Timeout(1, () => { _DespawnEmptyPlane(actor); }); } } } Last edited by ZaltysZ; 04-20-2011 at 06:26 PM. Reason: Code change |
#17
|
|||
|
|||
WOW! Thanks a lot!!!
|
#18
|
|||
|
|||
Quote:
the selection will be under cargo
__________________
Gigabyte Z68 Intel 2500K (@4.3 ghz)212 CM Cooler 8GB Ram EVGA 660SC (super clocked) 2GB Vram CORSAIR CMPSU-750TX 750W 64 GB SSD SATA II HD WIN7 UL 64BIT |
#19
|
|||
|
|||
thank you Zalty does this replace the original script?
__________________
Gigabyte Z68 Intel 2500K (@4.3 ghz)212 CM Cooler 8GB Ram EVGA 660SC (super clocked) 2GB Vram CORSAIR CMPSU-750TX 750W 64 GB SSD SATA II HD WIN7 UL 64BIT |
#20
|
|||
|
|||
Did you upload your mission somewhere? Could I have a look at it in FMB?
|
|
|