Go Back   The PokéCommunity Forums > Create & Discover > Game Development > Scripts & Tutorials
Reload this Page Essentials Script Pokémon B/W-style loading screen for Essentials

Notices
For all updates, view the main page.

Scripts & Tutorials This forum is for scripts and code, as well as all kinds of tutorials, software, tools and so forth. Remember to give credit!
The thread revival limit does not apply here.



Reply
 
Thread Tools
  #1    
Old December 19th, 2012 (1:14 PM). Edited December 19th, 2012 by carmaniac.
carmaniac's Avatar
carmaniac carmaniac is offline
Where the pickle surprise at?
 
Join Date: Apr 2009
Location: England
Age: 21
Nature: Relaxed
Posts: 682

Yes, this is a public resource for anyone who wants to use it, only tested with version 10 of essentials, please credit me if used.

Anyway, I present to you, B/W styled loading screen for essentials. To install this script, go to the script, PokémonLoad in the script editor, and replace the entire script with this new one below, download the graphics folder and put all the graphics into the Graphics/Pictures folder of your game.

http://www.mediafire.com/?olw1l5t5o6lfu8t

Code:
class PokemonLoadScene # :doc:
  def pbUpdate
    pbUpdateSpriteHash(@sprites)
  end

def pbStartScene @sprites={} @viewport=Viewport.new(0,0,Graphics.width,Graphics.height) @viewport.z=99998 savefile=RTP.getSaveFileName("Game.rxdata")

@sprites["overlay"]=BitmapSprite.new(Graphics.width, Graphics.height) @sprites["overlay"].z = 99999 @[email protected]["overlay"].bitmap @overlay.clear baseColor=Color.new(239, 239, 239) shadowColor=Color.new(140,140,140) pbSetSystemFont(@sprites["overlay"].bitmap)

if safeExists?(savefile) @sprites["Continue"] = Sprite.new @sprites["Continue"].x = 52 @sprites["Continue"].y = 4 @sprites["Continue"].z = 99998 @sprites["Continue"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Continue") @sprites["Continue"].opacity = 210

@sprites["NewGame"] = Sprite.new @sprites["NewGame"].x = 68 @sprites["NewGame"].y = 232 @sprites["NewGame"].z = 99998 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["NewGame"].opacity = 210

@sprites["Options"] = Sprite.new @sprites["Options"].x = 68 @sprites["Options"].y = 282 @sprites["Options"].z = 99998 @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["Options"].opacity = 210

textpos=[ [_INTL("CONTINUE"),84,10,false,baseColor,shadowColor], [_INTL("NEW GAME"),84,238,false,baseColor,shadowColor], [_INTL("OPTIONS"),84,288,false,baseColor,shadowColor], #[_INTL( ] pbDrawTextPositions(@overlay,textpos) else @sprites["NewGame"] = Sprite.new @sprites["NewGame"].x = 68 @sprites["NewGame"].y = 142 @sprites["NewGame"].z = 99998 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["NewGame"].opacity = 210

@sprites["Options"] = Sprite.new @sprites["Options"].x = 68 @sprites["Options"].y = 192 @sprites["Options"].z = 99998 @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["Options"].opacity = 210

textpos=[ [_INTL("NEW GAME"),84,148,false,baseColor,shadowColor], [_INTL("OPTIONS"),84,198,false,baseColor,shadowColor], ] pbDrawTextPositions(@overlay,textpos)

end

addBackgroundOrColoredPlane(@sprites,"background","loadbg", Color.new(96,96,248),@viewport) @sprites["locwindow"]=Window_AdvancedTextPokemon.new("") @sprites["locwindow"].[email protected] @sprites["locwindow"].visible=false @sprites["cmdwindow"]=Window_CommandPokemon.new([]) @sprites["cmdwindow"].x=512 @sprites["cmdwindow"].y=0 @sprites["cmdwindow"].[email protected] @sprites["cmdwindow"].visible=false pbFadeInAndShow(@sprites) { pbUpdate } end

def pbSetAuxiliaryWindow(loctext) @sprites["locwindow"].resizeToFit(loctext,[email protected]["cmdwindow"].width) @sprites["locwindow"].width=228 if @sprites["locwindow"].width<228 @sprites["locwindow"].height=Graphics.height @sprites["locwindow"].[email protected]["locwindow"].width @sprites["locwindow"].visible=true @sprites["locwindow"].text=loctext end

def pbSetParty(trainer,hasPokedex=false) for i in 0...trainer.party.length @sprites["party#{i}"]=PokemonIconSprite.new(trainer.party[i]) @sprites["party#{i}"].z=99999 @sprites["party#{i}"].x=80+60*i @sprites["party#{i}"].y=150 end end

def pbChoose(commands) @sprites["cmdwindow"].resizeToFit(commands) @sprites["cmdwindow"].commands=commands @sprites["cmdwindow"].x=512 @sprites["cmdwindow"].y=0 @sprites["cmdwindow"].visible=true loop do Graphics.update Input.update pbUpdate savefile=RTP.getSaveFileName("Game.rxdata") if safeExists?(savefile) if @sprites["cmdwindow"].index==0 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["Continue"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Continue_S") @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") elsif @sprites["cmdwindow"].index==1 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar_S") @sprites["Continue"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Continue") @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") elsif @sprites["cmdwindow"].index==2 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["Continue"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Continue") @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar_S") end else if @sprites["cmdwindow"].index==0 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar_S") @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") elsif @sprites["cmdwindow"].index==1 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar_S") end end

