Welcome Guest ( Log In | Register )

[ Big| Medium| Small] -



Post new topic Reply to topic  [ 33 posts ]  Go to page 1, 2  Next
    9robin3
  Tue Nov 01, 2011 6:40 pm
Robin Andblom
User avatar
Member

Party Mascot
Hi! I am working on a game in GAME MAKER 8 PRO. I tried to make an object moved with the mouse. I have an event which says

LEFT MOUSE BUTTON PRESSED: Move Free (direction 90 / UPWARDS)

This makes the OBJECT move UP only when pressing LEFT MOUSE on the object only(not globally!)

I then have another event saying this: LEFT MOUSE RELEASED : MOVE FREE (Direction: 270, down)

I have LEFT MOUSE BUTTON making the object move UP
Then when releasing LEFT MOUSE BUTTON, I have the OBJECT fall downwards again. Only when NOT pressing LEFT with the cursor over the object.

HERES A RECORD OF MY PROBLEM:



As you can see the OBJECT STILL moves any direction! I have to tap it or press it to make it go down again! Now that was NOT my idea, my idea was to make the OBJECT fall automatically when NO button is pressed (not globally) over the object! Please help, WHY does it continue moving? Am I using the wrong events?

NOTE: I want THE BOX to drop when mouse buttons IS NOT PRESSED OVER THE OBJECT, but it DOES NOT. I want it to move to LEFT when pressing LEFT MOUSE BUTTON (working) and UP when pressing RIGHT MOUSE BUTTON (working), and stop moving + DROP when NO BUTTON TOUCHED. At all. Right now nothing's working, but before I had to hover the mouse arrow over the object to make it drop again, simply not just releasing left/right arrow button (that I want). I have made a similar game in GM7 but GM8 doesn't seem to work in the same way.

COMMANDOS IN GM7:

OBJECT BOX: Left Mouse > Move 180 (LEFT)
Right Mouse > Move 90 (UP)
No Mouse Button > STOP MOVING + Move 270 (DOWN)


The difference is that it worked in GM7 WHEN I RELEASED any button, but in GM8, i need to steer curson OUT OF the object (BOX) and returning it over the BOX. Why is it like this? The release commandos doesn't work either! Thanks in advice:)

/9robin3

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Last edited by 9robin3 on Mon Jan 16, 2012 3:14 pm, edited 1 time in total.

Top Top
Profile      
 

    9robin3
  Sun Nov 06, 2011 1:05 pm
Robin Andblom
User avatar
Member

Party Mascot
bump! HELP!!!!

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    9robin3
  Thu Nov 24, 2011 6:44 pm
Robin Andblom
User avatar
Member

Party Mascot
anyone?

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    9robin3
  Wed Jan 04, 2012 11:52 am
Robin Andblom
User avatar
Member

Party Mascot
please anyone. there must be a solution-.-

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Sun Jan 15, 2012 5:53 am
The Radster is here!
User avatar
Sponsor


Location: United States
Let me see the code you are using. Are you using GML or the D&D?

_________________
awesome//sauce


Top Top
Profile      
 

    RadethDart
  Sun Jan 15, 2012 5:55 am
The Radster is here!
User avatar
Sponsor


Location: United States
I feel pretty bad that no one helped you, so hopefully I can still help you. I will check back frequently. If you want to get my attention faster, email me if you don't see a response.

radethdart@gmail.com

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Sun Jan 15, 2012 9:43 pm
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
I feel pretty bad that no one helped you, so hopefully I can still help you. I will check back frequently. If you want to get my attention faster, email me if you don't see a response.

radethdart@gmail.com


thank you! I am not using any code but simple commands. I made the command : Mouse - no button > STOP MOVING. But is that whats causing the problem?

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Sun Jan 15, 2012 10:18 pm
The Radster is here!
User avatar
Sponsor


Location: United States
Can you PM me your file and I can take a look at it for you. From what you are describing, I don't see why it wouldn't work. It might be the way you are declaring it. Would you be 100% against using GML for the code if I could make it work using GML? I could also try making it work using the D&D if you would prefer.

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Sun Jan 15, 2012 10:23 pm
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
Can you PM me your file and I can take a look at it for you. From what you are describing, I don't see why it wouldn't work. It might be the way you are declaring it. Would you be 100% against using GML for the code if I could make it work using GML? I could also try making it work using the D&D if you would prefer.


