Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: 2d Top Down Tank Game-Operation Special Delivery  (Read 9010 times)

0 Members and 1 Guest are viewing this topic.

Yatan vesh

  • Newbie
  • *
  • Posts: 17
  • Get busy livin',or get busy dyin'
    • View Profile
2d Top Down Tank Game-Operation Special Delivery
« on: December 20, 2015, 12:45:54 am »
Okay guys I've been working on a top down game featuring Tanks, Helicopters and Cars!!




The game has 2 modes-Campaign and survival(endless waves of enemies).
The Player can dynamically switch between tank, heli and car during gameplay using scroll bar.

Okay so i'm not using any animations or spritesheets or any other library, its pure c++ and SFML.

If anyone wants implementations of any of my classes to use in their projects,ping me and i'l provide you the generic methods(after modifying for your needs) OR you can View the SOURCE CODE on Github




Features:

#3 Tier Class inheritance for Vehicles
#AI Manager class that dynamically creates enemies to deal with during gameplay.
# Dynamic switching ability between Truck,Tank and Helicopter.
# AIRSTRIIIIIIKEEEESSSS
#custom handler functions to handle background image, collisions, Views etc.
# HUDclass for displating and handling HUD(Health,Speedometer and boost)
# A powerup class that handles powerups like health,giant,speed,BulletDamage
#Ally class to call Tank,heli's and Airstrikes for help in exchange for score.
#The Health and Boost for player are regenerative
#ProjectileClass for Bullets,missiles and machineguns
#Music System that automatically loads background music randomly when current track finishes.
#A self implemented Menu system(MainMenuClass) and pause screen.
#A class for handling splashscreen and fade animations.



Source Code and the entire project( Needs visual studio 2013):
https://github.com/Yatanvesh/Operation-Special-Delivery

Game Setup(Alpha build):
https://drive.google.com/file/d/0B7ut8lCPhmVWUkFmc25mcXQxMjg/view?usp=sharing

GamePlay Youtube link:
https://www.youtube.com/watch?v=wzhECxEgisU
« Last Edit: December 24, 2015, 02:13:19 pm by Yatan vesh »

Hapax

  • Hero Member
  • *****
  • Posts: 3054
  • My number of posts is shown in hexadecimal.
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #1 on: December 20, 2015, 01:56:55 am »
Looks quite nice! From where did you get the resources?

Why are you using only version 2.1 of SFML?  :o
Selba Ward - SFML drawables
Kairos - Timing Library
Rectangular Boundary Collision - Rectangular SAT Collision

@Hapaxiation - Hapaxia on Twitter

Yatan vesh

  • Newbie
  • *
  • Posts: 17
  • Get busy livin',or get busy dyin'
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #2 on: December 20, 2015, 02:04:16 am »
uhh i was halfway between the project when SFML 2.3 it came out. N i'm lazy as shit.


hmm resources-Google images mainly and some 2d game res websites.
So it May contain copyrighted images(1 or 2 maybe) but i wouldn't worry about it.
I've also used photoshop to separate the turret and tankbody from standard top down tank images and same goes for helicopters and many othe images.

Hapax

  • Hero Member
  • *****
  • Posts: 3054
  • My number of posts is shown in hexadecimal.
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #3 on: December 20, 2015, 02:11:00 am »
i was halfway between the project when SFML 2.3 it came out. N i'm lazy as shit.
It shouldn't be too difficult to change to 2.3. It doesn't really change any of the interface so your code shouldn't need to change.

it May contain copyrighted images(1 or 2 maybe) but i wouldn't worry about it.
You may want to find resources (or make your own!) that you have the right to use before distributing your game (and those copyrighted resources!), especially since you don't even credit who owns them!
Selba Ward - SFML drawables
Kairos - Timing Library
Rectangular Boundary Collision - Rectangular SAT Collision

@Hapaxiation - Hapaxia on Twitter

Yatan vesh

  • Newbie
  • *
  • Posts: 17
  • Get busy livin',or get busy dyin'
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #4 on: December 20, 2015, 02:15:59 am »
heyy I'm not distributing it. This is just a test game-my first game. If it recieves good enough feedback, I might just start over again and like you say,fetch or create resources. And yea i'll credit the resources in my credits option in Main Menu. Thanks for telling that
« Last Edit: December 20, 2015, 02:24:16 am by Yatan vesh »

Hapax

  • Hero Member
  • *****
  • Posts: 3054
  • My number of posts is shown in hexadecimal.
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #5 on: December 20, 2015, 02:30:31 am »
I'm not distributing it.
You are; you uploaded them to GitHub.

This is just a test game-my first game. If it recieves good enough feedback, I might just start over again and like you say,fetch or create resources.
That's understandable. It might be better to try starting with basic art next time (programmer art) and just add in the awesome images later on if you feel like it  :)

