Jump to content


Photo

Setting up a press (B) to open & close object


  • Please log in to reply
43 replies to this topic

#31 talonstart

talonstart

    Artist

  • GMC Member
  • 450 posts
  • Version:GM:Studio

Posted 03 May 2012 - 06:18 PM

I get what your saying.. but right now, this was what i was looking and is working for me right now.. The inventory object bag.. as i was stating is how i needed it open.. for that object carries vital information.. and things i use.. But i also see that i can just draw the sprite / and the texts / boxes / anything i want to be placed in there. but that wasnt my concern right now..

I'll still play with it.. and probably have more questions.. but right now, you made my object do exactly what i was looking for.. 1 + rep for you my friend Thanks so much.
  • 0

#32 FoxInABox

FoxInABox

    GMC Member

  • GMC Member
  • 5590 posts
  • Version:GM:Studio

Posted 03 May 2012 - 06:18 PM

In case you wanted to know.. your earlier open/close code could be cut down to:
if keyboard_check_pressed(ord('B')) with(obj_bag)visible=!visible;
and you can disable movement by checking if it is visible
if obj_bag.visible exit; // don't do code below if bag is open
remember to keep the code to open/close inventory above the exit code if you use it.. good luck
  • 0

#33 creators124

creators124

    awesomeliciousmember

  • GMC Member
  • 866 posts
  • Version:GM8

Posted 03 May 2012 - 09:16 PM

I think you should still do Jack's way since it is more efficient. :D
also I'm glad you found your solution if you have a problem drawing the inventory, tell us! Posted Image

Edited by creators124, 03 May 2012 - 09:17 PM.

  • 0

#34 talonstart

talonstart

    Artist

  • GMC Member
  • 450 posts
  • Version:GM:Studio

Posted 03 May 2012 - 09:30 PM

Jacks way is def. the direction i'll be heading when i get to that..
right now, not needing too.. i got what i was looking for, and when i get to drawing the (boxes) to collect the items, ill head his way.
i understand it now.. just needed that little push... was like he said, over thinking the situation.. trying to hard for something simple.

but im glad i figured this out.. this is 100% useful for many things now.. exciting :) actually... I never did states.. and case files never understood.
this cuts my scripting of true false statements in half.. very pleased with this outcome.
  • 0

#35 creators124

creators124

    awesomeliciousmember

  • GMC Member
  • 866 posts
  • Version:GM8

Posted 03 May 2012 - 09:41 PM

Jacks way is def. the direction i'll be heading when i get to that..
right now, not needing too.. i got what i was looking for, and when i get to drawing the (boxes) to collect the items, ill head his way.
i understand it now.. just needed that little push... was like he said, over thinking the situation.. trying to hard for something simple.

but im glad i figured this out.. this is 100% useful for many things now.. exciting :) actually... I never did states.. and case files never understood.
this cuts my scripting of true false statements in half.. very pleased with this outcome.

AWESOME!
You learned more GML coding! Posted Image
This is exciting!
Even I learned states and cases! :D Posted Image
well I'm just saying need help with drawing your inventory, tell us!Posted Image
  • 0

#36 talonstart

talonstart

    Artist

  • GMC Member
  • 450 posts
  • Version:GM:Studio

Posted 03 May 2012 - 09:48 PM

well how bout ill contact you when im ready to start scripting how to put the items in to the inventory..
Let me know if you can help me figure that out.. ill contact you personally
  • 0

#37 creators124

creators124

    awesomeliciousmember

  • GMC Member
  • 866 posts
  • Version:GM8

Posted 03 May 2012 - 09:56 PM

well how bout ill contact you when im ready to start scripting how to put the items in to the inventory..
Let me know if you can help me figure that out.. ill contact you personally

I love helping!
also not a big fan of coding yet.(because of medicine, I feel woozyPosted Image)
But I'll try my best!Posted Image
  • 0

#38 Jack Indie Box

Jack Indie Box

    GMC Member

  • GMC Member
  • 1558 posts
  • Version:GM:Studio

Posted 03 May 2012 - 09:56 PM

btw, the only reason i knew about states was university :P and i have rarely used them as i am lazy, but it is great coding practice. having coded in game maker since 4.0(self taught ofcourse) i never did use them till 4 years ago and its a hard habbit to break into XD

