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
> [EN] Khas Pixel Movement 1.2 - Need Help.
Elyhaym
post Jul 4 2012, 12:17 AM
Post #1



Group Icon

Group: Member
Posts: 1
Type: None
RM Skill: Undisclosed




Hello, I'm trying to use this script and I cannot seem to get the instructions OR the demo provided... Could someone please explain how to block a specific direction? Upon reading the directions, there is this bit of info.

"character.pixel_passable?(px,py,d)
This command checks the pixel passability from (px, py) to the direction d."

Does any body know what I put into these variables to work? Thanks for any help in advance.

(I think this is the right place =/
Go to the top of the page
 
+Quote Post
   
Night_Runner
post Jul 5 2012, 02:55 AM
Post #2


Level 50
Group Icon

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




Hi Mako, unfortunately you can't block a specific direction.

That command checks if the pixel 1 step away from the character in the direction specified can be walked on.
So for example, I could have a event run the script
CODE
character = $game_player
x = character.x
y = character.y
d = character.direction
can_walk_forward =
character.pixel_passable?(x, y, d)
can_walk_backward =
character.pixel_passable?(x, y, 10-d)
can_walk_left =
character.pixel_passable?(x, y, (3 * d) % 10)
can_walk_west =
character.pixel_passable?(x, y, 4)

Where the direction is like on the numpad, 2 is South, 4 is West, 6 is East, and 8 is North.

I take it you're looking for something like XP where you could block walking in a specific direction on a specific tile?

Edit:
The working demo link


__________________________
K.I.S.S.
Want help with your scripting problems? Upload a demo! Or at the very least; provide links to the scripts in question.

Most important guide ever: Newbie's Guide to Switches
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: 18th June 2013 - 11:08 PM
RPG RPG Revolution is an Privacy Policy and Legal
eXTReMe Tracker