Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 10-19-2001, 04:52 AM   #1
Registered User
Join Date: Sep 2001
Posts: 6
Unhappy another problem with "platform gaming"

okay I'd solved my previous problem about the "person" not being able to land.

Now when the person touches the side of the "block", I can't get him to stop moving to the side (i.e. he moves into the "block").

What should I do?

Code for "person":

onClipEvent (enterFrame) {
if (this.hitTest(_root["block"])) {
this._y += 0;
//here's the problem: what to put?
} else {
this._y += 4;

onClipEvent (enterFrame) {
if (Key.isDown(Key.RIGHT)) {
if (Key.isDown(Key.LEFT)) {
Schlave is offline   Reply With Quote
Old 10-19-2001, 06:05 AM   #2
ActionScript.org Founder
Jesse's Avatar
Join Date: Nov 2000
Location: New York
Posts: 8,736

If 'blocl' is a variablet hat should be:
if (this.hitTest(_root[block])) {
review the Advanced Paths tutorial.

Jesse Stratford
ActionScript.org Cofounder

Please don't email or PM me Flash questions, that's what the Forums are for!

Please don't rely on me reading my PMs either. Email me about important stuff.
Jesse is offline   Reply With Quote

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
global TextField Problem! Guru wonted mediaholic ActionScript 1.0 (and below) 3 07-20-2003 10:07 AM
Preloader problem with external movies ian27 Simple Stuff (Newbies) 16 04-17-2003 12:06 AM
[Q] Problem with zooming the map and the location/size of the movieclip inside of it. CyanBlue ActionScript 1.0 (and below) 6 01-13-2003 12:13 AM
No loader problem but a loading problem agenba Simple Stuff (Newbies) 1 02-11-2002 06:29 AM
stuck with "platform gaming" code Schlave Other Flash General Questions 4 10-17-2001 03:10 PM

All times are GMT. The time now is 01:43 PM.

Follow actionscriptorg on Twitter


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.