-
Content Count
86 -
Joined
-
Last visited
Community Reputation
4About Caedmon

-
Rank
Advanced Member
-
Will do. The same logic made it very easy to do the weapon one now That one is looking complete, now onto the item one which will just be icons and move horizontally..... this will hopefully make me think some more
-
Thank you very much for all your help pencilcase27. Here is the semi finished look: https://www.dropbox.com/s/n8mdbn4hkzw3hng/SFStatus.png?dl=0 I am going to try and use your logic to finish the equip and item windows. My previous method for the equip only displayed text
-
I agree dbchest. He is making me think now Every little bit is stretching my knowledge of Ruby. Between pencilcase and dp3's tutorials I hope to be self sufficient one day EDIT: Well If I spell out draw_text arguments with rect.x, rect.y, rect.width, line_height instead of just rect it is looking better.
-
Ah yes I see what you mean. how about my discrepancy in line spacing?
-
Okay I have it working..... partially..... no errors and the icon and skill both appear, but just not together class Window_Skill < Window_Base #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize (actor) super(145,25,155,210) self.opacity = 200 @actor = actor refresh end def actor=(actor) return if @actor == actor @actor = actor refresh end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh contents.clear draw_skill_text (line_height * 0) draw_skills (@actor) end def draw_skill_text (y) oldcolor = self.contents.font.color self.contents.font.color = Color.new(255,215,0) self.draw_text(0,y,80,line_height, "MAGIC") self.contents.font.color = oldcolor end def skill_item_rect Rect.new(0, 24, 155, 210-24) end def draw_skills (actor) rect = skill_item_rect @actor.skills.each_with_index do |skills, i| for skill in @actor.skills.each draw_text(rect, skill.name) draw_icon(skill.icon_index,rect.x,rect.y) rect.y += (line_height * 1) end end end end It kept kicking out the draw_icon argument so I changed it around to match Scene_Base and it appears in the right spot. draw_text appears but it appears a few lines lower than the icon. I also notice if I give them more than one skill that the skills repeat. In this test they had Tackle and Chakra. the icons went tackle, chakra, tackle, chakra. Text followed suit albeit a few lines lower. https://www.dropbox.com/s/n8mdbn4hkzw3hng/SFStatus.png?dl=0
-
skills would be the value (or item) in your link, which would be @actor.skills right? Which below would be the line: draw_text(rect, skill.name, 2) EDIT: So in understanding the for, in method. the for is calling to something below in this case skill, which is used in the skill.name and the in is calling to something above.
-
Hmmm I assumed it was grabbing from |skills, i|
-
I love the challenge. I will take a stab and let you know Thanks for the guidance..... to be continued...... class Window_Skill < Window_Base #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize (actor) super(145,25,155,210) self.opacity = 200 @actor = actor refresh end def actor=(actor) return if @actor == actor @actor = actor refresh end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh contents.clear draw_skill_text (line_height * 0) draw_skills end def draw_skill_text (y) oldcolor = self.contents.font.color self.contents.font.color = Color.new(255,215,0) self.draw_text(0,y,80,line_height, "MAGIC") self.contents.font.color = oldcolor end def skill_item_rect Rect.new(0, 0, 155, 210) end def draw_skills rect = skill_item_rect @actor.skills.each_with_index do |skills, i| for skill in skills draw_text(rect, skill.name, 2) draw_icon(rect, skill.icon_index) rect.y += (line_height * 1) end end end end It doesn't like the for skill in skills line. It says there is a problem with the 'each'
-
Okay so what am I missing at this point: class Window_Skill < Window_Base #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize (actor) super(145,25,155,210) self.opacity = 200 @actor = actor refresh end def actor=(actor) return if @actor == actor @actor = actor refresh end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh contents.clear draw_skill_text (line_height * 0) draw_skills end def draw_skill_text (y) oldcolor = self.contents.font.color self.contents.font.color = Color.new(255,215,0) self.draw_text(0,y,80,line_height, "MAGIC") self.contents.font.color = oldcolor end end 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 it seems to be barking at new_rect_for_first_skill. Undefined local variable on it.
-
Just show them in this case. Good to see you again pencilcase27
-
Hey thanks for the help i have been away from a computer so i will try this tonight and let you know. EDIT: Worked like a charm, of course! Thanks again.
-
Changing that to start does make the window behind the window disappear, which is great. Makes it look much crisper. Scroll issue still remains though. Can I give you a virtual high five though for your help? ^5
-
Oh sorry I was playing with that to see if it made a difference, I did have it in there right the first time. EDIT: You are a genius and I am a fool Thank you very much for that. Any idea how to fix the scroll down on the list? Also noticed that when I scroll down my headers vanish and an actor takes it place...... always something to work on
-
I sure will. I did do a test again and noticed that when I scroll to the bottom of my list that there appear to be multiple list windows. In the empty area of my list I see actors names blurred through the window opacity behind. I will edit this post shortly with the whole script.
-
Well I certainly get the 0 to pop up but it keeps refreshing the 0 and I am unable to get a 1 or 2 to populate.