if Input.trigger?(Input::C) return @sprites["cmdwindow"].index end end end

def pbEndScene pbFadeOutAndHide(@sprites) { pbUpdate } pbDisposeSpriteHash(@sprites) @viewport.dispose end

def pbCloseScene pbDisposeSpriteHash(@sprites) @viewport.dispose end end

module FontInstaller # :doc: # filenames of fonts to be installed Filenames = [ 'pkmnem.ttf', 'pkmnemn.ttf', 'pkmnems.ttf', 'pkmnrs.ttf', 'pkmndp.ttf', 'pkmnfl.ttf' ] # names (not filenames) of fonts to be installed Names = [ 'Power Green', 'Power Green Narrow', 'Power Green Small', 'Power Red and Blue', 'Power Clear', 'Power Red and Green' ] # whether to notify player (via pop-up message) that fonts were installed Notify = true # location of fonts (relative to game folder) Source = 'Fonts/'

def self.getFontFolder fontfolder=MiniRegistry.get(MiniRegistry::HKEY_CURRENT_USER, "Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Shell Folders", "Fonts") return fontfolder+"\\" if fontfolder if ENV['SystemRoot'] return ENV['SystemRoot'] + '\\Fonts\\' elsif ENV['windir'] return ENV['windir'] + '\\Fonts\\' else return '\\Windows\\Fonts\\' end end

AFR = Win32API.new('gdi32', 'AddFontResource', ['P'], 'L') WPS = Win32API.new('kernel32', 'WriteProfileString', ['P'] * 3, 'L') SM = Win32API.new('user32', 'PostMessage', ['L'] * 4, 'L') WM_FONTCHANGE = 0x001D HWND_BROADCAST = 0xffff

def self.copy_file(src,dest) File.open(src, 'rb') {|r| File.open(dest, 'wb') {|w| while s = r.read(4096) w.write s end } } end

def self.pbResolveFont(name) RTP.eachPathFor(Source+name) {|file| return file if safeExists?(file) } return Source+name end

def self.install success = [] # Check if all fonts already exist filesExist=true fontsExist=true dest=self.getFontFolder() for i in 0...Names.size if !safeExists?(dest + Filenames[i]) filesExist=false end if !Font.exist?(Names[i]) fontsExist=false end end return if filesExist # Check if all source fonts exist exist=true for i in 0...Names.size if !RTP.exists?(Source + Filenames[i]) exist=false break end end return if !exist # Exit if not all source fonts exist Kernel.pbMessage(_INTL("One or more fonts used in this game do not exist on the system.\1")) Kernel.pbMessage(_INTL("The game can be played, but the look of the game's text will not be optimal.\1")) failed=false for i in 0...Filenames.size f = Filenames[i] if safeExists?(dest + f) && !Font.exist?(Names[i]) File.delete(dest + f) rescue nil end # check if already installed... if not safeExists?(dest + f) # check to ensure font is in specified location... if RTP.exists?(Source + f) # copy file to fonts folder succeeded=false begin copy_file(pbResolveFont(f), dest + f) # add font resource AFR.call(dest + f) # add entry to win.ini/registry WPS.call('Fonts', Names[i] + ' (TrueType)', f) succeeded=safeExists?(dest + f) rescue SystemCallError # failed succeeded=false end if succeeded success.push(Names[i]) else failed=true end end else success.push(Names[i]) # assume success end end if success.length>0 # one or more fonts successfully installed SM.call(HWND_BROADCAST,WM_FONTCHANGE,0,0) if Notify fonts = '' success.each do |f| fonts << f << ', ' end if failed Kernel.pbMessage(_INTL("Some of the fonts were successfully installed.\1")) Kernel.pbMessage(_INTL("To install the other fonts, copy the files in this game's Fonts folder to the Fonts folder in Control Panel.")) else Kernel.pbMessage(_INTL("The fonts were successfully installed.\1")) end if Kernel.pbConfirmMessage(_INTL("Would you like to restart the game and apply the changes?")) a = Thread.new { system('Game') } exit end end else # No fonts were installed. Kernel.pbMessage(_INTL("To install the necessary fonts, copy the files in this game's Fonts folder to the Fonts folder in Control Panel.")) end end end

