Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[as3 - starling] help request

Status
Not open for further replies.
Banned
Banned
Joined
Dec 17, 2011
Messages
470
Reaction score
245
Hi all, i want to say that i am so stuck!!!
I wander if any of you knows how to fix this problem:
I am building a 2d space shooter multiplayer game and i need to know what is the best approach when it comes to rotation of spirits.
REMOVED
The black grid is the map.

The yellow square is your screen.
The normal space craft is your player
The red craft is your enemy.

the first example is how the game starts.

The second yellow screen example is how the game should act when you turn the ship to right.

Any example is highly appreciated or a function even if you want i can pay for solving this problem.
 
Experienced Elementalist
Joined
May 10, 2015
Messages
278
Reaction score
146
Rotate even the screen's view is going to be really difficult to do imo because you have to rotate the whole world (so aswell it's objects).
I think the best approach should be the rotation of your spacecraft without rotate the screen view, this should be easy if you applied a good management of those "objects" in your code ;)
 
Banned
Banned
Joined
Dec 17, 2011
Messages
470
Reaction score
245
ty for replay i fixed the issue, but now i am having troble with animating the other space ship in real time (moving,prediction, interpolating) xd
For those who want the answer is simple:
move pivotX and y to where your char is then rotate the map
 
Joined
Jun 8, 2007
Messages
1,985
Reaction score
490
but now i am having troble with animating the other space ship in real time (moving,prediction, interpolating) xd

That's a tough part in multiplayer game design over the internet or a slow network.

If things shoot projectiles, you should definitely go with dead-reckoning there. But the spacecrafts themselves should probably be interpolated. Basically, anytime something is going to move in a predictable way, you should try to use dead reckoning. If the thing moves unpredictably, (for example using the arrow keys or mouse-move events), you're kind of forced to use interpolation.

If you are using interpolation, I suggest using artificial lag to test, and play with the numbers. I find artificial lag helps, but is insignificant compared to real-world testing with multiple players with different internet speeds and different PC specs.
 
Status
Not open for further replies.
Back
Top