Solved

movieclip at the end of flash game

Posted on 2006-07-12
10
223 Views
Last Modified: 2010-04-03
hi, i have some flash games, and a flash file that i want to show when the game end,
is it possible? how?
0
Comment
Question by:svsvsv
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
10 Comments
 
LVL 17

Expert Comment

by:Dushan De Silva
ID: 17092369
When the falsh game is over occured , you can call external flash file(swf) using loadMovie() command, with replacing old movie (level0) or overlapping it(level1level2,..etc).

BR Dushan
0
 

Author Comment

by:svsvsv
ID: 17094302
how do i detect the end of the game?
0
 
LVL 17

Accepted Solution

by:
Dushan De Silva earned 250 total points
ID: 17097631
You must detect it, inside the game.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:svsvsv
ID: 17097656
the problem is that i have 1500 diferent games, i won't start rewriting them all, i want to make a swf that will load up the game, and when it ends i want to load another swf...
0
 
LVL 7

Assisted Solution

by:muxxter
muxxter earned 250 total points
ID: 17111101
I'm affraid Dushan911 is right, if you want it to be loaded automatically, you have to get the games themselves to recognize when they're done. Surely the games have an end condition.

I'm not sure how you load the games, but if you had a "main" flash page that loads the games within it, you could have that main page define a _global function that can be called from within the game itself. It's actually not a lot of code:

In the game, add this one line to the finished condition:

_global.game_finished(<add parameters here as needed>);

Then, in the main flash page, add the following:

_global.game_finished = function(<optional parameters>) {
     // do stuff here
}
...

The "main" page doesn't even have to be that complicated, you could even just have it as a wrapper. So, it would do nothing but define the global function and load the desired game.
Also, if you already have something like that set up, all you'd have to do is add the function definition, and you'd be done.

MuXx
0
 
LVL 17

Expert Comment

by:Dushan De Silva
ID: 17112974
Yes, I don't think without editing the inside of game code you can't implement it. And even if you use shared objects also you must edit the games.

And as earlier suggested, after loading movies using loadMoive command with levels you can access that loaded movie's variables. But it depends  on the implementation structure of the game.

BR Dushan
0
 
LVL 12

Expert Comment

by:SamuelRostol
ID: 17477996
Hehe, if you have created 1500 games yourself, it's nonsence that you can't figure this out yourself!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I know the transition can be hard. We got used to the ease of use ActionScript 2 had, but honestly, it became problematic later on, especially if designers were involved in the project and found it easy to add code as they saw fit. So, this artic…
There are times in your Flash CS4 application when you want more than a simple pointer or a hand, and it's hard to find an ideal walk-through to tell you what to do.  I spent a few days recently learning my way around making custom cursors in Flash,…
The goal of the tutorial is to teach the user how to how to record live broadcast.
The goal of the tutorial is to teach the user how to set there setting in Adobe Flash Media Live Encoder and YouTube for optimal video and audio quality.

735 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question