Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / A Few Questions - New To Dark GDK

Author
Message
mikeMarek 597
15
Years of Service
User Offline
Joined: 12th Feb 2009
Location:
Posted: 13th Feb 2009 02:22
Hi there! New to the forums and this game engine, so naturally I have a few questions. I do know some basics (like adding sprites to the screen, animating them, etc.) First, is there a way I can make a sprite rotate? Like a turret rotating towards the mouse. Second, what about buttons? I'm thinking of checking if the mouse is within the bounds of a button and returns true if the mouse is clicked, then runs a function, etc. Third, how can I get the mouse coordinates, check if the mouse is being clicked, etc. And finally, is there some sort of tutorial(s) (not the ones that come installed with the engine) that's sort of a database for all of the different functions/methods of doing different things. If anyone has been on Newgrounds and checked out AS Main, you'll know what I'm talking about.

Thanks for any help and/or replies, and any help is greatly appreciated!
-Mike
Kilrath
15
Years of Service
User Offline
Joined: 18th Jan 2009
Location: Alberta
Posted: 13th Feb 2009 15:11
When you install the GDK it puts a folder in your start menu. there is documentation in there that is very helpful on your first game. start up a 2D game and see what everything does then start adding your own things and messing with commands is the best way to learn it.

Saving the world, one bit at a time.... Wait it's not worth saving. Get your own bits!
andiconda
15
Years of Service
User Offline
Joined: 10th Feb 2009
Location:
Posted: 14th Feb 2009 05:45
programfiles/thegamecreators/darkgdk/documentation/information is a complete-ish manual
there are a few typos
you'd look in the input folder

dbMouseClick
dbMouseMoveX
dbMouseMoveY
dbMouseMoveZ
dbMouseX
dbMouseY
dbMouseZ


are some of the commands you'd use
Gatorules
15
Years of Service
User Offline
Joined: 17th Dec 2008
Location:
Posted: 17th Feb 2009 05:13
1. dbRotateSprite()

2. if ( dbMouseX()>=dbSpriteX(id) && dbMouseX<=dbSpriteX(id)+dbSpriteWidth(id) && dbMouseY()>=dbSpriteY(id) && dbMouseY<=dbSpriteY(id)+dbSpriteHeight(id) && dbMouseClick()==1 )
{run function}

3. dbMouseX(), dbMouseY(), dbMouseClick()

--hope this helps
Neuro Fuzzy
17
Years of Service
User Offline
Joined: 11th Jun 2007
Location:
Posted: 19th Feb 2009 01:13
Incase you don't have it, i attached the full list of commands

Attachments

Login to view attachments

Login to post a reply

Server time is: 2024-09-30 19:16:05
Your offset time is: 2024-09-30 19:16:05