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

Reply
 
Thread Tools Display Modes
  #1  
Old 05-08-2012, 08:55 AM
David198502's Avatar
David198502 David198502 is offline
Approved Member
 
Join Date: Dec 2009
Location: Austria
Posts: 1,536
Default patch changes-is it now possible to let ground vehicles&trains disappear(destroy)

is it now possible with the patch, that groundvehicles and trains get destroyed(disappear) when they reach their last waypoint???

im really looking forward for that possibility, as it would spice up my missions.
__________________
Reply With Quote
  #2  
Old 05-08-2012, 09:37 AM
FG28_Kodiak FG28_Kodiak is offline
Approved Member
 
Join Date: Dec 2009
Location: Swabia->Bavaria->Germany
Posts: 884
Default

At the moment it works good for Planes, but i get no Handle to the Waypoitnts of GroundActors nor is GetCurrentWayPoint() working for GroundGroups, at the moment, so its not possible to check if a Groundactor reached it last waypoint.
Reply With Quote
  #3  
Old 05-08-2012, 09:39 AM
David198502's Avatar
David198502 David198502 is offline
Approved Member
 
Join Date: Dec 2009
Location: Austria
Posts: 1,536
Default

thx for your testing and answering Kodiak...a bit disappointing though..hope this will soon be possible, as i would really like to implement "random" life on the ground...
__________________
Reply With Quote
  #4  
Old 05-08-2012, 10:19 AM
Ataros Ataros is offline
Approved Member
 
Join Date: Jun 2010
Location: USSR
Posts: 2,439
Default

onTaskCompleted 'works' on last waypoint as I was told. For aircraft at least, have no idea about ground units.
Reply With Quote
  #5  
Old 05-08-2012, 10:20 AM
David198502's Avatar
David198502 David198502 is offline
Approved Member
 
Join Date: Dec 2009
Location: Austria
Posts: 1,536
Default

according to Kodiak, it doesnt for ground vehicles
__________________
Reply With Quote
  #6  
Old 05-08-2012, 10:26 AM
FG28_Kodiak FG28_Kodiak is offline
Approved Member
 
Join Date: Dec 2009
Location: Swabia->Bavaria->Germany
Posts: 884
Default

GetCurrentWayPoint() is always 0 by Groundactors:
Code:
public override void OnTickGame()
    {
        base.OnTickGame();
        
        AiGroundGroup Group = GamePlay.gpGroundGroups(1)[0];

        if (Group != null)
            GamePlay.gpHUDLogCenter(null, "Waypointnr: {0}", new object[] { Group.GetCurrentWayPoint() });

    }
OnActorTaskCompleted often deliver strange results. But will testing it again. Maybe it works now.

Last edited by FG28_Kodiak; 05-08-2012 at 10:31 AM.
Reply With Quote
  #7  
Old 05-08-2012, 10:34 AM
David198502's Avatar
David198502 David198502 is offline
Approved Member
 
Join Date: Dec 2009
Location: Austria
Posts: 1,536
Default

but what can be considered as task?do the ground objects have to destroy something, or is reaching a waypoint considered as task as well?
__________________
Reply With Quote
  #8  
Old 05-08-2012, 10:54 AM
FG28_Kodiak FG28_Kodiak is offline
Approved Member
 
Join Date: Dec 2009
Location: Swabia->Bavaria->Germany
Posts: 884
Default

Groundactors seems are only counted if reached endpoint.

Ok seems to work, but not for trailers. :\

Code:
    public override void OnActorTaskCompleted(int missionNumber, string shortName, AiActor actor)
    {
        base.OnActorTaskCompleted(missionNumber, shortName, actor);

        if (actor is AiGroundGroup)
        {
            foreach (AiActor ac in (actor as AiGroundGroup).GetItems())
            {
                (ac as AiCart).Destroy();
            }
        }
    }

Last edited by FG28_Kodiak; 05-08-2012 at 10:56 AM.
Reply With Quote
  #9  
Old 05-08-2012, 12:45 PM
Smokeynz Smokeynz is offline
Approved Member
 
Join Date: Apr 2011
Posts: 106
Default

For ground vehicles I've had success with Onactorceated and a Timeout period then destroy

I set about 10-15 minutes longer than units take to reach endoint.

probably still wont remove the trailer though
Reply With Quote
  #10  
Old 06-18-2012, 07:41 AM
David198502's Avatar
David198502 David198502 is offline
Approved Member
 
Join Date: Dec 2009
Location: Austria
Posts: 1,536
Default

Quote:
Originally Posted by FG28_Kodiak View Post
Groundactors seems are only counted if reached endpoint.

Ok seems to work, but not for trailers. :\

Code:
    public override void OnActorTaskCompleted(int missionNumber, string shortName, AiActor actor)
    {
        base.OnActorTaskCompleted(missionNumber, shortName, actor);

        if (actor is AiGroundGroup)
        {
            foreach (AiActor ac in (actor as AiGroundGroup).GetItems())
            {
                (ac as AiCart).Destroy();
            }
        }
    }
hey kodiak,.....i dont know, but for me, it doesnt seem to work.

i created a mission, with a train, a tank and another vehicle, and neither of them seem to get destroyed if they reach their last waypoint....
Ps:what do you mean with trailers?
__________________
Reply With Quote
Reply


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 12:54 AM.


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