-
Content Count
267 -
Joined
-
Last visited
-
Days Won
1
Content Type
Profiles
Forums
Calendar
Blogs
Gallery
Everything posted by pencilcase27
-
CardGame inspired skill and battle system
pencilcase27 replied to pencilcase27's topic in Completed Scripts/Plugins/etc.
Currently I'm not able to do much but I really hope that I'll find some time to look at my old project in the next two months. There are still some things I am not very happy with and I'd like to change. But hey, I'm not dead -
Do you want the shop or the item to determine its cost? (Do you want the item to have a note tag that determines it cost or is this cost dependend on the shop you are visiting?) Your mockup has no selling feature. Do you want this removed for those kind of shops?
-
Oh, I kinda forgot about this. Sorry I'll take a look right away. Edit: You find the switch to turn this script on and off at the top of the script. Just replace the 1 with whatever number you want. I hope I fixed the bug.
-
I wrote something like this some time ago. I'll see if I find it. Edit: http://www.rpgmakervxace.net/topic/27075-script-mp-points-used-spell-power/ Not the most beautifull script, but if you need some changes, feel free to ask.
-
$game_variables[x..y] is an array containing all variables between x and y (including both of them). Now you can check them for values using .include?() $game_variables[5..8].include?(11) #=> true if either 5 or 6 or 7 or 8 equals 11. You should be able to use this in the script option of conditional branches.
-
Like this?
-
Trying to figure out how to make the damage formula's Dragon Quest style
pencilcase27 replied to GethN7's topic in Editor Support and Discussion
I don't understand this line 15 + 23 MATK x 2 = 76 - 23 MDEF x 2 = 30 DMG You can type anything you want into that window. If you want your skill deal 15 damage, write 15. -
class Window_BattleLog < Window_Selectable def normal_color Color.new(255, 255, 255) end end This would be the easiest way to change the color in a vanilla project without any scripts. Try placing this beneath all other scripts. If it doesn't work, please post the script you already use that changes your color.
-
@dbchest Yeah, thats mostly it. (http://en.wikipedia.org/wiki/Pseudocode)
-
Looking good! If you need help with those too, just send me a pm.
-
He, glad you like it. I enjoy helping and teaching people as long as they really want to learn. If the texts placement is off, you'll have to look at the thing that determines the location of your text: rect. Rect.new(0, 24, 155, 210 - 24) is a rectangle of width = 155 and height = 186. It's upper right corner is located at x = 0 and y = 24 of the bitmap, in this case the windows contents. Spelling out rect.x, rect.y, rect.width, line_height is equivalent to Rect.new(0, 24, 155, 24) since line_height = 24. And since now your rect has the same height as your text, it will be placed correct. "old rect with text" "new rect with text"
-
You still have two for - loops. This @actors.skills.each do |skill| ... end and this for skill in @actor.skills ... end means the same thing. When you write it twice, it will happen twice.
-
if you have an array like [1, 2, 3] and then use an each method on it, it looks like this: [1, 2, 3].each { |x| ...do stuff... } And in this case, "x" is the current number you use for what you do something. Now when you have an array of skills, like @actor.skills, and you use the each method on it, it looks like this: @actor.skills.each { |skills| ...do something } (or each_with_index, however I don't see why you need the index) and then, "skills" is the current skill you want to do something with (therefore I'd rather name it skill). And now you take that skill and use another each method on it. But the thing you named skills is not an array, its an element out of that array. So all you need to do is to remove the second if - loop and name the array item skill (or you could change the method arguments to skills,name and skills.icon).
-
Yes, but what IS skills? http://www.ruby-doc.org/core-2.1.4/Array.html#method-i-each
-
for skill in skills What is 'skills'?
-
This means that you'll have to write this method yourself I only wrote what the method has to do, not how it does it. You seemed interested in learning a little bit of scripting so I thought giving you just an idea on how to do this rather than a full solution would be better. If you however struggle and need help or simply want me to write it for you, that's fine, too. If you try to write this yourself, you'll need to know what a Rect is. Just type it into the help window (F1)
-
Compare party's speed in battle and use a specific skill based on who has the highest speed.
pencilcase27 replied to (n/a)'s topic in Programming
Battle Event, script, set condition to end of turn and time span to each round: # This gets the actor with the highest agi. actor = $game_party.battle_members.max_by { |member| member.agi } # Array of actor leader skill ID's [1st Actor, 2nd Actor, ... ] skills = [3, 9, 13, 2, 4] # -1 means random target. Set to -2 to make the skill choose the last target. actor.force_action(skills[actor.id], -1) # Don't touch this. BattleManager.force_action(actor) You'll need to add this event to every troop, or you could use a script (made by Yanfly I think) that lets you set one main battle event that runs for every troop. -
In this case, I think inheriting your window from Window_SkillList is not a good idea, since this inherits from Window_Selectable. And you don't want to select stuff, only show it. In this case I'd recomend you start with class Window_Skills < Window_Base. Then it also needs an @actor and an setter for this actor, something like def actor=(...). For this you can take a look at Window_SkillList how they did this. Next the window needs a method that returns an array of the four skills of @actor. Now you can write the method that draws those skills. In pseudo code this would look like this: def draw_skills rect = new_rect_for_first_skill for skill in skills draw_text(rect, skill.name, right_alignment) draw_icon(rect, skill.icon_index) move_rect_one_line_down end end And finally you'll need to add this method to the refresh method of this window.
-
Do you want to select the skills and do something with them or do you only want to show them?
-
You can use the script in any way you want to, but if you're done with your project and start selling it, a free copy would be appreciated. As a scripter it is always nice to see your script used in a game. BUT this script is written for a vanilla project and I don't know how it works with any parcour mod you mentioned. It even has some issues with reversing animations shown on the map and while I can probably fix that, writing any compatibility patches is most likely out of questions. I recomend testing this very carefully. What the script basicly does is saving the game every frame and adding that save to a big list. When you reverse time, with each frame, it loads the last save and then removes it from the list. Since saving is something every script should work with, I have high hopes that compatibility is high, but I can't make any promises.
-
I have something that sounds like you could use it. This allows you to reverse time on the game map via button press. Maybe it would be a good idea to try this in a new project first to see if it does what you want.
-
Your page ends one row earlier, but in total you have one row more. class Window_ActorList < Window_Selectable def page_row_max super - 1 end def row_max super + 1 end end
-
If you look closely, you'll see that the actor window also has a second window with the initial actor in it. The reason for this lies within the way the background sprite is made. Just create the windows in the start method (and not the initialize method) of the scene by changing def initialize... end to def start... end
-
def update super @status_window.actor = @list_window.current_actor @list_window.page - 1 if Input.repeat?(:LEFT) @list_window.page + 1 if Input.repeat?(:RIGHT) end Its += and -=, not just + and - Edit: def page=(i) page = i # set the page to i @page = 0 if @page > 2 # keeps the page @page = 2 if @page < 0 # in range (0..2) refresh # redraws the window RPG::SE.new("Cursor1").play # maybe play a cursor sound? end You wrote page = i instead of @page = i Jep, the second one fixed it. Works for me now.


