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: 11th May 2007 23:36
Quote: "there's no animation, but let me know what you think
[Code]
sync on:cls
sync rate 0
hide mouse



print "888888888888888888"
print "8****************8"
print "8 @@@@@@@ 8"
print "8 @@@@@@@ 8"
print "8 @@@@@@@ 8"
print "8 @@@@@@@@ 8"
print "8 @@@@ @ @ 8"
print "8 @ @ @ @ 8"
print "8 8"
print "8Elderly At Play 8"
print "888888888888888888"
print " 888888 "
print " 888888 "
print " 888888 "
print " 888888 "
print " 888888 "
print " 888888 "
print " 888888 "
print " 888888 "
print " 888888 "
print " 888888 "
print " ****** "
print " ****** "

"

but what is it?




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 23:48
It's a sign.

Let's try not keep bumping this post with ascii print statements. Especially since it's here in the DBpro Discussion board and not newcomers. While I like ascii and think that practices in text in array handling are great endeavor's. I was hoping that the code I provided would get people thinking in other ways to animate, store, scale, and diaply text.

Try to look at the code I already provided, and try to understand it. Try rotating the array used to store the image. Try thinking of collision detection. Perhaps turn the code into an ascii tetris game. Try reading in cahracter's from a seperate text file. That's what will help you gain understanding on how to use text.

I'm not trying to be harsh, but I really think this post should be moved to the newcomers board or locked.

So rather than just posting ascii creations, try doing something with them that is more versatile, and can actually be used in a game.

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 12th May 2007 00:29
I C, ok.

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: 12th May 2007 03:06
Quote: "It's a sign.

Let's try not keep bumping this post with ascii print statements. Especially since it's here in the DBpro Discussion board and not newcomers"


I agree, MOD can we move this to Newcomers Corner please.

However I too am interested in fiddling with it for a while.
Now, my first reaction for a very crude collision system would be;
1 - Throw 40 or 50 characters on the screen in random locations. Store those random locations in an array.
2 - My silly dancing man character is not a rectangular shape so you can't just check for a bounding rectangle type collision. But you could Hard Code a MASK into an array for him.
3 - We will know the dancing mans x,y position from the mouse coordinates so we could just compare the arrays whenever the mouse coords are within range of one of the random screen characters.


Just a first thought for an apparent collission detection.
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 12th May 2007 05:40
Cool.

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: 12th May 2007 15:47
This is where you will lay the foundations of one day doing your own Pixel Perfect Sprite Collisions using Memblocks without having to ask how?
It sounds complex but the principles are quite easy to grasp.


As a first go - Hard Coding the MASK will be easiest. (As opposed to calculating the MASK within the program).
Hard Coding a MASK for the dancing man would mean building an array containing the relative x,y coordinates of his extremities.

Imagine the dancing man is inside a rectangle that just touches his head, feet & hands.
Much of the rectangle will be empty space that we don't want to register a collision with.
The important coordinates that will define his MASK are the 12 points that would form a dot-to-dot if you were to draw straight lines just around his body.




Zenassem could you come back please. I just wanted to join in the conversation (I didn't want to take over or anything).
While I've got time for the pseudocode (I do that when I'm driving the car) - I'm alot slower actually punching out the code (partly because I am hung up of saving clock cycles - a consequence of my VAX days)!
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 12th May 2007 15:50
These coding things make my haed hurt

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
Zotoaster
19
Years of Service
User Offline
Joined: 20th Dec 2004
Location: Scotland
Posted: 12th May 2007 19:41
Just ignore it lol, every word of it. It will slowly come to you. You will feel a slight tug, and a faint voice whispering "what if... we.. could code a... more dynamic and flexible way where we can load ascii art?" and you will literarly see a lightbulb flash above your own head. So you will then learn about arrays and functions, and perhaps other things. This sorta thing will just keep happening (apart from the lightbulb bit, because you will come up with so many ideas that the lightbulb will burst (i.e. trying too many things) and you will get bored of the ideas). Then you will replace the lightbulb and ideas will flow back....


I'm talking crap aren't I?

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 12th May 2007 21:05
WTF, ya u r.

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
Benjamin
22
Years of Service
User Offline
Joined: 24th Nov 2002
Location: France
Posted: 13th May 2007 13:11
I believe you mean: What the fiddle, yes you are, my good man.

Tempest (DBP/DBCe)
Multisync V1 (DBP/DBCe)
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 13th May 2007 18:33 Edited at: 13th May 2007 18:33
No, i mean Where's the bunny?


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: 13th May 2007 21:41 Edited at: 13th May 2007 21:43
I'm going to finish up what I started on, but I needed to take some time to code some of my own game's routines.

The last few days I have been a bit busy:

