Sodabread 88 Posting Whiz in Training
public partial class Server

All code behind classes that match up with a .aspx page have to be partial classes. The page itself is part and the code behind is part.

Sodabread 88 Posting Whiz in Training

Re-reading your code, I'm thinking you want multiple structures, but correct if me I'm wrong.

You have products which have stock, price, sold... actual data.
You have a product type, such as shampoo, soap, tortillas, etc..., which have multiple products.

In the most basic sense, I think you could do something like:

struct product
{
    string brand;
    int stock;
    int sold;
    float price;
    // Other items that pertain to a product
}

struct productType
{
    product items[10];
    string name;
    int numOfProducts;
}

int main()
{
    productTypes inventory[10];
    int numOfTypes;
    cin >> numOfTypes;
    for(int i = 0; i < numOfTypes; i++)
    {
        cin >> inventory[i].numOfProducts;
        for(int j = 0; j < inventory[i].numOfProducts; j++)
        {
            //Take input for specific items
            cin >> inventory[i].items[j].brand;
            cin >> inventory[i].items[j].stock;
            ...
        }
    }
}

You should be able to figure out how to do the input using this method.

I think this is what you aimed to accomplish, but forgive me if I'm wrong.

Sodabread 88 Posting Whiz in Training

Input is only a single structure, so every time you input new data, it's overwriting what was previously there.

You can remove the "input" after your struct declaration and create an array of inventories in main, then apply the input to the specific product number that is put in.

Sodabread 88 Posting Whiz in Training

Perhaps try -lopenal32?

Sodabread 88 Posting Whiz in Training

Nissan GT-R

Sodabread 88 Posting Whiz in Training

If your project isn't being used for commercial purposes, I can't say enough about FMOD. I've used it in a few projects and it's extremely simple to get up and running and is license free.

If you want to write your own sound functionality from scratch, OpenAL is my suggestion as well.

Sodabread 88 Posting Whiz in Training

Better idea if you're just learning OGL is to check out nehe.gamedev.net. It doesn't get you into super advanced techniques, but so far, I've found it's the easiest to learn from outside of class.

Sodabread 88 Posting Whiz in Training

USA. We're due for it.

Sodabread 88 Posting Whiz in Training

What you're looking to do is called a tile engine. Research that a bit to get educated on the basics of how to start building one and go from there. Once you get the basic map structured and working, start working with a camera to move around your map, then expand step by step, adding characters, collision, objects, etc...

In addition to knowing that, you'll need to get familiar with one of the aforementioned graphics libs (DX/OGL) or GDI+ if you want the absolute basics.

Sodabread 88 Posting Whiz in Training

The only way to add classes to a linked list is to create objects/instances of those classes and add them to a list.

If you want multiple classes in the same list, you'll need to use inheritance and create child classes of a parent so they can be considered a type the same as the parent. In that case, you'll also need to know what type each one is in order to properly cast the object to get to any non-inherited functionality.

Sodabread 88 Posting Whiz in Training

OpenGL or DX development, 3D math, heavy OOP, memory management, scene management for a start.

Sodabread 88 Posting Whiz in Training

It might be a bit late, but this is the book I got in school and it had some real good info.

Book

Sodabread 88 Posting Whiz in Training

I'm actually really liking FF4. It's still a bit of a memory hog, but besides that, it's been blazing fast since the install on all my machines ranging from Win Server 2K3 through 7. I don't like Chrome or IE, so FF will probably stay as co-primary browser along with Opera for me.

Sodabread 88 Posting Whiz in Training

FMOD perhaps?

Sodabread 88 Posting Whiz in Training

I thought that's what you meant, but I didn't want to make any assumptions and make myself look more like a fool than I already do =)

Whatever lib you're using has to call underlying OS code because only the OS itself can really create that window, which is then manipulated by your application. The lib handles all of that for you so you don't have to code out all the platform checking yourself. If you're looking for an alternative to Allegro, check out SDL.

Sodabread 88 Posting Whiz in Training

Try reader[reader.GetName(0)].ToString(), then parse that.

Sodabread 88 Posting Whiz in Training

Excuse my ignorance, but what is xplatform?

As far as OS game development, a lot of the OS/App integration comes from your underlying libraries such as DirectX, OpenGL, OpenAL, SDL, etc... The main bit of OS specific programming you might need is window creation, at least that's all I ever really needed. There might be more you need for profiling or memory management or other stuff, depending on the language you use.

Hope that helps.

Sodabread 88 Posting Whiz in Training

Ah. My bad. I read it wrong the first time.

From the documentation for FreeGlut, it looks like it's not possible to do it on mouse button release as Tao only uses the 3 mouse buttons regardless of state. You would be able to create your own menu and call it to begin drawing on a button's release, but that also kind of partly defeats the purpose of using the Tao framework, at least for menus.

daniel955 commented: Good +1
Sodabread 88 Posting Whiz in Training

Check the previous status of your mouse button down. If the button was down and it's now up, you know the mouse button has just been released that frame and you can call your menu popup now.

Sodabread 88 Posting Whiz in Training

Looking at this code, you'll still always end up in the inventory because of this...

else if (choice = 10){
    done = true;
    invin();
}

You're assigning 10 to choice, rather than checking if it's equal. I couldn't tell you how many times I've made this same mistake =)

Sodabread 88 Posting Whiz in Training
Sodabread 88 Posting Whiz in Training

For the easiest way to get up and running, I would actually suggest using C# and the XNA framework.

See this site for the XNA Game Studio: http://www.microsoft.com/downloads/en/details.aspx?FamilyID=9ac86eca-206f-4274-97f2-ef6c8b1f478f

MS has put out a lot of tutorials on how to do the basics for both 2D and 3D games using that framework. As much as I love C++ and I'd rather develop in that than any language, I can't say enough about the ease with getting stuff up and running with XNA.

Sodabread 88 Posting Whiz in Training

You can use most any language anymore to create a game. The most popular ones I see right now are C#, C++, Java and Python.

Sodabread 88 Posting Whiz in Training

[Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL server does not exist or access denied.

That's all it gives me. Not a show stopper, but a pain in the rear regardless.

Sodabread 88 Posting Whiz in Training

Well, one thing I see right away is that you're re-declaring lots of variables.

Sodabread 88 Posting Whiz in Training

Yes, I'm referring to compiling, but the issue also occurs when opening a form object.

The controls are of the Adodc type.

Sodabread 88 Posting Whiz in Training

I actually found the issue with this one. Seems someone decided to change the connection timeout of that ADO object to 80000 seconds, which is a bit long. Should have been something easy to find, but I'm not exactly well versed in VB.

Regardless, do you know of any way to stop it from checking the connections? With giving the application a reasonable amount of time to connect to the server, the build process just takes so long because it goes through every connection to see if it's live, waits the 15 seconds, then lets you know the connection is unavailable before moving on to build the rest of the app. It just seems a bit silly to spend 20 minutes to build this app when it should take 20 seconds. Not to mention that you have to sit there and wait for it to error out so you can click ok to let it continue.

Sodabread 88 Posting Whiz in Training

I'm working on an application that has a slew of database connections throughout. The application is being developed on a system which is 100% disconnected from the server on which it will run. Every time I open a form object or attempt to compile, I have to wait n seconds before the dev environment spits out an error stating the database cannot be found.

The real problem is that there's a single ADO object in the app that has a seemingly infinite waiting time before the error comes up. The error never shows and I consequently, cannot finish the build of the application, nor can I open the form object that contains it. I can change the string by opening the .frm file in notepad, which allows me to open the form object in VB, but it doesn't help when building it.

My question is this: Is there any way to disable the checking of ADO connections during development/build?

Sodabread 88 Posting Whiz in Training

The easy answer is physics & "soft" targeting. Apply your x/y/z acceleration to the object, having it move toward the current node/point/target and once it gets within a pre-defined distance to that target, set it's new target to the next point and accelerate the object toward that new target. This should give a smooth transition, as long as you're not using a pure xVelocity = 2.0 type statement, but positive & negative acceleration.

Sodabread 88 Posting Whiz in Training

You tried using System.Security.Cryptography.XML?

Sodabread 88 Posting Whiz in Training

Just curious, why do you say NeHe is no good?

Sodabread 88 Posting Whiz in Training

Decent reply, wtf (although a littler holier than thou), but notice that you're replying to a thread that's almost 5 years old and to a user that hasn't been around for over a year =)

Most of the community is kind of rabid about resurrecting & replying to dead threads. Just a heads up.

Sodabread 88 Posting Whiz in Training

Yes, Excel should be able to be used as a "database". See www.connectionstrings.com.

Sodabread 88 Posting Whiz in Training

Change myMark[count].grade to myMark.grade.

Sodabread 88 Posting Whiz in Training

I don't know what your input is, don't forget that a character comparison is case sensitive. If you're entering "c" from the console, it won't match a grade of "C". You can use character arithmetic based on the ASCII table to determine whether input is lower or upper case and rectify it if it's not what you want.

Sodabread 88 Posting Whiz in Training

I'm in agreement with Nick for nehe. Easily the best "get up and running with OpenGL" site in existence. In addition, you can pick up the OpenGL Super Bible for less than $70 and you'll end up knowing a LOT more than a basic tutorial will give you.

Sodabread 88 Posting Whiz in Training

If I'm reading this right, you're looking for a way to store your objects externally so you can call on them when you need them and dispose of them when you don't.

My suggestion would be to create a manager class (or several) which will be able to create objects on the fly and keep your data stored in XML or whatever your favorite data file type is.

Example:
You can have a sprite manager class which when called upon, reaches out to your data file to get all the information for the sprite type you want to create.

// Depending on how you want to manipulate your sprites, either pass back an int or Sprite *, or whatever else you need
int SpriteManager::CreateSprite(string spriteName)
{
  XMLData spriteData = GetSpriteInfo(spriteName);
  Sprite *temp = new Sprite(spriteData.name, spriteData.dimX, spriteData.dimY, ...);

  // Push the sprite * onto a vector<Sprite *>
  spriteVec.push(temp);

  return this spriteCount++;
  // or
  return temp;
}
class tile
{
  private:
    Sprite *sprite;
    // or
    int spriteID;

  public:
    void DrawCharacter()
    {
      RenderManager::GetInstance()->Draw(sprite);
      // or
      RenderManager::GetInstance()->Draw(spriteID);
    }
}

This code has a lot to be desired, I just don't have the time to write out everything going on in my head about writing a 2D renderer.

You could also have render bins in which you deposit textures & positions where the render manager would pull from every frame to decide what to draw. This way, a game component could decide what to draw based on where an object …

Sodabread 88 Posting Whiz in Training

We don't just post code for people that ask for it. You need to do the work on your own, then come in and ask us for help on specifics if/when you get stuck.

In other words, we'll help with homework, but we won't do it for you.

Sodabread 88 Posting Whiz in Training

Check your if statement. Your comparison is not a comparison, but an assignment. A single = is assignment (int y = b), whereas a double == is comparison ( if(x == 5) ).

Change that if statement and let us know what happens.

Also, the sizeof(myMark) / sizeof(markRec) line is figuring out the count of records in your array of markRecs.

Sodabread 88 Posting Whiz in Training

Just tossing this out there...

My personal areas of interest are predominantly focused within the games industry. Info about new game releases, company expansions/mergers/splits/closures, new tech being used by the game industry... these are things that *I* would be interested in reading about.

I'm compelled to agree with Lusi here. I'm big into game industry news, but I do notice that a lot of reviews are very biased, where the comments are the only non-fanboy opinions lie, and most often they're just hate.

I realize that this isn't a gaming site and even the game development forum is rather.. *insert crickets sound here*, but a good unbiased pro/con style review (see classic EGM) would be cool for some of the bigger releases like Starcraft 2, Call of Duty, etc... or even an occasional under the radar/indie title would be nice.

The internet's a wonderful invention, but I like to get as much info from a single source as possible, rather than having a bajillion sites for a few different topics.

Sodabread 88 Posting Whiz in Training

Let me get this straight. In the button's click code, you have it create a connection to the database, then validate the text boxes? If that's the case, swap your validation & connection code and you're done. If that's not the case, then what do you mean?

Post some of your code and tell us where you're having trouble with it.

Sodabread 88 Posting Whiz in Training

Try: RequestedExecutionLevel level="requireAdministrator"

First link on Google with "C# run app as admin" yielded this.

Sodabread 88 Posting Whiz in Training

I recommend that you also take a look at some open source 3D games so you can get an idea of how things work.

In addition to learning DX and/or OpenGL, you're also going to need to know a good chunk of 3D math and more in depth rendering techniques before you can make a big game. I recommend checking out the Game Programming Gems & GPU Programming Gems series of books, along with a good OpenGL (OpenGL Superbible) or DX book. I don't know which DX books are that good because I mainly use OGL.

Also, gamedev.net is going to give you a lot more information about game development than you'll find here. They have lots of tutorials, specific forums, book articles, etc...

Good luck =)

