The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Creative Discussions > Game Development > Pokémon Essentials
Sign Up Rules/FAQ Live Battle Blogs Mark Forums Read

Notices

Pokémon Essentials All questions and discussion about Pokémon Essentials, the Pokémon game kit for RPG Maker XP, go in here. Also contains links to the latest downloads and the Essentials Wiki.


Reply
Click here to go to the first staff post in this thread.  
Thread Tools
  #1    
Old April 7th, 2013, 02:00 PM
Rayd12smitty's Avatar
Rayd12smitty
Shadow Maker
 
Join Date: Dec 2011
Gender: Male
I have another quick question. I want to call a script that will make the game zoom in on the player, and then another one that will zoom back out. I want it to be a gradual change like when you use
Code:
pbToneChangeAll(0,20)
where the 0 is the tone it fades to and 20 is the frames it takes to do it. Is there something like this to zoom in on the player in the over world?
__________________
Reply With Quote
  #2    
Old April 7th, 2013, 02:08 PM
Maruno's Avatar
Maruno
Lead Dev of Pokémon Essentials
 
Join Date: Jan 2008
Location: England
You mean like the battle transition which zooms in on the screen? Class ZoomInTransition is where to get started with that, although what you need depends a huge amount on what you want to do with this zooming.
__________________
Reply With Quote
  #3    
Old April 7th, 2013, 03:10 PM
Rayd12smitty's Avatar
Rayd12smitty
Shadow Maker
 
Join Date: Dec 2011
Gender: Male
Quote:
Originally Posted by Maruno View Post
You mean like the battle transition which zooms in on the screen? Class ZoomInTransition is where to get started with that, although what you need depends a huge amount on what you want to do with this zooming.
Yes thats exactly what I want. I want to make it so the player is zoomed in on like that when I select something in the menu. I am using a custom menu so I don't need to know how to edit that.
Code:
if Input.trigger?(Input::C)
          Audio.se_play("Audio/SE/Select")
          pbWait(2)
          10.times do
            if $Trainer.pokedex==true
              @sprites["Pokedex"].y-=16
            end
            if $Trainer.party.length>=1
              @sprites["Pokemon"].y-=16
            end
            if $Trainer.pokegear==true
              @sprites["Pokegear"].y-=16
            end
            @sprites["Bag"].y-=16
            @sprites["Trainer Card"].y+=25.5
            @sprites["Save"].y+=25.5
            @sprites["Options"].y+=25.5
            @sprites["Back"].y+=25.5
            pbWait(1)
          end
          ####ZOOM IN ON PLAYER
          Audio.se_play("Audio/SE/navopen")
          pbPokeDev
          ####ZOOM OUT ON PLAYER
          break
        end

This is the basic idea I had. The commented out parts would be zooming in and then when you close the thing in the menu it zooms back out to normal. I will take just about anything I can get. It doesn't have to show it zoom back out if thats not possible.
__________________
Reply With Quote
  #4    
Old April 7th, 2013, 06:24 PM
zingzags's Avatar
zingzags
Creator or Pokemon Serenity
 
Join Date: Jan 2009
Location: Boston
Age: 20
Nature: Adamant
Zooming in on player is basically enlarging the map, and the player. The effect you are looking for is to make a loop which will gradually zoom in until it reaches the desired enlargement point.
__________________
Pokemon Serenity is my fangame name.
name decided 12/15/09
Currently helping:
Pokemon ebony
and
Xenotime:
Reply With Quote
  #5    
Old April 7th, 2013, 06:28 PM
Rayd12smitty's Avatar
Rayd12smitty
Shadow Maker
 
Join Date: Dec 2011
Gender: Male
I understand that but I don't know what to put in the loop. I don't know the script XD
__________________
Reply With Quote
  #6    
Old April 8th, 2013, 06:48 AM
Luka S.J.'s Avatar
Luka S.J.
S.J.Ware HD
 
Join Date: Dec 2008
Age: 21
Gender: Male
Nature: Adamant
Quote:
Originally Posted by zingzags View Post
Zooming in on player is basically enlarging the map, and the player. The effect you are looking for is to make a loop which will gradually zoom in until it reaches the desired enlargement point.
That is not a good way to do it. First of all it's much more complicated. Second, if you are actually enlarging the map, you'll be enlarging it tile by tile, making them out of alignment at points which aren't perfectly divisible by the scale factor. I tried this method; it's complicated, and doesn't give you a smooth animation in return.
Quote:
Originally Posted by Rayd12smitty View Post
I understand that but I don't know what to put in the loop. I don't know the script XD
Maruno gave you everything you need. If you look at how the class ZoomInTransition actually works, you'll see that it uses the Graphics.snap_to_bitmap function, which basically creates a temporary screenshot of your screen. Create a sprite with that, and you have yourself a super easy method of creating transitions of all kinds.
__________________
[STOPPED][DEMO] Pokemon Blue Chrome
[DEVELOPING] S.J.Ware
[DEVELOPING] Tykanite

Last edited by Luka S.J.; April 8th, 2013 at 06:54 AM.
Reply With Quote
  #7    
Old April 8th, 2013, 10:19 AM
Rayd12smitty's Avatar
Rayd12smitty
Shadow Maker
 
Join Date: Dec 2011
Gender: Male
Thanks Luka...again haha. I'll look at it again.
__________________
Reply With Quote
  #8    
Old April 9th, 2013, 03:56 PM
zingzags's Avatar
zingzags
Creator or Pokemon Serenity
 
Join Date: Jan 2009
Location: Boston
Age: 20
Nature: Adamant
Quote:
Originally Posted by Luka S.J. View Post
That is not a good way to do it. First of all it's much more complicated. Second, if you are actually enlarging the map, you'll be enlarging it tile by tile, making them out of alignment at points which aren't perfectly divisible by the scale factor. I tried this method; it's complicated, and doesn't give you a smooth animation in return.

Maruno gave you everything you need. If you look at how the class ZoomInTransition actually works, you'll see that it uses the Graphics.snap_to_bitmap function, which basically creates a temporary screenshot of your screen. Create a sprite with that, and you have yourself a super easy method of creating transitions of all kinds.
I was talking in theory, never really tried it myself.
__________________
Pokemon Serenity is my fangame name.
name decided 12/15/09
Currently helping:
Pokemon ebony
and
Xenotime:
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
Minimum Characters Per Post: 25



All times are UTC -8. The time now is 04:45 PM.


Style by Nymphadora, artwork by Sa-Dui.
Like our Facebook Page Follow us on Twitter © 2002 - 2014 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2014 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.