How can i make the avatar bounce into a wall, in the avatarChat
please answer me, i will buy the product but i need to finish the chat, and i only need that!!
please, help me
How can i make the avatar bounce......
- JarochoCity
- Posts: 180
- Joined: 01 Dec 2005, 01:22
- Location: Mexico
- Contact:
Here's a good tutorial about making objects bounce --> http://www.flashkit.com/board/showthread.php?t=544413
- JarochoCity
- Posts: 180
- Joined: 01 Dec 2005, 01:22
- Location: Mexico
- Contact:
Yeah, i now how to do it but i dunno what......
Yeah, i now, but how can i do it in the Avatar Chat!?¿
All I can say is that once you have understood the simple code involved in making an object bounce you can apply it everywhere.
You will obviously need some basic knowledge of Actionscript and of the Flash authoring tool.
Also I'd reccomend to take the time to study the "Avatar Chat" tutorial and its source code.
Good luck
You will obviously need some basic knowledge of Actionscript and of the Flash authoring tool.
Also I'd reccomend to take the time to study the "Avatar Chat" tutorial and its source code.
Good luck
- JarochoCity
- Posts: 180
- Joined: 01 Dec 2005, 01:22
- Location: Mexico
- Contact:
Yeah, but i dunno what....
Yeah, of curse, but there is a problem i dunno wich instanse name i need to use, can you help me?
i dunno the instance name of the avatar, is attached to avatarMC but, if use that instance everyone is going to move..
i dunno the instance name of the avatar, is attached to avatarMC but, if use that instance everyone is going to move..
Also, something to think about is that the mostion of the avatar is determined by some sort of A* pathfinding routine. If you don't need that to walk around objects or somthing like that, you will want to create your own function for moving the avatars.
For example, you would use the sendObject function to send a new coordinate that you want your avatar to walk towards. The other clients will receive this and start the object traveling in this direction by continually changing the _x and _y properties of the MC. You could actually create an XSPEED and YSPEED so that the character contiunes in this direction until it reaches a wall, then you would just invert both speeds to create a bounce, and maybe multiply times -.95 to reduce the speed a bit on the bounce.
Hope this helps
For example, you would use the sendObject function to send a new coordinate that you want your avatar to walk towards. The other clients will receive this and start the object traveling in this direction by continually changing the _x and _y properties of the MC. You could actually create an XSPEED and YSPEED so that the character contiunes in this direction until it reaches a wall, then you would just invert both speeds to create a bounce, and maybe multiply times -.95 to reduce the speed a bit on the bounce.
Hope this helps
Carl Lydon
Illustrator, animator, programmer
----------------------------------------
www.gametrust.com
www.chamberofchat.com
Illustrator, animator, programmer
----------------------------------------
www.gametrust.com
www.chamberofchat.com
Return to “SmartFoxServer 1.x Discussions and Help”
Who is online
Users browsing this forum: No registered users and 35 guests