Submit Your Article


 
RPG Maker

Welcome Guest ( Log In | Register )


  Games Resources RPG Maker VX RPG Maker XP Scripts Tutorials Downloads

 
Reply to this topicStart new topic
> + [ Sprite Mover ] +, * Move sprite in pixel to get right location~
woratana
post Jun 2 2008, 09:06 PM
Post #1


Looking for scripter to hire? PM me *O*
Group Icon

Group: +Gold Member
Posts: 1,038
Type: Scripter
RM Skill: Undisclosed




Sprite Mover
Version 1.0
by Woratana
Release Date: 02/06/2008


Introduction
This is a little snippet I wrote for my project.
It's to fix the problem that sprite is too high or too low for the tiles behind.

I actually ran into this problem when I'm trying to put stuffs in 1 block height of cave's ground.
So I think to use script is easier than edit the sprite image~ biggrin.gif

Enjoy~ laugh.gif


Screenshots

The red fire use Sprite Mover, the blue fire doesn't~


Script
Place it above main
Attached File  VX_SpriteMover10.txt ( 2.18K ) Number of downloads: 351




Instruction
In the event page that you want to move sprite, add comment:
QUOTE
MOVE x_plus, y_plus

** x_plus: how many pixel you want to move sprite horizontally
(- number: move left | + number: move right)
** y_plus: how many pixel you want to move sprite vertically
(- number: move up | + number: move down)

For example, add comment:
QUOTE
MOVE 0, -20

to move sprite up 20 pixel~


Author's Notes
Free for use in your work if credit is included.


Bug Report?
Please give me these informations:
QUOTE
- What is it says in error window?
- When is it get error? (Right after run game, when you choose something, etc.)
- Do you have any other scripts running in your game that may crash with this script?


__________________________
Check out my NEW blog!!!



MVP (Most Valuable Poster) Award 2008


Go to the top of the page
 
+Quote Post
   
aevonhaldy
post Jun 2 2008, 09:58 PM
Post #2


Level 4
Group Icon

Group: Member
Posts: 58
Type: Developer
RM Skill: Beginner




Wow, this will really help maps look a lot nicer! And like you said, it is easier than editing the sprite itself. Thanks, Woratana!


__________________________
[Show/Hide] VX Project

Story - 85%
Database - 55%
Scripts - 90%
Maps - 8%
Graphics - 38%
Original Music - 20%
Go to the top of the page
 
+Quote Post
   
AmIMeYet
post Jun 15 2008, 07:25 AM
Post #3


new av & (dynamic) sig!
Group Icon

Group: Revolutionary
Posts: 149
Type: Scripter
RM Skill: Undisclosed




This adds a lot more realism to maps..... great idea!
Very usefull for forests and other places with a lot of misc. stuff on the ground...

