Implementation of Microsoft's XNA 4 APIS for Android, iOS, MacOS and Linux.

learn more… | top users | synonyms

6
votes
4answers
2k views

The right way to add images to Monogame/Windows

I'm starting out with MonoGame. For now, I'm only targeting Windows (desktop -- not Windows 8 specifically). I've used a couple of XNA products in the past (raw XNA, FlatRedBall, SilverSprite), so I ...
1
vote
1answer
130 views

How can I use a camera matrix with different resolutions?

I created a little jump'n'run game. The character(Mario) is always the center of the viewport. The game is running correctly if I use the resolution 800x480 pixel. But when I use another ...
1
vote
3answers
248 views

Code to generate a color gradient within a texture using a diagonal line

I want to generate a color gradient between two colors from x1,y1 to x2,y2. I'm unsure how to do this though. I can use Color.Lerp to get all of the color steps, but the problem is that I don't ...
10
votes
2answers
3k views

XNA 2d Camera Scrolling - why use matrix transform?

I am making a test game where I want the level to be constantly scrolling. To create this effect I have established a camera class which simply stores a vector2 position and an enum direction. It also ...
7
votes
7answers
11k views

How to generate Spritefonts for monogame

I just want to render some text to the screen using: monogame 3.0 MS Visual Studio 2010 C# Express In XNA, you were able to add fonts to the content pipeline quite easily. But this doesn't seem to ...
1
vote
1answer
166 views

How do I ensure that my 2D side-scroller camera stays within the world bounds?

I have tried implementing a basic 2D sidescroller camera in XNA, but I don't want it to be able to scroll past the edges of my tile map! I tried to fix it, but when I get the left side working, the ...
2
votes
1answer
795 views

Has anyone got the Krypton Lighting Engine working in MonoGame for Windows 8?

I've converted the core of the Krypton Lighting Engine so that it's compatible with Windows 8. The trouble I'm having when actually using it is that it can't load the KryptonEffect.xnb file. I'm ...
3
votes
1answer
73 views

Why is my cursor not working if I add a scaling matrix?

After moving the camera to any direction, my cursor isn't getting drawn on the correct position. For example: I move my camera to the right, after that I click on the screen, but the cursor isn't ...
2
votes
2answers
111 views

Properly rendering transparent areas of textures

I'm rendering a tree that contains branch meshes with partially transparent textures. If I render it with AlphaTestEffect and set the ReferenceAlpha to something low, I'll get this. I want to ...
1
vote
1answer
171 views

Bounding Box in Monogame for mouse picking

Hello guys so I'm implementing this mouse manager to be able to pick up objects. My application uses mainly textured quads in 3d space. I'm using bounding boxes in monogame to do so, however my ...
1
vote
1answer
474 views

MonoGame - when/how to save data

I am making a simple 2d game for WP in monogame/xna and am at a point where I want to save data. I have created a method to serialize the data (index, counter and percentage counter) to an isolated ...
1
vote
1answer
283 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 ...
0
votes
1answer
141 views

How can I scroll my tile maps?

I've been trying to understand how I can use matrix to implement a smooth tile scrolling system but I fail miserably. So I have a pretty big world stored in a multi-dimensional array which is ...
0
votes
1answer
107 views

Bounding Box in Monogame for mouse picking - Ray perspective

My mouse ray is screwing up precision. I don't really know how to fix it, maybe you guys can help. problem : (5.6mg gif) https://www.dropbox.com/s/v0z67afso88hsd1/perspective_ray.gif how i create ...
0
votes
1answer
196 views

Alpha From PNGs Butchered

I have a pretty vanilla Monogame game. I'm using PNG for all my sprites (made in Photoshop). I noticed that XNA is butchering the aliasing; no matter what I do, my graphics appear jaggedy. Below is a ...
-1
votes
1answer
141 views

Animation: mid-state

At the moment I have a simple static texture. Now I want to animate my sprite. The texture is a simple human. When the user press the enter button, the human gets into state2. This is the standart ...