I do know nothing about coding NOTHING. but if it craves the use of codes, can youhelp me with that too? I will prepare the file for tomorrow then I'll post it to you! hank you a lot^^

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Mon Jan 16, 2012 4:43 am
The Radster is here!
User avatar
Sponsor


Location: United States
No problem! If you have skype, maybe we could communicate through that so I can help you learn the language a bit. It is really easy if you have any learning experience of game languages. The GML is just like the drag and drop environment; I really like coding in GML. :)

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Mon Jan 16, 2012 7:07 am
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
No problem! If you have skype, maybe we could communicate through that so I can help you learn the language a bit. It is really easy if you have any learning experience of game languages. The GML is just like the drag and drop environment; I really like coding in GML. :)


nice, yeah I have skype :D I would be pleased!:) just add robinandblom

EDIT: Here is the GAME FILE:
http://www.megaupload.com/?d=W2UK5C98

NOTE: I want THE BOX to drop when mouse buttons IS NOT PRESSED OVER THE OBJECT, but it DOES NOT. I want it to move to LEFT when pressing LEFT MOUSE BUTTON (working) and UP when pressing RIGHT MOUSE BUTTON (working), and stop moving + DROP when NO BUTTON TOUCHED. At all. Right now nothing's working, but before I had to hover the mouse arrow over the object to make it drop again, simply not just releasing left/right arrow button (that I want). I have made a similar game in GM7 but GM8 doesn't seem to work in the same way.

COMMANDOS IN GM7:

OBJECT BOX: Left Mouse > Move 180 (LEFT)
Right Mouse > Move 90 (UP)
No Mouse Button > STOP MOVING + Move 270 (DOWN)


The difference is that it worked in GM7 WHEN I RELEASED any button, but in GM8, i need to steer curson OUT OF the object (BOX) and returning it over the BOX. Why is it like this? The release commandos doesn't work either! Thanks in advice:)

/9robin3

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Tue Jan 17, 2012 1:50 am
The Radster is here!
User avatar
Sponsor


Location: United States
You are going to be so mad at yourself when you realize what you have to do to fix this. :P

Change your "Mouse Released" events to "Global Mouse Left Released" and "Global Mouse Right Released."

That should solve your problem in GMK8. :) It worked for me, so if you have any more questions, let me know.

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Tue Jan 17, 2012 7:11 am
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
You are going to be so mad at yourself when you realize what you have to do to fix this. :P

Change your "Mouse Released" events to "Global Mouse Left Released" and "Global Mouse Right Released."

That should solve your problem in GMK8. :) It worked for me, so if you have any more questions, let me know.


ohh my:O so have you tried that? Haha how ackward of me xD I'll test that at once:)

EDIT: It doesn't really work, the object keeps moving in any direction if you hold the cursor still (even if box have moved away from cursor) it's just when you release it it drops. I want the box to drop when cursor's not pressed ON the object. Is that possible please?:P

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Tue Jan 17, 2012 1:37 pm
The Radster is here!
User avatar
Sponsor


Location: United States
Ah, I will check that out when I get home from work tonight. :) That's what I thought you were wanting. I am going to have to use GML for it, but I will comment heavily for you. :)

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Tue Jan 17, 2012 3:14 pm
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
Ah, I will check that out when I get home from work tonight. :) That's what I thought you were wanting. I am going to have to use GML for it, but I will comment heavily for you. :)



thanks:)

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Wed Jan 18, 2012 5:07 am
The Radster is here!
User avatar
Sponsor


Location: United States
After a little bit of time coding, I fixed your problem!

Place this in the step event of your object and then delete the mouse commands. You should only have the Create Event, Step Event, and Outside Room Event.

Expand to see the code.

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Wed Jan 18, 2012 7:29 am
Robin Andblom
User avatar
Member

Party Mascot
Thanks man:) it works. Well better anyway. But still it moves when cursor's outside of the BOX, not all the time, but a few seconds after the mouse has left the object. But maybe I'll have to go with this, still it works fine:)

EDIT: I need to do the same with a mirrored object. It moves instead of UP and LEFT, RIGHT and LEFT.

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Thu Jan 19, 2012 9:23 pm
The Radster is here!
User avatar
Sponsor


