SOLVED Hide AC_CREW objects?

Discussion in 'Tracks' started by Gunnar333, May 29, 2020.

  1. Gunnar333

    Gunnar333 Well-Known Member

    Joined:
    Aug 5, 2017
    Messages:
    321
    Likes Received:
    618
    Location:
    Germany
    I was wondering if anybody has a solution for the following situation:

    We can name an object: AC_CREW_0_xxx, AC_CREW_1_xxx, AC_CREW_2_xxx, etc....
    These objects will appear only when these teams/cars are loaded in game.

    Is there a way which do the opposite? Like when team 1-3 is in game these objects will be hidden?

    I want to make pit garage doors which are open when team is in game and closed when not.
     
  2. Johnr777

    Johnr777 Moderator

    Joined:
    Jul 26, 2017
    Messages:
    1,050
    Likes Received:
    615
    There might be a way... but dont quote me on it, all theory.

    What if you do 2 objects for the door, one name AC_CREW etc... and the other whatever object name you want.

    Same material for both - with alpha properties.

    Have the AC CREW kn5 carry the texture with black alpha channel, and the non AC CREW kn5 carry another texture with white alpha.

    If you prioritize the AC CREW in models.ini, it should use its texture first, therefor, no garage door.
     
  3. Gunnar333

    Gunnar333 Well-Known Member

    Joined:
    Aug 5, 2017
    Messages:
    321
    Likes Received:
    618
    Location:
    Germany
    Sounds like a good idea. This might work. I will fiddle around - let's see...
     
  4. luchian

    luchian Administrator Staff Member

    Joined:
    Jun 3, 2014
    Messages:
    3,007
    Likes Received:
    1,493
    I also wanted this for my track. I tried with lods, I failed :lol:.

    @Johnr777 's idea is much more intelligent, it might work! Please post if you succeed :D
     
  5. Gunnar333

    Gunnar333 Well-Known Member

    Joined:
    Aug 5, 2017
    Messages:
    321
    Likes Received:
    618
    Location:
    Germany
    Just did my first test. And I can say: SUCCESS!!!
    It works exact the way @Johnr777 suggested.
    I will post some screens and more details soon.
     
    Johnr777 and luchian like this.
  6. Gunnar333

    Gunnar333 Well-Known Member

    Joined:
    Aug 5, 2017
    Messages:
    321
    Likes Received:
    618
    Location:
    Germany
    So here we go. How to do open closed pit garages step by step:
    1. Create two garage door objects for every garage pit slot. And assign the same material to all of them.
      GarageDoors.jpg
    2. Create two textures with alpha channel, one for open, one for closed door
      Textures.jpg
    3. name all objects you'll use for open doors: AC_CREW_0, AC_CREW_1, AC_CREW_2, etc... and assign the open garage texture to them
    4. name all the objects for closed doors how you want (I used: GD_0_closed, GD_1_closed, GD_2_closed, etc...) and export these to a new fbx, load it in ks Editor and apply the closed garage texture to them.
      So all closed and open garage doors do have the same material but with two different textures.
      Export a closedgaragedoors.kn5
    5. in models ini load closedgaragedoors.kn5 after your kn5 with open doors

      Sounds a bit complicated but it works.
      Screenshot_ks_lamborghini_huracan_gt3_g333_sachsenring_31-4-120-13-31-18.jpg Screenshot_ks_lamborghini_huracan_gt3_g333_sachsenring_31-4-120-13-30-49.jpg
     
    ChicAnne, AccAkut and luchian like this.
  7. luchian

    luchian Administrator Staff Member

    Joined:
    Jun 3, 2014
    Messages:
    3,007
    Likes Received:
    1,493
    Man, this is so awesome. I know it's just a thing that many will not care, but I feel very excited about it! Thank you for sharing. Always pushing forward, awesome guys you are :nerd:
     
    ChicAnne, Johnr777 and Gunnar333 like this.
  8. Johnr777

    Johnr777 Moderator

    Joined:
    Jul 26, 2017
    Messages:
    1,050
    Likes Received:
    615
    Glad I could help :)
     
    Gunnar333 likes this.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice