[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 379: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 379: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4752: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4754: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4755: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4756: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
NetWoC • View topic - My First Sprite


All times are UTC - 5 hours [ DST ]


It is currently Tue Apr 16, 2024 3:30 am


Forum rules


1) This is PG 13 so please warn if you are posting something not suitable for little eyes or work.
NSFW is standard to denote this in the thread title.
However anything too unsuitable will get you a warning!

2)This is SPAM not Sparta: Avoid controversial issues such as politics or religion please and be nice. Niceness costs nothing and will gain SHINY!

3) Eternal does not ever apply to spam.

4)This is not the art forum: If you really must post many pictures then using links is helpful nice and stops people getting bogged down.

5) Reiteration: Being abusive to someone because of their age, size, sex, sexual orientation, race etc is NOT allowed. We love humour but even humour has limits. Think twice before posting something that could offend


Post new topic Reply to topic  [ 15 posts ] 
Author Message
 Post subject: My First Sprite
PostPosted: Sat Nov 14, 2015 2:54 pm 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
For some reason or another, I've found myself getting pulled back into C/C++ programming for many reasons including radiology development and developing a high school Computer Science curriculum for my home-schooled teens and out home-school co-op. While I have a bit of experience with programming, it's usually within a command-line interface with very little being done graphically or for Windows.. Even today, all of the MUMPS programming that I do is at a command line.

So today, I have done it. Successfully accomplished the creation of a window, loading of an texture from a file, and applying that to a 64 x 64 sprite. The result is my very first sprite ever! ;-)

I created the Sprite from hand, consisting of 4 64x64 sections each for cardinal point facing. Next is a change of facing upon event (keytroke maybe). And then movement. Finally, animation. This all is proving to be a whole lot more time intensive and less intuitive as it was say, 15 years ago...

As a consequence, you can imagine the possibilities that I have in my mind for an old 8-bit or 16-bit styled sprite-based JRPG...

:twisted:




((I'm sorry for Photobucket....that site is garbage. Gonna figure something out soon enough...))
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Tue Nov 17, 2015 7:14 pm 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
Added the apha channel to the texture so now it looks a lot better.
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Tue Nov 17, 2015 9:19 pm 
NetWoC Admin
Offline

Joined: Tue May 06, 2014 11:20 pm
Posts: 373
Location: Vancouver BC
I imagined this was about your discovery of a delicious carbonated beverage or even the discovery of a tiny magical being. After reading, I prefer to still imagine that to be the truth :P
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Tue Nov 17, 2015 10:29 pm 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Tue Nov 17, 2015 11:02 pm 
User avatar
Offline

Joined: Wed May 07, 2014 9:59 pm
Posts: 589
Location: New Hampshire
See, my mind went here: https://en.wikipedia.org/wiki/Sprite_(lightning)

;)

[/wx nerd]
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Wed Nov 18, 2015 9:15 am 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Wed Nov 18, 2015 3:29 pm 
NetWoC Admin
Offline

Joined: Tue May 06, 2014 11:20 pm
Posts: 373
Location: Vancouver BC
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Tue Dec 22, 2015 8:22 pm 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
Had a bit of a setback here. Went from sprites to circles and squares, but it's all good, 'cause I can take what I've learned and apply it to mythical winged creatures. I may draw and scan in the frames myself... Darn French side of me an it's artsy-fartsy OCD....
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Wed Dec 23, 2015 7:09 pm 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
The Shiny Spite Demo!!

Here it is, as promised. I took advantage of my half day off today to apply a small mythical winged creature to what I've done with squares and circles...

(Albeit, she's not very shiny....)



Here is the 4-1-1:

This was written in C++

The grid that you see is a 10 x 10 grid consisting of 32 x 32 cells. The images for the sprites are 32 x 32 as well, all images are on a single PNG "sprite sheet."

The sprites for the player (sprite, aka fairy) have a forward-facing, rear-facing, left-facing, and right-facing images. I have additional frames for animation, but I never had time to implement the animation yet.

The player sprite reacts to the Up,Down,Left,and Right arrow keys. Holding down an arrow key does not make the sprite move consecutively, rather, one keypress equals one space moved. This was by design, of course.

You can see the fairy move off of the grid....whoops' I think the window was 800x600, so that is the limits. I wonder what would happen if I tried moving her off of the grid ... Would she fall off the edge of the world, or find herself in China?

Do keep in mind, that this is awfully rudentary. I am learning, and believe it or not, have just knocked out some concepts with this. After a few years in MUMPS it is a bit, oh, shall we say, adventurous, trying to go back to C++. But it's worth it. I even wrote the "player" as a class, consisting of an X and Y variable for location, and functions to "set" and "get" those values. It's starting to come back to me, little by little.
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Thu Dec 24, 2015 1:47 am 
NetWoC Admin
Offline

Joined: Tue May 06, 2014 11:20 pm
Posts: 373
Location: Vancouver BC
s'lovely <3
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Tue Dec 29, 2015 3:19 pm 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Tue Dec 29, 2015 9:19 pm 
User avatar
Offline

Joined: Wed May 07, 2014 9:59 pm
Posts: 589
Location: New Hampshire
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Fri Jan 01, 2016 12:52 pm 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Fri Jan 01, 2016 8:12 pm 
User avatar
Offline

Joined: Wed May 07, 2014 9:59 pm
Posts: 589
Location: New Hampshire
Top
  Profile  
 
 Post subject: Re: My First Sprite
PostPosted: Tue Jan 05, 2016 8:21 am 
User avatar
Offline

Joined: Tue Jun 16, 2015 6:44 am
Posts: 106
Top
  Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 15 posts ] 

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron