Actionscript 3 :: Flash + Box2d Pool Game Breaks Online Because Shots Are Not Transmitted Precisely?
Dec 25, 2010
I'm, working on this pool game: [URL] open it in TWO browser windows you will see that the 2 player modus starts. When you make a shot, every shot gets copied to the other player. Unfortunately it is not precise enough. The player makes the shot with this code:
[Code]..
View 2 Replies
Similar Posts:
Jan 22, 2011
I play games on Pogo and have never had a problem with their Flash Games until released Daily Hot Shots. It doesn't load fully and I've done EVERYTHING I know to do to get it to play. No errors show up. I can play ALL the other flash games but this one. When I right click, the name of the site's owners do not show up....I have the settings showing though Not all of the game loads and that's the problem. I've tried uninstalling and reinstalling....tried a different browser and have the same exact problem. THIS GAME WILL NOT PLAY.
View 2 Replies
Dec 15, 2010
Here is my pool game engine done in Box2dFlash.I would like to make this simulation more realistic as I received mixed opinion from pool experts.Here is my standard wall setting:
var leftWall = _sim.addBox({x:0.9, y:8.15, width: 0.6, height: 11.5, density: 0, fillAlpha: wallAlpha, lineAlpha: wallAlpha});
And of the ball:
_solidBall_7 = _sim.addCircle({x:ballPosX - (ballRadius * 5) - 0.8, y:ballPosY, radius:ballRadius, density: 0.1, linearDamping: 1, isBullet: true, restitution: 0.7, angularDamping: 5, skin: Solid_Bordo});
What other params I might try to improve the realistic movement of the pool game?
View 1 Replies
Mar 19, 2010
As you can see on [url]...the last part of the Flash movie seems to be broken. Oddly enough, when I take the embedded SWF and view it separately[url]...
I'm not a flash expert, I don't know what can go wrong with embedding etc. but the actual FLA file seems to be ok, the map layer that is coming through randomly at the end shouldn't even be there! The frames at this point of the timeline on this layer are actually empty.
View 11 Replies
Nov 20, 2010
There are a lot of flash games that ask u to do repetitive actions. An example would be FarmVille or getting statistics on on-line poker game. What is the best way to create an interface between what you see on the screen, a bot's algorithm and clicking of the mouse. So basically, when I'm playing a texas hold'em on face book and if I get AA I want the bot to click all-in. If I don't get AA I want to fold. This is just an example, not the actual strategy. Or another examples would be routing tasks in farmville. So basically. It has to grab a picture of the screen. recognize patterns and convert them into an input of the algorithm. The output algorithms would be clicking on some other (may be same) patterns.
View 1 Replies
Aug 27, 2009
If we made a game in flash that has online, would it cost money to have the online server or something?
View 3 Replies
Jan 12, 2011
I'm trying to develop a simple Flash game using Actionscript 2 (I know its a bit dated, but its a simple project that doesen't benefict much from AS3), and I came up with an ideia of implementing an online leaderboard that records and shows the highscore of the player.
This isn't anything too complicated, but I seem to be having problem finding resources online that explain how I should implement this. All I want is a call, probably to a PHP/MySQL database that records the player's name (which will be recorded via a input window) and its current score. It would also have to show the best all time scores, by order. I should remind you that I am working on a Actionscript 2 so Actionscript 3 solutions are probably not going to work.
View 2 Replies
Jan 12, 2011
I want to know if there is any way to creat an online multiplayer game using flash or flex (flash builder).
View 1 Replies
Mar 20, 2011
I'm to make a clickable map divided in regions, where it is possible to see some info when you rollover the precisely defined regions, and when you click on that region > go to a specific website. Is it the best way to make this in Flash or are there other or easier ways?
View 1 Replies
Oct 4, 2010
I am going to create a online game, so what is better, JavaFX or Flash?
View 3 Replies
Mar 13, 2009
I want to make a multiplayer flash game- something very basic, like each person controls a dot which they can move around (doing this as a learning experience, not because it seems like a great concept for a game ). I'm pretty new to PHP and mySQL, and don't have a lot of experience in making flash apps that interact with outside scripts... and here's the approach i've thought up so far.i design the swf so that every 30th of a second or so it checks an xml file on the server (http:servernamedata.xml), and also sends a request to the server to run a php script and sends it four boolean values (which keys the player is pressing). The php script runs- it loads a mysql database which has each players x/y coordinates, adjusts those coordinates according to the bool (if player is pressing keys), resends the x/y coordinates to the mysql database, and generates an updated version of the xml, which the swf running on each players client computer will check to determine where to draw each dot.So to get to the point, what i want to know is:
1: is what i described even possible?
2: if it can be done, is this a good way to go about it or is it horribly innefficient (i eventually want to make games more complicated than moving dots around, and have as much code run server-side as possible to prevent hacking/cheating)
3: if this is a possible and OK way to do this, what sort of AS3 script do you use to make a flash app have a server execute a php script?
View 8 Replies
May 31, 2011
if anyone knows of any great tutorials on building an online mulitplyer game
View 1 Replies
Nov 22, 2003
I'm making an online game where you can walk around in a city, and you see the others walk around as well at the same time. I made the script in php. The problem now is: I'm loading vars from flash out of the php-file, I know I can fool the cache by adding a unique number to it. That works, but I'm loading the php-file every second and if you look at your temporary internet files, you get a list of maybe thousand times the same php-file. In the beginning that didn't really matter, but now when I look at my site stats the list is like 5000 pages long... There must be an other way to fool the cache. And I was thinking about an old html-tag I used once to make sure your html-file wasn't loaded from cache: [URL].
View 1 Replies
Jan 25, 2011
When is it a good idea to use an object pool in Flash? For example, is it a good/bad idea with bitmaps, MovieClips (with timeline animations inside of them), video, fonts?
View 1 Replies
Dec 28, 2011
I'm having trouble setting up my object pool. I created a "BallPoll" custom class to handle the pooling logic. I first call fillPool() to add 20 Ball objects into my array. Then in my document class when I want to create a Ball, I check the pool array. It isn't working and I'm not sure why.
[Code]...
View 1 Replies
Oct 27, 2009
I'm developing a multi-player game and I know nothing about how to connect from one client to another via a server. Where do I start? Are there any whizzy open source projects which provide the communication framework into which I can drop my message data or do I have to write a load of complicated multi-threaded sockety code? Does the picture change at all if teh clients are running on phones?
View 4 Replies
Jan 20, 2010
I am wanting to create an effect like the following site.If anyone has any idea on how to do this effect, I would be very greatful to hear from you.I am using Flash CS3.[URL]
View 2 Replies
Jan 27, 2009
How do u get the swf to fit precisely in the browser window? I looked here:
[URL]
View 5 Replies
Sep 22, 2009
I want trace every event on every object, there is way to do it?
View 2 Replies
Jul 11, 2010
I've been looking on the net for some time now (about 4 weeks on and off) and i've come across various ways of producing high score tables for both online and offline games. My query is:
Is it possible to produce a high score table for an online game using a document in the same location as the swf without using a PHP, SQL or any of the like languages? Either using a text document, xml, another swf or something else like that?
View 1 Replies
Jan 20, 2010
I am wanting to create an effect like the following site.I am using Flash CS3.[URL]
View 2 Replies
Aug 19, 2010
I have a function with Enter_Frame running and have it tween during the function. I know you could use object.y=object.y + 1 instead of the TweenLite i'm using now. But TweenLite gives the best effect I wanted. My problem now is, I wanted to remove the enter_frame function when its not collision each other. But when I traced hitTestObject, it have like a split second where the hitTestObject result return 'false'. So the tweening can't really finish 1st, and remove enter_frame run early while the object is still collisioning.
private function checkCollision (e:Event):void
{
//detect collision in array
[Code]....
View 1 Replies
Jan 3, 2011
I'm making a game like Arkanoid and to move the ship with mouse, I'm using the following code :
var mousex:int = costume.stage.mouseX;
if (mousex < paddleWidth/2)
mousex = paddleWidth/2;
else if (mousex > PhysiVals.STAGE_WIDTH - paddleWidth/2)
[code]....
Everything's going fine there! The paddle is moving the way it should! The problem is I want a little inclination towards the direction its moving and when it stops moving the angle of inclination should become zero.
View 1 Replies
Jul 24, 2011
I'm working on a AS3 Game Engine at the moment utilizing Box2D (2.1a) and 2D shadows. I have Box2D down but I've yet to find a way of drawing 2D shadows efficiently.I was following this tutorial only to be disappointed by the speed at which it rendered the Box2D shapes and the shadows.I was getting the vertices of the objects via this function:[code]And using it to draw the shadows via the AS3 graphics api.Can anyone recommend me a better more efficient way of programming 2D shadows?
View 2 Replies
Feb 13, 2011
I have a b2PolygonShape body and apply a force to it.
_recbody->ApplyForce( b2Vec2(6.0, -6.0), _recbody->GetWorldCenter() );
I want to change the centre of rotation of the body to be more in the front of the body. So that applyForce and also collisions make the body not turn in the centre but more in the front.
View 2 Replies
Apr 14, 2011
I'm making a Flash game, and I've encountered a really weird problem while trying to draw a polygonal shape in Box2D.
Here's the code I use:
var fixtureDefs:Array = new Array();
...
var fDef:b2FixtureDef = new b2FixtureDef();
fDef.density = 0;
[code]....
Where vertexArray is a valid array containing 4 b2Vec2 vertices, making up a convex shape.The problem is, when I test, collisions don't work right for that body. Most other objects -enemies, user-controlled characters - pass straight through, as if the body isn't there at all. Some raycasts pass through as well.
Infuriatingly enough, one kind of bodies I have (a custom enemy) somehow does detect the body and collides with it. The raycasts that particular kind of enemy attempts do work - when your character hides behind the polygon, it's like they can't see him.The other weird thing: when I try the same code, only go for SetAsBox instead of SetAsArray, it works exactly as it should.I'm using a custom ContactListener class, but I haven't done any contact filtering (unless it's possible to do that without realising).I'm using the Flash 9 version of Box2D 2.1a.
View 2 Replies
Jul 26, 2011
i'm using flash with box2D 2.1a. i'm rotating ball hanging on the string. The path which the rotating ball trace is ellipse. When releasing the rotating ball from the string i want the ball to fly with the obtained direction, velocity and strength. As you can see in the pictures.[URL]..I've tried to do it with setPosition (method of b2Body) and with various joints. But I haven't got the needed results.
View 2 Replies
Jan 12, 2012
I know that trying to model character movement in Box2D is always hard/impossible, but I'm trying to see if there's any way to make an user-controlled object that cleanly slides against other objects, going up or down, that makes it look like the character is climbing/walking up or a down. The character could be modelled as a circle if that simplifies matters, but I don't see how I could get this effect using just a circle with a joint motor.
There's a "wheel joint" in the C++ version of Box2d, which I suppose I could port to Flash, but I don't know if that would give the correct effect either. Another idea I had was to have the character do little jumps, based on the normal of the object that it is touching. But I suspect that at corners, or at contacts with multiple objects, this will give weird results.
View 1 Replies
Jan 13, 2012
Is it possible to modify a shape within a body after assigning it, for example I have a box shape for my game hero body, and when I press the down arrow I want my hero to crouch witch means that I need the body shape to be resized.
I've already searched in google but it appears that the topic of modyfing shapes is not so popular. If it's impossible maybe you know a better way of doing this.
View 1 Replies
Mar 9, 2012
I want to know if box2d b2BodyDef has a massdata property or if it can be accessed in some way. I am not sure whether this can be done in Cocos2D but I have seen it in the flash code I am trying to re-implement in cocos2d.Here is the the code that brought about the question.
[Code]...
View 1 Replies