XNA Game Studio 4.0 is a programming environment that allows you to use Visual Studio to create games for Windows Phone, the Xbox 360 console, and Windows-based computers.

learn more… | top users | synonyms (1)

2
votes
3answers
160 views

Should Draw method calculate the element's screen location?

Should Update take care of calculating the drawing position of element or should it be done exlusively in Draw method? If I calculate the drawing position of element in Update and then store it as ...
1
vote
0answers
104 views

DepthStencilState System.ObjectDisposedException [closed]

I developed a Windows Phone 7 & 8 game and released it already. Having integrated BugSense, I received a handful of errors mainly from specific versions of Windows Phone 8 OS (mainly ...
2
votes
0answers
293 views

XNA 4.0 Pixel Shader 3.0 Exact Texture Lookup/Sample Issue

I am stuck on trying to solve this problem. I originally had some shaders written that worked for XNA 3.1, but after converting to XNA 4.0 they would no longer compile due to instruction counts, flow ...
2
votes
2answers
365 views

How can I actually understand Instanced Geometry Rendering - so that I can implement it the way I need it

I'm stuck trying to implement instanced mesh rendering in my project. Particularly because I am failing to understand how certain components actually function - and how the drawing routine is actually ...
2
votes
1answer
223 views

XNA Framework Reach profile does not support separate alpha blend

Yesterday I released my app 'Pic Words' to the windows phone store. It is an Silverlight/XNA app that runs on Windows Phone 7.1 & 8. I have BugSense incorporated into my app. Today I started ...
3
votes
1answer
135 views

Smoothing the scrolling path in 2D

I have the following problem: In a 2D game the screen can scroll in any of the 4 directions. Basically, the center of the screen during scrolling moves from (x1,y1) to (x2, y2) whereby (x1,y1) is the ...
7
votes
3answers
559 views

How do I target a tank turret with an offset barrel?

I have a tank model consisting of multiple parts, a body, a turret and the barrel of the gun. The turret is offset from the body origin and can rotate around the Y axis(up). The barrel is connected to ...
4
votes
1answer
211 views

Creating rectangles from the inner part of a texture2D

Ok, this may be hard to understand, but I'll do my best. You will see that the first image is a normal mario, and the other is the result I am looking for. I'm trying to find a way to extract ...
4
votes
2answers
271 views

Refractive blur in XNA?

I'm writing a 2D hack-and-slash game using XNA. I really want to implement the blur-like, refractive effect of a sword or such moving really quickly, seen in such games as Dust: An Elysian Tail and ...
0
votes
1answer
110 views

Resizing a parallax background (bug)

I'm attempting my first 2D vertical scroller and can't seem to get the background size to work. For some reason, it stays small. I think in the beginning of the parallax scrolling class, I was told to ...
10
votes
1answer
403 views

How to know if the player is signed in?

I was wondering if there's any way to know if the "player" is signed in or not? Something like this: if (GamePad.GetState(PlayerIndex.Two).IsConnected && !Gamer.PlayerTwo.IsSignedIn) So ...
2
votes
1answer
203 views

XNA matrix order problem

I want a matrix that scales first and then rotates. I tried the code below, but it didn't work. zRotation, yRotation and xRotation are rotations that shouldn't be affected by the origin. allrot should ...
4
votes
2answers
157 views

What's involved in resetting the graphics device?

I'm playing with XNA 4.0, VS2010. I've created a window (not maximized) and drawn some sprites. All is good until I resize the window, after which the sprites stop displaying or only partially ...
0
votes
0answers
59 views

Certain grid lines not rendering as expected

I am drawing a simple quad (a triangle strip with 4 vertices) as the floor and then drawing an 8x8 grid over top (a collection of vertex pairs for a line list). The vertical grid lines work fine ...
0
votes
1answer
53 views

stretch images when window is re-sized in XNA

Is there a way to re-size all the images inside the view port in a XNA project. At the moment when I re-size the view port the background stays at the same size of the image when I want it to re-size, ...
4
votes
3answers
3k views

2D XNA Tile Based Lighting. Ideas and Methods [closed]

I am currently working on developing a 2D tile based game, similar to the game 'Terraria'. We have the base tile and chunk engine working and are now looking to implement lighting. Instead of the tile ...
0
votes
1answer
424 views

Windows Phone XAML and XNA Apps with Game Components

I am using the Windows Phone Template "Windows Phone XAML and XNA Apps" and targeting Windows Phone 7/8. Most examples show your game inheriting from Microsoft.Xna.Framework.Game and then adding ...
3
votes
0answers
159 views

ways to program glitch style effects [closed]

Most tutorials for generating glitch art usually has to do with some form of manipulation of the compression of files. Should my goal instead to replicate the look of these glitches in shaders or is ...
-11
votes
1answer
219 views

extremely frustrating yet noob question [closed]

This is incredibly embarrassing but.. I musta hit a key or something but whenever i go to edit a line of code i have, i can't just add extra code in.. it always writes over the top of my code and ...
7
votes
1answer
738 views

Implementing water effects (splashes) into XNA 4.0 game [closed]

I am creating a 2D XNA game and came across a tutorial on adding water effects (splashes) to an XNA game but after implementing it into my game I can't get it to scale down. Currently it takes up the ...
1
vote
1answer
157 views

How to grab textures from a texture atlas to be applied to 3d objects

Fairly basic question, but I'm having trouble on finding information on this sort of thing for beginners. I'm just trying to make cubes with different textures on the sides as a starting point. I have ...
1
vote
1answer
2k views

What is the status of Monogame now that XNA has been discontinued?

XNA has officially been discontinued, with support no longer being offered by Microsoft. Does this mean that Monogame has died also? I see that the site still says it is based upon XNA 4. What is the ...
-4
votes
1answer
416 views

XNA PC vs Monogame Online Multiplayer [closed]

I've got a mostly working PC game in XNA 4, and am looking to make it networked. From the documentation it seems that I can use XNA Networking through GFWL to do LAN sessions, but not online sessions ...
6
votes
1answer
594 views

Do I need to rewrite my HLSL shaders when porting from XNA to MonoGame?

I'm looking at porting an XNA project I have to monogame, but I have a fair number of HLSL shaders. It seems that Monogame for PC uses OpenGL as the rendering backend, and I'd rather not have to ...
0
votes
1answer
100 views

XNA 4.0 thick triangle strip to fix aliasing issues upon rotation

My triangle strip based lines are disappearing intermittently when I rotate my camera around the X axis. I was advised that this is due to aliasing issues and that "At a certain angle when its edge ...
1
vote
1answer
167 views

How to calculate the Screen Position of a bounding sphere/box?

Synopsis: What I have is an object rendered on the screen. I need to calculate the top-left / bottom-right of it's location on the screen in Screen Coordinates. Explanation: The object is ...
1
vote
3answers
2k views

How to create / draw clickable object (such as Button in WinForm) in XNA WP8?

I am developing a 2D (No 3D in every aspect) Windows Phone 8 turn based tactical games for my college project. I use Monogame. I want to draw an object similar to Button in windows form, that if the ...
0
votes
2answers
2k views

Load SpriteFont in XNA

I'm planning on my game using multiple backgrounds so I'm trying to use spritefonts to draw the text. Every time I load my spritefont I get a error. Line1 = content.Load<SpriteFont>("Courier ...
2
votes
1answer
509 views

Collision avoidance (AI)

Now my 3D model has complete AI behaviours, but my model has no collision avoidance while he is moving towards the player! Because of this, he gets stuck in front of 3D blocks sometimes. I think the ...
3
votes
1answer
99 views

center point of a text?

i'm drawing a text using a spritefont and the draw.string function of the spritebatch object. in some point, i need to augment the size of the text, so i use a variable to scale it. all this is ...
0
votes
1answer
72 views

International Font in XNA?

I'd like to know are there some international fonts? I mean a font for all European languages including Russia. The question is about XNA fonts.
1
vote
1answer
253 views

Damage indicator screen overlay

I want to make something already done by a lot of games , which is when I am taking so much hits from enemy red screen drawn like the following , using XNA 4.0: after it's drawn and I am still alive ...
0
votes
2answers
74 views

Can't show an object in a tapped coordinate

So hi, I have a problem. I want to show an object (Texture2D) in an area tapped by user. This is my fields : List<Texture2D> list = new List<Texture2D>(); List<Vector2> list2 = new ...
1
vote
1answer
365 views

How do I convert my XNA game to Android without using MonoGame?

I want to convert my XNA Game to Android, but I don't want to use MonoGame or ExEn. How can I do this?
0
votes
1answer
89 views

My Sprite Rectangle moves, but my sprite doesn't

Here's the issue, When I build, everything loads fine, everything works, but then, when you enter the game, the sprite is there. However, The sprite does not move, the sprite RECTANGLE does. Meaning ...
0
votes
3answers
327 views

Trying to get enemy sprites to move on C#

In my XNA game, I'm have the enemy sprites loaded and in the game screen. However, I put in the code to update their position in the Update method of the main class. The objective is to get the ...
1
vote
1answer
103 views

Where to put input detector?

So below is the usual XNA Game Component override method. If I want to add a touch input detector (lets say, I want to draw a rectangle under touched screen area), where do I put it and how? Googled ...
0
votes
2answers
257 views

XNA 4.0 Plane size

Possibly a dumb question, but do planes stretch on to infinity? I can't define a spanning area for it, and would have to do some sort of check for collisions like if(x intersects BoundingBox and ...
2
votes
1answer
107 views

XNA Scale and Render Targets

I'm working on a top down Strategy/RPG/Tower Defense XNA Game for Windows, and I'm running into an issue while scaling. My display mode is 1680 X 1050, and that is what I'm setting the ...
0
votes
1answer
168 views

XNA 4 Content Pipeline dependency

I tried to create something to parse XML with, which needs the inclusion of the Microsoft.Xna.Framework.Content.Pipeline; reference. This was fine and all, but as soon as I tried to debug, I got the ...
2
votes
1answer
296 views

Include a custom font when publishing in Visual Studio XNA

I have a custom font called "Gold Box Games" that I want to use in a game I'm making. I have the font installed on my computer and it works just fine in the program when I run it in test. However, ...
1
vote
0answers
23 views

Transparent RednerTarget2D afrer blending

How to get transparent bacground in RenderTarget2D after alpha blending? I use Color.Transparent to clear the render target, but I get black color after blending where alpha is 255 even that there is ...
2
votes
0answers
159 views

Problems loading Hilva tutorials [closed]

I'm a newcomer to XNA, and I'm evaluating some libraries. The Hilva Graphics Engine looks interesting, and I'm trying to run their tutorials. However, all of them give me errors. For example, if I ...
0
votes
1answer
236 views

How to prevent the player from clicking too fast [closed]

I'm having trouble with some bullets in my game, the M1911, which is supposed to be semi-auto is only capable of shooting one projectile per mouse click (trying to learn how to do multiple ones at ...
0
votes
2answers
164 views

How to create Button/Switch-Like Tile where you can step on it and change its value?

If the player steps on a Button-Tile when its true, it becomes false. If the player steps on a Button-Tile when it is false, it becomes true. The problem is, when the player stands on (intersects) ...
-1
votes
2answers
134 views

Trying to reduce health by a certain value once XNA [closed]

I've got a bullet and collision data for the bullet, when the bullet collides, it's supposed to cut an integer off of the max health for the object. Basically heres what I want: Object is shot, ...
2
votes
3answers
651 views

MonoGame and normal windowed desktop application

I am trying to move all my XNA projects to Monogame. But in project templates I found only XAML and horrible metro application template. Is MonoGame support creating application in good old windowed ...
0
votes
1answer
136 views

Why spritebatch.Draw shows blank output? [closed]

In my code below, I think it's correctly done. But idk, the image called by _bg is does not shown up. The screen only show White. Weirdly, there is 0 error message when I run it. (The RenderTarget2D ...
0
votes
1answer
126 views

XNA Camera Positioning All Wrong

I've been working in 3DSMax for years now and decided to give XNA 4.0 a try. I've got the majority of it working, however the camera is being a pain to me and I can't discern what's gone wrong. I ...
2
votes
2answers
328 views

Applying Angular Acceleration in a Basic Physics Model

I'm attempting to use a basic physics system to create an arcade flight model. So far I have managed to get the aircraft moving forward, apply gravity, etc. However, after trying to implement torque I ...