class PokemonLoad def initialize(scene) @scene=scene end

def pbDisplay(text,brief=false) @scene.pbDisplay(text,brief) end

def pbDisplayPaused(text) @scene.pbDisplayPaused(text) end

def pbConfirm(text) return @scene.pbConfirm(text) end

def pbTryLoadFile(savefile) trainer=nil framecount=nil game_system=nil pokemonSystem=nil mapid=nil File.open(savefile){|f| trainer=Marshal.load(f) framecount=Marshal.load(f) game_system=Marshal.load(f) pokemonSystem=Marshal.load(f) mapid=Marshal.load(f) } raise "Corrupted file" if !trainer.is_a?(PokeBattle_Trainer) raise "Corrupted file" if !framecount.is_a?(Numeric) raise "Corrupted file" if !game_system.is_a?(Game_System) raise "Corrupted file" if !pokemonSystem.is_a?(PokemonSystem) raise "Corrupted file" if !mapid.is_a?(Numeric) return [trainer,framecount,game_system,pokemonSystem,mapid] end

def pbStartDeleteScreen savefile=RTP.getSaveFileName("Game.rxdata") @scene.pbStartScene if safeExists?(savefile) if Kernel.pbConfirmMessageSerious(_INTL("Delete all saved data?")) Kernel.pbMessage(_INTL("Once data has been deleted, there is no way to recover it.\1")) if Kernel.pbConfirmMessageSerious(_INTL("Delete the saved data anyway?")) Kernel.pbMessage(_INTL("Deleting all data.\r\nDon't turn off the power.\\wtnp[0]")) begin; File.delete(savefile); rescue; end begin; File.delete(savefile+".bak"); rescue; end Kernel.pbMessage(_INTL("The save file was deleted.")) end end else Kernel.pbMessage(_INTL("No save file was found.")) end @scene.pbEndScene $scene=pbCallTitle end

def pbStartLoadScreen $PokemonTemp = PokemonTemp.new $game_temp = Game_Temp.new $game_system = Game_System.new $PokemonSystem = PokemonSystem.new if !$PokemonSystem @scene.pbStartScene cmdContinue=-1 cmdNewGame=0 cmdOption=1 cmdLanguage=-1 commands=[] savefile=RTP.getSaveFileName("Game.rxdata") FontInstaller.install data_system = pbLoadRxData("Data/System") mapfile=$RPGVX ? sprintf("Data/Map%03d.rvdata",data_system.start_map_id) : sprintf("Data/Map%03d.rxdata",data_system.start_map_id) if data_system.start_map_id==0 || !pbRgssExists?(mapfile) Kernel.pbMessage(_INTL("No starting position was set in the map editor.\1")) Kernel.pbMessage(_INTL("The game cannot continue.")) @scene.pbEndScene $scene=nil return end if safeExists?(savefile) trainer=nil framecount=0 showContinue=false haveBackup=false begin trainer, framecount, $game_system, $PokemonSystem, mapid=pbTryLoadFile(savefile) showContinue=true rescue if safeExists?(savefile+".bak") begin trainer, framecount, $game_system, $PokemonSystem, mapid=pbTryLoadFile(savefile+".bak") haveBackup=true showContinue=true rescue end end if haveBackup Kernel.pbMessage(_INTL("The save file is corrupt. The previous save file will be loaded.")) else Kernel.pbMessage(_INTL("The save file is corrupt, or is incompatible with this game.")) if !Kernel.pbConfirmMessageSerious(_INTL("Do you want to delete the save file and start anew?")) raise "scss error - Corrupted or incompatible save file." end begin; File.delete(savefile); rescue; end begin; File.delete(savefile+".bak"); rescue; end $PokemonSystem=PokemonSystem.new if !$PokemonSystem $game_system=Game_System.new Kernel.pbMessage(_INTL("The save file was deleted.")) end end if showContinue if !haveBackup begin; File.delete(savefile+".bak"); rescue; end end totalsec = framecount / Graphics.frame_rate hour = totalsec / 60 / 60 min = totalsec / 60 % 60 mapname=pbGetMapNameFromId(mapid) mapname.gsub!(/\\PN/,trainer.name) textColor=["0070F8,78B8E8","E82010,F8A8B8","0070F8,78B8E8"][trainer.gender] loctext=_INTL("<ac><c2=06644bd2>{1}</c2></ac>",mapname) loctext+=_INTL("Player<r><c3={1}>{2}</c3><br>",textColor,fmtescape(trainer.name)) loctext+=_ISPRINTF("Time<r><c3={1:s}>{2:02d}:{3:02d}</c3><br>",textColor,hour,min) loctext+=_INTL("Badges<r><c3={1}>{2}</c3><br>",textColor,trainer.numbadges) if trainer.pokedex loctext+=_INTL("Pokédex<r><c3={1}>{2}/{3}</c3><br>",textColor,trainer.pokedexOwned,trainer.pokedexSeen) end

