A Flash Developer Resource Site

Results 1 to 16 of 16

Thread: F5 SDK

  1. #1
    Junior Member
    Join Date
    Jun 2000
    Posts
    22
    has any1 been able to insert an actionscript function in the swf?
    and then a button that triggers that function?

    Or has some examples that do this?

    arTleVark




  2. #2
    Senior Member
    Join Date
    Jul 2000
    Posts
    503
    Yes. However, the actionscript functions in the Macromedia SDK are broken. You must fix them if you want to use it. I cannot give you a bugfix list, because according to Macromedia it voilates the license agreement. Recommendation: switch to the SWFSource SDK.

    Additionally, Flash5 Actionscript is not supported in the Macromedia SDK. The Create Function action tag is part of the Flash 5.0 specification. Recommendation: switch to the SWFSource SDK.


    --Jesse

  3. #3
    Member
    Join Date
    May 2001
    Posts
    70
    Do you mean that you cannot create swf file(using the SDK for flash 5) with attached action script to some of the objects in it?

  4. #4
    Senior Member
    Join Date
    Jul 2000
    Posts
    503
    Depends on which Flash 5.0 SDK. You cannot use Flash 5.0 Actionscripts with the Macromedia "flash 5.0" SDK. They are not supported (it is actually almost exactly like the flash 4.0 SDK...the only real difference is that the documentation on the file format structure that is included with the SDK is updated for most of the flash 5.0 stuff).

    The SWFSource supports Flash 5.0 Actionscripts.

    --Jesse

  5. #5
    Senior Member
    Join Date
    Jul 2000
    Posts
    503
    PS: As far as other non 5.0 actions are concerned (tags from flash 4.0 and below), the MM SDK supports them...but many of them just don't work at all because of bugs in the MM code that cause invalid data to be written to the SWF file.

    --Jesse

  6. #6
    Member
    Join Date
    May 2001
    Posts
    70
    Ok I have your SDK in place and working. I want to make something very simple. I have a movie in flash with one movie clip inside and some action script in it, and I want to make that using your SDK. How(at least the generic idea)????
    You don't have a movie clip object and another thing is you don't have support for loadmovie too.
    What if I want to load/unload an external movie at some point???

  7. #7
    Senior Member
    Join Date
    Jul 2000
    Posts
    503
    Of course I don't have support for either. Niether does the flash file format or any other SDK based on the Flash File Format.

    FlashTagDefineSprite is what you want for a "movie clip."

    Load Movie is accomplished by using the GetURL command ("The special target names '_level0' and '_level1' are used to load another SWF movie into levels 0 and 1 respectively" (MMFFSDK DOCS)).

    --Jesse

  8. #8
    Senior Member
    Join Date
    Jul 2000
    Posts
    5,087
    FS commands are sent using the GetURL command as well (You won't find that in the documentation). I think the Load Variable action is also but am not sure on the syntax. Jesse what is the syntax for the load variable action?

  9. #9
    Senior Member
    Join Date
    Jul 2000
    Posts
    503
    For load variables:

    ActionGetURL2

    Method:
    0 = None
    1 = GET
    2 = POST

    1. Pops window off the stack. window specifies the target window, which may be an empty string to indicate the current window.

    2. Pops url off the stack. url which specifies the URL to be retrieved.

    3. Method specifies the method to use for the HTTP request.

    o A value of 0 indicates that this is not a form request, so the movie clip’s variables should not be encoded and submitted.

    o A value of 1 specifies a HTTP GET request.
    o A value of 2 specifies a HTTP POST request.
    o If method is 1 (GET) or 2 (POST), the variables in the current movie clip are submitted to the URL using the standard x-www-urlencoded encoding and the HTTP request method specified by method.


    --Jesse

  10. #10
    Senior Member
    Join Date
    Jul 2000
    Posts
    503
    FSCommand syntax (for those interested)

    GetUrl("FSCommand:function_name","parameter");

  11. #11
    Junior Member
    Join Date
    May 2001
    Posts
    5

    SWF sample needed. Thanks.

    Anyone has SWFsource samples like the SwingSet in Java SDK 1.2 that can be shared with ?
    Thanks.

    Nobix

  12. #12

  13. #13
    Junior Member
    Join Date
    May 2001
    Posts
    5
    I am sorry that I didn't make it clear.
    What I meant is a comprehensive sample program using SWFsouce.
    For example, the SwingSet has lots of sample for how to use those GUI classes in Swing. So does Flash 5.0 sdk (but it got too many bugs.)


  14. #14
    Senior Member
    Join Date
    Jul 2000
    Posts
    503
    Not too many examples available yet (I am concentrating on finishing the library first). I am working on this, but they will come slowly as the completion of the library is more of a priority than the developement of examples for it right now (once in the import stuff and the exception handling is done, you can expect examples and better documentation to pop up fairly quickly).

    There is the simple image converter application up on the site now. Main.cpp also contains some commented source code illustrating the usage of many functions of the SDK. Also, you can now download some simple docs off of the SWFSource site too (the entire class heirarchy is listed).

    However, any examples in the Macromedia SDK can easily be converted to the SWFSource SDK (the classes are almost identical in usage, since they are based off of the flash file format).

    If you need something illustrated, just ask and I'll try to demonstrate it.


    --Jesse

  15. #15
    Member
    Join Date
    May 2001
    Posts
    70
    Hi I as abble to create a sprite and load an image into it but the really interesting thing is, can I load an external swf file into this sprite for example with GetUrl and how(if possible)?
    And the other question is how can I control in which frame to create/show the sprite and how to control it's properties (change it's position,duplicate,delete).
    The basic idea was to load a couple of external swf files and then position them and to be abble to control them(x,y,z-order).The swf files have prebuilt internally action scripts.

  16. #16
    Senior Member
    Join Date
    Jul 2000
    Posts
    503
    I've never tried to use load movie in a sprite...give it a shot and see (the docs don't say it is illegal).

    You can control position etc. in two ways:

    1) Use placeobject and remove object tags.
    2) Use action tags (SetProperty)

    --Jesse

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center