spunky1a's Q&A profile
Game Technologies: DirectX, XNA, XACT, etc. Collision Detection and Rotation issue
Hi, I am creating a pong game for my first game. I am having problems detecting collisions when i am using the Draw method of the spritebatch with the rotation parameters. if i use this code everything works great: //This method is in the Ball class called from update method protected virtual void CheckCollision() { if ( this .BoundingBox.Intersects( this .Game.Player1.BoundingBox)) { _velocity.X *= -1; _direction *= -1; } else if ( this .BoundingBox.Intersects( this .Game.Player2.BoundingBox)) { _velocity.X *= -1; _rotationdirection *= -1; } } the boundingbox property is implemented as follows: public BoundingBox BoundingBox { get { return new BoundingBox ( new Vector3 (_position, 0f), new Vector3 ...Show All
Visual Studio Express Editions Trouble Saving New Projects
Just installed VB Express. However I can't open new projects passed the initial simple one I've created. Toolbox is empty. Form is missing. Properties are missing. Have registered the IDE but still no luck. DO you see any new project templates (windows application, console application, class library). The toolbox will only be populated if you are currently working on a form in a new project, so if you arent working on a form using the form designer mode then the toolbox wont show any contents. The properties windows may also not show anything depending upon the current window your are working on - if its a code window then it may not show anything. Are you saying that you dont get any con ...Show All
.NET Development Bizarre .NET performance benchmarks
While attempting to achieve a maximum performance in .NET code I have stumbled on a very peculiar effect. If you compile and run the following C# code, you get a better performance in Debug configuration than in Release configuration. Moreover, if you comment out any one of the unused (!) case blocks in the Distance method, you get 5-fold !! increase in the performance in the Release configuration. I would appreciate any explanation that anyone can offer. And it would be great to hear comments from the .NET development them if they are following this forum. Thanks, Victor P.S. I am using VS 2005 and Framework v 2.0.50727.42 using System; using System.Text; using System.IO; using System.Diagnostics; names ...Show All
.NET Development GetRunningObjectTable in .NET 2.0
Apparently GetRunningObjectTable is a new supported method in .NET 2.0. It is accessible via IBindCtx.GetRunningObjectTable and the signature is given as... void GetRunningObjectTable ( out IRunningObjectTable pprot ) Which of course implies that IBindCtx is a supported .NET 2.0 interface too. This is good. We don't have to bother with all that tedious P/Invoke stuff. So... ... does anyone have any ideas on how to get hold of the .NET 2.0 object that implements IBindCtx (because the MSDN certainly doesn't give us any clues!) Cheers, ~swg swg wrote: ... does anyone have any ideas on how to get hold of the .NET 2.0 object that implements IBindCtx (because the MSDN certainly doesn't give us ...Show All
Visual C++ Project Templates
I use opencascade. I want to add its templates to the vc++2005 tempaltes, the *.awx files are available. What to do Even I do have the same problem. The link that you gave does not solve the problem The template is in Visual Studio 6.0 format (.awx extension) but Visual Studio 2005 does not seem to recognize it. In VS 6, .awx files are to be copied in "\Program Files\Microsoft Visual Studio\Common\MSDev98\Template" but what to do in Visual Studio 2005 Thanks ...Show All
Visual C++ Resource Editor: Add/Remove Operation impossible code read only - Release VS2005
Hi, I hope we can solve this problem in the following way also. Suppose we have "n" projects in our solution and we want to add one "message” in "n-x" [x < n] number project. Just do the following steps. ...Show All
Visual C++ C and C++ run-time DLLs in VC++ needed in Deployment servers
Hi friends, I have a small question on the C, C++ RTs. I have an application built in VC++. Now it runs fine in the machine where the application is built, since msvcr70.dll and msvcp70.dll are present. But it complains if I try to deploy the application in a machine(Windows 2003) where VC++ is not installed . I was wondering if there are any equivalent DLLs that comes with Windows 2003 so that I dont have to install VC++ there. What is the solution for this problem without having to install it. Is static linking a solution (which I don't think so ) Or bundling the CRT DLLs when I ship the product Can somebody suggest some help. Thanks, Robertis I am under the impression (and may be wrong) that msvcp7 ...Show All
.NET Development VB6 app fails with VS2005-built .NET DLLs
Hi, I have a VB6 app that works fine with several VS2003-built .NET (C#) DLLs, but will not run when the DLLs are built in VS2005. Initially, w/ VS2005-built DLLs, the app simply dies at startup with the error "Out of memory", trying to load the main C# control "MainCtrl". The depends.exe profiler reports an odd error with this DLL, as if it is trying to load the type library file instead of the DLL: 00:00:05.297: LoadLibraryExW("c:\my\MainCtrl.tlb", 0x00000000, LOAD_LIBRARY_AS_DATAFILE) called from "c:\winxp\system32\VERSION.DLL" at address 0x77C013C2 by thread 1. 00:00:05.297: LoadLibraryExW("c:\my\MainCtrl.tlb", 0x00000000, LOAD_LIBRARY_AS_DATAFILE) returned NULL by thread 1. ...Show All
SQL Server CSV file as a data source
Hi, Can a CSV file be used as a data source for Microsoft Analysis Services 2005 Rgds hari You can create SSIS pipeline, which will read CSV's and then uses AS Processing Task to load data into partitions. I have done it in the past, and while it is not a smooth ride (especially when your partitioning scheme of the cube is not trivial), it can be made work. ...Show All
SQL Server grouping question
Hi, I have a cube which has a "Product" dimension that has 4 levels which are: - High Level Product Name - Mid Level Product Name - Low Level Product Name - Product Name My fact table has measures for all 4 levels. I have a report with an MDX data source. The report contains a table control which has 2 columns, "product name" and a measure column. In my report I have defined two groups, one for product level 1, and another for product level 2. This will mean that my data will be grouped by products as follows: (below products a, b and c are level 1, x, y and z are level 2)... Product Measure - Prod A &nbs ...Show All
Windows Forms method with list of parameters
hi every body i am working in class that bind database with my application and i need to know how to make method that accept list of parameters (to execute Stored procedure with any number of parameters ) pleeeeeeeeeeeease i need help i need it to be liek that x.ExecuteStoredProcedure(storedprocedurename ,LIstofParameters ) thanks mr Bob zhu - MSFT for your interest but this method solve the problem from SQL side i need to do it from Microsoft Visual Studio enviroment (by C# Code) u know how to solve it ...Show All
Visual Studio Team System Work Item DB Maintenance
I am resposible for doing capacity planning for our TFS server. There seems to currently be no way to delete work items from the server which will cause our disk usage to increase forever. 1. Is there a plan for work item cleanup for a future version of TFS so long-lives TFS project can be maintained 2. If I delete a TFS project, does it delete all the associated work items for that project hi, this is my script in deleting the workitems... delete from WOrkitemLongTexts where ID=673 delete from WOrkitemsAre where ID=673 delete from WOrkitemsLatest where ID=673 delete from WOrkitemsWere where ID=673 ...Show All
Software Development for Windows Vista On Vista, iexpress launching the application window in the background!!
We use the Microsoft's IExpress to package a bottstrapper and MSI file into a self-extractable installer package.The self-extractable installer extracts bootstrapper (setup.exe) and MSI package and launches setup.exe which in turn launches msi package. The problem is when self-extractable is launched on Vista machine, the UI window is getting launched in the background. I have to use ALT+Tab to bring it to the foreground. But when the self-extractable is launched on other OS (XP, W2k3 server etc), UI window is properly launched in the foreground. Has any one experienced similar issue Is this an issue with Vista When I double click on the self-extracting iexpress executable, first elevation prompt is displayed in the ba ...Show All
Visual Studio Express Editions Installed Microsoft Windows SDK & now cannot build a thing! What's going on?
One time trying to build a Forms project I got this error message amongst others: error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup Debug\Rtry070118.exe : fatal error LNK1120 Then New CLR project and many other variations The ONLY source file in the project was this .cpp file! /* memset example */ #include <stdio.h> #include <string.h> int main () { char str[] = "almost every programmer should know memset!"; printf(str); getchar(); memset (str,'-',6); puts (str); printf(str); getchar(); return 0; } Build a CLR emty project with the above code and I get "Unable to start program 'c\documents and settings\dosrelic\my documents\visual studio 2005 ...Show All
.NET Development using object xpath.
Hi , I have a doubt regarding the object xpath navigator with which we can traverse through the objects by appliyig xpath over that. i downloaded the sample from http://msdn.microsoft.com/library/default.asp url=/library/en-us/dnexxml/html/xml03172003.asp In that sample i have added the same objects ArrayList basket = new ArrayList(); basket.Add( new Book( "Repairing your car with twine", 100, 25, new string [] { "Automotive", "Crafts" } ) ); basket.Add( new PowerTool( "Uber Drill 9000", 2, 1200, new string [] { "Drills" } ) ); basket.Add( new PowerTool( "Texas Chainsaw", 1, 1700, new string [] { "Saws", "Tree Care" } ) ...Show All