Location: United States
Hey, my computer at home went down yesterday, and I have been busy with some personal things, so I am going to try and fix my computer tonight and get that code written for you. Sorry about the delay.

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Fri Jan 20, 2012 1:30 pm
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
Hey, my computer at home went down yesterday, and I have been busy with some personal things, so I am going to try and fix my computer tonight and get that code written for you. Sorry about the delay.


Oh I am sorry that your computer broke:( ok well I just need the same thing but mirrored, to the UP, RIGHT box thanks^^

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Sat Jan 21, 2012 1:15 am
The Radster is here!
User avatar
Sponsor


Location: United States
I made the collision detection 100% better, and made this for both directions. It is really easy and interchangeable for what you are wanting to do. All it takes is copy/paste of my code into the step even of the object you want to move around.

The variables that you want to change are the ones at the top with the x, and the y.
Expand to see the code.


Box Move Left/Up
Expand to see the code.


Box Move Right/Up
Expand to see the code.

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Sat Jan 21, 2012 9:13 am
Robin Andblom
User avatar
Member

Party Mascot
Thanks a lot:D it works fine:) thanks!

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Sat Jan 21, 2012 3:59 pm
The Radster is here!
User avatar
Sponsor


Location: United States
If you need help with anything else, just make another post. I will try to make sure and check back at least once a day. :D

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Sun Jan 22, 2012 12:57 pm
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
If you need help with anything else, just make another post. I will try to make sure and check back at least once a day. :D


thanks its alright^^

But I can post a demo of the game. You'll se what I've done. It my very own strategy game.

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Mon Jan 23, 2012 4:07 am
The Radster is here!
User avatar
Sponsor


Location: United States
Sure! Send me a link! I would love to see it. :D

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Mon Jan 23, 2012 4:42 pm
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
Sure! Send me a link! I would love to see it. :D


Nice to hear^^ I am uploading now:)

EDIT: Here it is: http://sandbox.yoyogames.com/games/1931 ... -it-2-demo


PS. If your looking for Press It 1, then I think I have it somewhere. I'll find it^^ It doens't work o W vista or 7 though.

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Mon Jan 23, 2012 10:18 pm
The Radster is here!
User avatar
Sponsor


Location: United States
Hmm, I can't believe how awesome that game is going to be! Great idea! I am really happy to see that my coding helped you out. :P I noticed that you changed up the code just a little bit to help accommodate what you were trying to achieve. Excellent choice on the music. :3

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Mon Jan 23, 2012 10:43 pm
Robin Andblom
User avatar
Member

Party Mascot
Thank u very much^^ are you online at skype often?:)

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Tue Jan 24, 2012 1:43 am
The Radster is here!
User avatar
Sponsor


Location: United States
I get on occasionally. I am never at my computer for long periods of time now that I work on a computer all day at work. :P I have to give my eyes a rest sometimes, lol. I get on and check if you are online here and there.

_________________
awesome//sauce


Top Top
Profile      
 

    9robin3
  Tue Jan 24, 2012 8:49 am
Robin Andblom
User avatar
Member

Party Mascot
RadethDart wrote:
I get on occasionally. I am never at my computer for long periods of time now that I work on a computer all day at work. :P I have to give my eyes a rest sometimes, lol. I get on and check if you are online here and there.


haha its cool^^ thansk for the help and hope you will enjoy the short demo!

_________________
MY PAGES:
MY HOMEPAGE
MY FB GAME PAGE
MY YOUTUBE

__________________________________________________________________________________________
GAMES IN PROGRESS:

Image

Image


Top Top
Profile      
 

    RadethDart
  Wed Jan 25, 2012 4:50 am
The Radster is here!
User avatar
Sponsor


Location: United States
I enjoyed it with every moment! It surprised me when I couldn't play past a few levels...it wasn't fair! :( I was getting into it!

_________________
awesome//sauce


Top Top
Profile      
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 33 posts ]  Go to page 1, 2  Next


Who is online

Users browsing this forum: No users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

cron
We are an independent, not-for-profit game making community.
Homepage
Board Index
About Us
Downloadable Games
Free Browser Games
Games in Development
RPG Maker Support
Game Maker Support
Construct 2 Support
HBGames the eZine
Advanced RPG Maker
Site Announcements
Powered by phpBB © phpBB Group