Author Topic: Changing settings in runtime  (Read 62 times)

Beor Games

  • Guest
Changing settings in runtime
« on: March 30, 2021, 08:32:06 PM »
Hello,

I want to give players the possibility to adjust the settings during the game, but I don't see all settings available when connecting the script to a slider for example, how should I proceed?

Do you see any problem on changing these settings at runtime?

Thanks!

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6869
    • View Profile
Re: Changing settings in runtime
« Reply #1 on: March 30, 2021, 08:51:21 PM »
Yes, it possible, through the XFrameEffect.XFrameManager.instance property you can access all the settings.
Please check the documentation for sample code.

Beor Games

  • Guest
Re: Changing settings in runtime
« Reply #2 on: March 30, 2021, 08:55:15 PM »
Wow, that was fast!!! Thanks.

I've checked it, but couldn't find any reference to the "Minimum Quality" setting, does it have another name on the script?

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6869
    • View Profile
Re: Changing settings in runtime
« Reply #3 on: March 30, 2021, 09:01:01 PM »
Minimum Quality is "downsampling"
Maximum Quality is "downsamplingMax"

They got renamed in the Editor inspector for clarity. You can peek into the XframeEffectInspector.cs script.

Beor Games

  • Guest
Re: Changing settings in runtime
« Reply #4 on: March 30, 2021, 09:04:35 PM »
Perfect! that's what I was searching for!  ;D

Thanks for the super fast reply!

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6869
    • View Profile
Re: Changing settings in runtime
« Reply #5 on: March 30, 2021, 09:06:37 PM »
You're welcome! Thanks for using X-Frame.