C# is a multiparadigm, managed, garbage-collected, object-oriented programming language created by Microsoft in conjunction with the .NET platform.

learn more… | top users | synonyms

0
votes
1answer
214 views

Sharp DX Identity Matrix, Matrix.Forward vector pointing at negative Z

I'm trying to take a steady grip on Sharp DX. Already done some work like translating, scaling and rotating objects. Now i have to calculate the rotation matrix using only direction vector and ...
0
votes
1answer
254 views

MonoGame Linux Mouse.SetPosition doesn't work!

Having a really weird issue, it seems that no matter what I do I cannot get the Mouse to lock to the center of the screen in MonoGame. I triple checked all the possible noob mistakes, and ...
0
votes
1answer
63 views

Farseer: RemoveBody is not working [closed]

I want to remove bodies after they touched the character(playerrect). But the bodies get not removed. I set a breakpoint in the following line but it doesn't get yellow: ...
1
vote
1answer
126 views

Farseer: How can I remove a body?

I have many sensors(coins) in each level and I want to remove the sensors(coins) when the player rectangle(Mario) touches them. I check in OnCollision if Mario touches a coin, if he touches it, it ...
-2
votes
1answer
211 views

Programmatically creating a 3d mesh in XNA

Surprise! Another question related to Minecraft. Anyways: Rather than drawing thousands of blocks each frame, I remember reading somewhere that Minecraft breaks the map into 16x16x256 chunks, and ...
2
votes
1answer
300 views

Game Development AI, NPC & Entities Definition using Scripting Languages

i am developing a Multiplayer(actually MMORPG) architecture for learning purpose. I do have some game developement background, but all my engines were very rigid and completly developed for the game ...
-1
votes
1answer
671 views

“Car” movement in 2D dimension [closed]

I am searching for a simple tutorial how to add arcade car physics for my game. Exactly same user units behaviour i found in next games: Tank Hero: Laser Wars Death Worm: Video: ...
-4
votes
2answers
472 views

2D Graphics in CMD in C#

So, almost every programmer used Doom as inspiration for new Projects, right? So Doom and other classic MS-DOS game were played on something like Command Prompt. How do you display images in Command ...
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
323 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 ...
3
votes
5answers
710 views

Can I write code from 2 computers at the same time? [closed]

So I know it might not be that related to game dev, but I'm now starting a project with friends and we want to code. Thing is, we are not living close, and when several programmers write different ...
0
votes
1answer
51 views

Farseer: Difficulties with ContactListener

How can I register the ContactListener in XNA? In the box2d manual is written: 9.4 Contact Listener ... At run-time you can create an instance of the listener and register it with ...
-2
votes
1answer
77 views

C# Stack<> Problem [closed]

I'm trying to change List<> to Stack<> however I'm having a hard time figuring out. A snippet of my code on where my issue occurs is: private Stack<Gem> gems = new ...
-1
votes
2answers
2k views

Move object to position using velocity [duplicate]

I'm trying to make a simple object move to a desired location using its velocity. But I'm having trouble with it over shooting its target. I have to use velocity, I can't simply lerp the position, ...
2
votes
1answer
511 views

How to blend biomes with procedural terrain

I'm working on a terrain generator. Through multiple noise functions, I'm able to create many kinds of terrain I like, but I'm having a bit of difficulty joining them together in a seamless fashion. ...
1
vote
0answers
80 views

How to gradually decrease opacity of model?

I have been searching for this matter for a long time and slowly I begin to think that this option is not available in XNA for Windows Phone. I am trying to get a 3D-Model to be drawn at 50% ...
0
votes
1answer
234 views

Isometric Map Rendering Incorrectly [closed]

I've currently been trying my hand at Isometric map rendering via the tutorial over at XNA resources; http://www.xnaresources.com/default.asp?page=Tutorial:TileEngineSeries:4 However, unfortuanely ...
1
vote
1answer
263 views

MonoGame Cross-Platform Conditional Compilation Symbols

What are the possible compiler directives for MonoGame? For example, XNA contained directives for WINDOWS, XBOX/XBOX360, and WINDOWS_PHONE. I've also seen DIRECTX and OPENGL, but when would you need ...
-1
votes
1answer
123 views

SpriteBatch memory leak

I have a strange problem with XNA 4. I'm constructing a SpriteBatch using this.spriteBatch = new SpriteBatch( GraphicsDevice );. This leads to a memory leak up to 600 MB memory consumption. This ...
-2
votes
3answers
2k views

What should I know to start in game development? [closed]

I know this is asked very often here and probably my question will get closed, but I am clueless in this direction. I want to start creating my own PC games. I know C++ and a bit of C#. I created a ...
2
votes
1answer
106 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 ...
4
votes
1answer
190 views

How do I make a tile passable in one direction only?

I want that my character can jump through some of the tiles, like Mario does in this video: http://www.youtube.com/watch?v=zIPYzbNrNhc In this video, Mario jumps up through orange platforms, but ...
0
votes
3answers
601 views

How do I move a sprite to the mouse position?

So, I'm trying to make my sprite walk to the X-coordinate of my mouse click. This is my code: currentMouseState = Mouse.GetState(); MouseState mouseState = Mouse.GetState(); ...
-3
votes
1answer
276 views

Farseer: are you missing a using directive or an assembly reference?

I want to create a polygon in Farseer. I found an example in the documentation but it's not working because I get this error message: The type or namespace name 'Vertices' could not be found (are you ...
0
votes
1answer
102 views

Farseer: Ball is not getting slower

