Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / This is just fun....

Author
Message
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 10th May 2007 05:26
This is "Bunny" animation


Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 10th May 2007 05:36
Umm, how would you set the cursor randomly inside a certain area?

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 10th May 2007 05:44
Here is a 'fly' animation


Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
Agent Dink
20
Years of Service
User Offline
Joined: 30th Mar 2004
Location:
Posted: 10th May 2007 09:40
That's pretty cool for a start. Better than some text programs people post when they are just starting out

I have no signature...
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 10th May 2007 10:32
Quote: "Umm, how would you set the cursor randomly inside a certain area?"




That will set your cursor randomly within a 640 x 480 area.



Mistrel
Retired Moderator
19
Years of Service
User Offline
Joined: 9th Nov 2005
Location:
Posted: 10th May 2007 11:18
Is this the future of DarkBasic?

http://3dfolio.com
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 10th May 2007 14:44
@scragle ya, i got tired of errs, so i set variables that the program drew, about two lines extra XD.

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 10th May 2007 16:54 Edited at: 10th May 2007 16:56
n008, what would be interesting is to store the Ascii characters of our bunny friend in a 2D array or other struct. And then performm matrice operations to the data to rotate yee little bunny. It would also be insteresting to code an Ascii scale function that would fill empty spots as you expand the array, so that you could scale the bunny larger.

Then you could also test for "Ascii character-perfect" collisions with an ascii world.

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 00:26
Umm... How would i do all that?

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
NeX the Fairly Fast Ferret
19
Years of Service
User Offline
Joined: 10th Apr 2005
Location: The Fifth Plane of Oblivion
Posted: 11th May 2007 00:28
Don't blind him/her with science! (ok it's pseudocode, but it's used as a figure of speech)


Since the other one was scaring you guys so much...
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 00:39
lol, but seriously, how do i do that?

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 00:50 Edited at: 11th May 2007 01:02
I will code some of it now to give you a start. I just got back home. your bunny code really inspired me to create a game. I am currently mocking up a WIP on that, that will probably be ready in the next few days (I'm on leave from work for a few weeks, so I'll have lots of time.)

Link to how your post inspired me to create a game. Honestly the freshest, and most exciting idea I think I have ever had. So thank you.
http://forum.thegamecreators.com/?m=forum_view&t=105745&b=2&p=1

check out the last two posts by me!


Give me a little a few minutes to work with the bunny code, and I'll post in here as I complete each section. It will give you an Idea of what I am working on so that you can build off of it while I am coding the more difficult aspect which is the scale text array routines.


Ascii gif. to sprite for my game.




n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 01:08
OMFG!! That is Crazy awesome!!

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 01:12
It's seriously thanks to you. Your post got me thinking, and Blam it hit me!!! So I owe you alot for the inspiration.

I'm working on your code right now.

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 01:13
ok, but how did you do that animation in your post.(i know, a NOOBISH question)

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
GatorHex
19
Years of Service
User Offline
Joined: 5th Apr 2005
Location: Gunchester, UK
Posted: 11th May 2007 01:16 Edited at: 11th May 2007 01:21
Hmm, 14 years ago, on the Vax when the Internet was nothing more than text based gopher and irc, it might have been cool or new



http://www.KumKie.com http://bulldog.servegame.com
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 01:26 Edited at: 11th May 2007 01:43
n008,

The animation is done in my post by making seperate bitmaps of each frame of the character. Promotion which I believe is still sold here, is really great for doing 2D sprites and animation. There are other programs, like photoshop and jasc's paint shop pro comes with a animation editor. But I like Promotion.

ProMotion has tools/options to play frames, save frames etc.. to numerous formats. So you can create a .gif from all your animation frames. I've never used or written a .gif reader in DBpro, but DBpro has a create animated sprite command, that can take a bitmap of frame images and automatically cuts them out and creates each image of the sprite animation. the Play sprite command can then play the sprite from specified image ranges.

Promotion can also put the frames together into one file like a .gif. It can also perform the opposite and strip the frames out of a .gif, so that you can save them as seperate files, or seperate the images into one file containing all the sprite animation frames. You can select how many rows and how many colums it should use to fit your sprite animation in wahtever file extension (eg. .BMP).

So that's what you see in my above post. The grid of all the animation frames in one bitmap (which DBpro uses to create the sprite), and the .gif which is playing showing the animation.

Hope all of that makes sense.

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 01:32
Interesting

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
GatorHex
19
Years of Service
User Offline
Joined: 5th Apr 2005
Location: Gunchester, UK
Posted: 11th May 2007 01:34
The way art conversion to ASCII works is something like this..

Create an array of 256 charaters that best represent shades of grey from 0-255

Load and convert a picture to grey scale

Replace each pixel with it's corresponding grey ascii character.

If you wana animate it then snapshot the ascii pic and save as animated Gif frames.

I dunno how you do all that in DBP but it's simple to do with something like Delphi.

http://www.KumKie.com http://bulldog.servegame.com
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 01:37
I C, wow, all i wanted to do was show a rabbit dancing, lol.

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 01:46 Edited at: 11th May 2007 01:48
And thanks GatorHex for explaining the conversion part. There are numerous tools out there to do that. You don't have to (although some people I guess are talented enough to) create them by hand.

It'a always nice to have a utility that will convert any image to an ascii image.

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 01:53
I like too, but complex stuff... nah.

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 01:56
Uhh... That program kinda sucks, lol

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 02:17
That's the truth!!! There are better ones. I was just trying to give you an example of one for free. I did it myself after i posted the link and wasn't happy with the ascii image. lol!