@sprites={} @sprites["overlay"]=BitmapSprite.new(Graphics.width, Graphics.height) @sprites["overlay"].z = 99999 @[email protected]["overlay"].bitmap @overlay.clear baseColor=Color.new(239, 239, 239) shadowColor=Color.new(140,140,140) pbSetSystemFont(@sprites["overlay"].bitmap)

textpos=[ [_INTL("{1}",trainer.name),84,60,false,Color.new(57,165,255),Color.new(57,107,173)], [_INTL("{1}",mapname),84,90,false,baseColor,shadowColor], [_INTL("Badges: {1}",trainer.numbadges),84,135,false,baseColor,shadowColor], [_ISPRINTF("Time: {1:02d}:{2:02d}",hour,min),220,135,false,baseColor,shadowColor], ] pbDrawTextPositions(@overlay,textpos)

loctext+=_INTL("Party") if trainer.party.length>0 @scene.pbSetAuxiliaryWindow(loctext) @scene.pbSetParty(trainer,trainer.pokedex) end commands[cmdContinue=commands.length]=_INTL("Continue") if showContinue commands[cmdNewGame=commands.length]=_INTL("New Game") commands[cmdOption=commands.length]=_INTL("Options") else commands[cmdNewGame=commands.length]=_INTL("New Game") commands[cmdOption=commands.length]=_INTL("Options") end if LANGUAGES.length>=2 commands[cmdLanguage=commands.length]=_INTL("Language") end loop do [email protected](commands) if cmdNewGame>=0 && command==cmdNewGame savefile=RTP.getSaveFileName("Game.rxdata") if safeExists?(savefile) @sprites["overlay"].opacity = 0 end @scene.pbEndScene if $game_map && $game_map.events for event in $game_map.events.values event.clear_starting end end $game_temp.common_event_id=0 if $game_temp $scene = Scene_Map.new Graphics.frame_count = 0 $game_system = Game_System.new $game_switches = Game_Switches.new $game_variables = Game_Variables.new $game_self_switches = Game_SelfSwitches.new $game_screen = Game_Screen.new $game_player = Game_Player.new $ItemData = readItemList("Data/items.dat") $PokemonMap = PokemonMapMetadata.new $PokemonGlobal = PokemonGlobalMetadata.new $PokemonStorage = PokemonStorage.new $PokemonEncounters = PokemonEncounters.new $PokemonTemp.begunNewGame=true $data_system = pbLoadRxData("Data/System") $MapFactory = PokemonMapFactory.new($data_system.start_map_id) # calls setMapChanged $game_player.moveto($data_system.start_x, $data_system.start_y) $game_player.refresh $game_map.autoplay $game_map.update return elsif cmdLanguage>=0 && command==cmdLanguage @scene.pbEndScene $PokemonSystem.language=pbChooseLanguage pbLoadMessages("Data/"+LANGUAGES[$PokemonSystem.language][1]) savedata=[] if safeExists?(savefile) File.open(savefile,"rb"){|f| 14.times { savedata.push(Marshal.load(f)) } } savedata[3]=$PokemonSystem begin File.open(RTP.getSaveFileName("Game.rxdata"),"wb"){|f| 14.times {|i| Marshal.dump(savedata[i],f) } } rescue; end end $scene=pbCallTitle return elsif cmdContinue>=0 && command==cmdContinue unless safeExists?(savefile) pbPlayBuzzerSE() next end @sprites["overlay"].opacity = 0 @scene.pbEndScene metadata=nil File.open(savefile){|f| $Trainer = Marshal.load(f) Graphics.frame_count = Marshal.load(f) $game_system = Marshal.load(f) Marshal.load(f) # PokemonSystem already loaded Marshal.load(f) # Current map id no longer needed $game_switches = Marshal.load(f) $game_variables = Marshal.load(f) $game_self_switches = Marshal.load(f) $game_screen = Marshal.load(f) $MapFactory = Marshal.load(f) $game_map = $MapFactory.map $game_player = Marshal.load(f) $PokemonGlobal = Marshal.load(f) metadata = Marshal.load(f) $ItemData = readItemList("Data/items.dat") $PokemonBag = Marshal.load(f) $PokemonStorage = Marshal.load(f) magicNumberMatches=false if $data_system.respond_to?("magic_number") magicNumberMatches=($game_system.magic_number==$data_system.magic_number) else magicNumberMatches=($game_system.magic_number==$data_system.version_id) end if !magicNumberMatches || $PokemonGlobal.safesave if pbMapInterpreterRunning? pbMapInterpreter.setup(nil,0) end begin $MapFactory.setup($game_map.map_id) # calls setMapChanged rescue Errno::ENOENT if $DEBUG Kernel.pbMessage(_INTL("Map {1} was not found.",$game_map.map_id)) map=pbWarpToMap() if map $MapFactory.setup(map[0]) $game_player.moveto(map[1],map[2]) else $game_map=nil $scene=nil return end else $game_map=nil $scene=nil Kernel.pbMessage(_INTL("The map was not found. The game cannot continue.")) end end $game_player.center($game_player.x, $game_player.y) else $MapFactory.setMapChanged($game_map.map_id) end } if !$game_map.events # Map wasn't set up $game_map=nil $scene=nil Kernel.pbMessage(_INTL("The map is corrupt. The game cannot continue.")) return end $PokemonMap=metadata $PokemonEncounters=PokemonEncounters.new $PokemonEncounters.setup($game_map.map_id) pbAutoplayOnSave $game_map.update $PokemonMap.updateMap $scene = Scene_Map.new return elsif cmdOption>=0 && command==cmdOption scene=PokemonOptionScene.new screen=PokemonOption.new(scene) pbFadeOutIn(99999) { screen.pbStartScreen } end end @sprites["overlay"].opacity = 0 @scene.pbEndScene return end end

