XNA is a game framework by Microsoft that allows deployment for Xbox Live Indie Games as well as Windows Phone 7.

learn more… | top users | synonyms

-1
votes
0answers
12 views

In XNA, how do I make a sprite move towards another?

I am making a shoot-em-up with a player-controlled sprite with a gun: I have most of the game working, but I have gotten to the point where I need to load in the enemy characters and make them move ...
-3
votes
0answers
21 views

Going to be taking MTA: Game Development Fundamentals (98-374)

I'm going to be taking the 98-374 MTA exam in the coming weeks and I need some ideas on what to focus in and hone my skills on. Any ideas, suggestions, or comments? Please let me know! Thanks, ...
1
vote
0answers
21 views

XNA arcball camera steering issue

I have an arcball set up to follow my model in XNA. It rotates around the target correctly when holding in the left mouse button and moving the mouse. It zooms in and our correctly with the mouse ...
4
votes
1answer
48 views

Torus World Collision Dection

I am looking for a collision detection solution for use when 2d screen wrapping. Specifically, when the image is split between the right and left side I can only detect a collision for a limited ...
0
votes
0answers
31 views

XNA C# - Unhandled exception of type 'System.NullReferenceException' [on hold]

I'm making my first game (as part of my college course) and I have to make it in XNA using C#. My issue is that I'm trying to make a main menu, and after following a tutorial pretty much to the ...
0
votes
1answer
34 views

Choppy movement

So, I'm trying to write some code in C# XNA to make an enemy move in a random direction for 0.5 seconds, then switch direction and once again move for 0.5 seconds. However the problem I've discovered ...
1
vote
1answer
51 views

Problem, why the mouse cursor position is totally wrong, after resizing the window?

I come here, because i'm trying to add some "menu" interface in my small XNA Game . I found on internet a nice library adviced by many devellopers. Till now everythink is ok, the problem is my C# code ...
1
vote
0answers
20 views

Supported Orientation, Monogame, Windows Phone 8

I am developing a game in which I need to rotate the screen on Landscape mode or Portrait, and lock it that way. In Monogame, targeting Windows Phone 8.1 adding this code: ...
-1
votes
0answers
14 views

C# Xna , projectiles moving towards cursor problem [closed]

Hey i tried to make a program that evolves a character shooting projectiles toward the mouse cursor but i ran into a problem that i don't know how to fix. My character rotates fine towards the cursor ...
1
vote
0answers
24 views

Specific bone not present in the skeleton XNA

I have created a human mesh, bone structure, and animation rig in 3ds max for an XNA game I am developing for school. I am currently having a problem with one specific bone upon build in Visual ...
0
votes
0answers
15 views

XNA Texture mapping on model

I have a cube as my model and want to map a texture on every side of the cube. I have been searching for a while and most answers suggest using 3D max or using VertexPositionTextures. I am not ...
0
votes
1answer
37 views

What is the difference between a Viewport and a Scissor Rectangle?

In XNA, what is the difference between a Viewport and a Scissor Rectangle, and when should I use each one? It looks like viewport clipping is applied to the geometry before the rasterization state, ...
1
vote
0answers
11 views

XNA maximum VertexBuffer size exception

I am trying to build content(a text file contains list of triangles vertices) for an XNA application through a custom pipeline importer. It works ok. But when number of triangles gets near 1m(in this ...
1
vote
1answer
41 views

Find distance from Vector2 to nearest point in Rectangle

I'm setting up collision detection and I have Walls which store their positions as rectangles. I need to figure out the distance from a Vector2 to the nearest side of a rectangle. If this was two ...
2
votes
0answers
49 views

Read custom content in MONO-GAME in a cross-platform way

using Mono-Game, i have some custom content files in some binary format (not .xnb) in run-time i need to read the content of those files. i prefer to get a stream, but if something will give me a ...
0
votes
0answers
56 views

Texture Editing with Multhi-Threading

So I have this giant Texture2D(4096 * 4096, don't ask why) and all its data stored in an array of Colors. When I hit left MouseButton I create a blue 64 by 64 square at the cursors position using the ...
2
votes
1answer
65 views

In XNA, how do I access a model's dimensions with code?

I'm trying to rotate a model around some axes, but this rotates it around the world origin. I understand that I need to translate the object relative to its own size before rotating it, but I don't ...
0
votes
0answers
64 views

Smooth player movement in a tile map based engine

The character is moving too much fast, it teleports! Note that a tile is 80x80. Each cell has 4 bools to say if you can go up, down, right, left. Am I doing something wrong with Lerp? This is the ...
0
votes
1answer
98 views

Actually Implementing “C# as a scripting Language” in XNA

Following an example from this thread, I've made an application that dynamically loads in C# "scripts" (actually, plugins) into my game -- but I've hit a snag: how do I reference the assemblies for ...
0
votes
0answers
45 views

XNA 4.0 - Using premade .xnb font files

Basically, for our college project, we need to use a font in xna. The only problem is that we are not allowed to install it due to admin rights. Is it possible to use and load the .xnb file that gets ...
1
vote
1answer
30 views

Model texturing not seamless at certain zooms? (C# XNA)

I found a very odd glitch with my game this morning. XNA doesn't render certain textured models properly, while other models are completely unaffected. And it's not even like my models are made ...
3
votes
1answer
92 views

Is creating a blend state like this possible?

I'm wanting to create a custom blend state that is similar to XNA's BlendState.Additive, but slightly different. I'm wanting something like the 'custom' output below: Is something like this ...
0
votes
1answer
44 views

XNA - Darkening background and drawing something on top

In a game a group of friends and I are working on using XNA, we wanted to create an effect where we could darken the screen and draw something else on top of the darkened portion. For example, we have ...
0
votes
0answers
52 views

Unity or XNA allowing modifications from Steam Workshop

I'm about to start a sandbox project game for Steam, so modifications are important - before I begin, how do I allow people to create mods for the game through the Steam Workshop? I've looked but I've ...
0
votes
1answer
118 views

XNA game structure question

I see to be running into a problem here. I know it's easier to show code samples so here you go. This is my main game class namespace WindowsGame4 { public enum MoveDirection { Left, Right, Up, ...
1
vote
1answer
40 views

XNA/MonoGame RenderTargets not working

I'm having a problem with drawing 2 RenderTargets to the screen. using System; using System.Collections.Generic; using System.Linq; using System.Text; using Microsoft.Xna.Framework; using ...
1
vote
2answers
79 views

How to draw to a surface, then draw that surface to the screen

i have a 2D MonoGame Game (using DirectX), that was originally an XNA game. It involves prerendered shadows (they are Texture2Ds drawn with SpriteBatch.draw). Right now the shadows are being drawn ...
0
votes
0answers
22 views

How can I change the gear of my 2D character? [duplicate]

Is it possible to change the clothes of a 2D character(it's a 2D Windows Phone game) without creating new animations for that character? I want that the player can change the clothes of the character, ...
0
votes
1answer
39 views

XNA Rendering Blocks

I am currently building a little game in XNA and found something strange. I want to draw many blocks next to another (1x1x1 with a texture on the side) So what happens when I do it this lines ...
3
votes
3answers
199 views

How to achieve high Level of Detail on 3D models

I'm developing a 3D space-based game which allows free movement in all directions and features planets. Currently I am using the Visual Studio content manager to import models (spheres) with 2D ...
0
votes
1answer
51 views

how to stop camera at the end of world map when zoomed in

Im building a tile-based game, and Im trying to implement zooming in on the center of the screen. My problem is, when I get to the edge of the map and im zoomed in, Im noticing that my camera doesn't ...
0
votes
2answers
105 views

Draw many flashlights' focused lights' “circles” on a voxel engine map (and other objects)

So, I've been searching the internet for a while and I still didn't understand how to create a flashlight's "circle" in front of the camera over other objects. I found the following links: using ...
0
votes
1answer
26 views

XNA C# Texture Atlases

Fairly new to XNA and not an expert on C# either. So I was following a tutorial, specifically this one http://rbwhitaker.wikidot.com/texture-atlases-1, and there is a bit of code I am unfamiliar with. ...
0
votes
1answer
36 views

XNA Starting a parallel Thread during a draw loop is slower than doing the same task in the main thread in update loop

I'm using XNA and all of my drawing is done in the main thread. I am CPU-bound and I thought I could gain performance by moving some non-update logic (like animation update) from the update loop into ...
1
vote
1answer
39 views

Bug in XNA Developer function CalculateEigenVector() from the file “xnacollision.cpp”?

I am trying to decipher the content of the Microsoft XNA Developer source file "xnacollision.cpp" and I've found a function that calculates one of the three eigenvectors of a homogeneous system of ...
1
vote
1answer
114 views

Pixel Shaders To Create Predator Effect

I am learning shaders, and I figured I would try to use them to create sort of a predator effect. I got to the point where I rendered my level to a rendertarget and passed that to the shader file, ...
1
vote
1answer
92 views

FPS issue between computers results in slow down of animations and moving

I have been developing my game on two computers. I recently got a new computer and have noticed an issue that seems to be happening in my game. When computer 1 runs the game at 60 FPS everything ...
0
votes
1answer
57 views

What is the recommended way to store game entity data? [closed]

The following is specific to my problem, but I believe the principles can be applied to any game. I am currently working on a 3D game which will have many different types of spaceships. The physics ...
0
votes
3answers
98 views

Simple way to shoot bullets from a ship at angles for shoot em up

Just like the title says. I'm working on a shoot em up for a personal project, and I can't seem to get this to work. I don't have any code for it, but I do have the code to make my ship shoot, but ...
1
vote
1answer
85 views

XNA game publishing help with incompatibilities via content built at runtime

MY XNA game is finally complete, but I'm having difficulty getting it to run on other Windows computers. I've read similar other stackexchange topics here, here, and here, but I'm still gonna need ...
1
vote
1answer
77 views

Overlapping Vertex in DynamicVertexBuffer draw priority?

I am creating a voxel game, and I have recently run into an issue. My world is drawn by a DynamicVertexBuffer, which just consists of vertices for the blocks themselves. On top of that, I switch ...
0
votes
2answers
98 views

How to rotate (YAW) aircraft in XNA?

I'm developing a flight simulator based on Riemer's Blog tutorial (XNA C#). To control the aircraft, I use the following code: Quaternion additionalRotation = Quaternion.Identity; additionalRotation ...
0
votes
1answer
49 views

xna - Render background and multiple sprites to a single texture

I currently creating a game and I am trying to render my background and a sprite to a texture. Currently I have the background being rendered to a texture. But I am needing to render both my ...
1
vote
2answers
31 views

Flushing KeyboardState

I'm using a simple InputManager class for an XNA game with keyboardState and lastKeyboardState that gets updated and has KeyDown/KeyReleased/KeyPressed functions... but ran into a small problem: I ...
5
votes
1answer
323 views

How can I remove Magic Pink from an image at runtime using GraphicsDevice?

In XNA 4.0, I want to load all my textures at runtime, which means I will not be able to take advantage of the content processor. (This is fine because it would allow people to change graphics and ...
0
votes
1answer
30 views

Can I generate collision boxes from a model file with BepuPhysics and XNA?

I am currently developing a game using BepuPhysics in XNA 4.0, and I am trying to reasonably match the in game collision Entities with the Model they are associated with. My current workflow involves ...
0
votes
1answer
92 views

Fast mesh collision 3D (C# XNA)

I'm trying to write a simple program where a 3D landscape can be walked about with a basic camera. However, I've found it very difficult to do even simple collisions with my terrain. I'm wondering if ...
2
votes
3answers
178 views

MonoGame 3.3 Font loading

Is there any way to have fonts in game without making a separate Content Project and adding a .spritefont file in the new 3.3 Monogame? You can now load other resources directly from the Content ...
0
votes
2answers
46 views

MonoGame Point filtering movement appears Choppy/Jerky

When you move a sprite that is drawn using point filtering with a decimal number, example : 0.1 pixel or 100 * deltaTime (1.6) the movement appear choppy/jerky because it jumps from pixel to pixel. ...
0
votes
0answers
111 views

How to do animation of XNA model integrated with WPF?

Back with another weird question I managed to find a XNA Model viewer integrated with WPF which is this one https://xnamodelviewer.codeplex.com/ So I had a custom processor which sort of run multiple ...