I have tried on Visual C++ and Dev, both get alot of errors. The book uses a older visual c++, i guess thats the problem with that.
:confused:
Type: Posts; User: GameGenie
I have tried on Visual C++ and Dev, both get alot of errors. The book uses a older visual c++, i guess thats the problem with that.
:confused:
The code is huge but i can show the errors...
Compiler: Default compiler
Building Makefile: "C:\Dev-Cpp\Makefile.win"
Executing make...
make.exe -f "C:\Dev-Cpp\Makefile.win" all
g++.exe -c...
I have a book for c++ programming called Visual C++ Object-Oriented Programming, it makes a program thru the book called ZALTAR. When i try and compile the program i get lots of linker errors and...
I use windows xp home edition.
(1) I have a program called (starting program) that should open up another program called (opened program) when it runs, but i need the opened prgram to always be on the screen, and to still be...
Thanks alot :D
I didn't know i could put a function in the structure thanks. :D
I need the max health cause it will be changing for each level up.
Edit: I couldn't get it to work right inside the structure...
Ok, i've been messing around with structures and i made one for stats, like in a game. The problem is i'm trying to max the health and mana, so i use health and maxhealth.....
#include...
Oops :rolleyes: Thanks alot =)
What about making a class for alot of different types of monsters, each have there own stats.
#include<iostream>
class monster
{
public:
void cat()
{
I was thinking more like multiple monsters...say rat, dog, cat, bear, pig..........................but any would work just so i get the point of classes :D
Thanks that helped alot. I have another question though, why do you use "monster1.fight();" and not just monster.fight();?
Edit: Never mind that last question i figured it out :rolleyes:
Thanks for the reply but it doesn't help really, i know how to write one down. Can you tell me what that would do?
Edit: Also what would be a good way to use it?
I'm not 100% on classes and I was wondering if someone could give me a example and explain it.
Something like using a class to make monsters in a rpg...
Thanks ~GameGenie:D
Thanks for the reply :), but i'm getting some errors.
When i try and compile the snake or ball movement program i get a few errors...
[Linker error] undefined reference to...
I'm having some trouble getting started with graphics and i was wondering, is there (or someone could make one) a basic movement example i could get. When i press left it would move left, right it...
Oh :rolleyes: lol...um good ideal. Thanks :D .
I'm having a problem with using character variables. I'm trying to make a char variable equal a string like "hello" but still be able to change it.
char arp;
int pra = 1;
if( pra == 1 ){
...
Ok, thanks for the help everyone.
I finally figured it out..i was trying to hard to figure it out it was simple. I just changed the variable in each of my cases.
loop = 1;
while ( loop...
Sorry, i forgot to put the header file, i put the variables like that because i just wanted to try it. I'm trying to learn c++ this is like my third day...i'm sure i'll figure all the perfect stuff...
Thanks alot for the help, but i'm still having a problem i made a function to decide if it should quit or restart. It never reads the function just skips it all together. I'll make the code...
I just started c++ yesterday and i'm trying to make a calculator.
I'm using switch and cases to make +, - , *, and / and to get the answers but when i get the answer all i can make it do is close...