but heres for all of us going forward and actually coding with good practices and not regretting it later!
  • 0

#39 talonstart

talonstart

    Artist

  • GMC Member
  • 450 posts
  • Version:GM:Studio

Posted 03 May 2012 - 11:43 PM

Agree'd

I usually scripted in as2.0, But i got a little bug when scripting in as3 and was just so frustrated with there whole concept, and did some research for game engines, came across gamemaker 8.1.
Read about it, and saw it has alot of java / as2 feel to it, Just now i dont gotta script every event to happen like i was in as3.. import this , import that, add this, if that, cross your fingers there talking properly, checking mem leaks.. all became to slow my progress down when starting Nuclear Fallout (nebula shooter).. i been working on for almost 2 years. After getting gm... It worked like a champ for all my games to come. this is a perfect engine.. 2.5d games im into casual gamers.. NF will become a great shooter, (great graphics / effects) all built in 3dsmax, with a little help from a couple of coding buddies, who implanted alot of scripts as well..

Im glad to find a great community and people that are all willing to push and help on another, with proper communication..
  • 0

#40 creators124

creators124

    awesomeliciousmember

  • GMC Member
  • 866 posts
  • Version:GM8

Posted 03 May 2012 - 11:57 PM

Agree'd

I usually scripted in as2.0, But i got a little bug when scripting in as3 and was just so frustrated with there whole concept, and did some research for game engines, came across gamemaker 8.1.
Read about it, and saw it has alot of java / as2 feel to it, Just now i dont gotta script every event to happen like i was in as3.. import this , import that, add this, if that, cross your fingers there talking properly, checking mem leaks.. all became to slow my progress down when starting Nuclear Fallout (nebula shooter).. i been working on for almost 2 years. After getting gm... It worked like a champ for all my games to come. this is a perfect engine.. 2.5d games im into casual gamers.. NF will become a great shooter, (great graphics / effects) all built in 3dsmax, with a little help from a couple of coding buddies, who implanted alot of scripts as well..

Im glad to find a great community and people that are all willing to push and help on another, with proper communication..

WOW!
this makes me feel awesome!Posted Image
I'm glad I'm part of this community!Posted Image
I like felling helpful, main reason I'm here!Posted Image
also is everything going smoothly with the inventory selection menu?(possibly shop?)Posted Image
  • 0

#41 talonstart

talonstart

    Artist

  • GMC Member
  • 450 posts
  • Version:GM:Studio

Posted 04 May 2012 - 03:32 AM

ill be working on that tomorrow, If you wanna help creator.. I havnt got a clue, where to start to even add it yet.. Very soon.. i got a few tutorials to watch..
something bout (0,0) type arrays.. but im not understanding the process yet, trying to figure out how some added, the images, to show in the blocks, and how to even make the blocks,
but ill start slow.. and work my way up.

Thanks guys
  • 0

#42 creators124

creators124

    awesomeliciousmember

  • GMC Member
  • 866 posts
  • Version:GM8

Posted 04 May 2012 - 03:56 AM

wow...
what type of tuts?
I'll like to see them, too!Posted Image
I'll like to learn them, too!
also, you could use grids!
they are helpful in organizing!
if no, then tell me, or show me, some sort of of sketch where you'll like the items displayed!
  • 0

#43 talonstart

talonstart

    Artist

  • GMC Member
  • 450 posts
  • Version:GM:Studio

Posted 04 May 2012 - 12:14 PM

Starting on the inventory collecting today..
gonna read some tutorials.. follow some steps.. and figure out how i can make the boxes. and place them into the (obj_bag) so you can open and it'll be there not on the main screen..

creator ill keep in touch with you as i go.
  • 0

#44 creators124

creators124

    awesomeliciousmember

  • GMC Member
  • 866 posts
  • Version:GM8

Posted 04 May 2012 - 02:47 PM

Starting on the inventory collecting today..
gonna read some tutorials.. follow some steps.. and figure out how i can make the boxes. and place them into the (obj_bag) so you can open and it'll be there not on the main screen..

creator ill keep in touch with you as i go.

I'll like to know but I'm going to school! Posted Image
I guess I'm still learning, right?
well good bye till 8 hours from now and I know you'll figure it out by them.Posted Image
  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users