I don't know if you made your own music and/or sound effects either. They should be treated in the same way.
Selba Ward - SFML drawables
Kairos - Timing Library
Rectangular Boundary Collision - Rectangular SAT Collision

@Hapaxiation - Hapaxia on Twitter

Yatan vesh

  • Newbie
  • *
  • Posts: 17
  • Get busy livin',or get busy dyin'
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #6 on: December 20, 2015, 02:35:15 am »
github has source code. Well thanks for your suggestion..i never knew that. Yea, and the sounds are freeware.Downloaded 'em from royalty free sources. And I forgot to mention, I've created many resources using photoshop like backgrounds(a road texture, sand texture and boom u have a desert scene).
« Last Edit: December 20, 2015, 03:31:53 am by Yatan vesh »

Hapax

  • Hero Member
  • *****
  • Posts: 3054
  • My number of posts is shown in hexadecimal.
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #7 on: December 20, 2015, 10:50:39 pm »
github has source code.
True, but it also hosts the resources required, which, unfortunately, you don't have the right to distribute  :(

I've created many resources using photoshop like backgrounds(a road texture, sand texture and boom u have a desert scene).
Not sure what this means.
If it means that you created a new resource by manipulating an old resource, the original licence determines if that's okay. Royalty-free or Creative Common are two common ones used for this purpose.
If it means that you created them from scratch using brushes and/or filters etc., then I do commend you for your effort  :)
Selba Ward - SFML drawables
Kairos - Timing Library
Rectangular Boundary Collision - Rectangular SAT Collision

@Hapaxiation - Hapaxia on Twitter

Yatan vesh

  • Newbie
  • *
  • Posts: 17
  • Get busy livin',or get busy dyin'
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #8 on: December 20, 2015, 11:26:36 pm »
dude you know this shit too well. Well i just checked about that licence. most of the textures were from texturelib.com and it says "free for personal and commercial use".  Tank textures from opengameart.org. phew! I guess most of the stuff is good. I'll need to dig deeper and delete the stuff that may cause any trouble.

Mario

  • SFML Team
  • Hero Member
  • *****
  • Posts: 877
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #9 on: December 21, 2015, 06:06:00 pm »
Haven't tried it yet, but from looking at the screenshots I think the most apparent flaw right now is the absence of shadows. Even if we're just talking about simple, blurry and static drop shadows. Just add some depth to better separate things from the background and to add some depth (especially for the helicopters).

Yatan vesh

  • Newbie
  • *
  • Posts: 17
  • Get busy livin',or get busy dyin'
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #10 on: December 21, 2015, 06:24:12 pm »
shadows? Awesome idea!!
wonder why i never thought about that myself. I'll Implement that as soon as i can.
Thanks for the tip buddy!!

Hapax

  • Hero Member
  • *****
  • Posts: 3054
  • My number of posts is shown in hexadecimal.
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #11 on: December 22, 2015, 12:38:13 am »
most of the textures were from texturelib.com and it says "free for personal and commercial use".  Tank textures from opengameart.org. phew! I guess most of the stuff is good. I'll need to dig deeper and delete the stuff that may cause any trouble.
That's great news! Open Game Art is an excellent place for resources if you are unable to create them yourself for some reason.

Also, I agree that shadows would really help to add some depth.
Selba Ward - SFML drawables
Kairos - Timing Library
Rectangular Boundary Collision - Rectangular SAT Collision

@Hapaxiation - Hapaxia on Twitter

AFS

  • Full Member
  • ***
  • Posts: 115
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #12 on: December 22, 2015, 01:41:05 am »
I just wanted to add that if you want to add shadows, you don't need to have shadow textures in your files, you can just use the same textures as the helicopters but apply black color to them and some transparency in code:

sf::Texture helicopterTexture:
helicopterTexture.loadFromFile("helicopter.png");

sf::Sprite helicopter;
helicopter.setTexture(helicopterTexture);

sf::Sprite helicopterShadow;
helicopterShadow.setTexture(helicopterTexture);  // Same texture.
helicopterShadow.setColor( sf::Color(0,0,0,100) );  // Semi-transparent black color.
 

 ;)
« Last Edit: December 22, 2015, 01:43:40 am by AFS »

Yatan vesh

  • Newbie
  • *
  • Posts: 17
  • Get busy livin',or get busy dyin'
    • View Profile
Re: 2d Top Down Tank Game-Operation Special Delivery
« Reply #13 on: December 22, 2015, 01:15:36 pm »
I was thinking too hard how to solve the shadow problem. You sir, are a lifesaver! :D :D
That way I could Position that just a few pixels right,top,bottom or left to my sprite and move it along with my sprite. Great. Just great! Thanks buddy!!!

 

anything