The ball is not getting slower when it rolls over a straight platform. I added friction but that changed nothing, the ball still gets not slower. I want that the ball gets slower and slower and stops ...
0
votes
1answer
181 views

Farseer: Ball is not bouncing realistically

I created a ball that is rolling over platforms. When it falls from one platform to another, it should bounce just like in real life, but the ball keeps bouncing constantly and I don't know how to ...
1
vote
2answers
257 views

XNA spritebatch.Draw: Which part gets colored by the color parameter?

Which part gets colored and how can I control it? I have a rounded block and my goal is to have the center filled with a certain color chosen by that parameter. Here's the picture: ...
3
votes
3answers
502 views

MMOFPS Choosing protocol for high-traffic network (UDP or TCP)? [closed]

my question about the player position sender protocol. In this article, he says "Never use TCP for networking a multiplayer game". Ok but UDP datas are not ordered. In this case, if somebody walking, ...
1
vote
2answers
143 views

MMOFPS Player Positions [closed]

I'm working on a MMO game project. I have a question about MMOFPS game architecture. (I have basic network knowladge) (MMOFPS) I want to send player position to other players(clients) and other ...
1
vote
1answer
55 views

How can I access the translation part of a skinned Model object's bone transformation?

I have an animated Model, which I process with the SkinnedEffectProcessor. How I can access translations of that model during animation? It's always a BoneTransform I am working with, but I'd like to ...
1
vote
1answer
824 views

Does XNA have a built-in GUI library?

Does such a thing exist or do I have to code one? My project needs textboxes, buttons, input capture, timings for "press and hold keys" and so on. These are quite standard for a GUI library but hard ...
0
votes
0answers
30 views

Farseer physics engine: The name 'ConvertUnits' does not exist in the current context [duplicate]

http://digitalerr0r.wordpress.com/2012/03/11/farseer-physics-in-xna-4-0-for-windows-phone-1/ I tried this Farseer tutorial but I always get that error message in the following lines: ...
0
votes
2answers
484 views

C# XNA AABB vs AABB collision resolution, AABBs ghost through each other

I've been learning a bit of collision resolution through a tutorial here and I can't seem to get the AABBvsAABB resolution working, I have CirclevsCircle and AABBvsCircle resolution working with the ...
-4
votes
1answer
137 views

How to use a physics engine for collision detection? [closed]

I want to use Box2D.XNA or Farseer for collision detection in my 2D game, but I don't know how to start. I added Box2D.XNA to my solution, but I don't know how to create rectangles, circles or ...
4
votes
3answers
227 views

XNA Collision is quircky/wobbly, how to improve?

I am sorry if this was already answered but I couldn't find the answer. So I am doing a tile based platformer and when I was making collision I had quiet a struggle I looked here and googled for ...
1
vote
2answers
688 views

Winform + XNA (Microsoft Example) - Issues with Drawing Texture2D

Before I get started I would just like to say that I have been using the Microsoft Winform + Xna examples found here: WinForms Series 1: Graphics Device I think I somewhat understand how its working ...
-3
votes
2answers
522 views

How to preload a vast amount of models?

This is more a theoretical question, during runtime, my game runs smooth without any hickups. But as standard game-objects, my game contains collectibles such as coins (which are rotating Models). ...
-1
votes
1answer
405 views

How to add a timer - Visual Studio, XNA (C#)

I'm wanting to add a timer in an XNA game using C#. The ultimate goal is to increment a score in a game every second by 10 points. As of now the score stays at zero. Watching YouTube videos is proving ...
0
votes
3answers
458 views

Why does this game loop stop my process from responding?

I implemented a fixed time step loop for my C# game. All it does at the moment is make a square bounce around the screen. The problem I'm having is that when I execute the program, I can't close it ...
1
vote
0answers
125 views

How to integrate Javascript into C# and run scriptcode step by step

We are currently working on a Pokemon MMO trying to figure out how to implement an asynchronous scripting language the best. We don't want to work with threads or tasks, but the goal was to wait for ...
0
votes
1answer
290 views

Mouse Aiming Causing Rotation Jitter

When our game's ships move around, mouse aiming causes them to shake around a lot. The body being aimed is moved kinematically. I think we've narrowed it down to this block of mouse tracking code. ...
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 ...
1
vote
1answer
138 views

Rectangle collision is not working correctly [closed]

I have difficulties with the rectangle collision. My character can go through the right side and through the bottom of each platform rectangle. I guess their is a mathematical problem with the ...
0
votes
1answer
233 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 ...
-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
1answer
279 views

Unity3D custom camera matrix breaking shadows/lights in deferred rendering

EDIT 1: So it seems this is a common issue with Unity, and it comes from a bug in which custom camera matrices break deferred lighting and shadows. This topic right here talks about it a bit, but the ...
-1
votes
1answer
128 views

Why is my model flickering when translating

I have several models here. When they stand still during gameTime, there's no flickering. But as soon as I move them across the x-axis, they flicker on some places. protected override void ...
2
votes
1answer
1k views

Unity3D How too write to the back buffer AFTER the final pass of deferred rendering

I've been using this script and shader from the wiki, and they work wonders; my only problem is using them in deferred rendering. Now, the way this shader works is by writing to the depth buffer to ...
3
votes
2answers
728 views

Playing different particle effects in Unity on the same ParticleSystem

The question really sums it up: What is the best way to use one particle system for playing different particle effects? The scenario: GameObject is picked up and it starts playing a simple indicator ...
2
votes
1answer
136 views

How can I draw an Xbox Live avatar?

I want to replace the main character of my 2D game by an Xbox avatar. How can I do that? How can I add an avatar to my project? How can I draw an avatar? For example, I draw my main character like ...