hmmm, this might be a tall order, but I was wondering if anyone could help me with this.
see, I'm trying to um, make it so that instead of setting wild pokemon/other trainers' pokemon levels, the game gets the level of your first pokemon and then like...sets the opponent's level to be somewhere between two levels lower/higher than that.
um, I know it kind of sounds random and not at all useful haha but the thing is, my game isn't set in a whole region, it's just like...a small part of the region, and the character has only one pokemon with them at a time (as well as an egg!), so uhhh the thing is obviously depending on how much you grind, your pokemon could like be anywhere from freshly hatched to like, level fifty gazillion, when you come up against plot-related trainers, so pacing opponent's levels is freaking impossible >:(
so I was basically thinking...maybe I could just throw in something small in whatever script controls the battles (like... get first pokemon's level, get a random number between level-2 and level+2, change the opponent's level to that), but I have NO IDEA if that is even viable, or where I'd do it. so uhhhh just thought I'd ask some of you experienced scripters if this is an impossible idea of mine, or if I'm going about it in entirely the wrong manner and I'll have to write a whole brand new script to deal with battles (please god not this)...
I just wanted to voice my own opinions on this. Firstly, my favourite colour is purple. :classic: Also, I notice you say the player will only have one Pokémon at a time, which makes balancing much easier. The rest of my nattering below concerns the general idea of balancing, just for the sake of it.
It would be very difficult to come up with a good balancing system that reduces the chances of abuse. You need to consider a lot of things, including:
- (If only the first party Pokémon is considered) The player could lead with a weak Pokémon, only to switch in a much stronger one later and power over the opponents.
- (If all party Pokémon are considered) A simple level average won't work, because a team of 5 weaklings and one strong Pokémon would still have a low average level, leading to steamrolling again.
- (If the strongest 3 Pokémon only are considered) Same again - the other two could be weaklings just to drive down the average level.
- Different species are different. Bug Pokémon are typically weak, so trainers with them should be a little overleveled to compensate.
- You could also end up with the trainers owning "illegal" Pokémon, i.e. underleveled Pokémon. A level 15 Blastoise is not normal. Attempting to fix this (i.e. replace with the next highest evolution) would be even more complicated.
- (Considering number of badges) The number of badges the player has means little. It's not a good idea to use them as part of balancing.
I think analysing the player's Pokémon and deriving a level from that is wrong, because of the abusability mentioned above. Instead, I would suggest giving the trainer Pokémon core levels, and then restrict the balancing to +/- 5 depending on the relative strengths of them and the player (to even them out a little). It's not perfect, but it's a start.
Going any further with this would probably require some decent maths, namely mean and range of levels. With these two numbers you can tell if there's some abuse going on (i.e. one strong, five weak results in a low mean but big range), so you can adjust the levels accordingly. You can then take different groups of the party Pokémon and run the calculations with them too, to decide what the player is planning to do, and compensate accordingly.
This can get very complicated very quickly. And that's only discussing levels - what about taking natures/abilities/moves into account as well? Not only looking at the player's Pokémon's stats, but also modifying the trainer's Pokémon to suit (e.g. give Charmander an Electric move if the player has a Squirtle).
Nightmare.
Oh, and remember that balancing means the trainers may well have Pokémon whose levels(/stats/etc.) change with each encounter, and eagle-eyed players will pick up on that. They will, too - a few have complained that trainer Pokémon's genders/abilities are random and not fixed.
Does anyone know how to do the regional storages?
Theoretically, yes. Nickalooose asked me a short while ago about this, so I'll just repeat what I told him:
As a guess, I don't think implementing something like this would be too difficult. You'd need to do the following:
- Create new storage variables (just like how $PokemonStorage is one), one for each region (e.g. $PokemonStorageKanto, etc.). Note that this is in addition to $PokemonStorage. Have them all initialise the same way in PokemonLoad (i.e. as a set of storage boxes - $PokemonStorageKanto=PokemonStorage.new, etc.).
- Make sure these global variables are added to both the save/load functions (because you don't want to lose them when you close the game).
- Whenever you cross to a new region, first make the player deposit all their Pokémon (you'll have to force this, because they player cannot deposit their only remaining party Pokémon), then copy $PokemonStorage to whichever storage variable corresponds to the region you just left. Then clear $PokemonStorage and copy to it the contents of the storage variable corresponding to the newly entered region, and then make the player withdraw at least 1 Pokémon (only if they've been there before; if storage is empty, they're new here, so make them go see the Professor for a new starter instead).
Basically, you'll have a set of storage boxes for each region, plus
$PokemonStorage which will be a copy of whichever is the local region's boxes. All the scripts will only work with
$PokemonStorage, which is fine - the other ones you made are "archive storage"; they're not actively used.
As far as I can tell, as long as you do everything in point 3 each time you enter a different region, it should work fine. Obviously this requires some degree of care to implement in the region-crossings, as there aren't any convenient existing safeguards in place to stop you doing anything silly (e.g. going into the new region with no Pokémon). All of point 3 can and should be done in an event with fairly simple script lines - there's no need for anything more fancy than that.
I just came up with a pretty simple workaround:
PBDayNight.getShade() returns a number from 0 (full night) to 255 (full day) so you can adjust the screen tone color while entering the forest easily with condional branches...
Works great!
If you're using that how I think you're using that (changing the screen tone via the transfer events), I don't think it'll work properly. For one, the screen tone changes every minute, but setting a "change screen tone" line in the transfer event will only change the tone that one time. If you wait around in the forest for a few hours, you'll notice a difference. Even going from one side of the forest to the other takes time, and you'll end up with an offset tone for the rest of the game.
Secondly, the screen tone change won't be negated if you leave via Fly or Teleport or whatever.
I would recommend you look into using a fog instead, and setting the forest to "indoors" (so there's no tone change). Make the fog graphic look leafy, and make it as dark or as light as you want, and there you go.
2. I have some maps that cover multiple parts of the region map so i can't display the precise, actual position on the town map for the player.
I figured it'd be a good workaround to split up the maps (which works fine for that purpose) into multiple parts. But i still only want the map's name displayed in the upper left corner on entering the FIRST and LAST map of my map-parts and only if i enter from the right direction. so this can't be done using the ShowArea option in the metadata. My first idea would be to handle the events WHEN to show the map's name myself for those maps, but I'd need the script line to do so... i couldn't figure it out myself so maybe somebody knows how to trigger the map-name display by script code.
First a bit of chat:
This problem you have will only manifest itself when you look at the region map (I'll call it country from now on to avoid confusion) to see your current location. Because one map can only be designated one square in the country, your little trainer face will only ever be displayed in that one square, even if you happen geographically to be a few squares over.
It won't affect anything else, though. Fly destinations, hover-over information and all that are handled as part of the country information, not map-specific information (i.e. you define each square of the country for these things).
I'll agree that it's quite annoying, though. Poccil's probably clever enough to come up with some fix to this (even I can imagine how it might work, but I have little to no idea how to implement it). The only other option is to do what you suggest - split each big map up into smaller one square-sized maps, and selectively modify the signpost scripts to not display if going from map X to map Y.
I haven't done this myself, but I've at least found where it should be done. In
PokemonField, find the script procedure
Events.onMapSceneChange. In there is the following:
Code:
if mapChanged
if pbGetMetadata($game_map.map_id,MetadataShowArea)
scene.spriteset.addUserSprite(LocationWindow.new($game_map.name))
end
This should be modified to do the checks on whether the previous map is X and the new map is Y. The only problem is that there isn't a handy variable that remembers the number of the previous map (aside: if there was, you could use it to display those circles in DPPt that show where you've come from). You'll have to make one yourself. Once made, it's trivial to set up the comparison - but remember to make sure it works both ways (i.e. going from Y to X too).
4. I would like to have the experience bar fill WAY faster (graphically)... how can i achieve that? when i looked at the script i found something like "rect.fill" and i didn't know how to handle that.. i'd like to speed up this process to have it at least twice as fast(less frames or something) . any ideas?
Presumably you mean in battle.
PokeBattle_ActualScene, around line 590 (in the
update def of class
PokemonDataBox). Find the following:
Code:
if @animatingEXP
if !@showexp
@currentexp=@endexp
elsif @currentexp<@endexp
@currentexp+=[COLOR=Red]1[/COLOR]
elsif @currentexp>@endexp
@currentexp-=[COLOR=Red]1[/COLOR]
end
Change those numbers. Simple.