xboxscene.org forums

Pages: 1 [2] 3 4

Author Topic: Tetris  (Read 1931 times)

BenJeremy

  • Archived User
  • Hero Member
  • *
  • Posts: 5645
Tetris
« Reply #15 on: January 02, 2004, 05:01:00 PM »

user posted image

Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Tetris
« Reply #16 on: January 02, 2004, 05:04:00 PM »

Cool idea for the colors.  I'll add them for the board as well tonight (when the guests are done with the xbox).
Logged

BenJeremy

  • Archived User
  • Hero Member
  • *
  • Posts: 5645
Tetris
« Reply #17 on: January 02, 2004, 05:11:00 PM »

wink.gif It solves a lot of data management issues.

Again, very nice work!

If I can, I'll consider adding something so ActionScripts will have sprite-like access to images.
Logged

BenJeremy

  • Archived User
  • Hero Member
  • *
  • Posts: 5645
Tetris
« Reply #18 on: January 02, 2004, 07:02:00 PM »

Geez... how cool is this, anyway.... I was testing the Virtual Keyboard with the IR Remote, and I figured... why not try Tetris with the IR... and it worked pretty well!

Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Tetris
« Reply #19 on: January 02, 2004, 10:58:00 PM »

biggrin.gif

Blocks got an embossed look now, check it out:
user posted image

But they look much brighter on my TV, with my normal brightness/contrast settings.
Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Tetris
« Reply #20 on: January 03, 2004, 12:16:00 AM »

biggrin.gif

I've changed the <color> tag in the pieces xml to only include the RGB values (6 digits)  This way I can dim the colors just by adding an alpha value.  
I made the borders have a lower alpha value than the fill.  To my surprise, the pieces turned out to look 3d.  Here is a zoomed in pic of a block.
user posted image
The funny thing is that a box without a fill has a constant colored border (atleast it looks constant; eg. the box around the whole board).
So is this some sort of an easter egg or a bug?  Or was it meant to be like this?

Puzzled
Logged

BenJeremy

  • Archived User
  • Hero Member
  • *
  • Posts: 5645
Tetris
« Reply #21 on: January 03, 2004, 05:11:00 AM »

biggrin.gif

(Now thinking about the possiblity of doing Qix in ActionScript...)
Logged

koldfuzion

  • Archived User
  • Hero Member
  • *
  • Posts: 1226
Tetris
« Reply #22 on: January 03, 2004, 07:11:00 AM »

love.gif  
I'm sure people that have never used MXM have no idea about the power it contains. To make a game that looks and  works that good with just a couple txt files is crazy.

beerchug.gif
Logged

BenJeremy

  • Archived User
  • Hero Member
  • *
  • Posts: 5645
Tetris
« Reply #23 on: January 03, 2004, 07:12:00 AM »

wink.gif
Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Tetris
« Reply #24 on: January 03, 2004, 07:14:00 AM »

More on the 3d look

I set the fill to be around 50% alpha.  I set the border to be around 20% alpha.
I set the box to be 9 x 9 pixels.

I guess that the fill is drawn 9x9 pixels, but the border is drawn 10x10 pixels big.  That causes it to overlap on the topleft part, creating the highlight.  The 20% alpha border by itself creates the shadowed part.

A little bug, but pretty neat result in the end
Logged

BenJeremy

  • Archived User
  • Hero Member
  • *
  • Posts: 5645
Tetris
« Reply #25 on: January 03, 2004, 07:48:00 AM »

Well, I've added LINE (will be in next update) to the draw set, but image is a bit more complicated. I am also looking at a scheme where you can reference back to Draw List objects and manipulate them withouth having to redefine the draw list (handy for images, when sprites are working)

Hmmm.. given the flexibility of XML, I might tweak that a bit too... adding the ability to directly access any opened XML (%#<xmlhandle>.node% - but of course, embedding index values would be difficult. Perhaps I can fix that, too... maybe I could add the ability to nest variables with [] - %MyArray[index]% where the space between [] is interpreted as a variable name (and can be further nested in a similar manner.

My problem is with using % for the variable insertions into arguments... works fine, except when embedding a variable within a variable name. The brackets would solve that problem.
Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Tetris
« Reply #26 on: January 03, 2004, 08:00:00 AM »

That would also add the ability to use arrays
SET myItem%index% "aaa"
SET blah %myItem[index]%  <-- This statement couldn't be done before now.
Logged

BenJeremy

  • Archived User
  • Hero Member
  • *
  • Posts: 5645
Tetris
« Reply #27 on: January 03, 2004, 09:15:00 AM »

QUOTE (geniusalz @ Jan 3 2004, 12:00 PM)
That would also add the ability to use arrays
SET myItem%index% "aaa"
SET blah %myItem[index]%  <-- This statement couldn't be done before now.

Correct. I am in the process of upping the latest changes.... The embedded XML isn't in there yet, but the embedded regular vars is (See the test script in the internal.xml file for a good, tested example)

Theoretically, you can nest embedding, too. Looks like MXM's actionscripting just got a whole lot more powerful.

Some stuff I may save for a follow-on to MXM - implementing it in a true tokenizing BASIC client. If the other dashbuilders would consider the module concept (using DLLs) and help out, I could create a nice unified BASIC module that would allow freely distributable apps for Xboxers!
Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Tetris
« Reply #28 on: January 03, 2004, 01:12:00 PM »

QUOTE (BenJeremy @ Jan 3 2004, 02:15 PM)
Some stuff I may save for a follow-on to MXM - implementing it in a true tokenizing BASIC client. If the other dashbuilders would consider the module concept (using DLLs) and help out, I could create a nice unified BASIC module that would allow freely distributable apps for Xboxers!

I was going to suggest a tokenizer, and function calls with parameters and return values.
I don't really get why you want to 'save' it for later, seeing how well actionscripting is progressing.

You could even create a module to run actionscripts in other dashes, or even slowly add on to actionscripting to turn it into BASIC (it's similar enough already).
Logged

BenJeremy

  • Archived User
  • Hero Member
  • *
  • Posts: 5645
Tetris
« Reply #29 on: January 03, 2004, 02:56:00 PM »

QUOTE (geniusalz @ Jan 3 2004, 05:12 PM)
QUOTE (BenJeremy @ Jan 3 2004, 02:15 PM)
Some stuff I may save for a follow-on to MXM - implementing it in a true tokenizing BASIC client. If the other dashbuilders would consider the module concept (using DLLs) and help out, I could create a nice unified BASIC module that would allow freely distributable apps for Xboxers!

I was going to suggest a tokenizer, and function calls with parameters and return values.
I don't really get why you want to 'save' it for later, seeing how well actionscripting is progressing.

You could even create a module to run actionscripts in other dashes, or even slowly add on to actionscripting to turn it into BASIC (it's similar enough already).

Well, it's kind of an either-or thing, because of the syntax. In order to convert to a Basic Interpreter, I'd need to convert the ActionScripts.

If I had to do it all over again, I would have probably scrapped actionscript in favor of 100% basic. Even so, there are a ton of things I'd have to tweak on my BASIC interpreter to make it work with new data types and arrays.

Interestingly, the free-form, non-tokenized nature of ActionScripting makes it deceptively powerful. wink.gif
Logged
Pages: 1 [2] 3 4