Sodabread 88 Posting Whiz in Training

Try using a do...while statement. The PollEvent function is more than likely initializing the event object, so when you try to use the event object before it's been assigned anything.

Sodabread 88 Posting Whiz in Training

You're going to need to try and develop something on your own and then ask us for help if/when you get stuck. There's so much information out there on using C# with SQL, so I don't think you've really looked hard enough, unless you're using Google to find a complete project that you can just turn in. A quick search on "C# SQL" yields many pages, the first of which being exactly what you need.

Sodabread 88 Posting Whiz in Training

Have you tried Google?

Sodabread 88 Posting Whiz in Training

I could be wrong, but shouldn't the connection path have "\\" between the folders instead of "|"?

Sodabread 88 Posting Whiz in Training

It's not about negativity, it's about reality. The gaming industry is a very difficult one to thrive in unless you have the talent to back up everything you want to do. This is why just having a cool idea for a game is going to do next to nothing for anyone. The person with the idea needs to have one of the skills necessary to build the game, whether it be business sense, game design (not game idea think tanking), programming, etc... Like I said, game ideas are a dime a dozen, but you're going to need something else to back it up if you want to put a team together. The only way most people are going to do all the work on something that isn't their idea is if their getting paid for it.

DragonReeper commented: I tottally agree, but nobody knew better when they started out +0
Sodabread 88 Posting Whiz in Training

You have a few choices in databases. I recommend, as Chris does, that you get SQL Server Express. It's very easy to install and get up and running.

MySQL is also a good choice as it's free, open source, and works very very well, but the initial configuration can be a pain sometimes.

The last I would recommend, which is only a recommendation if you have MS Works or Office, is MS Access. I don't like it, in fact I hate it, but it's still usable and it's simple to setup new databases.

As for how to get another person to use your database enabled application, you'll have to make sure the other person has your choice installed, and build SQL scripts to set up the database in their installation. This is why MS Access is advantageous, as you can just ship that .mdb file with the executable and you're good to go, although the file can be changed rather easily.

Sodabread 88 Posting Whiz in Training

I've had it a couple times, but my old Pa Kua master drank it daily. It was ok, I suppose.