Author Topic: [TINYC5] CRA5TASTIC  (Read 2809 times)

0 Members and 1 Guest are viewing this topic.

Offline Optimus

  • DBF Aficionado
  • ******
  • Posts: 2452
  • Karma: 128
    • View Profile
    • Optimouse Demo Site
[TINYC5] CRA5TASTIC
« on: December 25, 2011 »
Hi!

I was normally not thinking about taking part in this compo, because I am not familiar with javascript or web developing but right the last two hours I have checked the tutorials and example framework and said why not?

It's not a serious entry, I just wanted to participate in the compo with the most I can do in a limited time. I thought of the title craptastic and then decided cra5tastic to match more the name of the library. Of course I don't mean that the lib is lame, it's only my entry that is crap :)

I really enjoyed my first try in coding anything javascript related. The lib is simple and great, gonna use it in the future too. I just need to familiarize more with javascript and find a debugger :)
Challenge Trophies Won:

Offline benny!

  • Senior Member
  • DBF Aficionado
  • ********
  • Posts: 4380
  • Karma: 228
  • in this place forever!
    • View Profile
    • bennyschuetz.com - mycroBlog
Re: [TINYC5] CRA5TASTIC
« Reply #1 on: December 25, 2011 »
You really did this in just 2 hours without having worked with javascript before ? Well, what can I say except - WOW !!! I like it a lot ... nice plasma floor-ceiling stuff with some sprites - runs pretty smooth on my laptop and chrome!

Thanks a lot for taking part and congratz for your first javascript work!
[ mycroBLOG - POUET :: whatever keeps us longing - for another breath of air - is getting rare ]

Challenge Trophies Won:

Offline Kirl

  • Senior Member
  • Pentium
  • ********
  • Posts: 1199
  • Karma: 229
    • View Profile
    • Homepage
Re: [TINYC5] CRA5TASTIC
« Reply #2 on: December 25, 2011 »
Really impressive work for 2 hours in a new language!  :o

For the next challenge I'd like to see what you can do when you spend the month on something, don't go so easy on us!  ;D
www.kirl.nl
Challenge Trophies Won:

Offline jace_stknights

  • Amiga 1200
  • ****
  • Posts: 399
  • Karma: 32
  • PEEK & POKE are not MOVEM!
    • View Profile
    • ST Knights WebSite
Re: [TINYC5] CRA5TASTIC
« Reply #3 on: December 25, 2011 »
Yep great piece of work for two hours of work!  :o
Challenge Trophies Won:

Offline neriakX

  • Atari ST
  • ***
  • Posts: 115
  • Karma: 29
  • CodeNoob
    • View Profile
Re: [TINYC5] CRA5TASTIC
« Reply #4 on: December 25, 2011 »
wow, I'm pretty surprised how good that demo is. You did very well! I couldn't do this in 2 days ;)
cheers,
neriakX

Challenge Trophies Won:

Offline padman

  • Senior Member
  • Pentium
  • ********
  • Posts: 977
  • Karma: 258
    • View Profile
Re: [TINYC5] CRA5TASTIC
« Reply #5 on: December 25, 2011 »
Cool stuff!  :)
Challenge Trophies Won:

Offline combatking0

  • JavaScript lives!
  • Senior Member
  • DBF Aficionado
  • ********
  • Posts: 4569
  • Karma: 235
  • Retroman!
    • View Profile
    • Combat King's Barcode Battler Home
Re: [TINYC5] CRA5TASTIC
« Reply #6 on: December 26, 2011 »
Excellent demo - I've been coding JS for many years, but I've no idea how to code a plasma effect.

The 3D rotating dots are also convincing.
You are our 9001st visitor.
Challenge Trophies Won:

Offline Kirl

  • Senior Member
  • Pentium
  • ********
  • Posts: 1199
  • Karma: 229
    • View Profile
    • Homepage
Re: [TINYC5] CRA5TASTIC
« Reply #7 on: December 27, 2011 »
Excellent demo - I've been coding JS for many years, but I've no idea how to code a plasma effect.
Alright, I just have to take this, because a plasma is so simple. I'm parroting jim here, but you just need 3 values for the R,G and B that move between 0-255 with some kind of offset between them. Easy with a sine:

Code: [Select]
var R = 127 + 127 * Math.sin( randomCal1 );
var G = 127 + 127 * Math.sin( randomCal2 );
var B = 127 + 127 * Math.sin( randomCal3 );

Now the cool thing is that no matter what you choose to do for randomCal1, 2 or 3, it will always keep between 0 and 255. So just go wild with some semi random calculations using the x and y of the pixel you're setting.

Everlasting respect and elitist status follows naturally!  ;D
www.kirl.nl
Challenge Trophies Won:

Offline jace_stknights

  • Amiga 1200
  • ****
  • Posts: 399
  • Karma: 32
  • PEEK & POKE are not MOVEM!
    • View Profile
    • ST Knights WebSite
Re: [TINYC5] CRA5TASTIC
« Reply #8 on: December 27, 2011 »
yep this is the "official" technique. On oldschool machines, as this way is two hard for the processor, you can use tricks like cycling colors in palettes, and moving backgrounds pre-calculated by these formulas.
Challenge Trophies Won:

Offline Kirl

  • Senior Member
  • Pentium
  • ********
  • Posts: 1199
  • Karma: 229
    • View Profile
    • Homepage
Re: [TINYC5] CRA5TASTIC
« Reply #9 on: December 30, 2011 »
I just noticed that I can see the dots spinning over two different axis, like the optical illusion of a spinning mask which you can see as either concave or convex. Pretty cool! :)
www.kirl.nl
Challenge Trophies Won:

Offline Hotshot

  • DBF Aficionado
  • ******
  • Posts: 2114
  • Karma: 91
    • View Profile
Re: [TINYC5] CRA5TASTIC
« Reply #10 on: December 30, 2011 »
Impressive Stuff there and what even more impressive that you have done in 2 hours  :o :clap: