Virtual Thoughts from eRoom-D

Thoughts on web development, Flash, Flex, and game design.

Getting Flex and Flash to play nice to each other, when they are not on the same server.

August25

Ok, so recently I needed to get a Flash swf into a Flex project and have the two talk to each other. Ok, fairly normal, I did it for a page navigation scroll bar that was AS2 and got it to talk with our Flex project and it works great. Problem though, the Flash swf I need to bring in will exist on another server, and the scroll bar I had worked on, we embedded into the project.

I spent days working on this. Why?

Well, two things:

  1. We get these files from a design firm and I wanted to not change their code that we gave them earlier.
  2. Cross domain issues.

I tried everything I could think of to bust this open, searched around, and came up with the solution. I had to change the code that the design firm used, moving them from AS2 to AS3.

Sean the Flex Guy has an excellent and simple tutorial for doing half of what I needed. It loads in a Flash swf animation, and then Flex talks to it to move the animation forward frame by frame. So that was covered, at least once I made the decision to move to AS3.

The other half, Flash talking with Flex wasn’t covered, but I found a solution in the Adobe Docs. As long as both the Flex and Flash swfs have their Security.allowDomain set properly, then the two can communicate back and forth (this needs to be set for the Flex to Flash work too). What I found out, was that events, such as Mouse events, will bubble if this is set properly. So all I needed to do was to listen for the MouseEvent that was fired when the buttons in the Flash swf were clicked. The rest was easy.

I imagine that if there is something else that happens in the Flash swf, you can create a custom event for it, and listen for that in the Flex swf. Since there are more things in Flash and Flex than are controlled buy your MouseEvents Horatio.

Powered by ScribeFire.

Popularity: 100%

posted under Flex | 3 Comments »

The fate of my Flex accessibility project.

August25

Ok, so some of you might be wondering what happened to the accessibility project that I was going to be working on several months back. Well…

It turns out that the major stumbling block here was the wmode tag that was being used. It needed to be set to wmode=opaque, and it was set to wmode=transparent. Why? Well, wmode transparent as most of you know, allows for Javascript dropdowns to flow over the Flash Player, which we have on many of our client sites. Unfortunately, how it does this is it makes the Flash Player effectively transparent (go figure) to the web browser’s DOM. So the web browser doesn’t take it into account when drawing things on screen. This has the added effect of making the screen readers that attempt to read the contents of the Flash Player either not see it at all, or act erratically when they do start to read it. Nice eh?

So, setting wmode=opaque, the five second change, solved most of the problems with our accessibility, so there was no need for me to do the research and my project on it was cancelled. I do still think that there was a lot to learn for everyone on accessibility, and that the sources out there do cover it, but not all in one place. We’re under tight deadlines though, so any saved time is taken by other things. Considering it meant that I didn’t have to work a weekend or too late, I was totally cool with that.

Powered by ScribeFire.

Popularity: unranked

posted under Flex | No Comments »

Post Gen Con – Pre Dragon*Con, Vegas After Midnight, etc.

August24

Ok, I had meant to post things earlier, but at least it’s sooner than the last gap was long.

Gen Con was a blast, at least as good as last year, I would say baring a few things, even better than last year. Vegas After Midnight ran very well, and we got both exceptional feedback and a host of possible playtesters. VAM was stripped down to start, but Daniel Perez (http://dmperez.com/) focused in on something that I hadn’t been able to put a name to. That was that we only had half or less of the Madness mechanics in the game. We just had ways to incur Madness, but nothing about it’s effects, or how to track it. So we slashed the things on the character sheet that required Madness (really just a few things), and ran with the edited versions. As I said, they went great, and the feel of VAM without Madness is there, now we just need to add in the darker aspects of Madness to make it complete.

Going as press for the second year in a row was definitely worth it. I got a great interview with Greymalkin Press about their new game Desolation, which never got recorded due to a recorder snafu. I am working with them to get it redone soon. Oh, and btw, Matt Somers, one of the key designers, has been my friend since college. Full disclosure and all that.

I also got to play Hellas with Jerry Grayson (http://hellasrpg.com), and that was awesome. I had the pdf review copy before the con, but it was so nice I had to buy a copy. So you can expect to hear it played on The Game Master Show (http://thegamemastershow.com) soon, along with Desolation.

Met a bunch of old friends, many of them podcasters, and met a fair amount of new ones. Played several playtest sessions with them, like: Mythender, and Mecha. Two excellent games, that just need a bit more polish. I expect to hear about them coming out within the next year.

I did get to go to the White Wolf party this year, thanks Matt – I think, but if you want to hear more about that, you’ll have to listen to the podcast for The Game Master Show that comes out soon. We’re recording it tonight.

Toodles!

Popularity: 14%

Gen Con 2008 Day 2!

August15

It’s been a looong time since I have last posted, but…

I am at Gen Con 2008, day 2 (Friday). Mick and I have run Vegas After Midnight (http://vegasaftermidnight.net) three times now, and it has been excellent. We have learned a lot of the rough spots, and already started sanding them down. We have loved all of our players, and a good portion of them we think are going to playtest for us. We are going to run it at least three more times before the end of the con, and I can’t wait to run them!

I’ve also done an interview for The Game Master Show (http://thegamemastershow.com), and ended up recording silence through my own fault. We also have played Hellas (http://hellasrpg.com), again, awesome – more to come on that front.

Ok, Erin is pulling me out to eat. So more later hopefully!

Popularity: unranked