• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

An option to lower/rise sound

Qwertyis666

Dragon Trainer Since 1996
60
Posts
10
Years
  • Hi, I search on the forum and the Wikia and I found nothing about add an option to lower or rise the music and/or the battle,etc sound in the game. Any tips?

    Thanks in advance and sorry for my bad english
     
    1,224
    Posts
    10
    Years
  • You could add it as an option, and then find all the methods that play bgms and such, and have them change their volume to that option if it exists.

    Code:
    volume=$PokemonSystem.volume if $PokemonSystem.volume
     
    119
    Posts
    10
    Years
  • You could add it as an option, and then find all the methods that play bgms and such, and have them change their volume to that option if it exists.

    Code:
    volume=$PokemonSystem.volume if $PokemonSystem.volume

    sorry if i sound dumb but how would i go about adding this as an option?, im a noob at scripting
     
    1,224
    Posts
    10
    Years
  • sorry if i sound dumb but how would i go about adding this as an option?, im a noob at scripting

    I would suggest looking at how other options work, and trying things based on that. Playing around with and studying existing scripts is a good way to learn.
     
    119
    Posts
    10
    Years
  • I would suggest looking at how other options work, and trying things based on that. Playing around with and studying existing scripts is a good way to learn.

    alright, thanks. ill try that out, ill post my results if i can figure it out
     
    119
    Posts
    10
    Years
  • ok, so i know that this probs isnt the best way to figure this out but i kinda decrypted Pokemon Omicron and looked at their script in order to fix this. i know this is wrong but i figured out how to add this to the options by looking through their scripts.
    If you would like to add this feature,
    replace your Game_System script with this :
    Spoiler:
    and then add the red in PokemonOptions
    Code:
    class PokemonSystem
      attr_accessor :textspeed
      attr_accessor :battlescene
      attr_accessor :battlestyle
      attr_accessor :frame
      attr_accessor :textskin
      attr_accessor :font
      attr_accessor :screensize
      attr_accessor :language
      [COLOR="Red"]attr_accessor :volume
      attr_accessor :soundvolume[/COLOR]
    then add the red here
    Code:
      def initialize
        @textspeed   = 1   # Text speed (0=slow, 1=mid, 2=fast)
        @battlescene = 0   # Battle scene (animations) (0=on, 1=off)
        @battlestyle = 0   # Battle style (0=shift, 1=set)
        @frame       = 0   # Default window frame (see also $TextFrames)
        @textskin    = 0   # Speech frame
        @font        = 0   # Font (see also $VersionStyles)
        @screensize  = (DEFAULTSCREENZOOM.floor).to_i # 0=half size, 1=full size, 2=double size
        @language    = 0   # Language (see also LANGUAGES in script PokemonSystem)
        [COLOR="Red"]@volume    = 100[/COLOR]
      end
    end

    and finally the red here
    Code:
    # Quote this section out if you don't want to allow players to change the screen
    # size.
           EnumOption.new(_INTL("Screen Size"),[_INTL("Small"),_INTL("Medium"),_INTL("Large")],
              proc { $PokemonSystem.screensize },
              proc {|value|
                 oldvalue=$PokemonSystem.screensize
                 $PokemonSystem.screensize=value
                 $ResizeOffsetX=0
                 $ResizeOffsetY=0
                 pbSetResizeFactor([0.5,1.0,2.0][value])
                 if value!=oldvalue
                   ObjectSpace.each_object(TilemapLoader){|o| next if o.disposed?; o.updateClass }
                 end
              }
           ),
           [COLOR="Red"]NumberOption.new(_INTL("Music Volume"),_INTL("%d\%"),0,101,
             proc { $PokemonSystem.volume },
             proc {|value|
               $PokemonSystem.volume=value
               if $game_system.playing_bgm != nil
                 $game_system.playing_bgm.volume=value
                 $game_system.bgm_memorize
                  $game_system.bgm_stop
                  $game_system.bgm_restore
              end
              
              }
          ),
           NumberOption.new(_INTL("Sound Volume"),_INTL("%d\%"),0,101,
             proc { $PokemonSystem.soundvolume },
             proc {|value|
               $PokemonSystem.soundvolume=value
               if $game_system.playing_bgs != nil
                 $game_system.playing_bgs.volume=value
                 $game_system.bgs_memorize
                  $game_system.bgs_stop
                  $game_system.bgs_restore
              end
              
              }
          )[/COLOR]
    If you use this give all credit to the Pokemon Omicron/Zeta team as i used their scripts to find this out
     
    1,224
    Posts
    10
    Years
  • If you use this give all credit to the Pokemon Omicron/Zeta team as i used their scripts to find this out

    My whole point in not telling you exactly what to do was so that you would try to figure out how to code it yourself, not copy somebody else's.
     
    119
    Posts
    10
    Years
  • My whole point in not telling you exactly what to do was so that you would try to figure out how to code it yourself, not copy somebody else's.

    i know that but i have no knowledge in scripting at all, the only thing i really copied was the last part as i could not figure it out. anyways i posted this so others could use this

    NumberOption.new(_INTL("Music Volume"),_INTL("%d\%"),0,101,
    proc { $PokemonSystem.volume },
    proc {|value|
    $PokemonSystem.volume=value
    if $game_system.playing_bgm != nil
    $game_system.playing_bgm.volume=value
    $game_system.bgm_memorize
    $game_system.bgm_stop
    $game_system.bgm_restore
    end

    }
    ),
    NumberOption.new(_INTL("Sound Volume"),_INTL("%d\%"),0,101,
    proc { $PokemonSystem.soundvolume },
    proc {|value|
    $PokemonSystem.soundvolume=value
    if $game_system.playing_bgs != nil
    $game_system.playing_bgs.volume=value
    $game_system.bgs_memorize
    $game_system.bgs_stop
    $game_system.bgs_restore
    end

    }
    )
     

    Nickalooose

    --------------------
    1,309
    Posts
    16
    Years
    • Seen Dec 28, 2023
    Decrypting games 'tut tut'... This is one of the reasons why people don't release their games... Everything in the Options scripts is all you need to learn... I suggest in future you learn through Essentials or scripts posted in the scripts section, you're giving away peoples hard work.
     
    1,224
    Posts
    10
    Years
  • Decrypting games 'tut tut'... This is one of the reasons why people don't release their games... Everything in the Options scripts is all you need to learn... I suggest in future you learn through Essentials or scripts posted in the scripts section, you're giving away peoples hard work.

    Is there a more secure way to encrypt rmxp games? It literally takes zero skill to decrypt them using the built in method.
     

    Luka S.J.

    Jealous Croatian
    1,270
    Posts
    15
    Years
  • Is there a more secure way to encrypt rmxp games? It literally takes zero skill to decrypt them using the built in method.

    I remember CollosalPokemon having posted a method here. On every other RMXP forum I looked, the general consensus seems to be that there is no solid way to encrypt your game. Which would be a shame. I haven't tried CP's method, so I don't know how effective it is, but I'm guessing it's your best bet for now.

    Shame people have to be such butts and steal content. Happened to my game. All the content stolen. I know I won't be releasing any more of it.
     
    1,224
    Posts
    10
    Years
  • I remember CollosalPokemon having posted a method here. On every other RMXP forum I looked, the general consensus seems to be that there is no solid way to encrypt your game. Which would be a shame. I haven't tried CP's method, so I don't know how effective it is, but I'm guessing it's your best bet for now.

    Shame people have to be such butts and steal content. Happened to my game. All the content stolen. I know I won't be releasing any more of it.

    Thanks. I release the majority of my scripts on here anyhow, so I'm not too concerned, but I can imagine it being a big problem for other people. I saw when that person stole yours, but I think your stuff is recognizable enough that you'll usually get someone that calls them out.
     

    Nickalooose

    --------------------
    1,309
    Posts
    16
    Years
    • Seen Dec 28, 2023
    The thing with features is, if you show your work before a release, many people will recognize it... But Mej, Luka is right, there is no way to do so, you just got to kind of rely on honest people around here... Which is preposterous to assume... Obviously there are a fair few, but don't hold your breathe... There are a couple encrypters around, but I don't think they can do much different to what RMXP does.
     
    119
    Posts
    10
    Years
  • i just want to say i would never steal anyone's work, i only used this to figure something out, i wouldn't take their work and call it my own, thats just dumb, also i wont be doing this in the future either as i will try and figure something out myself, which i know i should have done in the first place. also do you know how to encrypt a game that is over 1gb as when i try and encrypt it it just crashes and doesnt actually work
     

    Savordez

    It's time to end fangames.
    115
    Posts
    10
    Years
  • The options stolen from Omicron have a problem anyway; adjusting the sound while in the start screen starts playing music (which is very weird especially if the music is a route theme). Either you come up with something or hope someone else does and releases it here.
     
    119
    Posts
    10
    Years
  • The options stolen from Omicron have a problem anyway; adjusting the sound while in the start screen starts playing music (which is very weird especially if the music is a route theme). Either you come up with something or hope someone else does and releases it here.
    it works perfectly fine for me, so you must have done something wrong, and no i dont have to come up with something!, if it doesnt work for you try and fix it.
     
    Back
    Top