Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

122 Neutral

About dahmer45

  • Rank
  1. I'm looking to get into scripting Starsiege tribes but I haven't been able to find any good tutorials on google. Can someone please point me in the right direction? Thanks in advance.
  2. dahmer45

    Inventory for text rpg?

    I'm kinda lost. Could you maybe show me some code? Thanks. EDIT: I got this #include <iostream> #include <string> using namespace std; int main() { //1 = sword //2 = axe //3 = greatsword //4 = bow //5 = mace int inventory[10]; int x; string take; cout << "Take sword?"<<endl; cin >> take; if(take == "y") { inventory[1] = 1; } if(inventory[1] > 0) { cout << "Iron longsword. 2 damage"<<endl; } else if(inventory[1] <= 0) { cout << "You dont have anything!"<<endl; } system("pause"); } It displays the the name and damage of the sword when you take it. But it also displays it when you dont take it. What am I doing wrong?
  3. I'm trying to code a small text based rpg in c++. But I can't figure out how to do the inventory. I've tried using strings and arrays, but nothing works. How should I go about doing this? Any help is appreciated. Thanks.
  4. dahmer45

    Back to basics

    Quote:Original post by quagmire Yeah, that used to happen to me alot when I had started re learning C++. I am not using SDL for C++. It is pretty cool. Just remember to put in that system("PAUSE"); next time if(dahmer45 does not enter wat I told him to) { cout<<"ENTER SYSTEM("PAUSE");\n"; I just had to do that. I'm not used to using system("PAUSE") because with allegro you have your while(!key[KEY_ESC) loop.
  5. dahmer45

    Back to basics

    Ok I added system("PAUSE") and it works now, thanks guys. IDE is compiler right?
  6. dahmer45

    Back to basics

    Ok I added return 0; but its still doing the same thing.
  7. dahmer45

    Back to basics

    Ok, when I make a new project I don't see a precompiled headers box. I only see 'Create directory for solution' box. Also what template should I use?
  8. dahmer45

    Back to basics

    I've decided to throw everything I've learned out the window and re learn C++. So ealier today I made a simple hello world program. But when I run it, it shows a black window and crashes.Heres my source code. #include "stdafx.h" // MSVC++ throws a fit if i dont include this #include <iostream> using namespace std; int main() { cout << "Hello World\n"; } Someone please help me.
  9. dahmer45

    Difference between C and C++

    Wow i didn't expect so many replies. This has all been really helpful, thanks guys.
  10. dahmer45

    Difference between C and C++

    Quote:Original post by EasilyConfused Brilliant thread topic. However, having read the forum sticky about posting in beginners... C++ is (almost) a superset of C in that it preserves most of the original features of C while adding (among others) object-oriented features. I would suggest googling "object oriented programming" if you don't know much about this. So C++ is the same as C but with more features. OK then thanks for the answers guys :)
  11. dahmer45

    Difference between C and C++

    So C++ is better for programming games, and C is better for programming applications?
  12. dahmer45

    Difference between C and C++

    Quote:Original post by Anonymous Poster 1 Meaning what?
  13. Whats the difference between C and C++?
  14. dahmer45

    Game crashing

    Ok thanks _ODIN_.
  15. dahmer45

    Game crashing

    So I need to declare bitmaps after i initialize allegro? Ok thanks
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!