__________________

Pokémon: Lost Souls.







Developed by Carmaniac.


Quote originally posted by Luka S.J.:
My balls seem to be fine.
Reply With Quote

Relevant Advertising!

  #2    
Old December 19th, 2012 (1:33 PM).
Arma's Avatar
Arma Arma is offline
The Hyena
Silver Tier
 
Join Date: Dec 2009
Location: The Hague
Age: 23
Gender: Male
Nature: Jolly
Posts: 1,254

Looks sweet, I'll definitely be using this in my game!
Thanks a lot!

__________________
Reply With Quote
  #3    
Old December 19th, 2012 (1:42 PM).
carmaniac's Avatar
carmaniac carmaniac is offline
Where the pickle surprise at?
 
Join Date: Apr 2009
Location: England
Age: 21
Nature: Relaxed
Posts: 682

Quote originally posted by elarmasecreta:
Looks sweet, I'll definitely be using this in my game!
Thanks a lot!

No problem at all, I'll probably over the Christmas holidays also do the b/w menu for essentials.

__________________

Pokémon: Lost Souls.







Developed by Carmaniac.


Quote originally posted by Luka S.J.:
My balls seem to be fine.
Reply With Quote
  #4    
Old December 19th, 2012 (8:01 PM).
Rayd12smitty's Avatar
Rayd12smitty Rayd12smitty is offline
Shadow Maker
 
Join Date: Dec 2011
Gender: Male
Posts: 647

It is really nice. I installed it and found an error though. It works fine when resuming a game, but something is wrong with new game.

Code:
---------------------------
Pokemon Melanite
---------------------------
Exception: NoMethodError

Message: undefined method `[]' for nil:NilClass

PokemonLoad:469:in `pbStartLoadScreen'

PokemonLoad:466:in `loop'

PokemonLoad:596:in `pbStartLoadScreen'

DebugIntro:6:in `main'

Main:37:in `mainFunctionDebug'

Main:15:in `mainFunction'

Main:15:in `pbCriticalCode'

Main:15:in `mainFunction'

Main:47

Main:46:in `loop'

This exception was logged in

C:\Users\Administrator\Saved Games/Pokemon Melanite/errorlog.txt.

Press Ctrl+C to copy this message to the clipboard. --------------------------- OK ---------------------------

__________________
Reply With Quote
  #5    
Old December 19th, 2012 (10:45 PM).
carmaniac's Avatar
carmaniac carmaniac is offline
Where the pickle surprise at?
 
Join Date: Apr 2009
Location: England
Age: 21
Nature: Relaxed
Posts: 682

Quote originally posted by Rayd12smitty:
It is really nice. I installed it and found an error though. It works fine when resuming a game, but something is wrong with new game.

Code:
---------------------------
Pokemon Melanite
---------------------------
Exception: NoMethodError

Message: undefined method `[]' for nil:NilClass

PokemonLoad:469:in `pbStartLoadScreen'

PokemonLoad:466:in `loop'

PokemonLoad:596:in `pbStartLoadScreen'

DebugIntro:6:in `main'

Main:37:in `mainFunctionDebug'

