~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Winter in India :D

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Yes I think he exactly means that which are used for spamming everyone's mail boxes.

Thread closed.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Ah winter for me.
Why ? Its so calm, the cold wind blowing, my thoughts drifting....
Ah it is so good..

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

The API ( Here Ogre ) takes care of it. It makes all the DirectX and OpenGL related calls transparent to you, so you need not worry. And btw professional engines like Ogre make use of both DirectX and OpenGL underneath. THis all will become clear to you once you start studying the engine -- but be warned Ogre *is tough* so unless you take it seriously, it wont take you seriouly :D.

And btw Ogre3D is free to download, its open source.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Hmm... sorry though I dont have the time as such to join your party but I will try to help as much as I can (have made a game once )

1. For a list of free game engines along with their reviews look here

2. As far as 3D modelling tools are considered, if you have big bucks you can go for the professional tool 3ds max or Maya. A free 3d modeller is Blender and has the features which match the professional ones (though its a bit tough to learn it).

3. Level editors are also aplenty out there but sadly they require you to pay for using it. A free one is Deled

4. Good sound libraries are:
Fmod: http://www.fmod.org
OpenAL: www.openal.org

5. Network API's
RakNet: http://www.rakkarsoft.com
Zoidcom: http://www.zoidcom.com

6. Physics Libraries:
Newton Game Dynamics: http://www.newtondynamics.com
Novodex: http://www.novodex.com
ODE: http://ode.org
Tokamak: http://www.tokamakphysics.com

As far as my experience and persoanl recommendation is concerned go with Irrlicht

Reaons:
1. Supports a lot of file formats
2. Has a level editor and support for .NET languages.
3. Has a very active community.
4. You can start being productive in a week or so.

IF you are really up for a challenge and want to do some serious …

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

"Where is the '}', where is the closing '}'? Now, where is that 'if-- where is the damned 'if' !?."

Instead of on a comp screen, my compiler was displaying on a newspaper, and as I flipped each page I could view each cpp, header, etc. I never found the "}" or the damned "if". :rolleyes:

Whoa that sure is some dreams,..:mrgreen:

Damn when I come to think of it, I dont even remember what I dream..

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

[edit]sorry ~s.o.s.~ for duplicating your answer.[/edit]

Ah come on Mr. Dragon, you are embarassing me... no problem at all.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Because this is a code which accepts [search]command line arguments[/search]. You need to run it using a console window by supplying parameters at the command line.

If you using windows you can invoke it by opening the command prompt, going to the location where the executable of the program resides ( .exe file ) and typing this;

c:\Path_to_your_exe\program_name 12 <-- any number you want

This should do the trick.

Hope it helped, bye.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Because EOF is actually a maro which is defined in stdio.h as #define [B]EOF[/B] [I]<integer constant expression < 0>[/I]

The macro yields the return value used to signal the end of a stream or to report an error condition

In your case its the end of stream thing which is causing the break of loop.
In Mr. Dragons case it is the 0 which is returned by the fgets( ) which is causing the termination.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

All my dreams are in black and white... Do any of you dream in colour?

Same here, all in black and white. And what more, the dreams are hazy, cant see them very clearly.. :cheesy:

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Yes I have played it but have dumped it a long time back. I completed all the campaigns and after that the game started to look boring...

Dont think you would get many takers here.

Maybe Miss Dani should start a new Lounge for gamers so they can discuss the games they have played ... but dont think many people would participate in such a thing...

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Why not to use EOF see HERE

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Welcome back my friend.My best wishes and reps to you.

Hoping to make good friends with you..

Regards,
~s.o.s~

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Damn it has started again.

But this time I tried it out with IE6 and the problem doesnt occur there, so I think its a firefox issue.

And strange enough the image chopped here is of the same guy I had posted before.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Its a bit heavy to grasp on your first attempt but try to read this and you will know most of which you want to.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Ask from the user the number of values that he would want to sum up.
Something like:

int max_values = 0 ;
cout << "Enter the max values you want: " ;
cin >> max_values ;

for( i = 0; i < max_values; ++i )
{
   // do all here
}
~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

along with Mr. WaltP...:P

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

So who's the one with the smoking avatar?

Ouch... You sure have good observational powers.... consider being Sherlock Holmes :mrgreen:

Somebody needs a girlfriend... I can give you a discount on a slightly used Girlfriend 1.0...

Yeah maybe then there would be someone to kick Wolfie when he makes sarcastic comments. :cheesy:

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Okay here are a few pointers:

1. Use int main( ) not just main( ) and append a return 0 stmt at the end of main( ).

2. Dont hard code the file names in the function, its not a good practice. Just keep the file name in a constant array of characters.

3. I am not sure on this one, but, dont use \\ in your file paths, it is not cross platform complaint. Use forward slashes instead ( / ).

4. After opening the files do check whether the operation is successful, it is a good practice.

