fotis8's Q&A profile
Game Technologies: DirectX, XNA, XACT, etc. Question about location and number of main game objects
Ok so I'm still starting out with XNA, so apologies if this sounds like a strange question. I'm still getting the hang of the architeture of XNA, and am having trouble working out the numbers and location in the heirarcy of certain important game objects. Im using a GameState style engine for my game, and refer to each "state" as a "screen" This is my current layout... GraphicsDevice - One in main game class, passed through constructors to relevent functions ContentManager - One per "screen", made sense as if a screen unloads then all its content should unload too ( ) SpriteBatch - Currently one for each low level game object (eg, Sprite object, UIElement object) however i think this should be higher up and pa ...Show All
Visual C++ When "It just works!" doesn't. :(
Hi, To test out "C++ Interop", I created a static library in VC++ 6.0: Here is the contents of the header file (staticLibrary.h): #ifndef STATICLIBTEST_H #define STATICLIBTEST_H #include <string> using std::string; int add352(int value); string sayHello(string name); #endif Here is the implementation (staticLibrary.cpp): #include "staticLibrary.h" int add352(int value) { return value + 352; } string sayHello(string name) { string s1("Hello, you are the greatest, "); return (s1 + name + "!\n"); } This code compiles fine in VC++ 6.0 and it produces an object called "staticLibrary.lib ...Show All
Visual FoxPro Suggestion for VFP-MySQL Multiuser env.
Hi all, I've just shifted from Foxpro tables to MySQL server based application. For a multiuser environment in VFP I used to have the temporary tables for the individual users in their own local machines. But in case of Mysql / oracle how to handle this situation The temporary table that I 'm speaking of are generated when I want to create some reports or perform some maintenance on tables. For example consider a scenario of producing a Sales analysis report. In VFP based application I created a local table say temp and put the data from invoice, invoice return and all related tables. then I manipulated the temp table to suit my reports. There was no problem in multiuser env. since each user created their own 'temp' table in thei ...Show All
Game Technologies: DirectX, XNA, XACT, etc. beta 2 mouse input (windowhandle and ismousevisible)
Setting Mouse.WindowHandle to Game.Window.Handle doesn't seem to do anything... I assume it should only cause mouse events that happen on that window to be captured, but I'm getting mouse events even if I'm on some other window. Also, setting Game.IsMouseVisible doesn't seem to work all the time. I'm trying to hide the cursor while the right button is down, but it doesn't hide. If I set it to false outside of the if statement, it does hide... I know it's entering that if statement though, as I'm doing other things there. When you say "in beta 2" does that mean it's something that will be fixed, or is that the final functionality It presents a problem for doing camera movement... for example, ...Show All
Visual C++ Term not initialized?
The program listed below works just fine without the while loops, but once I enter in the while loop it no longer works: #include <iostream> #include <cmath> using namespace std; int main ( void ) { char term[10]; // Number of years of loan. Used for users knowledge of length of loan. // char loan[10]; // Monetary amount of loan. For use with equation to produce monthly payment amount, and for display to the user. // char rate[10]; double loanvalue; char exit; cout << "Mortgage Calculator" << endl; // The following lines are used to display the loan information to the user. // cout << "For a loan with the following:" << endl; while (exit != 'n') { cout << "Ent ...Show All
Game Technologies: DirectX, XNA, XACT, etc. 3d tools using mfc+Directx
hi all, Basically am a entry level game programmer now i had started my path on tool development, presently i am developing a software like motion editor for that i need to write code for the basic setup so i want to know is there any article of tutorial for creating the basic setup using MFC + directx. ie multiple viewport (you know what a editor needs) please help... KissPsycho Since you say you are an entry level game programmer, I assume you haven't started doing anything major yet with tools programming. I don't know how familiar you are with VC# .Net or MFC but, my advice would be to use VC# .Net with Managed DirectX. In my view, it is the best set of tools available for amateur game tools ...Show All
SQL Server MCDBA or MCTS
For my last 3 years I have work with the SQL 2000 as a database analysis. Now I want to get a certification to prepare me to look for a better job. Which certification is more valuable in today job marker MCTS or MCDBA. Indeed, you don't gain any benefits when doing MCDBA. The only benefit you could have is to gain some extra knowledge when studying for the exam but since you allready have some experience this will be limited. There is an upgrade track from MCDBA to MCITP Administrator but this is only for the administrator track and not for the Development or Business Intelligence track. You can check the multiple possibilities at http://www.microsoft.com/certification Greetz, Geert Geert Verhoeven Consul ...Show All
Visual Studio 2008 (Pre-release) Only letters and numbers in a TextBox
Hi all, I have a TextBox in which I want the user to enter only letters and numbers. How do I go about this Cheerio, Frances That is unfortunately so so easily done. If you implement the KeyDown-event for the TextBox, you get this: private void KeyDownEventHandler(object sender, KeyEventArgs e) { // do something. } The only thing you can get there is e.Key, of which you can't get the ASCII value. Thanks, Frances ...Show All
Visual Studio Sandcastle - how to generate additional content for root namespace pages?
I understand that I will have to do some xslt work, but I'm hoping that someone with some Sandcastle expertise can outline what I need to do to achieve my goal, which is as follows: We have many namespaces in our application. In the root namespace pages, I want to create a new section under the members section called "Resources". I want this section to be a table containing links to additional reading material (UML class diagrams, DRDs, etc.). Ideally, I'd like to store the information needed to build this section somewhere within each assembly's project... in an xml file or such. So... how should I store the information, and which xsl file(s) do I need to modify TIA! Thanks ...Show All
SQL Server Trigger data corruption
I have a weird issue with a trigger... I have a table called category, which has a column [Name], and a record "113_Install". I have the following query in an AFTER UPDATE trigger on this table: INSERT INTO DataPump_PendingCategory (CategoryName) SELECT i.[Name] from DELETED After changing the data in Category, I see the following record in my pending table..."113_Ins D" or something similarly corrupt looking. From what I can tell, both of the tables have the same settings, any thoughts I can't see anything in there that might be contributing to the problem. It looks like the next step, albeit, not a pleasant one, is to script out the FK constraints, Data, then DROP the table and recreate it -AND hopefull ...Show All
Visual C++ Creating Owner Draw ListBox using Create function
I have created an owner drawn list box as follows DWORD dwFlags = WS_CHILD|LBS_OWNERDRAWFIXED|WS_BORDER|WS_POPUP|LBS_NOTIFY|LBS_NOINTEGRALHEIGHT; m_ListBox.CreateEx( 0, WC_LISTBOX, _T("ListBox"), dwFlags, CRect(10,10,250,250),this, 0 ); But the DrawItem call is not happening to the listbox. Any clues Maybe you do not provide the important MeasureItem handler for your control, or the control does not contain items, or the control actually should be created with Create function ...Show All
Visual Basic Launching a .exe prgram from within a VB program
Howdy, I am wanting to write a simple program to launch my application from a button, basically like the old Office launch bar. what i would like is that i press button X, and it loads microsoft word, I press button Y and it loads Half Life. I have been playing with system.io but i dont seem to get it...lol Thanks in advance. Dwayne Schaffarz System.diagnostics.process.start method will work and allows you to launch applications either by specifying the executable files such as System.diagnostics.process.start("Notepad.exe") or by specifying a filename with an application associated with it, such as System.diagnostics.process.start(" http://www.yahoo.com ...Show All
Windows Forms Making a label button...
Hello guys and girls! ;) I have one label with a x mark that hides the form where it is and other form is showed. This label as two more events, MouseEnter and MouseLeave and they change the color of the x mark. But the problem is...when i enter the form with the label again these events don't respond anymore, and the color persists. What is the problem Thks all.. Maybe the MouseEnter and MouseLeave events only apply when the form is the active one. See if clicking on the form's title bar makes a difference. ...Show All
Visual C# who catches explicity thrown exception ?
I have a question about the usage of throw in the following code I found on msdn. In this code, an excpetion is caught using try catch block and in the catch block it is rethrown using an explicit throw statement. My question is that who handles the explicitly thrown exception The same catch if this is the case then the compiler will be trapped infinitely inside the catch block. using System; using System.IO; public class ProcessFile { public static void Main() { FileStream fs = null ; try //Opens a text tile. { fs = new FileStream("data.txt", FileMode.Open); StreamReader sr = new StreamReader(fs); string line; //A value is read from the file and output to the console. line = sr.ReadLine(); Console.Wr ...Show All
Visual Studio Express Editions cannot switch to debug-mode
Hi everybody, in my VS C# 2005 Express I cannot switch to debug-mode any longer. The respective pull-down in the toolbar is shadowed and the menu-entry for the configration-manager is not available at all. What has happened Thanks for you help. Regards, Holger. didn't try that because... <see next posting> Figo Fei - MSFT wrote: Hi, You mean missing If so, go to Tools | Import Export Settings and reset your settings to General Development Settings. Thanks ...Show All
