Feral Heart

Help & Guidance => Game Help => Topic started by: tinnuvari on June 08, 2016, 07:09:19 pm

Title: Help with Sky Mods
Post by: tinnuvari on June 08, 2016, 07:09:19 pm
I have downloaded a galaxy sky mod. I remember reading somewhere a long time ago that it was possible to make the galaxy mod show up only at night. Is it possible? If so, where do you edit the coding?
I can't seem to figure it out, and there's nothing about it online, so I wonder if it is possible.
Title: Re: Help with Sky Mods
Post by: Hakumi on June 08, 2016, 07:11:45 pm
The only way I can see that happening... Is if the person was making a map and putting that sort of thing in the material file and then setting the time that way.
This is just my guess and I could be horribly wrong.
Title: Re: Help with Sky Mods
Post by: tinnuvari on June 08, 2016, 07:14:47 pm
I wonder if it'd be possible to set the timing? I don't know how long the day/night cycles are, though. I know on the moon phase mod it's set to turn after a certain point of time.
Title: Re: Help with Sky Mods
Post by: Hakumi on June 08, 2016, 07:18:14 pm
For the game itself, maybe not(?) But for a map ( making it ) then yeah. I've been seeing some saying 3Ominutes before the cycle changes.
Title: Re: Help with Sky Mods
Post by: tinnuvari on June 08, 2016, 07:19:40 pm
Okay. I will see if I can at least make a custom sky for our next map. Thank you for your help!
Title: Re: Help with Sky Mods
Post by: Hakumi on June 08, 2016, 07:21:29 pm
No Problem & Good Luck ~!
Title: Re: Help with Sky Mods
Post by: Wyldercat on June 09, 2016, 03:44:49 pm
Well, you can replace the respective sky files in your FeralHeart media folder, I think, so that it appears publicly, but I'm not sure if it would be so easy as to manipulate the timing of the mod. I'm not too familiar with OGRE coding, which the game uses, but maybe if you play around with it in custom a bit, you can have some success.
Title: Re: Help with Sky Mods
Post by: Kynvuu on June 09, 2016, 03:55:43 pm
I want to say that there is a way to do this, because it's just a matter or allowing textures to appear at certain times, though I'm not entirely certain. I'll take a look at the coding for ya in a bit and see if I can come up with anything c:
Title: Re: Help with Sky Mods
Post by: Wyldercat on June 09, 2016, 04:02:18 pm
I've been looking at some scripts myself, and I'm afraid I can't isolate any particular timeset coding, or at least not one I can recognize. It looks like it might take editing the entire script.
Perhaps searching through the mod's files themselves may be worth the search.
Title: Re: Help with Sky Mods
Post by: tinnuvari on June 09, 2016, 08:13:49 pm
I've found a way to make it work, actually! It's in the sky.material file.

material Sky/SkyMat
{
   receive_shadows off
   technique 1
   {
      pass
      {
         lighting off
         depth_write off
         fog_override true
         fragment_program_ref Sky_PS
         {
            param_named_auto skyTop custom 1
            param_named_auto skyBot custom 2
         }
         texture_unit
         {
            texture skyMask.png
         }
      }
      pass
      {
         lighting off
         depth_write off
         scene_blend add
         fog_override true

         texture_unit
         {
            anim_texture skynebula01.png TransSky.png 1800
            scale 0.3 0.3
            tex_coord_set 0
         }
      }
   }
   technique 2
   {
      pass
      {
         lighting off
         depth_write off
         fog_override true
   
         texture_unit
         {
            colour_op_ex source1 src_manual src_manual 1 0 0 1
         }
         texture_unit
         {
            texture skyMask.png
            colour_op_ex blend_texture_alpha src_current src_manual 0 1 0 1
         }
      }
   }
}