ActionScript 3.0 :: State Of SharedObject Using Multiple .swf Files?

Apr 12, 2011

I have a multi .swf file project hosted inside a main container (let's call this main.swf) with each "child" .swf being loaded by a Loader object and placed on stage. One of the .swf files contains a game of sorts (let's call this game.swf") with the need to save the state of the game when other .swf files in the site are being loaded and placed on stage.
 
My question is thus: in implementing Local shared objects, what/where is the location on disk when I go to test the save state of the game? I'm interested for a couple of reasons. One is how I might be able to point a tool such as this: [URL] to look at shared object properties in the data member. Currently this tool points itself to the standard temporaty location on the hard disk. The second is to see why the following doesn't work:
 
Using the code in the main parent .swf file to clear out the data in the SharedObject instance seems to be getting different results when I use main.swf to do something like this: 

var so:SharedObject = SharedObject.getLocal("gameState");
var started:Boolean = false;
so.data.gameStarted = started;

[code]...

how should I be implementing shared object to manage game state if the user clicks on a button to load different .swf files inside the main .swf file but never leaves the actual "site" using multiple .swf files.

View 3 Replies


Similar Posts:


ActionScript 2.0 :: Multiple Checkboxes - SharedObject

Jul 18, 2006

I have Multiple checkboxes and a input box on a page and am trying to save there state to a SharedObject.

The Input text saves as per usual and I can output wether the checkboxes are selected to a another Input Text Field but this information will not save to the SharedObject - althought it will if i manually change the information.

View 3 Replies

ActionScript 3.0 :: Loading SharedObject Across Multiple Domains?

Jun 7, 2009

Let's say you wanted a flash movie to load the same SharedObjects no matter where it is accessed. Is this possible and how would you set up the parent movie to transport the SharedObjects?

View 3 Replies

Media Server :: SharedObject.NoAccess Error When Trying To SharedObject.getRemote?

Feb 18, 2012

I've installed developer version of Flash Media Server 4.5 and trying to get remote object, but no matter how I call my object all i get is this error .I've rad configuration guide and it told me that I should set StorageDir for shared objects, enable RPC (<RPC enabled="true">) and allow shared object (<Allow>users</Allow> in <RPC> - <SharedObject> tags)

View 1 Replies

AS3 :: Visible State On Multiple Button Instances

Jul 29, 2010

I have two instances of the same button on the stage (with the same instance name) and need to make them not visible.[code]but it only affects one of the two buttons. Can I keep the two instances with the same name and get both to be nov visible, or do I have to change the instance name for one set of the buttons?

View 3 Replies

ActionScript 3.0 :: Default State With Multiple Mouseovers?

Sep 16, 2010

I need to have a default state for a bunch of alpha-switched mouseover buttons. The buttons look like this;

ActionScript Code:
mygeartoothur_btn.addEventListener(MouseEvent.MOUSE_OVER, fl_MouseOverHandler_ur);
function fl_MouseOverHandler_ur(event:MouseEvent):void

[code]......

View 5 Replies

ActionScript 2.0 :: Multiple Rollout 'if' State Options Required

Jun 20, 2009

I have navigation set up, where on rollover of each button 3 separate movieclips are affected. On release another movieclip is effected and a swf is loaded. Fine so far - here is the code (where the first mclip is where the buttons are located and the command goes to a frame in that mclip, the 2nd mclip is called 'copy' and the 3rd is called 'date')(the mclip effected on release is called 'overs'):-

[Code]....

View 1 Replies

ActionScript 1/2 :: Multiple Rollout If State Options Required?

Jun 20, 2009

I have navigation set up, where on rollover of each button 3 separate movieclips are affected. On release another movieclip is effected and a swf is loaded. Fine so far - here is the code (where the first mclip is where the buttons are located and the command goes to a frame in that mclip, the 2nd mclip is called copy and the 3rd is called date)(the mclip effected on release is called overs):-

[Code]...
 
The last time i put a problem on to this forum, i also spent a long time pasting my code and trying to describe my problem in detail, i then received an email from someone asking me what my problem was! Please only reply with questions based on what i've put here, if it doesn't make any sense to you then don't worry about it. If it does make sense to anyone out there tho, or if you have a better way of turning rollover states on and off, please dont' hestitate to get in touch with me.

View 13 Replies

Flex :: Assign Multiple States As Base For Another State?

Nov 29, 2009

Is it possible, in flex, to assign multiple states as base for another state? Say I have state "stateA" that adds a button "buttonA" and state "stateB" that adds a button "buttonB". Is it possible to create a state "stateC" that is based on state "stateA" and "stateB"? If not, is there a workaround to accomplish that? Also notice that the button IDs should be "buttonA" and "buttonB" and I can't have several buttons in different states with the same ID ... Here is an example of what I want:

[Code]...

View 1 Replies

ActionScript 3.0 :: SharedObject Error: Error #2134: Cannot Create SharedObject?

May 9, 2011

Gives me this error:

Error: Error #2134: Cannot create SharedObject.
at flash.net::SharedObject$/getLocal()
at as3_shared_objects/showVar()

[code]....

View 2 Replies

ActionScript 1/2 :: Dynamic InstanceName - Link The State Id's In The Xml Record To The State MovieClips That Make Up The Map?

May 12, 2009

I have a flash map that contains 51 movieClips, one for each state.Sample instanceName for a state (Alabama) would be: S_01
 
I have a XML record that contains specific info for each state.<stateID>01</stateID
 
I am trying to link the stateID's in the XML record to the state movieClips that make up the map.var stateInstanceName = 'S_' + stateID;
 
I was just trying to do a simple trace command to see if I could pull the _width of each state clip to see if I was linked up:
 
trace(mapInstance.stateInstanceName._width)

View 7 Replies

ActionScript 3.0 :: Flex - Loading Page As One State And The Main Application Design In Another State?

Apr 9, 2011

It's my understanding that view states can be useful when switching the layout of design elements. Such as, a loading page as one state and the main application design in another state. Is this the correct use of them? Additionally, I have a label in State1 and I cannot figure out how to access that label via actionscript. labelID.text = "New Text"; is not working.

View 2 Replies

Actionscript 3 :: Adding A Rollover State To A Spark Button When State Is Disabled?

Apr 14, 2011

I need to add a rollover effect to the disabled state of a Spark button. This way, users can rollover the button and know why the button is disabled.I think I would have to override ButtonBase's getCurrentSkinState. Is there anyway to test if a mouse cursor is over a disabled button?

View 1 Replies

Flex :: Get State Group / Actual State Object For Current?

Mar 30, 2012

I'm using Flex 4.5 and trying to take advantage of the new state groups feature. I have two States (call them readType1 and readType2) that both belong to the same stateGroup (call it readOnly). There are several places where I'd like to do something based on the current state, and it would be the same thing for the two read states. [code]...

View 1 Replies

Flex :: Set Size Of State After Moved Child State Using AIR?

Jul 25, 2009

In my air project i used current state size is width="441" height="358" . i have link button like Singin then move to singin state (currentstate='singin')

<mx:State name="signin">
<mx:SetProperty name="height" value="616"/>
<mx:SetProperty name="width" value="919"/>

So application resize into 616,919 . After that function finished move to current state like(currentstate='') But size not be changed . How can i set the size for current state?

View 1 Replies

Flex :: Fade All The Elements Of The Next State When Transitioning From Any State?

Jan 27, 2010

I want to fade all the elements of the next state when transitioning from any state.I tried different things but I can't get it to work. And I don't want to manually add transitions for every state.

Something like:

<s:Transition fromState="*" toState="*">
<s:Fade target="*" duration="500" />
</s:Transition>

View 2 Replies

Flex :: Creating State Children Before Switching To State

Mar 25, 2010

In my view I have a welcome screen:

[Code]...

Which is a pretty small component and I have panelContainer:

[Code]...

Whilst the user is reading the warm and fuzzy welcome note in the welcome state I want to be creating the big expensive panels state so taht when we switch there is no delay. Before the panels state is set panelView is null but I presume there must be an IDefferredInstance floating around somewhere that I can use to kick off the creation of the view. How can I get hold of it?

View 1 Replies

ActionScript 3.0 :: Make One Sound On The Over State And A Different One On The Down State?

Oct 4, 2008

I am trying to get converted to Actionscript 3 from AS2.In old versions of flash, you simply placed the sound in a keyframe inside the button on the over or down state. Worked fine, but not anymore.I guess the sound must be set up with actionscript and a listener.I understand linkage. how to make one sound on the over state and a different one on the down state?

View 4 Replies

ActionScript 3.0 :: Save Multiple Text Files From Multiple Text Boxes?

Mar 2, 2011

As the title states, I need to know how to save multiple text files, from multiple text boxes on the screen. Each textbox has the instance name of t1, t2, t3... and so on. Here is the code I have now:

[Code]....

View 3 Replies

Flash :: Access State In Flex "Current State" From Movie Clip?

Sep 3, 2011

i curious how to access state in flex "Current State" from flash movie clip??..so far i make movie clip in flash and it has button inside with name " button" and i put this flash file into flex in "state 1" flex application..i want to make event handler for "button" that trigger changing state from "state 1" to "state 2" in flex application..and in flex application i do not write anything because i have no idea how to deal with this stuff..

View 1 Replies

CS3 Preload Multiple Files?

Feb 25, 2010

how can i make a preloader load multiple external (mp3) files before entering the site itself?

View 1 Replies

Play Multiple .swf Files One After Another?

Oct 6, 2006

I have two flash files that I would like to play back to back in the same location on my site. I would like one to play, and then when it's done, I want the other to play in its location.

I googled around and read up on the loadmovie variable, which I thought that is what I needed, but it isn't working.

To start out, what I did was create a new flash file, then I inserted an image into the timeline on its own layer, converted it to a movie clip (named pic_mc), did a fadeout effect on that image, then I created a new layer, and on the frame directly after the image, I put the following:

Code:

loadMovie("/images/preferred-reseller-hosting-0001.swf", "pic_mc")

I then ran a test (ctrl+enter) and all I see is the fade out image, and not the other flash movie. I even uploaded the .swf to my site and tested it there in a real world situation, and it didn't work. It just fades the image out and restarts the movie.

View 14 Replies

IDE :: Best Way Of Loading Multiple XML Files?

Dec 7, 2009

What is the best approach in AS3 when loading multiple XML files. I have 3 XML files I need to load. Should make separate XML loaders and functions for each XML file?

View 1 Replies

Storing Multiple Animation Files?

Aug 19, 2009

I want to have a TV screen and hundreds of (small) flash animations load up in the 'TV'. I'm assuming I'm going to have to use Actionscript, so I'm looking into that right now. However, what would be the best way to organise this? Each "TV" will have a different set of "Channels". Do I create each 'channel' and save them as seperate SWF files, or is it possible to have them all in one main file. I can then flick through each 'channel', which essentially unloads the current animation and loads the next one

View 2 Replies

Loading Multiple Jpeg Files

Jul 7, 2009

i'm making a simple portfolio site, and bringing in a series of jpeg files using a 'for' loop and the Loader class. once all the files are loaded in, i'd like to just be able to add, remove, tween, etc... the items from the stage as need-be by using instance names, such as movie clips or Sprites. but for some reason, i cannot seem to figure out how to have each image, as its loaded in, be separately accessable to me after the loop has completed.

View 10 Replies

Play Multiple Flash Files One After Another?

Nov 2, 2009

I have a series of animations of graphs etc in different flash files. Tried to put everything on the one timeline but was getting way too confusing so thought I would put each part in a separate flash file.
 
What I want to do is, once one file has come to an end load the next one up to play and so on. This is all part of a presentation so the user will click the keyboard to progress to the next file.

I'm using Flash CS4 on a Mac with Action Script 3.0.

View 38 Replies

Flash :: Should Have Multiple Swf Files On Different Webpages

Jan 29, 2010

I'm writing a small game app in Flash, and I'm wondering what the benefits of having one giant SWF loading everything vs multiple webpages and multiple SWF's.

View 1 Replies

Flex :: Possible To Upload Multiple Files At Once?

Jan 20, 2011

I need a component where user can click on browse button and select multiple files using ctrl key and upload them at once. Please note that it is dfferent from clicking add more files each time a file gets uploaded. Is it posible in flex?

View 2 Replies

ActionScript 3.0 :: Using The Same Object Across Multiple Swf Files?

Aug 4, 2009

I have 2 FLA files, a "menu.fla" and "game.fla"

In my "menu.fla" I create an object of my class:

var gameEngine:Engine = new Engine();

I click on a button in "menu.swf" to load my "game.swf" into the window...

I would like to know how can I use the "gameEngine" object in my "game.swf"?

Also, I have to code that runs on a "left-arrow" key-press in "menu.fla", but I also have some code running on a "left-arrow" key-press in "game.fla".

Once "game.swf" is loaded, and I press the "left-arrow" both the code from "menu.swf" and "game.swf" executes.. I only want the game.fla's "left-arrow" code to execute?

I also noticed that "game.swf" is basically layered over "menu.swf". Is there a more efficient way to load .swf files?

View 0 Replies

ActionScript 3.0 :: Navigation Between Multiple SWF Files?

Aug 20, 2009

I'm still working on this project and it got literally huge... at least huge enough to consume all of my 3 GB RAM memory and crash my Adobe Flash CS4. Anyway, I decided to put the site on several swf's but the problem is that I've never done that before so I have no idea how to navigate between them.

Basically I have a main swf file, inside it there's an image (let's say its instance name is "projects_btn") that should take me to "Projects.swf", and I want to click on an "x" sign (its instance name is "xSign_btn") inside Projects.swf that would take me back to the main swf file "Bnaider2.swf".

View 8 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved