Results 1 to 8 of 8

Thread: Disabling an airfield?

  1. #1
    Team Fusion Salmo's Avatar
    Join Date
    Nov 2011
    Posts
    2,332
    Post Thanks / Like
    Total Downloaded
    191.25 MB

    Disabling an airfield?

    ATAG_Collander has asked about a method to disable an airfield. Does this work? I can't get the call to the routine right so haven't been able to check it.

    Code removed by author
    Last edited by Salmo; Oct-18-2012 at 12:33.

  2. #2
    ATAG Member ATAG_Knuckles's Avatar
    Join Date
    Nov 2011
    Location
    Mesa, Arizona
    Posts
    1,657
    Post Thanks / Like
    Total Downloaded
    3.75 MB

    Re: Disabling an airfield?

    Ahhh looks pretty close to me

    DUTCH what do you think :Grin:

  3. #3
    ATAG_Colander's Avatar
    Join Date
    Nov 2011
    Location
    Bir Tawil
    Posts
    11,128
    Post Thanks / Like
    Total Downloaded
    255.73 MB

    Re: Disabling an airfield?

    Salmo,

    To disable the strip you would need to add a line like this:
    airport.StripState(i)=maddox.game.world.AiAirportS tripState.DAMAGED;

    The problem is, that will damage the strip but not the spawn point. If I'm correct, you will still be able to spawn and take off as long as you avoid using that particular strip.

    I could be wrong though. Perhaps I will need to do more testing.

    Colander.

  4. #4
    Dutch
    Guest

    Re: Disabling an airfield?

    Quote Originally Posted by ATAG_Knuckles View Post
    DUTCH what do you think :Grin:
    It's totally double dutch to this Dutch me ole dutch.

    With a smattering of Ancient Greek, some Mandarin and I think I detect a smattering of Arameic, but not sure.

    :blush!:

  5. #5
    ATAG Member ATAG_Knuckles's Avatar
    Join Date
    Nov 2011
    Location
    Mesa, Arizona
    Posts
    1,657
    Post Thanks / Like
    Total Downloaded
    3.75 MB

    Re: Disabling an airfield?

    Quote Originally Posted by ATAG_Dutch View Post
    It's totally double dutch to this Dutch me ole dutch.

    With a smattering of Ancient Greek, some Mandarin and I think I detect a smattering of Arameic, but not sure.

    :blush!:
    Thought so ! I totally concur mate: alright then off to my next mountain top to conqueror. :bgsmile:

  6. #6
    Team Fusion Salmo's Avatar
    Join Date
    Nov 2011
    Posts
    2,332
    Post Thanks / Like
    Total Downloaded
    191.25 MB

    Re: Disabling an airfield?

    Quote Originally Posted by ATAG_Colander View Post
    Salmo,

    To disable the strip you would need to add a line like this:
    airport.StripState(i)=maddox.game.world.AiAirportS tripState.DAMAGED;

    The problem is, that will damage the strip but not the spawn point. If I'm correct, you will still be able to spawn and take off as long as you avoid using that particular strip.

    I could be wrong though. Perhaps I will need to do more testing.

    Colander.
    OK Colander. Two possible solutions?
    1. In the OnPlaceEnter event, check for airfield/spawnpoint runway status (BLOCKED) & do something like destroy the player plane at the spawnpoint until the airfield is available again (Yuck, awful solution )

    or

    2. destroy() the airfield/spawnpoint completely & reload the spawnpoint from a sub-mission after a period of time. (Very clunky )
    Last edited by Salmo; Apr-12-2012 at 08:50.

  7. #7
    Student Pilot Ataros's Avatar
    Join Date
    Apr 2011
    Posts
    26
    Post Thanks / Like
    Total Downloaded
    0

    Re: Disabling an airfield?

    In an archive attached to this message Small_Bee creates and destroys 109E4 and Spit IIa spawn points if this is what you are looking for. http://forum.1cpublishing.eu/showpos...1&postcount=17

    IIRC in one of Naryv examples included in a different archive he also creates and destroys spawns. _allSamples2.zip attached here http://forum.1cpublishing.eu/showpos...07&postcount=1

  8. #8
    ATAG_Colander's Avatar
    Join Date
    Nov 2011
    Location
    Bir Tawil
    Posts
    11,128
    Post Thanks / Like
    Total Downloaded
    255.73 MB

    Re: Disabling an airfield?

    Thanks Ataros.

    From what I see, it looks like a workaround for what I'm asking for (still a good idea).
    If I'm correct, instead of simply enabling/disabling the spawn points, they get destroyed and recreated by re-loading a mission file with the spawn point on it.

    I would like something that does not rely on loading another mission file.


    Thanks again,
    Colander.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •