[RM ACE] HELP WITH MENU
Posts
Pages:
1
Shit got me fucked up. I'm using Yanfly's JP Manager, and I have it tweaked to where it shows the JP amount (I label it 'SP' instead) in the status screen. However
SP is all weird and whatnot. How do I align it with and under the LV stat, so SP is under LV and how much SP is under the LV numerical?
SP is all weird and whatnot. How do I align it with and under the LV stat, so SP is under LV and how much SP is under the LV numerical?
Base it on this function in Window_Base:
Now, as I look at the JP Manager code, it looks like it should automatically have it in the order of "SP <num>", by way of:
That code there. Basically, that's going to draw the icon (if there is one), the vocab for the JP, and then the JP number itself. If you've written it in yourself to show the SP, you can provbably instead just use this:
Insert a new script
I commented out the section to show the status icons as I'm not sure where you're displaying them with your intended change. That should basically line it all up, if what I'm reading from the JP Manager Script is correct is correct.
Let me know if that works or if I should wake up more before attempting some patchwork code.
Edit: Spelling corrections. Spelling corrections everywhere.
def draw_actor_level(actor, x, y)
change_color(system_color)
draw_text(x, y, 32, line_height, Vocab::level_a)
change_color(normal_color)
draw_text(x + 32, y, 24, line_height, actor.level, 2)
end
Now, as I look at the JP Manager code, it looks like it should automatically have it in the order of "SP <num>", by way of:
#--------------------------------------------------------------------------
# new method: draw_actor_jp
#--------------------------------------------------------------------------
def draw_actor_jp(actor, dx, dy, dw = 112)
draw_icon(Icon.jp, dx + dw - 24, dy) if Icon.jp > 0
dw -= 24 if Icon.jp > 0
change_color(system_color)
draw_text(dx, dy, dw, line_height, Vocab::jp, 2)
dw -= text_size(Vocab::jp).width
change_color(normal_color)
draw_text(dx, dy, dw, line_height, actor.jp.group, 2)
end
That code there. Basically, that's going to draw the icon (if there is one), the vocab for the JP, and then the JP number itself. If you've written it in yourself to show the SP, you can provbably instead just use this:
Insert a new script
class Window_Base < Window
def draw_actor_simple_status(actor, x, y)
draw_actor_name(actor, x, y)
draw_actor_level(actor, x, y + line_height * 1)
draw_actor_jp(actor, x, y + line_height * 2, 56)
#draw_actor_icons(actor, x, y + line_height * 2)
draw_actor_class(actor, x + 120, y)
draw_actor_hp(actor, x + 120, y + line_height * 1)
draw_actor_mp(actor, x + 120, y + line_height * 2)
end
end
I commented out the section to show the status icons as I'm not sure where you're displaying them with your intended change. That should basically line it all up, if what I'm reading from the JP Manager Script is correct is correct.
Let me know if that works or if I should wake up more before attempting some patchwork code.
Edit: Spelling corrections. Spelling corrections everywhere.
Well, I messed around with that new script you made and I got the 'SP' value to line up perfectly under the LV value by changing
to
BUT the actual numerical value is still to the left of SP instead of the right like the numerical value for LV is.
edit: lol fixed the code tags so you can actually see it
draw_actor_jp(actor, x, y + line_height * 2, 56)
to
draw_actor_jp(actor, x, y + line_height * 2, 26)
BUT the actual numerical value is still to the left of SP instead of the right like the numerical value for LV is.
edit: lol fixed the code tags so you can actually see it
All right, I made some changes, tested it, this should work; make sure it's pasted below the JP Manager script:
You appear to have a bit more space between your LV text and the the actual level number than I do in the project I tested it on, so you may need to tinker with the part that reads "dx + 32" to get the right spacing.
Again, status icons are commented out because I'm not sure how you want to display them, if at all.
class Window_Base < Window
def draw_actor_simple_status(actor, x, y)
draw_actor_name(actor, x, y)
draw_actor_level(actor, x, y + line_height * 1)
draw_actor_jp(actor, x, y + line_height * 2, 56)
#draw_actor_icons(actor, x, y + line_height * 2)
draw_actor_class(actor, x + 120, y)
draw_actor_hp(actor, x + 120, y + line_height * 1)
draw_actor_mp(actor, x + 120, y + line_height * 2)
end
def draw_actor_jp(actor, dx, dy)
change_color(system_color)
draw_text(dx, dy, 32, line_height, Vocab::jp)
change_color(normal_color)
draw_text(dx + 32, dy, 24, line_height, actor.jp.group, 2)
end
end
You appear to have a bit more space between your LV text and the the actual level number than I do in the project I tested it on, so you may need to tinker with the part that reads "dx + 32" to get the right spacing.
Again, status icons are commented out because I'm not sure how you want to display them, if at all.
Oh, because I'm daft and changed the arguments after I pasted it in here.
On the draw_actor_jp line in the draw_actor_simple_status method, change it to:
draw_actor_jp(actor, x, y + line_height * 2)
I removed the need for the draw width argument and forgot to edit the version I pasted here (sorry).
On the draw_actor_jp line in the draw_actor_simple_status method, change it to:
draw_actor_jp(actor, x, y + line_height * 2)
I removed the need for the draw width argument and forgot to edit the version I pasted here (sorry).
It works!
One more thing though.
I figured a three digit max would be a good limit to how much SP one can acquire. But when I set the current SP to a three digit number (or higher) it gets all scrunched up like this
Is this a fundamental issue with my font code or something else?
One more thing though.
I figured a three digit max would be a good limit to how much SP one can acquire. But when I set the current SP to a three digit number (or higher) it gets all scrunched up like this
Is this a fundamental issue with my font code or something else?
Nope - it's an easy fix, actually, but does require changing some numbers.
Just change the draw_actor_jp from my previous version to that. All it does is make the area it draws the number wider and moves it slightly to the left to account for that.
def draw_actor_jp(actor, dx, dy)
change_color(system_color)
draw_text(dx, dy, 32, line_height, Vocab::jp)
change_color(normal_color)
draw_text(dx + 20, dy, 36, line_height, actor.jp.group, 2)
end
Just change the draw_actor_jp from my previous version to that. All it does is make the area it draws the number wider and moves it slightly to the left to account for that.
Pages:
1