最美情侣中文字幕电影,在线麻豆精品传媒,在线网站高清黄,久久黄色视频

歡迎光臨散文網(wǎng) 會(huì)員登陸 & 注冊(cè)

注意,這是一條編程求助視頻?。?!急需大佬們幫忙

2023-07-03 11:44 作者:梅弟meide  | 我要投稿

以下是我寫的代碼邏輯, X軸y軸就是移動(dòng)的gUI的位置,isfollowing是用來確定x軸移動(dòng)方向的,比如x軸是每幀+3或-3

if (this.x軸 >= (float)(Screen.width / 2 - 250) && this.x軸 <= (float)(Screen.width / 2 - 250 + 500) && this.y軸 >= 0f && this.y軸 <= (float)(Screen.height / 2 - 150))

{

this.x上 = true;

}

else

{

this.x上 = false;

}

if (this.x軸 >= (float)(Screen.width / 2 - 250) && this.x軸 <= (float)(Screen.width / 2 - 250 + 500) && this.y軸 >= (float)(Screen.height / 2 - 150 + 330) && this.y軸 <= (float)Screen.height)

{

this.x下 = true;

}

else

{

this.x下 = false;

}

if (this.y軸 >= (float)(Screen.height / 2 - 150) && this.y軸 <= (float)(Screen.height / 2 - 150 + 330) && this.x軸 >= 0f && this.x軸 <= (float)(Screen.width / 2 - 250))

{

this.y左 = true;

}

else

{

this.y左 = false;

}

if (this.y軸 >= (float)(Screen.height / 2 - 150) && this.y軸 <= (float)(Screen.height / 2 - 150 + 330) && this.x軸 >= (float)(Screen.width / 2 - 250 + 500) && this.x軸 <= (float)Screen.width)

{

this.y右 = true;

}

else

{

this.y右 = false;

}

if (!this.isfollowing && !this.ismoving)

{

this.x軸 += 3f;

}

if (this.isfollowing && !this.ismoving)

{

this.x軸 -= 3f;

}

if (this.x軸 > (float)(Screen.width / 2 - 250) && this.y左)

{

this.isfollowing = true;

}

if (this.x軸 < (float)(Screen.width / 2 - 250 + 500) && this.y右)

{

this.isfollowing = false;

}

if (this.x軸 > (float)Screen.width)

{

this.isfollowing = true;

}

if (this.x軸 <= 0f)

{

this.isfollowing = false;

}

if (!this.yisfollowing && !this.ismoving)

{

this.y軸 += 3f;

}

if (this.yisfollowing && !this.ismoving)

{

this.y軸 -= 3f;

}

if (this.y軸 > (float)(Screen.height / 2 - 150) && this.x上)

{

this.yisfollowing = true;

}

if (this.y軸 < (float)(Screen.height / 2 - 150 + 330) && this.x下)

{

this.yisfollowing = false;

}

if (this.y軸 >= (float)Screen.height)

{

this.yisfollowing = true;

}

if (this.y軸 <= 0f)

{

this.yisfollowing = false;

}

新宾| 西华县| 巩义市| 高阳县| 祥云县| 逊克县| 若羌县| 汉沽区| 华宁县| 德保县| 留坝县| 大荔县| 山阴县| 平度市| 公主岭市| 南涧| 蓬安县| 云林县| 定远县| 比如县| 三明市| 荆州市| 宁夏| 麦盖提县| 承德县| 衡东县| 吕梁市| 泗阳县| 正镶白旗| 太仆寺旗| 景东| 北流市| 城固县| 建湖县| 岳普湖县| 定安县| 班玛县| 望谟县| 垦利县| 邳州市| 平定县|