嗨,大家好我正在嘗試更改導入爲文件的變量。任何人都可以幫助我指出。如何更改導入的動作腳本中的私人變量
這是externalfile.as
private function SetNewPosition()
{
this.newX = this.GetRandomXPosition();
this.newY = this.GetRandomYPosition();
this.totalDistance = this.GetDistance();
var time:Number = this.totalDistance/this.speed;
speedX = (this.newX - this.x)/time;
speedY = (this.newY - this.y)/time;
}
原代碼
我試圖到下一頁末和newY從Main.as做出改變分享如何我可以解決此感謝!
不直接從'Main.as'中創建getter和setter, externalfile.as' – Cherniv