"At first, dreams seem impossible, then improbable, and eventually inevitable." - Christopher Reeve
AS3 Calls to JavaScript
Author: Tommy Leung | 08.26.2008 | Category: Internet, Programming
I don’t write nearly as much programming help posts than I could be. There seems to be so much of them out there as it is. However, when I come across something that I think isn’t all that well known or clearly discussed, I feel compelled to release that information into the great unknown of the Internet.
So, I was doing a project that needed a Flash movie–coded in AS3–to make some calls to JavaScript for functionality that JavaScript is more capable of doing. There are various FSCommands that you can use in ActionScript but, nothing really suited my needs. I had some JavaScript functions that needed to be called when certain things happened in the Flash movie.
The quickest method I found for doing this is simply using navigateToURL(). You simply make a call to javascript:FUNC()wth target of _self. More specifically:
navigateToURL("javascript:FUNC()", "_self")
That’s it. :)
Sixx: A.M.
Author: Tommy Leung | 08.25.2008 | Category: Music, Videos
I went to see Motley Crue this weekend–Saturday, August 23rd, 2008– at the PNC Bank Arts Center. The Crue put on a great show. I personally love the sexual images mixed in with the political messages. What I took away most from the show was from one of the opening bands: Sixx: A.M. I knew nothing about this band until I went to see the show. Trapt, Papa Roach, and Buckcheery also opened but, they didn’t leave quite the same impression. Sixx: A.M. is Nikki Sixx’s–of Motley Crue–band. They played some great music and I went to find some more when I got home. They are pretty awesome. If you’ve never listened to them before, go do it now. :)
Here is a taste of their 1st single: Life is Beautiful:
Â
Silly Olympic Math
Author: Tommy Leung | 08.18.2008 | Category: Sports
The IOC can officially report that He Kexin of China won the Gold in the uneven bars event finals but, without some meaningful sudden death scenario, He Kexin and Nastia Liukin of the USAÂ should both have received Gold. Liukin and He both scored a 16.725 in the event–creating a tie–but, with some illogical mathematics, Liukin fell into second place and a received a Silver.
The first tiebreaker scenario made sense. The competitor with the higher execution score would place ahead. That makes sense since execution is meaningful in gymnastics. However, He and Liukin had the same execution score.
The second tiebreaker scenario didn’t make sense. The calculation of the execution score takes into account 6 deductions. The two extremes are dropped and the four remaining deductions are averaged and then subtracted from 10. This second tiebreaker drops the next highest deduction and averages the remaining three.
Do you see the ironic and illogical reasoning behind this? The Olympics is a competition to find the best athelete or to put it a different way: an athlete who makes the least mistakes. Deductions are bad. This tiebreaker takes the highest remaining deduction and gets rid of it. The person who made a bigger error benefits. Does that really make sense?
The Georgian/Russian Truth
Author: Tommy Leung | 08.15.2008 | Category: News, Politics, Videos
I put up a video at Tommy Liberty about a 12 year old girl who was in the area where the conflict between Georgia and Russia is occurring. She squarely places the blame on Georgia for attacking South Ossetia and causing all the death and destruction–she was actually thankful for the Russians. Watch it.
Knowing what we know, do we really want to get involved in this conflict? I’m saying that we should not put a base in Poland and send aid to Georgia.
US Women’s Take Gold, Silver
Author: Tommy Leung | 08.15.2008 | Category: Sports
About time! Our women’s gymnastics team took the gold and silver in the all around finals. The Chinese had won gold in the men’s team, men’s all around, and women’s team. The Chinese national anthem was becoming quite common in the gymnastics arena. We finally got to hear a different tune.
Nastia Luikin and Shawn Johnson took the gold and silver respectively. Yang Yilin of China took the bronze.
Tommy Liberty
Author: Tommy Leung | 08.14.2008 | Category: Internet, Politics
Isn’t that catchy? Tommy Liberty. In line with mission to create focused blogs on topics that I like writing about, I have launched Tommy Liberty as the place where I will keep my political writings. I’ve also put a tab in the menu above alongside my fitness blog. :)
Don’t Blame Sacramone
Author: Tommy Leung | 08.13.2008 | Category: Sports
Gymnastics is one of the events that I watch every Olympics and this time is no different. While our men’s team took the Bronze and were ecstatic about it, our women’s team took the Silver and the reaction was completely different. I’m not saying we should accept Silver and be done with it–our team is damn good and we should be aiming for the Gold. The Chinese team so happened to have been better on that day.
Alicia Sacramone would be the easy target to pick out and blame for our loss to China. NBC’s Johnny R explains why Alicia should not be blamed. She didn’t have her best performances at the team finals but, I’m sure she wanted to have done better–her reactions tell the story. There are still more events coming up for Alicia and other members of our gymnastics team. What we should be doing is supporting our athletes in their upcoming events.
There are still more Gold medals to be won and while the Chinese surprised us this time, we’ll be ready for them next time. :)
Categories
- Books (5)
- Business (17)
- Cartoons (1)
- Economics (16)
- Health and Fitness (3)
- Internet (23)
- Life (20)
- Marketing (18)
- Money (5)
- Music (4)
- News (4)
- Nightlife (3)
- Politics (29)
- Programming (4)
- Relationships (2)
- Science (2)
- Sports (4)
- Technology (3)
- Uncategorized (1)
- Video Games (12)
- Videos (14)





