Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - happyman

1
Hello! I'm using a very cool Zelda Screen Transitions script in my game. It's a script that breaks apart a big map into smaller segments and has a smooth scrolling animation between the segments, just like the original Zelda game.

Problem is my game has a world map too, and I don't want the world map to use this script, only the inner areas like caves and such.

So what can I do to turn off and on an entire script? My knowledge of scripts is pretty limited, but I can do small mods to a simple script. I've tried searching for a solution, but maybe I don't know what to look for... Thanks in advance!

Here's the script in case anyone wants to take a peek:

#==============================================================================
# ** Classic Zelda Screen Transitions
#------------------------------------------------------------------------------
# * Created by: albertfish
# * Version: 1.0
# * Last edited: September 7, 2010
#------------------------------------------------------------------------------
#  Version History:
#    Version 1.0: September 7, 2010
#      - Initial release
#------------------------------------------------------------------------------
#  Description:
#    This script mimics the screen transitions found in the 2D Zelda Games.
#------------------------------------------------------------------------------
#  Features:
#    - Separeated a large map in to small screen size parts and adds a smooth
#      transition between the parts.
#------------------------------------------------------------------------------
#  Install Instructions:
#    Place this script above the main script and below the default scripts.
#==============================================================================

#==============================================================================
# ** Spriteset_Map
#------------------------------------------------------------------------------
#  This class brings together map screen sprites, tilemaps, etc.
#  It's used within the Scene_Map class.
#==============================================================================

class Spriteset_Map
 #--------------------------------------------------------------------------
 # * Object Initialization
 #--------------------------------------------------------------------------
 alias af_czst_ssm_init initialize
 def initialize
   @x = ($game_player.x - $game_player.x % 20) * 128
   @y = ($game_player.y - $game_player.y % 15) * 128
   @amount_x = 0
   @amount_y = 0
   @scrolling = false
   @prev_x = $game_player.x
   @prev_y = $game_player.y
   $game_map.display_x = @x
   $game_map.display_y = @y
   af_czst_ssm_init
 end
 #--------------------------------------------------------------------------
 # * Scroll Right
 #--------------------------------------------------------------------------
 def scroll_right
   @x += 128
   @amount_x -= 1
   if @amount_x <= 0
     @scrolling = false
   end
 end
 #--------------------------------------------------------------------------
 # * Scroll Left
 #--------------------------------------------------------------------------
 def scroll_left
   @x -= 128
   @amount_x += 1
   if @amount_x >= 0
     @scrolling = false
   end
 end
 #--------------------------------------------------------------------------
 # * Scroll Up
 #--------------------------------------------------------------------------
 def scroll_up
   @y -= 96
   @amount_y -= 1
   if @amount_y <= 0
     @scrolling = false
   end
 end
 #--------------------------------------------------------------------------
 # * Scroll Down
 #--------------------------------------------------------------------------
 def scroll_down
   @y += 96
   @amount_y += 1
   if @amount_y >= 0
     @scrolling = false
   end
 end
 #--------------------------------------------------------------------------
 # * Frame Update
 #--------------------------------------------------------------------------
 alias af_czst_ssm_update update
 def update
   if !@scrolling
     # Determine if the screen needs to scroll left or right
     if $game_player.x % 20 == 0 && ($game_player.x - 19) * 128 > $game_map.display_x
       @amount_x = 20
       @scrolling = true
       @prev_x += 1
     elsif $game_player.x % 20 == 19 && ($game_player.x) * 128 < $game_map.display_x
       @amount_x = -20
       @scrolling = true
       @prev_x -= 1
     end
     # Determine if the screen needs to scroll up or down
     if $game_player.y % 15 == 0 && ($game_player.y - 14) * 128 > $game_map.display_y
       @amount_y = -20
       @scrolling = true
       @prev_y += 1
     elsif $game_player.y % 15 == 14 && ($game_player.y) * 128 < $game_map.display_y
       @amount_y = 20
       @scrolling = true
       @prev_y -= 1
     end
   else @scrolling
     # Scroll either left or right
     if @amount_x > 0
       scroll_right
     elsif @amount_x < 0
       scroll_left
     end
     # Scroll either up or down
     if @amount_y < 0
       scroll_down
     elsif @amount_y > 0
       scroll_up
     end
     $game_player.x = @prev_x
     $game_player.y = @prev_y
   end
   $game_map.display_x = @x
   $game_map.display_y = @y
   @prev_x = $game_player.x
   @prev_y = $game_player.y
   af_czst_ssm_update
 end
end
class Game_Character
 def x=(x)
   @x = x
 end
 def y=(y)
   @y = y
 end
end
2
Is it possible to call a common event whenever my character examines a tile with a terrain tag?  This would have to be the tile in front of the character, not the current tile the character is on.

I'm asking because I've written my own fishing event system, contained within one common event.  I want the player to fish in water anywhere in my game, but I don't want to put an event on every water tile (I've tried that, and of course it was horrible).  There must be a better way.