FILE* fp ;
if( ( fp = fopen( "a.txt", "r" ) ) == NULL )
{
     fputs( "file opening failed", stderr ) ;
     exit( 1 ) ;
}

5. fscanf( ) normally returns the number of items scanned and in the case of error a NULL is returned.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Hello.

Just wanted to tell you that this behaviour is only for Daniweb. I am currently usign Firefox 1.5.3

I havent tried it out on other browser.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Looks like the page didnt load all the way (Sometimes that happens to me also)

No its not because of page loading... this happens for each and every page of Daniweb and that too when it has being fully loaded..

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Hmm... this is what I get for suggesting a new thing.

Though I have noticed one thing, whenever there is a healthy, I am the only one on one side while the rest of the members on the other.

Here is what happens when you get Bad rep, and now imagine if it was not annonymous.

IF it were not anonymous, I would have made the matters clear with the OP by PMing him.. no harm done to the forum or no strain on it.
The reason I started the thread was that I thought MIss Dani would be knowing the name of the one who did that ...

We'd have to disable this feature for SOS though otherwise he might top himself. Or worse still, quit programming and go back to hand stiching footballs.

Naa.. I aint a coward. I would have settled the matter by giving him back what he gave me. And with my current reputation I sure would have turned his status from green to red. And no I dont know how to stitch footballs and dont plan on learning that.

And, for the record, both iamthwee and me (who is nearly fortythwee) are joking, Mr SOS!

Atleast someone here knows that I have got a bad sense of humour :D

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

what go to hell doesnt fit in!

In this game, your post should be coherent with the previous post... it is not necessary it should go along with the big picture.
Hence

And they all ... go to hell

seems to be correct

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

I'm still looking for an legal version of girlfriend 1.0. I can't find an serial for the downloaded once.

Go download a pirated one.. :mrgreen:

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Funny you asked. I quit smoking last Sunday.

And you must have taken really strong one for the last time to end it all...:cheesy:

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Now its working fine........
It happens sometimes ( has happened a couple of times ) and doesnt go away until I restart my machine.
Dont know whether it has to do with my PC or Daniweb ?

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Dont know if anyone else is having this problem but most of the images of Daniweb on my web page are chopped off?

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

i dont like the reuputation system as noone ever gives you any - ive got like 600 odd posts and basically no reputation
have you seen the msn q&a beta dani?
i think a "best answer" type system woule be good

It just depends on the forum, and I think Daniweb has got a lot of evolving to do in terms of reputation.
There are many forums where reputation is rampant and in full swing. What I mean by this ? Well its like if I am a moderator of C++ forum or you are a C++ forum frequenter and if you find a post of Javascript nice or informative or feel that the post has very good content, you add the reputation to that person.

The reason reputation works there is because the people who have added reputation, their name appears at the bottom of the post, no need to go to the control panel. Thats the thing people like the post about it since it shows to you who has added rep to you and even you keep that in mind the next time you encounter that persons post.

The name here is not specfied since Miss Dani thinks that giving out name will cause increased tension among the members. But I dont
think there is any kind of tension among people of forums where there is open reputation system.

And as far as adding reputation is concerned I add REP …

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

BTW, just wanted to tell you that I ran your code and it worked fine for me. Any specific you are encountering ?

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

No I aint a sponsor, I am a moderator of Software development, Windows and Site Management. (The ones you see on top menu )

And Area 51 basically features the forums updates or suggestions from your part on what more should be implemented and what changes are to come up.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

yay ive just noticed now im "practically a master poster"

Congratulations Mr. James :cheesy:

Hey I just noticed I am now... err.. "Oh I C" :eek:
Hm..
:mrgreen::mrgreen::mrgreen:

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Almost everything related to WinAPI can be found here:
http://www.winprog.org/tutorial/

Here you will find the answer to your question in the 9th chapter.

Hope it helped, bye.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

~S.O.S.~:
Cenotaph by Bolt Thrower

Eeeeks.. all these guys do is keep on growling..hehe not my type. Looks like you are absolute death metal, grindcore fan...
Even I was once, when I was all downtrodden, thought there was nothing left to lose, everything was gone and all that.

And with lyrics like these, my emotions were intensified..

Chopped in half

Feel the blood spill from your mouth
With rotting ways comes destiny
Feel the soul taking over, bleed!

Chopped in half

Feel the blood spill from your mouth
With rotting ways comes destiny
Feel the soul taking over, bleed!

But now I am trying to change the way I look at life, trying to be a better human..coz I have learnt that life always sucks, its your responsibility to make it worthwhile and enjoy your living.:mrgreen:

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Damn looks like I am the only one here whose scheme sucks,...

Speed : 150 kbps

Duration : 9 PM to 9 AM

Charges : $12 pm

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