- Friday night my daughter's best friend had her sweet 16 party, so I couldn't work on anything.

- Saturday to now (I just got home 15 minutes ago) I had to give the wifey and I some well deserved bonding time and so I treated us to a weekend in the Hamptons and Montauk. (NO COMPUTER OR TV)

I need a few hours to get going today. I have to balance my computer-coding time with my loving family. It's hard because when I get on a hot-streak of coding, art, modeling, I would love to be obsessed and tune everything else out for days-on-end. I have learned the hard way the effects it has on my family & myself when I overinduldge in my own introverted world.

I have burned out numerous times from the stress and grief I get for spending so much time here and on my game projects. And to be honest the people who worry about me are right.

So in order for me to stick around for the long term, I have to pace myself and balance things. I love this place, but I can't put myself in a situation where I feel full of guilt and have to leave programming altogether like some sort of 12 step program.

So give me a little time today, and I plan on finishing the ideas that I had on this.

Thanks
~zenassem

Bartman
19
Years of Service
User Offline
Joined: 26th May 2005
Location: A rural village in NSW Australia.
Posted: 14th May 2007 10:21
zenassem - I totally feel you - I'm in the same place.


p.s. (I've always wondered - is that Zen Assembly, because I like it - or did I miss something?)
A Tea Spoon
17
Years of Service
User Offline
Joined: 23rd Apr 2007
Location: good ol USA!
Posted: 14th May 2007 21:21
Dance stick man!


funny.

What if the hokey pokey really IS what it's all about?
zenassem
21
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 14th May 2007 21:48
Bartman, indeed it is Zen Assembly.

It comes from Michael Abrash (The Zen of Assembly Languag), and his articles.

TANSTAFC There ain't no such thing as the fastest code!

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 15th May 2007 03:17
sure there is :lol:
J/C but this is pretty fast:


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: 15th May 2007 03:29
Well, I didn't feel like spending time to work out the random platform generator. So I just made a repeatable level. I'm just finishing the scrolling window and collision. I removed the animation frames for now, because DBpro is a bit slow with text commands, and the FPS dropped exponentially. So I'm stiking with 1 frame for now.



Zombie 20
17
Years of Service
User Offline
Joined: 26th Nov 2006
Location: Etters, PA
Posted: 15th May 2007 04:23
I saw the stick man and i couldn't resist, its not done and most of the time was taken lining up the second edition.



A Tea Spoon
17
Years of Service
User Offline
Joined: 23rd Apr 2007
Location: good ol USA!
Posted: 15th May 2007 23:02
Lol. this is funny.

finished the stick danceing


What if the hokey pokey really IS what it's all about?
A Tea Spoon
17
Years of Service
User Offline
Joined: 23rd Apr 2007
Location: good ol USA!
Posted: 16th May 2007 23:22
and now, a new stupid cheesy dancy man!

lol

What if the hokey pokey really IS what it's all about?
MikeB
17
Years of Service
User Offline
Joined: 5th Apr 2007
Location: My Computer, Shropshire, England
Posted: 20th May 2007 18:10
Quote: "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. "


Hi, I'm a DBP nooby, and I was wandering what the "specifications" of the image I use to create the animated sprite needs to be?

Thanks very much, and I can't wait to see this game when it's done .

E.D.

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 20th May 2007 19:48
Now we just need to get an ide-er for the game!

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: 21st May 2007 16:17 Edited at: 21st May 2007 16:28
Hi ED - Rather than type out an explanation of the Create Animated Sprite / Play Sprite Commands again I will Cut n' Paste a reply I made to a similar query some time ago. (I believe that the Docs have been updated since then).

Quote: "
Hi all,
Well here's the gen on the create Animated Sprite fiasco.

Create Animated Sprite.
I have no hesitation in praising the creators of DarkBasic for the quality of their wonderful software, however the quality of their documentation makes me wonder if English is their second language.
So, let me just add one word to the syntax for the Create Animated Sprite Command that will miraculously clear up so many issues for anyone inexperienced in the command.
"FRAMES" - CREATE ANIMATED SPRITE Sprite Number, Filename, FRAMES Across, FRAMES Down, Image Number
(i.e. it's not PIXELS Across per frame, PIXELS Down per Frame,)

Play Sprite.
Who else thought that the animation should play after the Play Sprite command is executed? Me too, but it's just not so. Essentially all Play Sprite does is keep track of the frame number for you and then each iteration of the Play Sprite command the sprite is drawn with the next frame. If play sprite isn't inside some kind of loop then it will only play the first frame and then the program will continue along, probably without anybody even noticing that the sprite was displayed at all. The documentation for this command mentions nothing of this - in fact the words.... "This command will play an animated sprite" are downright misleading! - what were they thinking? I seriously doubt that the doc writer had ever used this command.

So anyway, this brings us all back to square one, where you are just better off managing the animation yourself.

Thus-henceforth-hereunto.
If you created an animation bitmap that looked like this --> |/- and called it "rotating_lines.bmp" then your Create Animated Sprite Command would be --> Create Animated Sprite 1,"rotating_lines.bmp",4,1,2

This creates sprite number 1 from the bitmap "rotating_lines.bmp" which is 4 frames across by 1 frame down and stores the full image in image number 2. Use the Sprite command a-la, Sprite 1,x,y,1 to put sprite 1 on the screen at the x,y coordinates using image 1. Lastly if you must use Play Sprite, use the Play Sprite command inside a loop to cycle through the frames of the animation a-la, Play Sprite 1,1,4,100 which means Put sprite 1 back on the screen using frames 1 through 4 with a 100 millisecond delay between displaying each new frame. See the code snippet.

However rather than using Play Sprite it is better to use the Sprite command inside the loop and then increment the image number to make the animation happen. You will then also have control over the number of times the lines rotate as well as the x,y position of the rotating lines. Create Animated Sprite can still be used to initially create sprite 1 with a four frame animation. See Zenassem's and JessTicular’s excellent code examples above to see how this would be done without the Play Sprite command!
"



Now for the Specs of the image.
There's only one specification, really. The Image (JPEG/BITMAP) needs to be made up of a series of images evenly placed in a grid. If that sounds confusing...... Think of Tic-Tac-Toe. If you made an animation out of a Tic-Tac-Toe grid it would be a 9 frame animation, 3 frames across and 3 frames down. The create Animated Sprite command will start at the Top Left frame and read across the top row then come down to the middle row and read across it Left to Right then again on the bottom row.


However - The focus of this thread is on ASCII Animation with some type of functionality - just as the ZenAssem master has tried to inspire us not to simply animate some text but to also do something funky with it.

So using an Animated Sprite here will not assist the fermentation of this topic!
I really encourage you guys to take Zenassems code and re-post it with some additions of your own.
A Tea Spoon
17
Years of Service
User Offline
Joined: 23rd Apr 2007
Location: good ol USA!
Posted: 21st May 2007 21:01
Quote: "and I can't wait to see this game when it's done"


did i miss something? who be making a text animation game?

thats not such a bad idea....

What if the hokey pokey really IS what it's all about?
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 21st May 2007 23:37
Well, first we need ASCII sprites, a game script, layout, etc. You know, everyone could help

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
A Tea Spoon
17
Years of Service
User Offline
Joined: 23rd Apr 2007
Location: good ol USA!
Posted: 22nd May 2007 22:33
I just had an idea, i could make a Dance Dance revolution type game for my text dancy man!

first... how make the text scroll?

ill make a thread for this

What if the hokey pokey really IS what it's all about?
n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 23rd May 2007 02:38
lol, that sounds....


Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
RUCCUS
19
Years of Service
User Offline
Joined: 11th Dec 2004
Location: Canada
Posted: 23rd May 2007 03:47
If you're just asking for help on every aspect of the game, without even attempting to do it yourself, you're not making it at all.

MikeB
17
Years of Service
User Offline
Joined: 5th Apr 2007
Location: My Computer, Shropshire, England
Posted: 23rd May 2007 11:25 Edited at: 23rd May 2007 11:28
While we are on the topic of ASCII.......

http://youtube.com/watch?v=-EPhrqDCZQc

and

http://youtube.com/watch?v=kdhrE5RMDfQ

E.D

n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 23rd May 2007 21:20
lol, that star wars thing waz kool! Oh, and i am currently learning C++, so...

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!
A Tea Spoon
17
Years of Service
User Offline
Joined: 23rd Apr 2007
Location: good ol USA!
Posted: 23rd May 2007 21:53
im not asking for help on every aspect of the game, i just wanted to ask a question. every time i try to get the text to scroll it has issues, and gives me errors.

sorry...

What if the hokey pokey really IS what it's all about?
Zombie 20
17
Years of Service
User Offline
Joined: 26th Nov 2006
Location: Etters, PA
Posted: 29th May 2007 14:31 Edited at: 29th May 2007 22:21
Hey just bumping this one more time, I'm creating my final installment of db animation . Here's what I have so far. Let me know what you think!!!




n008
17
Years of Service
User Offline
Joined: 18th Apr 2007
Location: Chernarus
Posted: 29th May 2007 17:18
Nice, but you forgot to set the text back to size 12, and break the text strings so they don't go off the screen.

Ling creckt tsi nocreckto havela? NASA chetallnar mo lu'ul nasding!

Login to post a reply

Server time is: 2024-11-25 19:43:06
Your offset time is: 2024-11-25 19:43:06