EDIT: Also, since I don't want to make two posts at once, I'm looking for good HP/SP Bars to be on screen at all times.  (It's called a HUD, right?)  But the only bars I can find are BlizzABS-only, and I'm not using BlizzABS.  Help?
3
Script Requests / Mouse control/shooting CBS
March 01, 2010, 03:42:25 am
I highly doubt this script will be created, due to the obvious difficulty.  But I would love to talk about the possibility, and what everyone thinks about it.


So I have this idea for a CBS.  My friends and I are discussing an RPG in a modern world setting, where the player uses guns to fight.  It's also important to note that there are no other party members.  Just one guy.  Basically, when the player enters a battle and selects the fight command, I want a 5-second timer to appear.  During those 5 seconds, the player can click on the enemies using the mouse to "shoot" them.  Once his 5 seconds are up, it's the enemies' turn.  On their turn, however, it would be just like a normal battle.


And that's exactly what it is.  Now imagine the customizations that would make this so cool:

Different weapons can have different statistics:
Dispersion rate.  A pistol could shoot 6 times during the player's 5 seconds, while a Shotgun can only fire twice.
Area damage.  A pistol has a small area of affection, while a shotgun can harm a large area.

Enemies would have weak points, where shooting the head of something would deal more damage, or shooting a shield would deal no damage (and maybe even reflect the bullet back at the player).  Enemies could move around the battlefield while you're shooting at them, making some enemies slow and easy to defeat, while others could be small, faster targets.

Special accessories could increase the attack time (from 5 seconds to 6), or they could increase the stats of a weapon (dispersion rate, increase area damage, shoot through shields, etc).
Equipping different kinds of ammo could affect damage or cause special effects (Fire bullets cause fire damage, Poison Bullets cause poison, Silver Bullets deal 2x damage to werewolves, etc).

Dual wielding using the left and right mouse buttons?  Possibly.  But normally you need to equip guns and bullets, and there's not really room for two guns and two bullets...  so. it would be cool, but I could live without it.

Special items, such as Grenades, would make use of this point-and-click battle system as well.

I'm not sure what other scripts will be used in the game, but I feel like a battle system is something that should be worked out first.  I would definitely use a one-man CMS.  There is no party in this game.  Do you think that simplifies the battle system, or does it create more problems?

So, do you think something like this can be made?  I've only played around with a few scripts, so I know this would span a few script pages.  I figure it might take 4, at the least.  1 script would enable mouse control in battle, 1 script would correct the player's battle turn to make it a 5-second live-action turn (there's no need to modify the enemies phase, but do you need to?  I don't know how modifying a CBS works), 1 script for enemy movements during battle and 1 script for the weapon/bullet/accessory customization database.  There probably needs to be more.

So what do you guys think?  (sorry if this is a lot of text, I just get really excited thinking about it)



4
Script Requests / Pop-up choice window?
November 21, 2009, 03:45:34 pm
I have a lot of instances in my game where the player is given choices.
I was wondering if I could script a choice window that pops-up separately from the other text window?

Also, can there be more than four choices?  Often times, I have to use "more choices" as the 4th choice, which branches off to other choices, and I hate it.  If too many choices appear onscreen, can the choices scroll up to reveal more?

I've searched, but couldn't find a script for this.  If one is made, are there easy instructions to fully manipulate it?
5
I've never requested a script before, so please excuse me if I'm out of line anywhere.

I'm making a Harvest Moon/Animal Crossing Game and I need a way of giving items to NPCs as gifts.

Here's what I really want to happen:
When you speak with a character, the player is given three choices:  Talk, Gift, Nevermind (or something).  Obviously, choosing "Talk" would display text for the specified character.  I don't have a problem here, or with the choice "Nevermind."  :D  But when you choose "Gift," I need a menu to pop up, displaying a list of items currently in possession of the party.  I'm thinking selecting an item would deplete held quantity of said item by 1, and a text box would display for the NPC.  If I can store the selected item as a variable, then I can use Condition Branch to determine different reactions from the NPC depending on the item.  Example: "Oh, thank you, I love flowers!"  or "Ew!  Gross!  I hate bugs!"  I have variables that determine the happiness of every NPC, which would change depending on the gift.

I also think it's important to cancel the process of gifting while the window's open.  Doing so would probably Jump to a Label, specified in the "Nevermind" option.  <-- Unless someone thinks of a better way.

So that's it.  I want to be able to control this script with eventing (I'm not sure if I even need a script).  All I need is the power to summon a Gift Window when a player chooses "Gift," and assign the selected item to a variable.  Seems simple enough, I hope.

Coincidentally, I'm also having trouble finding a good HP/SP bar displayed onscreen during gameplay (Not in the menu or battle, in the field).  Can anyone help me out?  Thanks for any help :)

Edit:
I forgot to mention, I'm using some scripts already.  Don't know if they'll affect this request though.  I'm using Blizzard's ATES, a Ring CMS and an AMS (advanced message script).  The CMS might be a problem if you think i need to access the menu to get to the items...  But I'm not a scripter and idk.

Added resolved tag ~ G_G