ActionScript 3.0 :: Creating A Dynamic Grid?
Mar 26, 2011
I would like to create a simple 2D interactive grid. The user should be able to increase and decrease the number of axis (both X and Y simultaneously) that compose the grid, and also the scale of the grid itself (Zoom in and Out).
If this goes well enough, I would like to be able to plot graphical content on the grid that visually changes as the grid itself changes. They should, in some way, be linked to one another and correspondingly affected by the same two parameters. This, however, would be a second step. I am more concerned with the base grid model at this point.
View 1 Replies
Similar Posts:
Mar 24, 2011
I would like to create a simple 2D interactive grid. The user should be able to increase and decrease the number of axis (both X and Y simultaneously) that compose the grid, and also the scale of the grid itself (Zoom in and Out).
If this goes well enough, I would like to be able to plot graphical content on the grid that visually changes as the grid itself changes. They should, in some way, be linked to one another and correspondingly affected by the same two parameters. This, however, would be a second step. I am more concerned with the base grid model at this point.
View 1 Replies
Oct 12, 2010
So I'm making a game that uses blocks... I want to create an initial grid of blocks on the screen inside a grid container. as you move the grid container around, more blocks would be added dynamically to the grid... either to the left, right, or bottom.
View 1 Replies
Feb 19, 2012
I'm trying to make an application with flash builder that performs operations on square matrices. I take in the size of he matrix (n) but now, I am having difficulty figuring out how to generate an n by n grid of text inputs where the user can enter the matrix element values.
View 2 Replies
Mar 19, 2007
I really like the thumbnail gallery for its simplicity and beauty. But I would like to ad or vertical scroller (I'm unable to find it here too, maybe I'm blind, just I'm more at the end of my seeking options) or a make a grid thumbnails, that will show 2 columns of thumbs and 5 pictures in each columns, then under the 2 columns i would like to ad a sort of arrow or button that if my gallery have more then 10 pictures it will go on the next thumbnail list. I'm not looking for any extra fading effects or special movements. Just would love to have a single thumbnail grid on side, with option to have lists of thumbnails by 10 if there is more then 10 pictures or so.
View 14 Replies
Aug 10, 2004
i'm creating a grid and i can place everything in nice columns but i cannot figure out how to create a new row. here's the code i use:
Code:
var numColumns:Number = 7;
var columnWidth:Number = Stage.width/7;
[code].....
View 4 Replies
Jun 22, 2009
There's not that I can't do this, I just want the best way on how to. I want to create a grid in as3 and draggable items that snap to the grid. I guess you all know what I mean. The best way seems to create small boxes like explained in URL... Then add an addeventlistener to it that when the draggable item hits it, the x and y need to be set. Or is there an easier way?
View 4 Replies
Aug 8, 2003
I'm trying to create a grid of instances of (74x56) clips, and each one of the created instances must be named and numbered in an order so that it goes from left to right, top to bottom. I have been trying this with attachMovie and duplicateMovie, but unable to figure all out. can someone give me a hint?
View 14 Replies
Oct 29, 2004
I'm having problems creating a grid that will change individual movieclips' frame when rolled over when the mouse is down. My script seems to be acting erratically, when I push buttons, all of the mcs change even though the code to change them is onRollOver.Click on the "Create Your Own Map" button in the bottom left.Then you should be able to use the buttons in the bottom right to select the new color/value of the grid items.Here is the code I am using to do this:
Code:
_root.mouseIsDown = 0;
wallSel.gotoAndStop("wall");
pathSel.gotoAndStop("path");[code]....
View 12 Replies
Jul 11, 2004
I'm trying to create a grid of hexagons by using nested for loops. I picked up this code trawling the forums but this creates a diamond shaped pattern of hexes rather than neat rows that interlock together. I want to create one row in the first place, increment the x and y placing coords so as the next row is offset as appropriate to lock it into place under row above.
This is the code I'm using, which is clearly not doing the trick.
spacing = 35;
spacing2 = 35;
for (x = 0; x < 10; x++){
[Code]....
View 1 Replies
Jun 27, 2010
how to create a xml photo gallery but somehow all of them doesn�t discuss what i need to know. [code].....Especially i am interested in howto structure the xml for such an portfolio / gallery grid and having custom tweening for the thumbs to transition in and transition out, handling the click event for x thumb and loading the "big" content to a new container. Adding preview/next button functionallity to the Thumbnail Grid and for each "big" content and so on.
View 1 Replies
Feb 28, 2006
I just want to create a grid, this is the script:
MovieClip.prototype.drawRect = function(w, h) {
this.beginFill(0x006699, 100);
this.moveTo(0, 0);
this.lineTo(0+w, 0);
this.lineTo(0+w, 0+h);
this.lineTo(0, 0+h);
[Code] .....
View 5 Replies
Nov 7, 2009
I am working on a project where I need an interactive matrix of 500x500 clickable elements. I thought this would be an easy task in actionscript3 but boy was I wrong. I was able to create a matrix where each element was a Sprite object with attached Mouse click event. But here the performance problems begin. FlashPlayer10 can handle up to 100x100 matrix, but when I increase my matrix I start getting script timeout in browser player... Here is how my "unfinished" matrix looks like.So how should I approach this problem? I was hoping flash will be able to handle so many elements, but I guess I was wrong. I want to have a pan control to pan around for objects off screen and of course zoom in/out control.It's true I'm not very professional in Flahs and actionscript but a friend who is told me this would be no problem implementing in AS3? I need this in flash as the thing needs to be hosted on website.
View 6 Replies
Nov 7, 2009
I am working on a project where I need an interactive matrix of 500x500 clickable lements. I thought this would be an easy task in actionscript3 but boy was I wrong. was able to create a matrix where each element was a Sprite object with attached Mouse click event. But here the performance problems begin. FlashPlayer10 can handle up to 100x100 matrix, but when I increase my matrix I start getting script timeout in browser player... Here is how my "unfinished" matrix looks like.
So how should I approach this problem? I was hoping flash will be able to handle so many elements, but I guess I was wrong. I want to have a pan control to pan around for objects off screen and of course zoom in/out control.It's true I'm not very professional in Flahs and actionscript but a friend who is told me this would be no problem implementing in AS3? I need this in flash as the thing needs to be hosted on website (unless there is a better tool for doing something like this...).
View 12 Replies
Mar 10, 2011
I have a grid made from dynamic boxes and I need to check each box to see if it is selected or not to perform a function..
Problem is I have 60 boxes in the grid - in the code below, there are only the boxes which need to be selected !
I still need to add the other 54 boxes and set them as .chosen = false;
Surely there's a more efficient way of doing it than my code ??
if(event.currentTarget.parent.getChildByName("m1").chosen == true && event.currentTarget.parent.getChildByName("m2").chosen == true && event.currentTarget.parent.getChildByName("m3").chosen == true &&
[Code]....
View 6 Replies
Apr 15, 2010
On GridItem object there's a colIndex and on GridRow a rowIndex. But both are declared internal so I do not have acces on that information.
Is there another way to get the position of an object in a grid.
View 1 Replies
May 28, 2010
I am trying to create a dynamic datagrid in Flex 3, I have a list of columns a list of objects which correspond to datapoints for those columns which I fetch from a url. While the grid works perfectly fine the problem is that sorting on the columns is done in lexical order.[code]...
View 1 Replies
Feb 24, 2011
I want to make a grid where i have set width and height for each cell in a grid..
but I want to be able to include colspan and rowspan so that i could have boxes that are 1x1,1x2,1x3,2x1,2x2, etc.. pretty much whatever amount of boxes that i want each cell to take up..
creating a grid of 1x1 boxes is easy .. but when I start throwing in the different sizes .. i am not sure where to start..
my first idea was to have it iterate through each possible cell and then create an array of cells that have a list of cells that it takes up.. that way i can iterate and search to see if that particular cell space is taken when i place cells of different size ..
View 0 Replies
Jan 3, 2008
I'm trying to add a new row to dynamically created thumbnail grid. So far I've copied and edited a BrainGiants PhotoDrop menu script and managed to add an new row there with a nested for loop, but the thumbnails on the new row won't show right. There's just one thumb showing, I guess the rest of the thumbs are beneath the one showing..I'm messing up the for loop somehow, but can't get a hold of it.. I know all the thumbs load fine cus I've tried to load them to just one row and all of them showed up properly.
[Code]....
View 1 Replies
May 11, 2010
I have a store style website that uses a grid format gallery to display a grid of thumbnail products which can then be clicked.url...I have created xml captions that sit ontop of each thumbnail in the grid. They display fine when static but I wanted them to only display when you mouse over the corresponding thumbnail.I have code that tweens all of the captions (thumb_caption) to 0% alpha and the tweens to 100% alpha upon MouseOver and then back to 0% alpha on MouseOut.At the moment there is one problem - When you hover over ANY thumbnail the caption for the LAST thumbnail fades in not the corresponding one for THAT thumbnail.Example - if I have 10 thumbnails and I hover over thumbnail 1 the caption for thumbnail 10 appears ontop of thumbnail 10. (not caption 1 over thumbnail 1 like it should!)[code]
View 1 Replies
May 28, 2011
I need to create a dynamic pixel grid controlled by a slider. That means I need a grid (for example 10x10 rectangles) and you should be able to scale it (by the slider) for example to a 100x100, 50x50, etc. rectangles grid..
View 28 Replies
Apr 3, 2006
i want to display a grid of video thumbnails, whose parameters are loaded from XML. the number of TNs is variable but the area in which to display them is of a fixed size. i'd like the number of rows/columns AND the TN's size to vary to fill the available space, whilst maintaining the TN's aspect ratio e.g. display area is 200w x 300h and there are initially 10 TNs (which are 4:3 ratio, say): 3 columns and 4 rows of TNs 62 px x 46 (i think) but if the number of TNs goes up to 30, or down to 3, i want the code to adapt, to give me a 6 x 8 grid or a 1 x 2 etc.
View 4 Replies
Dec 16, 2005
Im using this xml "data.xml":
HTML Code:
<XML>
<salesreps>[code]...
I want to generate a mc for each rep with 6 text fields containg the 6 values for eash rep.So for this xml there would be 3 mc's with 6 text fields in each. This is one of my first times really diving in to xml parsing in Flash.
View 3 Replies
Jun 16, 2003
I really like the text effect Pom used in the footer contest, and would like to use the same grid-type method of creating mc letters but with a different effect. i understand how to change the parameters and shapes of the letters, but can't seem to figure out which piece of code is purely for the explosion effect. basically, i want the letters but with the 'Repel' effect from[URL] here is Pom's AS:
[AS]
cellSize=3;
radius=10;
damp=.85;
[code]....
and here is the .fla using the repel effect using pre-made mc:
View 6 Replies
Dec 28, 2009
Is it possible to create a dynamic xml file which changes in some fields to populate an advanced data grid?I have to display continents, countries, society and its values but i want to change randomly only the value and not all toegether...The client side application call the database by an asynchronous httpservice.LCDS, Blaze or similar are not allowed.
View 1 Replies
Feb 3, 2012
I'm currently working with the OLAPDataGrid component and got stuck at a relatively simple task: I want to style the last row of the grid differently from the rest, so my cell item renderer needs to know whether he's rendering the last row with content in the overall grid, including those rows currently not rendered because they are outside the visible grid space. AdvancedGridListData's rowIndex property only gets me the row index of the renderer relative to the range of visible grid rows, i.e. when I scroll down the grid, a data item with an index greater than 0 gets the rpw index = 0.
View 2 Replies
Oct 9, 2009
I need to create a simple multiplication grid where children will fill the grid. Its an empty grid at the begining, when they start the time start as well.Its a grid of 10 x 10. when they enter the last number, the grid should show what they did wrong and the time they spend. It's an idea of how it could work but if anyone has something that looks like this.
View 6 Replies
Jul 5, 2011
I want to make a square grid of fixed side length but varying grid number using code.That is, the number of grids should be specified by the user (say 3*3) and after pressing a button, the stage should be broken into 3*3 grids.I don't want any code, just a method on how to do it. I have tried it by using simple loops but the method just fails for no reason I can figure.
View 5 Replies
Mar 31, 2010
Whenever I add paddingRight to a column in the flex grid, it adds the padding to the header as well.Is anyone familiar with how I can add paddingRight just to the column and not to the header? Below is the column code where I was specifying the padding.
<mx:DataGridColumn width="60" headerText="Type" dataField="Grade" headerStyleName="headerLeft" textAlign="left" draggable="false" resizable="false" headerRenderer="GridHeaderRenderer" paddingRight="5"/>
View 1 Replies
Sep 24, 2009
I have a mx:Grid component in my flex application. But I would like to resize it by clicking and dragging in the border. This component doesn't allow doing that.I want to put a panel in each gridItem of this Grid component and resize it.
View 1 Replies