• 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.

[Archive] Pokemon Essentials: Starter Kit for RPG Maker XP

Status
Not open for further replies.
102
Posts
15
Years
    • Seen Jul 19, 2017
    Hi, can somebody help my write a code that turns on a switch if it is day or night. I currently set it to work in events when the player changes a map but it would be better as part of the script. The switch numbers are 51 for day and 52 for night. Please help me. Thanks.

    This is the code used in the events (not too awe inspiring, I know)
    codea.png
     
    10
    Posts
    15
    Years
    • Seen Feb 24, 2012
    as I do music for a wild pokemon that is already different from, for example I want a song of wild pokemon in a continent and in another
     

    Luka S.J.

    Jealous Croatian
    1,270
    Posts
    15
    Years
  • Hi, can somebody help my write a code that turns on a switch if it is day or night. I currently set it to work in events when the player changes a map but it would be better as part of the script. The switch numbers are 51 for day and 52 for night. Please help me. Thanks.

    This is the code used in the events (not too awe inspiring, I know)
    codea.png

    why don't you just make one switch and name it
    Code:
    s:Time.now.hour<6||Time.now.hour>=20
    This way you dont have to do dozen of events. So when it's night, the switch will be on and when its day it will be off.
    Or you can just make a common event.
     

    Monorail

    X in yo Y
    11
    Posts
    14
    Years
    • Seen Jun 24, 2009
    Hey guys, I just made an account on these forums. My friend and I are trying to put together our own pokemon game, he's the more creative one, and I'm the more computer oriented one, so I'm scripting it...
    Anyway, when I try to test my game, two things happen that I really can't get fixed.
    1. There is no start menu. I've looked in the notes a bit about the scripts, but nothing is mentioned anywhere about how to implement a start menu... Because of this, it leads to other problems, like not being able to own pokemon, and crashing whenever I get into a trainer battle.
    2. Going through doors crash the game.
    This is a typical error message from trying to go through a door.
    Code:
    ---------------------------
    ****** Essentials
    ---------------------------
    Exception: RuntimeError
    
    Message: Failed to load bitmap: Graphics/Characters/11
    
    BitmapCache:195:in `load_bitmap'
    
    BitmapCache:235:in `character'
    
    Sprite_Character:62:in `update_or'
    
    PerspectiveTilemap:408:in `shadow_update'
    
    Shadow:167:in `update'
    
    Sprite_Character:6:in `perspectivetilemap_initialize'
    
    PerspectiveTilemap:404:in `shadow_initialize'
    
    Shadow:143:in `initialize'
    
    Spriteset_Map:31:in `new'
    
    Spriteset_Map:31:in `_animationSprite_initialize'
    
    
    
    This exception was logged in errorlog.txt.
    
    Press Ctrl+C to copy this message to the clipboard.
    ---------------------------
    OK   
    ---------------------------
    The maps that are crashing are the ones that came with Pokemon Essentials.

    Thanks for any help!
     
    2,048
    Posts
    16
    Years
    • Seen Sep 7, 2023
    why don't you just make one switch and name it
    Code:
    s:Time.now.hour<6||Time.now.hour>=20
    This way you dont have to do dozen of events. So when it's night, the switch will be on and when its day it will be off.
    Or you can just make a common event.
    To elaborate, poccil implemented a system which, if you name a switch 's:_____', it will evaluate the script after the colon. Pretty useful ;)
    Hey guys, I just made an account on these forums. My friend and I are trying to put together our own pokemon game, he's the more creative one, and I'm the more computer oriented one, so I'm scripting it...
    Anyway, when I try to test my game, two things happen that I really can't get fixed.
    1. There is no start menu. I've looked in the notes a bit about the scripts, but nothing is mentioned anywhere about how to implement a start menu... Because of this, it leads to other problems, like not being able to own pokemon, and crashing whenever I get into a trainer battle.
    2. Going through doors crash the game.
    This is a typical error message from trying to go through a door.
    Code:
    ---------------------------
    ****** Essentials
    ---------------------------
    Exception: RuntimeError
    
    Message: Failed to load bitmap: Graphics/Characters/11
    
    BitmapCache:195:in `load_bitmap'
    
    BitmapCache:235:in `character'
    
    Sprite_Character:62:in `update_or'
    
    PerspectiveTilemap:408:in `shadow_update'
    
    Shadow:167:in `update'
    
    Sprite_Character:6:in `perspectivetilemap_initialize'
    
    PerspectiveTilemap:404:in `shadow_initialize'
    
    Shadow:143:in `initialize'
    
    Spriteset_Map:31:in `new'
    
    Spriteset_Map:31:in `_animationSprite_initialize'
    
    
    
    This exception was logged in errorlog.txt.
    
    Press Ctrl+C to copy this message to the clipboard.
    ---------------------------
    OK   
    ---------------------------
    The maps that are crashing are the ones that came with Pokemon Essentials.

    Thanks for any help!

    The start menu is accessed using X, instead of the usual Enter. If you mean the Pokémon menu option isn't appearing, then the starter kit is set to automatically show/hide it depending on whether you actually have a Pokémon with you.
    As for the error, somebody else had the same error a few pages back. That time, it was caused by the person deleting the intro event, or not starting on the map with the intro event. Check that your starting position is still in the empty map with the intro event in the top-left, and that the pbChangePlayer and pbTrainerName scripts are still called in the event.
     
    102
    Posts
    15
    Years
    • Seen Jul 19, 2017
    why don't you just make one switch and name it
    Code:
    s:Time.now.hour<6||Time.now.hour>=20
    This way you dont have to do dozen of events. So when it's night, the switch will be on and when its day it will be off.
    Or you can just make a common event.

    Thanks for the help. I didn't see it in the notes but I found it now after you told me.
     

    Monorail

    X in yo Y
    11
    Posts
    14
    Years
    • Seen Jun 24, 2009
    As for the error, somebody else had the same error a few pages back. That time, it was caused by the person deleting the intro event, or not starting on the map with the intro event. Check that your starting position is still in the empty map with the intro event in the top-left, and that the pbChangePlayer and pbTrainerName scripts are still called in the event.
    I changed both of those, should I just reinstall pokestarter?
     

    Maruno

    Lead Dev of Pokémon Essentials
    5,286
    Posts
    16
    Years
    • Seen May 3, 2024
    I changed both of those, should I just reinstall pokestarter?
    Nope. The fix is very simple. Just edit the event in the Intro map, and add in two separate "run script" commands, one for each of the following:

    Code:
    pbChangePlayer(0)
    pbTrainerName
    The first one will actually just set the player graphics to the male trainer. See the original intro for how it works as part of a "boy or girl?" setting.

    The second one opens the "name trainer" screen.

    Remember to create separate "run script" lines for each of those two.
     

    Monorail

    X in yo Y
    11
    Posts
    14
    Years
    • Seen Jun 24, 2009
    First off, thanks Maruno and Wichu
    Next problem of mine: I want to make it so that there's a boulder that you need to push over to go down into a secret tunnel, akin to Zelda.
    The problem is that for whatever reason, the transport trigger cancels out the boulder animation and its trigger, is there a way to get around that?
    Thanks again.
    Edit: Another problem. Trainers always give me the text "SKIPPING BATTLE..." instead of battling, even if i copy the trainers from the starter kit...
     
    Last edited:
    2,048
    Posts
    16
    Years
    • Seen Sep 7, 2023
    It's because you don't have any Pokémon in your party. You need to give the player a Pokémon in order to battle trainers.
     

    Minorthreat0987

    Pokemon Tellurium
    462
    Posts
    18
    Years
    • Seen Jan 28, 2021
    Can someone tell me if there is a way to turn a selfswitch on through a script function.

    Like I have an autorun event and when it ends I want to turn selfswitches on for all of the events involved so that all the events disappear, not just the event that has the event script in it...understand?

    Thank you so much!
     

    Atomic Reactor

    Guest
    0
    Posts
    well, can't you just make a one switch and turn it on s all the events will go away when it's on?
    That's what I would do..
     

    Minorthreat0987

    Pokemon Tellurium
    462
    Posts
    18
    Years
    • Seen Jan 28, 2021
    well, can't you just make a one switch and turn it on s all the events will go away when it's on?
    That's what I would do..

    You could yes, but you only have a set number of switches, so for the smaller events in the game that don't affect anything else in the game, for me it makes more sense to use self switches. I know something like what I am asking exists because I used it all the time in Iridium, but I can't remember the script for it..XD
     

    Maruno

    Lead Dev of Pokémon Essentials
    5,286
    Posts
    16
    Years
    • Seen May 3, 2024
    You could yes, but you only have a set number of switches, so for the smaller events in the game that don't affect anything else in the game, for me it makes more sense to use self switches. I know something like what I am asking exists because I used it all the time in Iridium, but I can't remember the script for it..XD
    You can have up to 5000 global switches. Are you seriously saying you're already using all 5000 of them?
     

    SytheXP

    Net Labs/UG Founder
    387
    Posts
    16
    Years
  • Can someone tell me if there is a way to turn a selfswitch on through a script function.

    Like I have an autorun event and when it ends I want to turn selfswitches on for all of the events involved so that all the events disappear, not just the event that has the event script in it...understand?

    Thank you so much!

    What I think you are wanting to do is something similar to one of my events.

    I added a Youngster chara in my game that wont let you pass to leave the first map unless you have your first pokemon. Ok so Ill tell you what to do to make one similar to this and hopefully it will help you.

    Ok first have your autorun event open at the bottom right click and click insert. On the 1st tab 2nd column 1st choice theres a button titled CONTROL SWITCHES click it. Make a New control switch titled so that you will remember the name. Then go to all your other events you want to go away after the autorun event is done and click make new event page. On the top left corner Click the first little circle then select the switch you just made. Now there to ways to erase the event. The easiest is just hit apply after making that event page, Dont add anything except the switch being turned on. Thus it changes the graphic into nothing and it has no text or anything. Next which would be completely pointless but I use on events just to make sure they are gone or if I want them to delete themselves after they are done running is adding the ERASE EVENT command into the event itself. You do this by right clicking the event page, clicking insert, On the first tab first column the 12th button down is the ERASE EVENT button click it to add the command then click apply.

    I hope I helped you a little bit

    EDIT: Also I was told here to look for repositioned/correctly resized 4th gen pokes. I mean the ones that come with poke essentials work but the pixels are messed up and theyre all a bit choppy looking. Can someone tell me what post its on please?
     
    Last edited:

    Maruno

    Lead Dev of Pokémon Essentials
    5,286
    Posts
    16
    Years
    • Seen May 3, 2024
    EDIT: Also I was told here to look for repositioned/correctly resized 4th gen pokes. I mean the ones that come with poke essentials work but the pixels are messed up and theyre all a bit choppy looking. Can someone tell me what post its on please?
    What you want is physically impossible. The 4th Gen sprites are 80x80 pixels, while the 3rd Gen sprites are 64x64 pixels. Some of the sprites, that are only small creatures, can be cropped to that size (thus making them look bigger), but the larger creatures that fill the 80x80 boxes cannot be resized without losing something. They just can't.

    And I think you want the Game Development Resources thread for requests like this. It's a sticky, and fairly self-explanatory.
     
    6
    Posts
    14
    Years
    • Seen Dec 13, 2010
    Hi, I've run into a small scripting problem. See I've been trying to add Diamond and Pearl moves to my game despite my lack of Ruby knowledge and so far the code has been self-explanatory enough that I've been able to add new classes to the "PokeBattle_MoveEffects" thing relatively easily. The move sucker punch has been causing me problems though, I don't suppose someone could please tell me what code I need to type to make a move miss if your opponent has called a damaging move?

    Edit: I just found this thread where someone's doing the same thing only with more experience and is nearly done, so I'll just wait for that.
     
    Last edited:

    Minorthreat0987

    Pokemon Tellurium
    462
    Posts
    18
    Years
    • Seen Jan 28, 2021
    Abandoning my previous question because I was unaware you got 5000 switches ( I thought you only had 999) But now I have two new questions...

    1. Is there a way to make the gender choice like DP, where when you have highlighted boy the male sprite is in color but the female is grayscale, and vice versa.

    2. Does anyone know a relatively easy was to create a starter selection similar to R/S/E, I could probably figure one out, but having help would definitely make it go a lot faster.

    Thanks!
     

    PoKéMaKeR1

    Pokemon Rancher creator!
    282
    Posts
    16
    Years
  • I'm having problems using the pbSetSelfSwitch function it just doesn't work the way I want it to work... Any suggestions?

    Thanks in advance!!

    PoKéMaKeR​
     
    Status
    Not open for further replies.
    Back
    Top