When Google first came out with Gmail, it was total chaos. Everyone wanted an invitation so that they could have an email account with 1 GB !!! of space. (obviously it was a marketing gimmic on part of google to create fictious scarcity of accounts by asking for invitations )

But now it has died out, and having a Gmail account doesnt make me feel special. All my Gmail accounts (yes ! all and I have many ) are lying out there, waiting to be checked in...since I use only one and even that is only 2% full ;)

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Hey there buddy, welcome to Daniweb and enjoy your stay here. Hoping to see you soon in the C++ forums ;)

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Dont you think there is a prob with your for loop.

The format is for( initial conditions or initialize vars; check condition; after_each_loop) And what you have written is :

for(pos=s.begin(),pos2=s.end()-1,pos!=s.end(),pos2!=s.begin()-1,pos++;pos2--)

You have messed up with the placement of your " ; "

To avoid the complexity of this loop place the init stmts outside the for loop like:

start = s.begin( ) ;
end  = s.end( ) - 1 ;

for( ; start <= end; start++, end-- )

{
   // your stmts here
}
~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Okay, I am going to ask you why rely on characters if you have strings at your disposal. I havent as such seen the whole code but I think what you are trying to do is to accept the input from the user in string form as abbr and display the corresponding state.

The thing I dont understand is why work at the character level. Why not make use of the string class which greatly simplifies a lot of things.

Also as Mr. Dragon suggested, try using maps which will greatly simplify your task

int main()
{
    int a = 0; // initialize variables always

// dont use two characters, use string as you have already used instead
     char firstLetter = '\0' ;   // setting char to null char
    char secondLetter;

    string stateName;

    cout << "       STATE POSTAL CODE CONVERTER\n\n";
    cout << "Enter the two character Postal Code to see\n"
        << "it's corresponding State. (for example AK)\n\n";
    cin >> firstLetter >> secondLetter;
    
// replace this cryptic while loop and switch 
// use string compare operator == instead
     while ( (firstLetter != 'E') && (secondLetter != 'X') )
    {       
       <--snipped-->
        cout << "Enter another State Postal Code or \"EX\" to exit\n\n";

// you have to press enter two times and the program is case
// sensitive and works for only uppercase characters.

        cin >> firstLetter >> secondLetter;
    }

// dont use this loop, use [I]cin.get( )[/I] instead

    for(a = 1; a < 3000000000; a++);  // acts as a …
~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Hey,When you initialize it like that w/o any number, it is either an unknown number, or in most cases, 0.

Uninitialized is uninitialized, and always holds a junk value with the exception of global variables which are automatically initialized to 0.

Sharky, to avoid such subtle bugs *always* initizlize your variables when declaring it.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Just wanted to let you know that you cant have more than one int main( ) function in your project.

And also try out the thing about right clicking on the project view. One of these two can most likely help you out.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

In fact your example doesn't even exhibit behaviour you would expect when using the word 'permutation'

Hehe, looks like we are not the only ones asking him this question.
There are others out there....

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

A non recursive way, if it suits your need:

http://www.daniweb.com/code/snippet533.html

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Why use Turbo C? Try downloading Dev-C++, Code::Blocks, or if you're into the command line, gcc.

Agreed.
Better move on with the times rather than being left behind. When using Turbo C, beginners keep getting weird ideas about how to clear the screnn, checking for key hits, using the useless inbuilt graphic library.
Using modern optimizing compilers keep you from using non standard funcitons in your program.

Do a reality check ? Want graphics in your program to make a game, use third party graphics engine ? Want GUI ? Use GTK+.
There always is a better alternative if you have open ideas about it.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Hmm.. never ever encountered such a problem, but just to make one thing sure..

Are you right clicking on the project in the project window to your left and selecting "set as active project" to the project which you are working on ?

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Hmm...What have you been smoking lately Wolfie ?

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

Ah..getting senile in young age is not the best of things that can happen to you....

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

LOL nice one. Guess the question has two correct answers... :D

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

First of all

1. Indent your code properly so that it is easy for us to go through it.

2. Dont use void main( ) , use int main ( ).

3. You have very much accomplished most of the task, but I think the mistake you are doing in your case is to put all the things together.

FOr eg. I can see in your code that you have generated both the shapes using the same for loop. It would be a very good idea to make your each and every shape generation distict and modular, since all the other shapes are just derivates of the first two.

Make your code into something like:

int main ( )
{
   // generate the first shape seperately
   for( .... ) 
   {
    // logic for first shape
    }

   // generate the second shape
   for ( ... )
  { 
   // logic for second shape
   }
}

OR

int main ( )
{
    generate_first(dimensions_for_the_shape ) ;

    generate_second(dimensions_for_the_shape ) ;
}

This way, you would need to do less rewriting and the logic is greatly simplified.

~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster
~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

LOL.. wow man, where did you get hold of this pic.

Hey wait...dont tell me its your printer..:D