[Guide] c++ your first program will be cool! menu

Shout-Out

User Tag List

Results 1 to 12 of 12
  1. #1
    Ollox's Avatar Member
    Reputation
    5
    Join Date
    Oct 2007
    Posts
    122
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [Guide] c++ your first program will be cool!

    Hello guys! time to learn c++ eh...

    in this tutorial:
    - show you what many functions mean..
    - make a little program..

    Requiments:
    - use Dev c++
    - a brain?

    open your c++ make a new Console Application
    (or just make a Source File CTRL+N)
    if you take the Console Application you will see some codes...
    and u wont do that in Source File..
    the code is:

    #include <cstdlib>
    #include <iostream>

    using namespace std;

    int main(int argc, char *argv[])
    {
    system("PAUSE");
    return EXIT_SUCCESS;
    }

    something like that... now im gonna teach you what this is...
    iostream it has many functions like cout...
    cout is a command that says something you want.. like cout << "hello everyone!";
    using namespace std it will well, use the keyboard if you use a Pause function..
    int main( ) that should ALLWAYS been in the project its the source in your program..
    the { means the code should be here it starts here... example:

    int main()
    {
    cout << "hello mmowned!?";
    }

    the main will say hello mmowned but you need #include <iostream> for the operator
    cout is included there.
    the other } its a block.. it will stop the code.
    system(""); its a good command many things can used there.. like PAUSE it will pauses program and
    say Press any key to continue...
    if you use system("Pause >nul"); it will have a pause function but it wont show you the text. (could be usefull)
    return EXIT_SUCCESS; means it will exit the program if its done everything right.


    Other:
    in the other tutorials i have checked in mmowned everyone is
    using \n its make new line.. but why not use << endl;
    it will end the line there and its much easier..
    // means its a comment it wont make something in the program..
    example //HELLO THIS IS CRAZY

    lets make a program now:

    first you will start with a Source File in dev c++ hold CTRL+N
    now write:
    #include <cstdlib>
    #include <iostream>
    #include <windows.h>

    using namespace std;
    int main(int argc, char *argv[])
    {
    char ourstring[50] = "As you know.. C++ ownz!";
    int len = strlen(ourstring);
    for (int i = 0; i < len; i++)
    {
    cout << ourstring[i];
    Sleep(100);
    }
    //====================================
    cout << "\n";
    system("PAUSE");
    }


    and press F9 the program now will auto write a cool text
    called "As you know.. C++ ownz!" you can change that in the code

    thanks everybody for watching!!
    make now some funny program

    //olloX

    [Guide] c++ your first program will be cool!
  2. #2
    Spinewhip's Avatar Member
    Reputation
    4
    Join Date
    Mar 2007
    Posts
    57
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Er How does this help me make a WoW server?

  3. #3
    kruz2's Avatar Member
    Reputation
    2
    Join Date
    Mar 2008
    Posts
    29
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    that helps you with C++ and that will help you making scripts for your wow server!

  4. #4
    samsta458's Avatar Contributor
    Reputation
    98
    Join Date
    Apr 2007
    Posts
    372
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    rofl at root. Yeah wrong section buddy, theres a specific programming forum + I don't see any REAL way this ties directly to emu servers other then being a programming language.


  5. #5
    **Sweeny**'s Avatar Member
    Reputation
    33
    Join Date
    Dec 2007
    Posts
    282
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    that helps you with C++ and that will help you making scripts for your wow server!
    Making a script with <iostream> helps your server how?

  6. #6
    900number's Avatar Member
    Reputation
    1
    Join Date
    Jul 2008
    Posts
    17
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    great guide thanks +Rep

  7. #7
    obionekanobi123's Avatar Member
    Reputation
    1
    Join Date
    Mar 2008
    Posts
    64
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    nice guide ty for that

  8. #8
    Ollox's Avatar Member
    Reputation
    5
    Join Date
    Oct 2007
    Posts
    122
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    thanks 900number and obionekanobi123

  9. #9
    Ollox's Avatar Member
    Reputation
    5
    Join Date
    Oct 2007
    Posts
    122
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Making a script with <iostream> helps your server how?
    i just wanted to show you what this means..

  10. #10
    micko's Avatar Member
    Reputation
    14
    Join Date
    Sep 2006
    Posts
    56
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    string roflfunction( int user, int forum)
    {
    for(int user = wtfmakesnosense, user >= smokingCrack, rep--)
    {
    lol = lol++;
    }

    return omg;
    }


  11. #11
    Ollox's Avatar Member
    Reputation
    5
    Join Date
    Oct 2007
    Posts
    122
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ey micko nice

  12. #12
    **Sweeny**'s Avatar Member
    Reputation
    33
    Join Date
    Dec 2007
    Posts
    282
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i just wanted to show you what this means..
    You wanted to show us a 10 lined script when we can just go to cplusplus.com and have like 25 pages of showing us basics with <iostream> ?

Similar Threads

  1. What will be your first toon to 85?
    By Gnomercii in forum World of Warcraft General
    Replies: 6
    Last Post: 12-07-2010, 08:52 AM
  2. Your first python program!
    By reaxonz in forum Programming
    Replies: 2
    Last Post: 06-18-2008, 10:28 AM
All times are GMT -5. The time now is 02:22 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search