Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > IL-2 Sturmovik: Cliffs of Dover > FMB, Mission & Campaign builder Discussions

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #16  
Old 09-14-2011, 05:02 AM
fearlessfrog fearlessfrog is offline
Approved Member
 
Join Date: Jul 2010
Posts: 64
Default

Quote:
Originally Posted by Das Attorney View Post
Thanks for the hard work and research on these scripts. Some really awesomesauce going on in this thread.

I was wondering if someone could help me though. I'm using naryv's script to dispatch ambulances etc in a MP dogfight. There's also AI planes that periodically spawn and then land. The problem is that everytime an AI plane lands, fire trucks etc will spawn and eventually lag the game out.

Is there a way of limiting the spawn to just players?

I used to do scripting for Arma 2 (sqf) and the following would be appropriate to filter out AI:

PHP Code:
if (_x == playerthen
{
     
// code 
}; 
I'm not used to C# yet and don't know the syntax well at this point. How could I filter out the AI so firetrucks etc only spawn and deploy for human controlled planes?

I've looked in the examples, but I can't 'get it' yet. I know you're busy guys so even a basic example/link would get me started.

Thanks
On a quick peek, I think there may be a bug around line 212, i.e. this bit:

Code:
                        if (!CurTechCars.Contains(TmpCar))
                             CurTechCars.Add(TmpCar);
                        MissionLoading = false;
..in that it's adding new cars even if they exist as it doesn't find a match for the existing object.

Another way to do this would be an 'if (CurTechCars.count < MAX_CARS) in before the CurTechCars.Add(TmpCar)

Hopefully that's a few clues, as I'm away from a computer (typing this on a pad)
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:38 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.