Bahhhh! There should be a good free one out there. I'll look later

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 02:24
Is it possible to create two loops in a program, or, set a timer, then when the timer gets to a certain time, end one loop and start another?

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 02:47
Ok I have to correct the animation frames, as I messed them up when I made the data statements. But I'll get it going, you will still be able to see what I am doing. Play around with the muliplier in the text line. Add numbers to the result to move bunny around.

Here's what I have so far


n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 03:04
Wow thats really cool

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 03:09
I'm working on using the keys for movement, and zooming in and out. I'll finish off with collision detection against a "random real-time ascii-generated scrolling level". Woot! I love oldskool!!!!!

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 03:29 Edited at: 11th May 2007 03:33
oldshool rulz

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 03:33 Edited at: 11th May 2007 03:37
Ok take a look at this. Don't go off the screen with him, becuase I haven't prevented going out of bounds yet.

use the arrow keys to move and zoom the bunny
right and up zoom-in on the bunny (without filling in gaps)
left and down zoom out

I think it will give you some ideas on how far you can go with something like this. For now I need to setup the dynamic ascii world generator. Tis fun!!!






indeed my friend. indeed it does!

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 03:40 Edited at: 11th May 2007 03:40
Right on!

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 03:41
Whoa! Warping bunny!

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
Zombie 20
17
Years of Service
User Offline
Joined: 26th Nov 2006
Location: Etters, PA
Posted: 11th May 2007 03:44
you have all inspired me to do some animation tests . that is so freaking cool!! i love programming so much, its the simple joys isn't it?

Code Dragon
18
Years of Service
User Offline
Joined: 21st Aug 2006
Location: Everywhere
Posted: 11th May 2007 03:45
That animated gif is awesome!

You've reached a new level of coolness, zenassem.

"Once there was a polygon mesh who was very sad because he was only Gouraud shaded."
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 03:50
Nothing fancy, but could be used in the oldskool game


Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 03:51
Any1 like teh fly?

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 04:08
AH! I can't get the text to move! Are you supposed to put the key If/Then inside the loop or outside? i set it to move the text, but no luck.

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
Zombie 20
17
Years of Service
User Offline
Joined: 26th Nov 2006
Location: Etters, PA
Posted: 11th May 2007 04:37
okay making more as i speak, but here's just some symbols and numbers.



n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 04:42
What is that supposed to do?

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 04:58 Edited at: 11th May 2007 05:01
[edit]
I think zombie was creating platforms that could be used as the terrain for the character to walk on. My random generator needs some serious tweaking, but I have to go out for a couple of hours. here is what I was up to. I hate responsibilities!
[/edit

Ok I sped things up by turning the backdrop back on. and started generating the random world. Unfortunately I have to clean an office tonight (we run a second business and my guy was sick). So I figured it would be best to give you what I have. I'll finish it tonight or tomorrow morning). The way it is now, there is 1 sync, and the animation frames are taken out for now. It's pretty easy to get it back in. Or you could use the other code. I just wanted you to be able to see how I was beginning to create the landscape.



n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 05:06
Geez, that's cool

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 11th May 2007 05:11
Thank you,

It's been honestly a lot of fun doing this stuff. And it was well worth it if you were able to learn a bit from it, and have some code that you can modify.

whatever you modify for a key has to go between the if and endif for thae key. Try removing the inc or dec of the zoom lines. Or add the vertical inc zoom into the right key and the dec zoom for the y values to the left key. This way he'lll grow in both directions when the right key is pressed, and shrink in both directions when the left key is pressed.

Once i finsish the landscape scroolling and collision, i will answer any questions you have about the code.

Enjoy! Happy discoveries!

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 05:34
HEHEHE!


Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
Zombie 20
17
Years of Service
User Offline
Joined: 26th Nov 2006
Location: Etters, PA
Posted: 11th May 2007 05:39 Edited at: 11th May 2007 05:57
yea, kinda hehe, but i'm not too good at it . I'll keep trying animations stuff though.

noo8-dude that is soooo coool! i want that as a screensaver . I'm going to keep building.

another one.


n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 06:11
If you slowed it down and had audio, it would look like he was talking, And thanks, the gun was HARD!

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
Zombie 20
17
Years of Service
User Offline
Joined: 26th Nov 2006
Location: Etters, PA
Posted: 11th May 2007 09:22
there's no animation, but let me know what you think


n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 11th May 2007 15:00
Nice XD.

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
Bartman
19
Years of Service
User Offline
Joined: 26th May 2005
Location: A rural village in NSW Australia.
Posted: 11th May 2007 18:13
noo8, That gun is the most original thing I have seen in ages. And originality is hard to find.

You've done real good!
........If this thing catches on we could all end up with a new Discussion Board for ASCII Animation.

Let's see some more.
Bartman
19
Years of Service
User Offline
Joined: 26th May 2005
Location: A rural village in NSW Australia.
Posted: 11th May 2007 18:50
Can I have a go too.....

Zombie 20
17
Years of Service
User Offline
Joined: 26th Nov 2006
Location: Etters, PA
Posted: 11th May 2007 19:18
i put some static objects i made for zenassam in the thread about the universe being made with darkbasic.

Login to post a reply

Server time is: 2024-11-25 17:50:34
Your offset time is: 2024-11-25 17:50:34