⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 rightl.java

📁 俄罗斯方块游戏
💻 JAVA
字号:
import java.awt.*;
public class RightL extends SquareShape {
	private Color rightLColor=new Color(0,255,0);
	public RightL() {
		super();
		this.color=rightLColor;
		// TODO Auto-generated constructor stub
	}

	protected void defaultRotate() {
		// TODO Auto-generated method stub
		for(int i=0;i<3;i++)
		{
			postion[i][0]=xpos;
			postion[i][1]=ypos+i*20;
		}
		postion[3][0]=xpos-20;
		postion[3][1]=ypos+40;
	}

	protected void firstRotate() {
		// TODO Auto-generated method stub
		for(int i=0;i<3;i++)
		{
			postion[i][0]=xpos+(i-1)*20;
			postion[i][1]=ypos+20;
		}
		postion[3][0]=xpos-20;
		postion[3][1]=ypos;
		
	}

	protected void secondRotate() {
		// TODO Auto-generated method stub
		for(int i=0;i<3;i++)
		{
			postion[i][0]=xpos-20;
			postion[i][1]=ypos+i*20;
		}
		postion[3][0]=xpos;
		postion[3][1]=ypos;
	}

	protected void thirdRotate() {
		// TODO Auto-generated method stub
		for(int i=0;i<3;i++)
		{
			postion[i][0]=xpos-(i-1)*20;
			postion[i][1]=ypos;
		}
		postion[3][0]=xpos+20;
		postion[3][1]=ypos+20;
		

	}

}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -