3 Replies Latest reply on Nov 24, 2006 1:56 PM by geraguilar

    usinf flash onto send me message

    geraguilar
      hi, i'm using flash SWF onto director and clicking a button send me a message: A Fatal ERROR has occured, Director will close now (some like that), Do you know why is this?
        • 1. Re: usinf flash onto send me message
          Level 7
          What functionality does clicking the button perform?
          • 2. Re: usinf flash onto send me message
            geraguilar Level 1
            I'm using in the AS code of flash functions to call event handlers ( button.onRelease = function () { ... } ), also several other functions, i think this is not the problem. I am using mp3 sound and movie clips attached from library, the corious is that in other games it works fine. Belive me, i can't find the problem. when i run director with the game-flash embebbed program send me a message: Dir crash it have to be closed -> next... Warning! Director is complety out of memory and must exit inmediatly. Save changes...
            • 3. Re: usinf flash onto send me message
              geraguilar Level 1
              Wow! i find something... error ocurred while streaming sound

              I use a mp3 sound which is been attached from library to stage, this one weight 127 kb, if i optimaze it and put the file size down finally works, the problem is that the quality sound decrease xtremly! ... reading a few in the director help find a case:

              clearError ()...
              ---
              Example
              This handler checks to see if an out-of-memory error occurred for a Flash cast member named Dali, which was streaming into memory. If a memory error occurred, the script uses the unloadCast command to try to free some memory; it then branches the playhead to a frame in the Director movie named Artists, where the Flash movie sprite first appears, so Director can again try to play the Flash movie. If something other than an out-of-memory error occurred, the script goes to a frame named Sorry, which explains that the requested Flash movie can’t be played.

              -- Lingo syntax
              on CheckFlashStatus
              if (member("Dali").getError() = #memory) then
              member("Dali").clearError()
              member("Dali").unload()
              unloadCast
              else
              _movie.go("Sorry")
              end if
              end

              // JavaScript syntax
              function CheckFlashStatus() {
              var ge = member("Dali").getError();
              if (ge = "memory") {
              member("Dali").clearError();
              unloadCast;
              _movie.go("Artists");
              } else {
              _movie.go("Sorry");
              }
              }
              See