Main:15:in `mainFunction'

Main:15:in `pbCriticalCode'

Main:15:in `mainFunction'

Main:47

Main:46:in `loop'

This exception was logged in

C:\Users\Administrator\Saved Games/Pokemon Melanite/errorlog.txt.

Press Ctrl+C to copy this message to the clipboard. --------------------------- OK ---------------------------

At line 469, replace @sprites["overlay"].opacity = 0 with:

Code:
        savefile=RTP.getSaveFileName("Game.rxdata")
        if safeExists?(savefile)
          @sprites["overlay"].opacity = 0
        end

__________________

Pokémon: Lost Souls.







Developed by Carmaniac.


Quote originally posted by Luka S.J.:
My balls seem to be fine.
Reply With Quote
  #6    
Old December 20th, 2012 (5:07 AM).
VEGET@ VEGET@ is offline
 
Join Date: Feb 2010
Gender: Male
Posts: 69

Now works fine, and looks great thanks a lot

Reply With Quote
  #7    
Old December 20th, 2012 (9:03 AM).
Rayd12smitty's Avatar
Rayd12smitty Rayd12smitty is offline
Shadow Maker
 
Join Date: Dec 2011
Gender: Male
Posts: 647

Thanks it works now. This is awesome will give credit!

__________________
Reply With Quote
  #8    
Old December 20th, 2012 (9:07 AM).
ppooookkkkkkk ppooookkkkkkk is offline
Banned
 
Join Date: May 2012
Location: Newbud town (Pokemon Morning/Night)
Age: 15
Gender: Male
Nature: Gentle
Posts: 229

Wow this will defenatly make my game look better thanks a lot!

Reply With Quote
  #9    
Old December 20th, 2012 (10:27 AM).
XerX's Avatar
XerX XerX is offline
Team Mercury Leader
 
Join Date: Dec 2012
Location: British Columbia, Canada
Age: 19
Gender: Male
Nature: Modest
Posts: 15

Hey, I got the following error when I replaced the script.

Code:
---------------------------
Pokemon Essentials
---------------------------
Exception: NameError

Message: uninitialized constant Scene_DebugIntro::PokemonLoadScene

DebugIntro:4:in `main'

Main:37:in `mainFunctionDebug'

Main:15:in `mainFunction'

Main:15:in `pbCriticalCode'

Main:15:in `mainFunction'

Main:47

Main:46:in `loop'

Main:55

This exception was logged in ./errorlog.txt.

Press Ctrl+C to copy this message to the clipboard. --------------------------- OK ---------------------------

__________________
Reply With Quote
  #10    
Old December 21st, 2012 (3:08 AM).
carmaniac's Avatar
carmaniac carmaniac is offline
Where the pickle surprise at?
 
Join Date: Apr 2009
Location: England
Age: 21
Nature: Relaxed
Posts: 682

Quote originally posted by XerX:
Hey, I got the following error when I replaced the script.

Code:
---------------------------
Pokemon Essentials
---------------------------
Exception: NameError

Message: uninitialized constant Scene_DebugIntro::PokemonLoadScene

DebugIntro:4:in `main'

Main:37:in `mainFunctionDebug'

Main:15:in `mainFunction'

Main:15:in `pbCriticalCode'

Main:15:in `mainFunction'

Main:47

Main:46:in `loop'

Main:55

This exception was logged in ./errorlog.txt.

Press Ctrl+C to copy this message to the clipboard. --------------------------- OK ---------------------------

What version of essentials are you using?

__________________

Pokémon: Lost Souls.







Developed by Carmaniac.


Quote originally posted by Luka S.J.:
My balls seem to be fine.
Reply With Quote
  #11    
Old December 21st, 2012 (8:30 AM).
XerX's Avatar
XerX XerX is offline
Team Mercury Leader
 
Join Date: Dec 2012
Location: British Columbia, Canada
Age: 19
Gender: Male
Nature: Modest
Posts: 15

Quote originally posted by carmaniac:
What version of essentials are you using?

I'm using Pokemon Essentials 10.

Reply With Quote
  #12    
Old December 21st, 2012 (9:00 AM).
carmaniac's Avatar
carmaniac carmaniac is offline
Where the pickle surprise at?
 
Join Date: Apr 2009
Location: England
Age: 21
Nature: Relaxed
Posts: 682

Quote originally posted by XerX:
I'm using Pokemon Essentials 10.

Not sure why you would be getting that error in debug mode. I guess trying to by-pass that load method might help. Go to the main script, and change line 3 return Scene_DebugIntro.new to return Scene_Intro.new(['intro1'], 'splash') just to see if it lets you play in debug mode.

__________________

Pokémon: Lost Souls.







Developed by Carmaniac.


Quote originally posted by Luka S.J.:
My balls seem to be fine.
Reply With Quote
  #13    
