public void setAction(int a) {
        switch (a) {
            case 119: {
                action = 0;
                break;
            }
            case 100: {
                action = 1;
                break;
            }
            case 115: {
                action = 2;
                break;
            }
            case 97: {
                action = 3;
                break;
            }
            case 38:
            case 39:
            case 40:
            case 37: {
                action = 4+(a-34)%4;
                break;
            }
            case 8: {
                action = 8;
                break;
            }
        }
    }