Answer Questions
snez hi, question about mouse cordinates in 3d world
hi, i want to be able to click on a 3d object with the mouse, how can i do that i know its somthing to do with picking i read about it, but i dont know how to make it happen, how can i do that i know there is a sample to pick in the SDK, but the SDK is realy evil to beginners... thx. and another question, i want to keep track of my 3d objects positions, now, after im putting the vertexes into a buffer, what im doing right now is just moving the object using the Translation matrix (i have a posX value and with it im moving the object trhough the matrix), is there a way to directly access the vertexes in the buffer and change them if there is, how thx. * i have a hamble request, please do ...Show All
Peter_vienna Dream Build Play - partner in crime
I'm still hard at work on a new game I'm working on, but it's more for fun than anything I would submit for a contest. But I really want to enter the dream, build, play contest too, I just don't think I'll have the time to do it all on my own. Does anyone out there want to partner up I'm no programming guru, but I've got a few skillz. I've been messing with XNA since beta 1, I got one (and a half) xna game(s) under my belt, and I'd say my biggest assets are creativity, thinking outside the box, analytical problem solving, writing, story, plot, characters, and high fives (not necessarily in that order) ...only reply if you plan on winning! I certai ...Show All
Rajesh batchu Draw Fonts into a Texture?
Hey all, First, thanks to those who created XNA...I'm one with lots of ideas, not a lot of time to get my head around the finer points of DirectX - this is for me. Can't wait to play this stuff on my 360. To the point -- I'm building a varient on Asteroids for my kid and want to put a score up onto the screen. I'm gathering from the docs I've read (and the stuff I've tried that doesn't appear to work) that there's no easy way to just "myFont.DrawText(myTexture,"Hi there!",100,100,Color.White)" and have it just work I assume that I'll have to fire up my PhotoProg, find some font I like, turn each of the numbers 0-9 into a .dds and fire them onto the screen as textures If that's the case, is anybody putting li ...Show All
Chris Holland Will XNA Game Studio Express support multiplayer?
Please, please tell me that XNA Game Studio Express will support multiplayer... Singleplayer games are fun, but multiplayer games are 10x as fun. You are right. I haven’t thought about this kind of multiplayer even if I had build such multiplayer games in the past. As written in the FAQ the initial release will not contain support for networking. Hi DT. Sorry for taking awhile to get back. -XNA GS Express may at some point in the future support some form of network access. There are a lot of thorny issues that we have to figure out so we can't make any commitments. However, I wouldn't say never :) -The first relesae of XNA GS Pro will support Xbox live ...Show All
Ronald L xbox 360 controller thumbsticks
hello, I'm trying to move a Sprite with my 360 controller thumbstick, the X directions are working but the Y directions go the wrong way. can someone help me here's my code: void UpdateBall() { GamePadState gamepadstatus = GamePad .GetState( PlayerIndex .One); if (gamepadstatus.IsConnected == true && gamepadstatus.PacketNumber != gamepadvorigestatus.PacketNumber) { if (gamepadstatus.Buttons.Back == ButtonState .Pressed) { this .Exit(); } if (gamepadstatus.ThumbSticks.Left.X > 0) { int thumbstickX1 = Convert .ToInt32(gamepadstatus.ThumbSticks.Left.X); ball.ballposition.X += thumbstickX1 * 4; } if (gamepadstatus.ThumbSticks.Left.X < 0) { int thumb ...Show All
Dracosveen Need to learn c# for xna!
Hello everyone, Just a quick question. I'm really excited about xna and running code on my 360. I'm currently working as a c++ programmer and I'd consider myself at an intermediate level, after finishing my degree and a year in industry. I'm currently teaching myself directX 9 and I want to get started on xna but unfortunately I have no knowledge of c#. I've extensive experience with java from college but I consider c++ to be my native language. Anyway to bring my slightly drink fueled rambling to an end, I've learned the only way to get to grips on a programming language is through small projects. In college we never fully implemented a windows GUI, they taught us swing on linux and I've played a bit with swt in eclipse. So for me it seem ...Show All
Tryin2Bgood XNA GSE Language restrictions
I've gone through the XNA GSE FAQ and I'm not sure I understand the decision in developing XNA GSE in a manner that doesn't allow it to integrate into Visual Studio languages other than the Express editions. Sure you can run C# Express alongside Standard, Pro and Team editions of Visual Studio, but I would suspect that a great many hobbyists (to which XNA GSE is targetted) have invested in at least Standard and even Pro editions. Won't these users be giving up extremely useful IDE features and coding tools because Express editions lack these features due to the nature of them being free products I honestly fail to see the logic in all this :) - Seef Seefer wrote: Thanks for the ...Show All
Mark Shvarts Tile Engine Tutorial - Part 2
We just posted part 2 of our Tile Engine Tutorial over at www.xnaresources.com ! This tutorial covers the following: - Updating the tile set handling to use a tile sets with transitions, etc.. - Adding smooth scrolling to the map engine - Adding a game screen overlay Here is a screenshot of the finished product: http://www.xnaresources.com/images/TileTutorial2.jpg Pop over and run through the tutorial: http://www.xnaresources.com Just finished going through the tutorial. Pretty useful! I'm learning quite a lot here. As a little exercise for myself, I tweaked it to smooth scroll by partial tiles rather than whole tiles - I actually found the code for this to be simpler than whole tile smooth scrolling, b ...Show All
Ben Levy Rotating a bounding box
I have a game with a bat of which you hit balls with. in terms of collision detection im looking at a bounding box. The bat is long and thin, and can be rotated, however there doesn't seem to be a way to rotate a bounding box. It would be very obvious if the bat was at 45 degrees but surrounding by a square bounding box. Is there any way to rotate the box, or is there a different collision detection method i can use If you are familiar with matrices and coordinate space transforms, then do the following: Transform the balls position (or trajectory) into the bat's coordinate space before performing the collision check. That way, you can still use the bat's axis aligned bounding box. The Xna Bounding ...Show All
McGeeky Rendering Question
first of all, I'm using d3d 9.0 C# 1.1 And now to the problem: I'm writing a little application in which i parse a dxf file (contains geomtry information) and render it. the application allows pan, tilt and zoom. big dxf files containes thousands and more entities. at the moment I'm rendering the entities to a texture and then I'm rendering the texture. the problem is when i render on a texture with a X8R8G8B8 format it acts like a bitmap - which means, when I'll zoom in the objects (for example lines) will become thicker. (I want them to stay at the same size). I saw that there's a format called VertexData but I couldn't create a texture with that format. I would like to render it staright to the device, but every cycle of ...Show All
Kamii47 Material Alpha
For testing purposes I try to create a simple transparency effect, but whatever I do it does not work... PresentParameters presentParams = new PresentParameters (); presentParams.Windowed = true ; presentParams.SwapEffect = SwapEffect .Discard; presentParams.EnableAutoDepthStencil = true ; presentParams.AutoDepthStencilFormat = DepthFormat .D16; presentParams.PresentationInterval = PresentInterval .Immediate; device = new Microsoft.DirectX.Direct3D. Device (0, Microsoft.DirectX.Direct3D. DeviceType .Hardware, this , CreateFlags .SoftwareVertexProcessing, presentParams); ... this .device.RenderState.ZBufferEnable = true ; this .device.RenderState.Lighting = true ; this .device.RenderState.Ambient = Color .From ...Show All
John.Doe The values used in the attempt to create the GraphicsDevice were invalid.
Is this because my graphic card does not support shader model 2 I didn't even know of this requirement till I saw it on the readme file. Time to change my geforce4 I got it to work. Add this line after the Graphics component is created: graphics.AllowMultiSampling = false ; Then in the WindowsGame_Starting function set graphics.AllowMultiSampling equal to false again. What type of card do you have We should be giving a better exception message than that (i.e. we check for lots of things and throw better exceptions but that one must have slipped through.) I'm getting the same error here at work..... card is an nVidia Quadro 2. lol.... not sur ...Show All
nglow Bug in texture content importer (alpha generation)
It appears that a texture will be made chroma-keyed, even if you don't select the chroma-keyed texture processor. When importing a pre-saved DDS from Photoshop, pure magenta color turns to black (which in DXT1 can mean alpha), even when using the plain "texture (mipmapped)" processor. Bug filed at: https://connect.microsoft.com/feedback/ViewFeedback.aspx FeedbackID=237899&SiteID=226 "...make the model use the texture that I specify, rather than its own!" Could you explain what you mean by this Where are you specifying the texture for the model Suppose I have Cube.x. Cube.x references Image.dds. The way I understand it works right now, if Image.dds and Cube.x are both in the same folder, just ...Show All
TOM_MUE DreamBuildPlay is up!!!
Now go register!! Actual contest details to come the week of Feb 5th ..jeez whoever designed the website should be shot for this oversight uphhh....they turned this piece of junk off. M$ please keep pro. More missing states... North Dakota, New Jersey, and Vermont are all missing... The site is live and yes we realize there are a few things that haven't quite propped properly. We've got people looking to get these fixed asap. To be clear, yes you will be able to register outside the US as this is a global competition. And yes, the missing states will be re-annexed shortly. Apologies for the wrinkles in the ro ...Show All
Alexnaldo Santos How to use View and Projection matrix?
Hi. I'm trying to draw a vertex buffer (using PositionColored vertex) but I can't see anything. So, reading about it on the web, I've found that I need to set two matrix: Projection and View. I've donet it! Take a look: // Create the vertex buffer private void OnVertexBufferCreate(object sender, EventArgs e) { VertexBuffer buffer = (VertexBuffer)sender; CustomVertex.PositionColored[] verts = new CustomVertex.PositionColored[3]; verts[0] = new CustomVertex.PositionColored(0.0f, 1.0f, 1.0f, Color.Aqua.ToArgb()); verts[1] = new CustomVertex.PositionColored(-1.0f, -1.0f, 1.0f, Color.Black.ToArgb()); verts[2] = new CustomVertex.PositionColored(1.0f, -1.0f, 1.0f, Color.Purple.ToArgb()); buffer.SetD ...Show All