Old December 21st, 2012 (9:56 AM).
XerX's Avatar
XerX XerX is offline
Team Mercury Leader
 
Join Date: Dec 2012
Location: British Columbia, Canada
Age: 19
Gender: Male
Nature: Modest
Posts: 15

Nevermind. I figured it out. I had to delete my old save file.

__________________
Reply With Quote
  #14    
Old December 28th, 2012 (9:33 AM).
ActionReplayer's Avatar
ActionReplayer ActionReplayer is offline
 
Join Date: Jun 2012
Gender: Male
Posts: 44

Thanks man, certainly gonna user it.

Reply With Quote
  #15    
Old December 29th, 2012 (1:36 PM).
p.claydon p.claydon is online now
 
Join Date: Jan 2011
Gender:
Posts: 324

is there a way to change the names colour depending on gender?

Reply With Quote
  #16    
Old January 11th, 2013 (12:54 PM).
Arx's Avatar
Arx Arx is offline
Blade of Justice
Silver Tier
 
Join Date: Jul 2012
Location: Earth
Age: 18
Gender: Male
Nature: Timid
Posts: 4,022

Does this work on Essentials 11? If yes, i'm definitely going to use that for my game.

__________________
|| ||
I am the white void, I am the cold steel, I am the just sword, with blade in hand shall I reap the sins of this world, and cleanse them in the fires of destruction! I am Hakumen! The end has come.
Reply With Quote
  #17    
Old January 11th, 2013 (1:40 PM).
carmaniac's Avatar
carmaniac carmaniac is offline
Where the pickle surprise at?
 
Join Date: Apr 2009
Location: England
Age: 21
Nature: Relaxed
Posts: 682

Quote originally posted by JNathan:
Does this work on Essentials 11? If yes, i'm definitely going to use that for my game.

In theory it should work just fine, if it doesn't, I can update the script when free to 11.

__________________

Pokémon: Lost Souls.







Developed by Carmaniac.


Quote originally posted by Luka S.J.:
My balls seem to be fine.
Reply With Quote
  #18    
Old January 11th, 2013 (2:39 PM).
Maruno's Avatar
Maruno Maruno is offline
Lead Dev of Pokémon Essentials
 
Join Date: Jan 2008
Location: England
Posts: 5,128

It'll work, just without the Mystery Gift option.

__________________
Reply With Quote
  #19    
Old January 19th, 2013 (2:14 PM).
Dradier234's Avatar
Dradier234 Dradier234 is offline
 
Join Date: Oct 2012
Gender: Male
Nature: Careful
Posts: 309

Very nice.. This is awesome. :D

__________________
http://poke-fans.forumotion.com/
Join Here
Reply With Quote
  #20    
Old January 19th, 2013 (4:43 PM).
Radical Raptr's Avatar
Radical Raptr Radical Raptr is offline
#BAMFPokemonNerd
 
Join Date: Mar 2011
Location: everywhere
Age: 21
Gender: Male
Nature: Sassy
Posts: 1,121
Send a message via Skype™ to Radical Raptr

I am loving this
I'll be changing the graphics but great job! Thank you for this credible resource

__________________

~My Deviantart - Litharreon Wiki - Litharreon Game Download~

Reply With Quote
  #21    
Old February 8th, 2013 (12:40 AM).
Kaito123 Kaito123 is offline
 
Join Date: Jul 2012
Gender: Male
Posts: 50

Quote originally posted by Maruno:
It'll work, just without the Mystery Gift option.

It is possible to make the Mystery Gift in this script? So you can use it for all Features in Essentials 11?

Reply With Quote
  #22    
Old May 10th, 2013 (3:54 PM).
Obito Uchiha's Avatar
Obito Uchiha Obito Uchiha is offline
 
Join Date: Apr 2013
Gender: Male
Posts: 50

I've tried to make it compatible with v11. The only difficult to make it wrong it the cinditional branch.

