Jump to content
New account registrations are disabed. This website is now an archive. Read more here.

Leon

Legend
  • Content Count

    1,713
  • Joined

  • Last visited

  • Days Won

    23

Everything posted by Leon

  1. What you are missing in your initial coding in the first post is the ID of the item. Without that, you cannot distiguish 1 item from the others. Further, there is not variable or method named 'item' in Game_Party, so calling on that will not work. If I had more information on how you plan on using the code snippet, i could offer a better method. For instance, if you plan on using this in-script, or in an event and calling it that way. If you are planning calling it through event, I suggest a variable identifying the item's ID. Then use: $game_party.items[x].icon_name == "icon_name" Of course, to use that, you have to use the 4th tab under conditional branch in the event setup AND add this small script into your game to allow you to access the hash setup for items the party owns: class Game_Party attr_accessor :items end Now, the other way doesn't include using Game_Party, but goes straight to the item database. To use this method, use: $data_items[x].icon_name == "icon_name" Now, x must equal the item's ID. For instance, if the item is item number 4, then x must equal 4.
  2. As I said before, you are always welcome back; and ergo, greeted with open arms. Welcome back.
  3. First, to draw people to download, it would help to have some story information and screenshots. Give a little razzle-dazzle. You have to make it sound and look appealing (like on the back of a game case.) Let me give you an example from one of my previous demos.
  4. You must make the previous Tone change not trigger again. A good switch helps with that.
  5. Leon

    HP/SP Script Help

    You could, but it will off-center it some. Here's a crack at it: class Window_Base def draw_actor_hp(actor, x, y, width = 144) # Draw "HP" text string self.contents.font.color = system_color self.contents.draw_text(x, y, 32, 32, $data_system.words.hp) # Calculate if there is draw space for MaxHP if width - 32 >= 108 hp_x = x + width - 108 flag = true elsif width - 32 >= 48 hp_x = x + width - 48 flag = false end # Draw HP self.contents.font.color = actor.hp == 0 ? knockout_color : actor.hp <= actor.maxhp / 4 ? crisis_color : normal_color self.contents.draw_text(hp_x - 8, y, 48, 32, actor.hp.to_s, 2) # Draw MaxHP if flag self.contents.font.color = normal_color self.contents.draw_text(hp_x + 48 - 8, y, 12, 32, "/", 1) self.contents.draw_text(hp_x + 60 - 8, y, 48, 32, actor.maxhp.to_s) end end #-------------------------------------------------------------------------- # * Draw SP # actor : actor # x : draw spot x-coordinate # y : draw spot y-coordinate # width : draw spot width #-------------------------------------------------------------------------- def draw_actor_sp(actor, x, y, width = 144) # Draw "SP" text string self.contents.font.color = system_color self.contents.draw_text(x, y, 32, 32, $data_system.words.sp) # Calculate if there is draw space for MaxHP if width - 32 >= 108 sp_x = x + width - 108 flag = true elsif width - 32 >= 48 sp_x = x + width - 48 flag = false end # Draw SP self.contents.font.color = actor.sp == 0 ? knockout_color : actor.sp <= actor.maxsp / 4 ? crisis_color : normal_color self.contents.draw_text(sp_x - 8, y, 48, 32, actor.sp.to_s, 2) # Draw MaxSP if flag self.contents.font.color = normal_color self.contents.draw_text(sp_x + 48 - 8, y, 12, 32, "/", 1) self.contents.draw_text(sp_x + 60 - 8, y, 48, 32, actor.maxsp.to_s) end end end class Window_BattleStatus def refresh self.contents.clear @item_max = $game_party.actors.size for i in 0...$game_party.actors.size actor = $game_party.actors[i] actor_x = i * 160 + 4 draw_actor_name(actor, actor_x, 0) draw_actor_hp(actor, actor_x, 32, 150) draw_actor_sp(actor, actor_x, 64, 150) if @level_up_flags[i] self.contents.font.color = normal_color self.contents.draw_text(actor_x, 96, 120, 32, "LEVEL UP!") else draw_actor_state(actor, actor_x, 96) end end end end
  6. Leon

    HP/SP Script Help

    Which game maker? VX or XP?
  7. Sorry, but one for RMXP requires hacking the core system. You see, they added this into RGSS2
  8. UPDATE: The previous version allowed the viewmap in the lower right corner to see the upper left corner. Has been corrected.
  9. Use a variable. That is a hint. Instead of the number '2', use a variable to call up the event's ID. If you need mroe syntaxes related to variables, use the RGSS Library in the Help file.
  10. I like digging into the vault of old games.
  11. I just wanted to *bump* this so people knew it existed.
  12. Use a switch to end it. set a local switch to 'a', then add a new page that needs that switch on as a prerequisite.
  13. This script will allow you to resize your RMVX game window to allow a larger or smaller window for gameplay. Instructions are in the script's header. Enjoy! ~Leon #=============================================================================== # * Resize RMVX by Leon_Westbrooke - v. 1.1 #------------------------------------------------------------------------------- # This script allows you to resize the game window for your RMVX game. # # Instructions: Fill out the module's values for WIDTH and HEIGHT. # # Notes: # All other menus will have to be rewritten to fill the screen completely. # You can do this, or search for any scripts that use a larger/smaller # display size. I will be writing some scripts for 640x480 display; mainly # because I prefer that size. # # The max size is 640x480. # # Overwritten Methods: # Game_Player # center(x, y) # Game_Map # setup_scroll # scroll_down(distance) # scroll_right(distance) #=============================================================================== #------------------------------------------------------------------------------- # * RESIZE module #------------------------------------------------------------------------------- module RESIZE #----------------------------------------------------------------------------- # Sets width of the window. #----------------------------------------------------------------------------- WIDTH = 640 #----------------------------------------------------------------------------- # Sets height of the window. #----------------------------------------------------------------------------- HEIGHT = 480 end #------------------------------------------------------------------------------- # END RESIZE module #------------------------------------------------------------------------------- #------------------------------------------------------------------------------- # * Game_Player class #------------------------------------------------------------------------------- class Game_Player #----------------------------------------------------------------------------- # CENTER_X and CENTER_Y are recalculated with a variable instead of integer. #----------------------------------------------------------------------------- CENTER_X = (RESIZE::WIDTH / 2 - 16) * 8 CENTER_Y = (RESIZE::HEIGHT / 2 - 16) * 8 #-------------------------------------------------------------------------- # * Set Map Display Position to Center of Screen # x : x-coordinate # y : y-coordinate #-------------------------------------------------------------------------- def center(x, y) display_x = x * 256 - CENTER_X # Calculate coordinates unless $game_map.loop_horizontal? # No loop horizontally? max_x = ($game_map.width - (RESIZE::WIDTH / 32)) * 256 # Calculate max value display_x = [0, [display_x, max_x].min].max # Adjust coordinates end display_y = y * 256 - CENTER_Y # Calculate coordinates unless $game_map.loop_vertical? # No loop vertically? max_y = ($game_map.height - (RESIZE::HEIGHT / 32)) * 256 # Calculate max value display_y = [0, [display_y, max_y].min].max # Adjust coordinates end $game_map.set_display_pos(display_x, display_y) # Change map location end end #------------------------------------------------------------------------------- # END Game_Player class #------------------------------------------------------------------------------- class Game_Map def setup_scroll @scroll_direction = 2 @scroll_rest = 0 @scroll_speed = 4 @margin_x = (width - (RESIZE::WIDTH / 32)) * 256 / 2 # Screen non-display width /2 @margin_y = (height - (RESIZE::HEIGHT / 32)) * 256 / 2 # Screen non-display height /2 end #-------------------------------------------------------------------------- # * Scroll Down # distance : scroll distance #-------------------------------------------------------------------------- def scroll_down(distance) if loop_vertical? @display_y += distance @display_y %= @map.height * 256 @parallax_y += distance else last_y = @display_y @display_y = [@display_y + distance, (height - (RESIZE::HEIGHT / 32)) * 256].min @parallax_y += @display_y - last_y end end #-------------------------------------------------------------------------- # * Scroll Right # distance : scroll distance #-------------------------------------------------------------------------- def scroll_right(distance) if loop_horizontal? @display_x += distance @display_x %= @map.width * 256 @parallax_x += distance else last_x = @display_x @display_x = [@display_x + distance, (width - (RESIZE::WIDTH / 32)) * 256].min @parallax_x += @display_x - last_x end end end #------------------------------------------------------------------------------- # Resizes game. #------------------------------------------------------------------------------- Graphics.resize_screen(RESIZE::WIDTH, RESIZE::HEIGHT) #------------------------------------------------------------------------------- # END Resize #-------------------------------------------------------------------------------
  14. Dude! The merchant on ark's map goes through the tent! it goes in just left of hte doorway. And no ambience music Ark? uncharacteristic of you.
  15. Yeah, make sure it was a fair run. I mean, come on! ARK beating me? (I am SOOOO jk)
  16. You know, I would like a view at each contestant's maps. That too would be nice.
  17. Ark, Congradulations. Guess my reign is over.
  18. I know you are a man of your word, kiriashi, but I seriously believe that Chief will show. He has merely 5 hours and 45 minutes, and I don't think he'll make it. However, I do respect your decision.
  19. Time for series two of the infamous Name That Game! Here we go. A total of 6 points possible, 3 per. Points will be divided among all winners. Ark got 3 SP for his guess in the previous round, and none were awarded for Bionic Commando. Next two games are in the top post.
  20. Open the Help file and look under RPG Maker XP - Material Specifications. Or you can look at this site
  21. It isn't the quantity of posts, but the quality of posts. So long as they are relevent and helpful, it is a quality post.
  22. Go in the database, under 'Tilesets' and set their passability for O to X
  23. No worries, man. I'm just borrowing a page from Shadows of the Forgotten for ambience; and added a touch of coding for... a spritz of fun. Yes, both are mapping related. EDIT: Resubmitted.
  24. I shall start work with those 500 lines. *cracks knuckles* gotta get to work, now. Ark, I love you. Eat my dust.
×
×
  • Create New...