Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 27 Dec 2012
Offline Last Active Mar 02 2013 04:48 PM

Topics I've Started

[XNA] 2D - Creating a Weapon Slash, Swipe, Swoosh, Trailing Effect with Shaders?

19 January 2013 - 02:31 AM

I wasn't sure where to start this thread, in the game programming section or XNA.  If it is in the wrong area, feel free to move it, and my apologies.


I would like to add a trailing effect to a sword in a 2D game. I've seen this same effect done in quite a few games and I thought there would be information for it plastered all over the place, but I couldn't find much other than 3D examples and Texture2D effects.


The effect that I would like looks almost as if the area behind the sword is distorted and warping the general area around it.

Does anyone know of a tutorial, example, or book on how to approach this for a 2D sprite?

I am completely new to shaders, but I would love to have this effect in my game.

[XNA] Dynamically Assign a Data Type ?

13 January 2013 - 01:51 AM

I am trying to brush up on my C# / XNA and I cannot figure out how to assign a data type at runtime.

I want to refer to all characters by creating a new Character.cs

Then inside of the Character.cs I instantiate a character type and choose a sub-.cs


Here is a representation of what I am used to doing in AS3:


public Character Char = new Character();
CharType(Char, "Ninja");

public void CharType(Character Char, String chartype)
  if(chartype == "Ninja")
     Char.GameChar = new Ninja();
  else if(chartype == "Soldier")
     Char.GameChar = new Soldier();



var GameChar;

Is this possible in XNA / C#?

To be more clear, I am having trouble have the "var GameChar" in the Character.cs.  I cannot find a way to program the variable into the class without first assigning a data type to it.  I tried using an 'Object' and 'dynamic' but they wouldn't allow me to access variables within the GameChar variable.


If not, can anyone give me some pointers?

What language should I learn next?

27 December 2012 - 03:43 PM

Hello GameDev!


I have been learning and fine-tuning the way I program games for some time now in Actionscript 3 and I feel that I have hit the limits of what the language can do for me in terms of the types of games I can create with it. (AIR doesn't even have joystick support tongue.png)


I have an Associates degree in programming, a Bachelors in game development and I know (at least) the basics of a lot of the common game development languages, including C++, C#/XNA, Java, (etc, etc, etc).  I plan on making a living creating games and would like to start focusing on a language that can help me make a career out of game development.


Recently, I have been interested in choosing a language to replace AS3 as my main language.  C#/XNA was the first thought in my mind, but then I read that Microsoft won't be supporting XNA any longer.


I would like to create multi-platform (Mobile, Console, PC/Mac/Linux, Web) games and I've heard that Monogame is capable of doing most of the target platforms.  I am independent at the moment, but I would certainly like opportunity for this skill to help me land a job in the future.


Does any happen to have experience in this area and can lend me some advice? 

Should I learn C++, raw C# (without XNA), Monogame or something else?


I hope everyone has/is having/had a great holiday. 

Thanks in advanced!