Experimental French corvette Créole sails furling

Discussion in 'Programming' started by evening, Jul 28, 2022.

  1. evening

    evening
    Expand Collapse

    Joined:
    Jun 17, 2018
    Messages:
    30
    Well guys I'm working on this vehicle for a while now, everything is done by me alone from the textures to the coding, the model is finished and all the basic functions the same, I managed to write two set of LUAs using the original content as reference but I reached a cul de sac.

    I'd love to be able to furl (wrap up around the yeards) the sails, I tried doing it using hydros on the vertical axis beams but without diagonal beams the sail is too floppy and doesn't feel under tension, rigidifing the shape through diagonals makes it react perfectly to the wind but doesn't allow me to furl them using hydros.

    I thought about that problem for a longer time that I'd like to admit and I thought about solving it this way, I wouldn't have animations but it's better than nothing:
    I - LUA switching coltris drag coefficient from spread out value to let's say 0.1 when a key is pressed
    II - placing both a spread out mesh and a furled up mesh, switching the sail material/texture to an alpha texture for the spread out sail and doing the opposite (alpha to base material) for the furled up sail mesh, basically switching them from view without reloading the vehicle

    I'm pretty sure the second point is possible, it's basically the same dynamic as DeformGroups changing material on impact but controlled by a key, I'm not sure about the first point, is it possible to change coltris values dynamically?

    And well I don't have any clue how to write that lol so if anybody has ideas on how to deal with this and/or is willing to help I'd love that person with my whole heart because that's the last barrier before finishing this mod, so thanks in advance!

    P.S. I'm attaching a link to the mod developement thread, I hope it doesn't break the rules and I don't want to self-promote but it's faster than attaching the pictures again here:
    https://www.beamng.com/threads/french-corvette-créole-1827.86231/
     
    • Like Like x 1
  2. evening

    evening
    Expand Collapse

    Joined:
    Jun 17, 2018
    Messages:
    30
    Got it done, no help needed anymore!
     
  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