School Assignment? Project Due Tomorrow? Chat LIVE With A Programming Expert!

Welcome to Dream.In.Code
Become an Expert!

Join 307,136 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 1,994 people online right now. Registration is fast and FREE... Join Now!




XNA texture vertical motion

 

XNA texture vertical motion, XNA Getting Texture2D to randomly generate from top to bottom

kchenry2003

11 Oct, 2009 - 03:55 PM
Post #1

New D.I.C Head
*

Joined: 10 Oct, 2009
Posts: 2

In XNA , I need code to make my sprite sheet generate randomly and move from the top down. Currently I have the sprite sheet working but in moves diagonally across the screen, but the sprite does not stay in the rectangle and I can't figure out how to get the texture to randomly generate.

This post has been edited by kchenry2003: 11 Oct, 2009 - 03:56 PM

User is offlineProfile CardPM
+Quote Post


SixOfEleven

RE: XNA Texture Vertical Motion

11 Oct, 2009 - 04:09 PM
Post #2

lives.ToCode();
Group Icon

Joined: 18 Oct, 2008
Posts: 3,066



Thanked: 171 times
Dream Kudos: 775
Expert In: C, C#, XNA, Game Programming, Programming Concepts

My Contributions
First, those XNA utilizes C# this is a Game Programming question so I'm moving this to Game Programming.

Second, Dream In Code would like to see a good faith effort on your part. Could you please post the code you have tried and what is not working the way you expect it to. Please post your code in tags.

code.gif
User is offlineProfile CardPM
+Quote Post

Aeternalis

RE: XNA Texture Vertical Motion

12 Oct, 2009 - 08:25 AM
Post #3

D.I.C Regular
***

Joined: 13 Jul, 2009
Posts: 273



Thanked: 25 times
My Contributions
What your talking about is procedural textures a quick google search on that topic gives you this post that might be helpful to you.

Procedural textures in XNA

Good luck
Aet

User is offlineProfile CardPM
+Quote Post

Hellbroth

RE: XNA Texture Vertical Motion

15 Oct, 2009 - 11:10 AM
Post #4

D.I.C Head
**

Joined: 15 Aug, 2009
Posts: 53



Thanked: 1 times
My Contributions
QUOTE(Aeternalis @ 12 Oct, 2009 - 08:25 AM) *

What your talking about is procedural textures a quick google search on that topic gives you this post that might be helpful to you.

Procedural textures in XNA

Good luck
Aet



XNA is the worst thing i ever used honest no resources and tutorials nothing complete waste of time....
User is offlineProfile CardPM
+Quote Post

SixOfEleven

RE: XNA Texture Vertical Motion

15 Oct, 2009 - 06:36 PM
Post #5

lives.ToCode();
Group Icon

Joined: 18 Oct, 2008
Posts: 3,066



Thanked: 171 times
Dream Kudos: 775
Expert In: C, C#, XNA, Game Programming, Programming Concepts

My Contributions
QUOTE(Hellbroth @ 15 Oct, 2009 - 01:10 PM) *

XNA is the worst thing i ever used honest no resources and tutorials nothing complete waste of time....


I don't know where you have looked but there are many resources and tutorials available for XNA online as well as many excellent books. http://creators.xna.com is an excellent site that pops to mind right off the bat for example.

I will admit XNA does still have a few things that need to be worked on but it is an excellent platform for creating games. Just like anything that is relatively new it will have a hard time being accepted.

But let's not get into a "This is a bad language/API/SDK for writing games with type of war." Every programmer is different and learns and understands languages differently.

Games can be, and are, written in just about every language with every API/SDK/Framework.
User is offlineProfile CardPM
+Quote Post

stayscrisp

RE: XNA Texture Vertical Motion

16 Oct, 2009 - 02:23 AM
Post #6

Mouth->Insert(Foot);
Group Icon

Joined: 14 Feb, 2008
Posts: 1,404



Thanked: 53 times
Dream Kudos: 300
My Contributions
@OP

Can you explain what you are trying to achieve a little more?
User is offlineProfile CardPM
+Quote Post

Hellbroth

RE: XNA Texture Vertical Motion

27 Oct, 2009 - 08:56 PM
Post #7

D.I.C Head
**

Joined: 15 Aug, 2009
Posts: 53



Thanked: 1 times
My Contributions
QUOTE(stayscrisp @ 16 Oct, 2009 - 02:23 AM) *

@OP

Can you explain what you are trying to achieve a little more?



Probably he want's to make the sprite go from the top to the bottom but i assume in his if statement's he has made two if so they work the same time and the character goes for example down and right at the same time. So he should use if for going down and else if for turning to right. As for the random thing i don't have any clue.

XNA isn't that but in the end it just needs a lot of search in order to begin and find a suitable book.Sorry for my bad attitude it was realy imature from me.

My apologies.

This post has been edited by Hellbroth: 27 Oct, 2009 - 08:58 PM
User is offlineProfile CardPM
+Quote Post

antshockey

RE: XNA Texture Vertical Motion

30 Oct, 2009 - 03:17 AM
Post #8

New D.I.C Head
*

Joined: 16 Oct, 2009
Posts: 11


My Contributions
There is a book called Learning XNA 3.0 by Aaron Reed it teaches you exactly what your looking for.
There are many tutorials on XNA, I know this because I have used many of them myself from time to time
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic

Time is now: 11/21/09 02:52PM

Live Help!

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter Fan Us On Facebook

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month