I am using Pixel Movement, Is it possible to move diognal using only 4 Dirs so it dosnt keep its default icon_state like
if usr is walking to left and bump into densed turf, then user holds left and presses north (to move Diognal NorthEast) the iconstate changes to North or what ever it is on 8 dirs icon
ID:803963
Jun 8 2012, 7:01 am
|
|
Jun 8 2012, 7:59 am
|
|
You can do something like this:
|
In response to Forum_account
|
|
but i want it to work something like this
if(src.MN || src.QueN) |
In response to Lord Kakarot
|
|
I have no clue what those variables are, but by the looks of the step() logic, I can tell you that the library already lets you slide along walls. If what you're asking is "when the player slides along a wall, the player's dir is in the direction of movement instead of key input" then Forum_account's solution should work.
|
Did you run the code I posted? If so, how is it different than what you're trying to do?
|
*Sorry for the Links*
Here are the 2 demos, One is based on Byond's Pixel Movement and other one based on Forum Account's Pixel Movement, my Concern is more on how the diognal works Byond Pixel Movement. Forum Account's Pixel Movement Based Byond Based Pixel Movement Demo using my code shown above |
In response to Lord Kakarot
|
|
Lord Kakarot wrote:
*Sorry for the Links* It's not a problem that you provided demos, but I'm still not sure what you're going for. If you want to use all 8 directional states, you can use this code instead: mob |
In response to Forum_account
|
|
Forum_account wrote:
Lord Kakarot wrote: > mob Thanks that solved my problem but now i am getting another problem which is when you host game with pixel movement, the movement lags |
What do you mean by "the movement lags"? Due to network latency a game will never run as well over a network as it will when you run it locally, so some difference in performance should be expected.
|
In response to Lord Kakarot
|
|
Lord Kakarot wrote:
byond://67.210.108.209:39484 That link isn't working. I've seen pixel movement work fine before, so if you're seeing a lot of lag it's most likely a problem with someone's internet connection. |
In response to Forum_account
|
|
Forum_account wrote:
Lord Kakarot wrote: There i hosted it again but i dont know how long will it be on Edit: Wrong port byond://67.210.108.209:3948 the right one |