MMOCC the isometric world scene, 2006–now
Archive. Archived from the original MMOCC Forum (2006–2010), recovered from the Internet Archive. The forum is read-only history now — the scene talks on Discord. If you posted here and want something removed, get in touch.

[AS] One avatar per tile

11 posts · vBulletin era
#1
The user dont' move!!
#2
Hello! I have muy own MMOCC made in flash like bittybay or HabboHotel but I have a trouble with avatars; Avatars are devolved, are not solid, and I would like to solve this problem, such as in the examples of TonyPaa, the example ISO MOUSE (tut1.

Ex:
If an avatar are in tile x: 2 y: 2 With another avatar I click x: 2 y: 2 the avatar wals to the tile but don't stop one after, the two avatars in the same tile
#3
Dunno. And if statement?
#4
I'm no AS coder but I would assume it would work like this:

When someone moves to a tile it would perform a check to see whether the tile you are trying to move to is walkable: Code:
#5
The idea is make the avatar solid. The same thing happens in BittyBay.
#6
If you really want to solve this a method would be to make sure you have each avatars location stored in variables somewhere and a function which checks if there's an avatar on that square.

Code:
#7
Tnx EGONick!!
I make it because I have 8 Positions programmed and the avatar can go in diagonal (X,Y,Z)

But, where i have to put the function?
#8
I'm assuming you have a check if the tile's walkable, it would go in with that if statement.

Code:
#9
like this?

Code:
#10
No, that'll be your tile definition. It'll be in your moveChar function.
#11
is these the function:
Code:

Recovered from /coding-wise/8570-one-avatar-per-tile-2.html · captured 2008.