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 / Making My Second Game (Need Help)

Author
Message
vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 11th Feb 2011 15:05
Hello all!

How title says im making my second game in C++ and DGDK

I need a little help here.
I will explain the game and how i wanna do things:

1- Game Type: Is a 2d Shooter view from the top.
The Objective is to kill the ghosts who will be spawned.

My first question is:

How can i start? (i already made the Graphics and load them
dbLoadImage( "Data\\player.png", 1);
and etc..

what i do now?

Thanks all

(ALL PEOPLE WHO HELPED WILL BE CREDIT!)

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
WLGfx
17
Years of Service
User Offline
Joined: 1st Nov 2007
Location: NW United Kingdom
Posted: 11th Feb 2011 15:19
To start with you would probably look into how you lay out your levels. Tile based is probably the easiest way to go but how you develop on that is up to you.

Warning! May contain Nuts!
vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 13th Feb 2011 19:01
hum.. that seems im stupid..

idk how to make it :S

i was thinking beggining with the game system like declaring the Ints and stuff...
Do you know some good tuts about 2D ?

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
WLGfx
17
Years of Service
User Offline
Joined: 1st Nov 2007
Location: NW United Kingdom
Posted: 13th Feb 2011 22:20
The samples that come with GDK should be more than plenty to help anyone get started with GDK, 2d, 3d, audio, etc. Apart from that there's tons of resources on the web related to 2d programming.

For tile maps you would start by setting up a 2d array

int map[max_width][max_height];

each variable in the array would be an image number to draw the map.

Warning! May contain Nuts!
vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 15th Feb 2011 22:29
hum i will check the Dark Invaders full pdf and a tuts that i found on youtube and it should get me into it.

Just 2 questions:

- Can i insert a Auto Ghost Spawner?
- How can i make the bullets go to mouse direction (i will not insert ammo limit)

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: <script> alert(1); </script>
Posted: 15th Feb 2011 22:50 Edited at: 15th Feb 2011 22:51
Quote: "- How can i make the bullets go to mouse direction (i will not insert ammo limit)"


well the point is, you will make the sprite move forward always using dbMoveSprite, so all you need is an angle to set the sprite to so it can go on (dbRotateSprite), so how can we get this angle? first off, get the mouse position,

after that, point the sprite to the mouse position


and after that, just move the sprite as usual...(in loop, dbMoveSprite)

vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 16th Feb 2011 16:37
and the X and Y of the loop movement is the DX and DY right?

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: <script> alert(1); </script>
Posted: 16th Feb 2011 17:54 Edited at: 16th Feb 2011 17:55
i don't get what you mean, DX is "delta X" and DY is "delta Y", this is just to get the distance between the sprite and the mouse then we use dbAtanFull to get the angle between them and then rotate the sprite to be "facing the mouse"

then just use dbMoveSprite, the above is just used once at the launching of the bullet (unless you want the bullet to keep following the mouse, then use it once before any dbMoveSprite)

vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 17th Feb 2011 15:09
but i dont need to make a variable to the path of the bullet?

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
beginner98
15
Years of Service
User Offline
Joined: 22nd Jun 2009
Location:
Posted: 17th Feb 2011 15:43
I think this may be too ambitious for your current level. Work on something simple like Pong to get used to your the GDK engine and then make something that requires a little more game logic, maybe give the second paddle AI?

c++ = easy GDK = IMPOSSIBLE lol
vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 17th Feb 2011 19:23
hum ok thanks for the hint and Hassan thanks for trying to help, i will stay low making sh*t games first.

I will cred both of you in my game (this shooter here) when i done it.

Thanks all!

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 27th Feb 2011 17:25
Hey hassan i was reading again and again your replies and i want to ask one thing

So my game is on its way. and i think i dont explain well what it will be.

so..

1- the Game player will be a "circle" and so this:
Quote: "after that, point the sprite to the mouse position"

i think its not needed.

2- It will be simple spawn and shoot game.
example: 10 ghosts spawn in the map. and the player just need to shoot!


now i made the movement, the maps with theire walls collisions etc etc.

I want to make something like when the ghosts are spawned i want they move to the player's X and Y. then if they touch him games over xd


How hard can it be?

Thanks for your help Hassan i already credit you
PS: in the credits you want that i type Hassan or other name...? just say xD

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: <script> alert(1); </script>
Posted: 27th Feb 2011 21:04
how are you gonna shoot them? i don't understand what you want to do, the player moves? on which axis? he shoots only infront of him or to where the mouse is pointing? please give more details and ask specific questions so someone could answer.

Quote: "How hard can it be?"

nothing's hard! if you're asking about the collision, dbSpriteCollision will check whether 2 sprites are colliding or not, so you simply check for all enemies whether they are colliding with the player or not, if one of them is, then, game over

Quote: "PS: in the credits you want that i type Hassan or other name...? just say xD"


well..Hassan..if you want, thanks.

vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 28th Feb 2011 15:28 Edited at: 28th Feb 2011 15:29
look i made one "model" in Game Maker, do you wanna check to see what i want to do?

PS: i want to make a c++ version because i wanna be "full" credited by it. Game maker has no honor on it.

If you wanna check the game: http://vitinho444.hostoi.com/Games/S2S/Release.rar

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
Yero008
13
Years of Service
User Offline
Joined: 5th Dec 2010
Location: Romania
Posted: 28th Feb 2011 22:05
Can you tell me how you use(embed) the icon?
vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 2nd Mar 2011 15:25
Quote: "Can you tell me how you use(embed) the icon? "


in Game maker?
If yes its on options. then just load a icon

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5

Login to post a reply

Server time is: 2024-11-19 12:22:45
Your offset time is: 2024-11-19 12:22:45