EDIT: Does it movethe whole event, or only the graphic? (Like if you move it more than 32 pixels, do you use it at the original position, or where the graphic is then placed?

This post has been edited by AmIMeYet: Jun 15 2008, 07:55 AM


__________________________

>>Latest EventScripter news: Conditional Branches fully working! Currently working on a documentation site. Topic: EventScripter
>>Portals (yes, in RPG Maker VX!)
>>Working with Sojabird on his Scriptology; I also invented Scriptuzzle.. Try one; make one!
[Show/Hide] USEFULL script snippets:
[Show/Hide] Do require's in VX:
CODE
$LOAD_PATH << Dir.getwd #You only need to call this once
Kernel.require("includable.rb") #replace includable.rb with the name of the file you want to load
[Show/Hide] Invert Dash enabling:
CODE
#=============================================================================#
# # #                            ANTI DASH HACK                           # # #
# # #                              By AmIMeYet                            # # #
# # #                           please credit me                          # # #
#=============================================================================#
class Game_Player < Game_Character
  def dash?
    return false if @move_route_forcing
    return false if in_vehicle?
    return true if Input.press?(Input::A) and $game_map.disable_dash?
  end
end

This snippet basically inverts the dashing.. allowing you to dash only when 'disable dashing' is checked.
This way, normal maps disable dashing, but the ones you set to disable actually allow dashing..

It should be placed where you normally place the scripts ('above main', in the materials section of the scripts window)..
Go to the top of the page
 
+Quote Post
   
woratana
post Jun 15 2008, 08:50 AM
Post #4


Looking for scripter to hire? PM me *O*
Group Icon

Group: +Gold Member
Posts: 1,038
Type: Scripter
RM Skill: Undisclosed




It's not pixelmovement. so it will move only graphic. smile.gif

And if you want to move event 32 pixel, you can just move it to other block. Don't need this script. tongue.gif


__________________________
Check out my NEW blog!!!



MVP (Most Valuable Poster) Award 2008


Go to the top of the page
 
+Quote Post
   
AmIMeYet
post Jun 15 2008, 10:18 AM
Post #5


new av & (dynamic) sig!
Group Icon

Group: Revolutionary
Posts: 149
Type: Scripter
RM Skill: Undisclosed




QUOTE (woratana @ Jun 15 2008, 06:04 PM) *
It's not pixelmovement. so it will move only graphic. smile.gif

And if you want to move event 32 pixel, you can just move it to other block. Don't need this script. tongue.gif

Yes, I know that, but I mean it as a 'what if' scenario... an example....
But you just answered my question, so I understand it now smile.gif


__________________________

>>Latest EventScripter news: Conditional Branches fully working! Currently working on a documentation site. Topic: EventScripter
>>Portals (yes, in RPG Maker VX!)
>>Working with Sojabird on his Scriptology; I also invented Scriptuzzle.. Try one; make one!
[Show/Hide] USEFULL script snippets:
[Show/Hide] Do require's in VX:
CODE
$LOAD_PATH << Dir.getwd #You only need to call this once
Kernel.require("includable.rb") #replace includable.rb with the name of the file you want to load
[Show/Hide] Invert Dash enabling:
CODE
#=============================================================================#
# # #                            ANTI DASH HACK                           # # #
# # #                              By AmIMeYet                            # # #
# # #                           please credit me                          # # #
#=============================================================================#
class Game_Player < Game_Character
  def dash?
    return false if @move_route_forcing
    return false if in_vehicle?
    return true if Input.press?(Input::A) and $game_map.disable_dash?
  end
end

This snippet basically inverts the dashing.. allowing you to dash only when 'disable dashing' is checked.
This way, normal maps disable dashing, but the ones you set to disable actually allow dashing..

It should be placed where you normally place the scripts ('above main', in the materials section of the scripts window)..
Go to the top of the page
 
+Quote Post
   
Netto
post Jun 15 2008, 10:33 AM
Post #6


芸術家
Group Icon

Group: Revolutionary
Posts: 708
Type: None
RM Skill: Skilled




This is great, less work to do on mapping now laugh.gif


__________________________
Current Project[RC]: Twilight Realm 3DMMORPG w/dx9, and char creation through mysql after I get a server, now C++ scripting
Current Project[VX]: Obsidian Trilogy just started 08/12/2008
Current Project[XP&RM2K3]: none
Go to the top of the page
 
+Quote Post
   
Mr_E_Man
post Jun 19 2008, 01:04 PM
Post #7


Level 8
Group Icon

Group: Revolutionary
Posts: 124
Type: Event Designer
RM Skill: Skilled




This is like an absolute must for mapping with VX.


__________________________
We exist within all things and all things exist within us... it's very crowded.
Go to the top of the page
 
+Quote Post
   
Calintz16438
post Jun 19 2008, 02:43 PM
Post #8


Level 5
Group Icon

Group: Member
Posts: 74
Type: Artist
RM Skill: Skilled




Wow!!
This is a very useful script.

Thank you for your post!!
Go to the top of the page
 
+Quote Post
   
BigEd781
post Jul 17 2008, 01:32 AM
Post #9


No method: 'stupid_title' found for `nil:NilClass'
Group Icon

Group: Revolutionary
Posts: 1,829
Type: Scripter
RM Skill: Undisclosed




So, this is really just about my favorite script for the time it saves me editing sprites, but may I suggest one thing?

CODE
def comment?(comment, return_index = false )    
    if !@list.nil?
      for i in 0...@list.size - 1
        next if @list[i].code != 108
        s = @list[i].parameters[0]
        s.upcase!
        if s.include?(comment)
          return [true, i] if return_index
          return true
        end
      end
    end
    return [false, nil] if return_index
    return false
  end
end


Replacing this function (only three lines really) will make it case insensitive. I found myself typing "move" a lot. Thanks for the script.


__________________________
`
Give me teh codez!!!


I am the master debator!
Go to the top of the page
 
+Quote Post
   

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Lo-Fi Version Time is now: 24th May 2013 - 04:18 AM
RPG RPG Revolution is an Privacy Policy and Legal
eXTReMe Tracker