Why can't it identify the target?
here scrip usingt:
player_1.onrelease = function() { player_id = '2'; };
player_2.onrelease = function() { player_id = '2'; };
if(player_id == (2 or 1)) {
if(key.isdown(key.up)) {
player_[player_id]._y = player_['player_id]._y - 2;
}
}
i want user clicks on player he/she wishes control/move. , when user clicks on player, according clicked on. like it's dynamic. suggestions on why doesn't move player specific player_id?
player_1.onrelease = function() { player_id = '2'; };
player_2.onrelease = function() { player_id = '2'; };
if(player_id == (2 or 1)) {
if(key.isdown(key.up)) {
player_[player_id]._y = player_['player_id]._y - 2;
}
}
i want user clicks on player he/she wishes control/move. , when user clicks on player, according clicked on. like it's dynamic. suggestions on why doesn't move player specific player_id?
> player_[player_id]._y = player_['player_id]._y - 2;
that plain wrong
maybe want
this["player_"+player_id]._y -= 2;
--
jeckyl
that plain wrong
maybe want
this["player_"+player_id]._y -= 2;
--
jeckyl
More discussions in ActionScript 1 and 2
adobe
Comments
Post a Comment