i have a problem.
i want to know how can i change the equipment menu?
i want to use buttons.png and window.png for the windows any tips were can i get the info needed?
You would need to learn how to edit the scripts so that you can modify it in any way that you want... or find a script that does that.
That is not a question that doesn't deserve its own thread. Please start a new thread.
ALL of the menus use the default windowskins. You would need to find a script that uses images instead. Luna Engine might be a good starting point if you can't find anything else.
@Bloodmorphed:
If you want to only give the actor the skills he'd have learned from his class you could use
actor.init_skills
after doing the class switch.
Usually learn_skill and forget_skill are the only way a character changes his learned skills, so it's possible (although probably not very likely) other scripts rely on this behavior.
However, in this case, you probably also could divide all skills into different categories, and let only the right classes provide a certain skill category for the actor. In this case the actor won't forget the skills, but they are not shown in the skills menu.
At least you could reduce the loop a bit, so you don't have to create a new skills array for every iteration:
actor = $game_party.target_actor
actor.skills.each { |skill| actor.forget_skill(skill.id) }
actor.change_class ...
I want to properly draw an actor's graphic / sprite in a window. For example, here's what I do:
class Window_Murggs < Window_Base #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize super(0, 0, window_width, fitting_height(1)) refresh end #-------------------------------------------------------------------------- # * Get Window Width #-------------------------------------------------------------------------- def window_width return 160 end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh contents.clear $game_party.members.each do |mem| draw_actor_graphic(mem, 0, 0) end end #-------------------------------------------------------------------------- # * Open Window #-------------------------------------------------------------------------- def open refresh super endendBut it doesn't show the sprites...
What does it give you? Have you compared that to the other classes? I remember having some similar trouble a while ago, and I wasn't calling create_contents.
Yes, I seem to have been getting nothing whenever I display the sprites. I created a new method called create_contents and called it this way:
#-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh contents.clear create_contents end def create_contents $game_party.members.each do |mem| draw_actor_graphic(mem, 0, 0) end endBut still no sprites 🙁
You can't overwrite that method! Well, you can, but that won't help. 😀
What Shaz meant is that after the 'contents.clear' line, just simply add a 'create_contents' line. That is a default method in Window_Base, so you can call it without defining it in the class itself.
If that won't help, how does your character graphic looks like?
Maybe it is not using the right sheet setup. If your graphic got a $ sign before it's name, it should be a 3x4 sheet, if not, it should be a 12x8 sheet.
Also fitting_height(1) is not enough to display the graphic fully, unless your character's height is not bigger than 24 pixels. But I doubt this would prevent it to be displayed fully.
Add a 'p mem' line before the 'draw_actor_graphic' line. Start the game, open your scene and watch the console. If it prints out the members, than it iterates the members without problems. If not, than the problem lies in your party having no members, I guess..
I am using the default sprites, as this is a fresh project. I did it this way:
class Window_Murggs < Window_Base #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize super(0, 0, window_width, fitting_height(1) + 90) refresh end #-------------------------------------------------------------------------- # * Get Window Width #-------------------------------------------------------------------------- def window_width return 160 end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh contents.clear create_contents $game_party.members.each do |mem| draw_actor_graphic(mem, 0, 0) end end #-------------------------------------------------------------------------- # * Open Window #-------------------------------------------------------------------------- def open refresh super endendBut still the sprites doesn't seem to show. I just want to display the sprites of those certain members Turning Down (in the Set Move Route, where the position Turn Down is). However, this seems to be getting nowhere in my script :\
In case of the draw_actor_graphic method, the x/y parameters do not specify the upper left corner of the operation rect but the middle of the line below it.
Drawing your character sprites at 0/0 will therefore draw them outside of the bitmap. You could try 16/32 instead.
Ahh yeah, that should be the problem.
Which leads to another problem in your code.
You can't specify a direct value for x and y in an iteration when drawing something. It would result them being drawn on top of each other, and I guess, that's not what you want. So, depending on how you want to show them (vertically or horizontally lined up), you will need to add at least +32 to either Y or X after each drawings.
Great, the problem is solved. However, is there a way I can separate the sprites? They're being drawn on one place. I want them to be drawn in line in the window... like this:
| | | |
since everyone of them is cluttered on the same position.
as sixth mentioned it, you have to add 32 to your Y variable to show the sprites horizontal in line.
just make sure to add 32 every time a new sprite is shown.
Replace x and y with an actual number.
I just gave the syntax, not a direct solution.
x should be at least 16, and y should be at least 32.
Fixed, thank you very much.