Posts

X-PLOD3

Image
Here's the code for a new game That I've created! It's called X-PLOD3 (pronounced as explode)... The idea of the game sprouted when I and my brother along with our friends Stephen and Ephraim sat down. Earlier in the day, Ephraim played my Hand Cricket game and got surprisingly hooked to it :). It was really motivational to see someone like my game! After a while, he (Ephraim) came up to me and asked if I had any other games other than the 2 (both which I have blogged). I said no but, I also mentioned that If he had any idea then I'd make it into one. He said let's do something new and we started spitting out ideas and as a result of that mindless mixture of ideas this game took its shape. Well, enough said. Now about the game. The game's rules are simple. At each turn, 5 missiles randomly head towards the Earth , each randomly in any of the three 120 degree sectors  ( left sector , middle sector and the right sector ). At each turn, you have 5 m...

HOW TO CREATE TEXT GAMES USING C! : PART 2 (Getting started!)

Image
So, in the previous post I've described a simple program to generate a random number within a range ( 1 to 6 for a dice) .  Now, any type or genre of a game requires actions of the player. So in this part, I bring in another basic element of a game into the code that is actions of the player So how do we make a player act ? The answer is to simply alert him with messages ( as there's no way to reach out to his throat and demand him ) to act using the console output functions such as printf()  and take the actions he performed using the console input functions such as scanf() . So, now using the  printf() and  scanf()  I've constructed a simple guess game! //let's create a number guessing game when a dice is rolled #include <stdio.h> #include <stdlib.h> #include <time.h> int main(void) { int number,guess; srand(time(NULL)); //randomly generate number number = (rand()%6)+1; ...

What Google says about your favorite Programming Language

Image
Here is something interesting that I did. :) I did a quick Google search( not exactly ) to see what are the top most results in the drop down menu of google search bar I have done Google search for the following 10 programming languages C C++ C# Java JavaScript Objective C Perl PHP Python  Ruby So, here are the results! C : (My favorite!) C++ : C# : Java : JavaScript : Objective C : Perl : PHP : Python : Ruby : Most of them show pretty much the same, but hope you liked the post. Here's some food for thought before leaving :) keep thinking and See ya later!

HOW TO CREATE TEXT GAMES USING C! : PART 1 (Using the rand() function)

Image
So, you might stumble upon this page while searching how to make simple text games using C. Here below is the first part of 'simple to understand' explanation of how you can create games using C! The most important characteristic of any game or match(both digital and physical) is its randomness in which actions or moves take place. That is what makes a game interesting Consider the classic rock paper scissors game! Here the fun lies in randomness of selection of options by both the players even though the number of choices is limited So if we could somehow get this characteristic into our program... Then we are very well on our way to making exciting games! So how do we bring randomness into our program? Well, for this very purpose, we have a predefined function under the 'stdlib.h' header file and the function name is rand() functionality of rand() : The rand() function generates a random pseudo-number between 0 and 32767 So how can we use ...

HAND CRICKET

Image
  Hand Cricket! I bet if you're a student like me in India you'd definitely know that it's most enjoyable hand game one can play at anytime and anywhere. If you know the rules of cricket then it's pretty simple to understand this game. Game of cricket consists of 3 parts: Toss:  Here you have to select heads or tails... if the luck is on your side and the tossed coin flips to the side you selected then you'll have the advantage of selecting whether to bat first or bowl first... on the other hand if you loose; the advantage is taken by the opponent 1 st innings : What you do in the first inning is decided by the Toss. 2 nd Innings: Here's the interesting and final part of the game... Rise to defend if you have batted first and score at will and win if you'd chosen to bowl first Batting and Bowling in Hand cricket :  In the game you have fixed amount of wickets ( lives ), you have to score before you loose all yo...

BOT FIGHT

Image
(Album art by Vamsi ) This is a simple text based strategy game ... an evolution of Rock, paper, scissors game. In this game, two robots are pitted against each other and your main aim is to make the health of another bot 0. To accomplish this, each player has got three options; Charge, Shoot, Defend. Charge : Charges you up and enables you to attack. You cannot shoot with 0 charges. Shoot : Deals 5 damage to the opponent. (Requires at least 1 Charge) Defend : Defends and protects your health. Plan wisely and defeat your opponent before you get defeated. Compete against the computer to test your luck and skill! This first ever game published by me... hope the Exe file below works on your PC, anyway, I've provided code below! NOTE: Not compatible with all systems... Hope it works on yours... .exe Download  (   Click Run Anyway when you are prompted  ) If it doesn't run on your system, nothing to fret abou...