Code:
if (trainer.mysterygiftaccess rescue false)
      @sprites["Continue"] = Sprite.new
      @sprites["Continue"].x = 100
      @sprites["Continue"].y = 4
      @sprites["Continue"].z = 99998
      @sprites["Continue"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Continue")
      @sprites["Continue"].opacity = 210

@sprites["NewGame"] = Sprite.new @sprites["NewGame"].x = 116 @sprites["NewGame"].y = 232 @sprites["NewGame"].z = 99998 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["NewGame"].opacity = 210

@sprites["Options"] = Sprite.new @sprites["Options"].x = 116 @sprites["Options"].y = 282 @sprites["Options"].z = 99998 @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["Options"].opacity = 210

@sprites["MysteryGift"] = Sprite.new @sprites["MysteryGift"].x = 116 @sprites["MysteryGift"].y = 332 @sprites["MysteryGift"].z = 99998 @sprites["MysteryGift"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["MysteryGift"].opacity = 210

textpos=[ [_INTL("CONTINUE"),132,10,false,baseColor,shadowColor], [_INTL("NEW GAME"),132,238,false,baseColor,shadowColor], [_INTL("OPTIONS"),132,288,false,baseColor,shadowColor], [_INTL("MYSTERY GIFT"),132,338,false,baseColor,shadowColor], #[_INTL( ] pbDrawTextPositions(@overlay,textpos)

But "(trainer.mysterygiftaccess rescue false)" doesn't work and removing the "rescue false" will it end with an error (method mysterygiftaccess doesn'tc exist)

Has someone an idea how the conditional branch should look?

__________________
Reply With Quote
  #23    
Old May 19th, 2013 (12:28 AM). Edited May 19th, 2013 by bleach12.
bleach12's Avatar
bleach12 bleach12 is offline
ProjectM76Creator/AmateurCoder
 
Join Date: Jan 2011
Location: Australia
Gender: Male
Posts: 6

I would love to use this, but I'm having a problem. I've put the code in and all, but when I get to the menu screen, the background is correct, but the actual bars and boxes that you selected aren't BW styled, they still look like the default.

EDIT
I put the code in the TrainerCard section not the Loading one xD
Stupid mistake, code works perfectly

__________________

www.youtube.com/user/ProjectM76
Check us out if you want, leave a like and also support our new project, Project Pokemon
Reply With Quote
  #24    
Old May 20th, 2013 (5:32 AM).
Obito Uchiha's Avatar
Obito Uchiha Obito Uchiha is offline
 
Join Date: Apr 2013
Gender: Male
Posts: 50

And I still haven't an idea why "trainer.mysterygiftaccess" as condition at the beginning doesn't work...

__________________
Reply With Quote
  #25    
Old May 22nd, 2013 (1:06 PM).
Nickalooose Nickalooose is offline
--------------------
 
Join Date: Mar 2008
Gender: Female
Posts: 1,285

Quote originally posted by Obito Uchiha:
I've tried to make it compatible with v11. The only difficult to make it wrong it the cinditional branch.

Code:
if (trainer.mysterygiftaccess rescue false)
      @sprites["Continue"] = Sprite.new
      @sprites["Continue"].x = 100
      @sprites["Continue"].y = 4
      @sprites["Continue"].z = 99998
      @sprites["Continue"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Continue")
      @sprites["Continue"].opacity = 210

@sprites["NewGame"] = Sprite.new @sprites["NewGame"].x = 116 @sprites["NewGame"].y = 232 @sprites["NewGame"].z = 99998 @sprites["NewGame"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["NewGame"].opacity = 210

@sprites["Options"] = Sprite.new @sprites["Options"].x = 116 @sprites["Options"].y = 282 @sprites["Options"].z = 99998 @sprites["Options"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["Options"].opacity = 210

@sprites["MysteryGift"] = Sprite.new @sprites["MysteryGift"].x = 116 @sprites["MysteryGift"].y = 332 @sprites["MysteryGift"].z = 99998 @sprites["MysteryGift"].bitmap = BitmapCache.load_bitmap("Graphics/Pictures/Bar") @sprites["MysteryGift"].opacity = 210

textpos=[ [_INTL("CONTINUE"),132,10,false,baseColor,shadowColor], [_INTL("NEW GAME"),132,238,false,baseColor,shadowColor], [_INTL("OPTIONS"),132,288,false,baseColor,shadowColor], [_INTL("MYSTERY GIFT"),132,338,false,baseColor,shadowColor], #[_INTL( ] pbDrawTextPositions(@overlay,textpos)

But "(trainer.mysterygiftaccess rescue false)" doesn't work and removing the "rescue false" will it end with an error (method mysterygiftaccess doesn'tc exist)

Has someone an idea how the conditional branch should look?

Well, first of all, you can't just take pieces of code, throw them together and expect them to work...

if (trainer.mysterygiftaccess rescue false)

That is saying, "can mystery gift be accessed... If yes... Show Mystery Gift option.", not, "if I click this... Do something special."...

If you want it to check whether Mystery Gift is on, you will need to use something else like

commands[cmdMysteryGift=commands.length]=_INTL("Mystery Gift") if (trainer.mysterygiftaccess rescue false)

As it is already...

To add the mystery gift option... Try putting that line of code around line 456... However, then you will need to put how the window will work... What the command MysteryGift will do... Etc. etc.

Try copying the right sections before trying to make something out the blue... There's your start.

Reply With Quote
Reply
Quick Reply

Sponsored Links
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 11:48 AM.