Skip to content

Commit

Permalink
Merge pull request #8 from MyrddinoptRoodt/add_documentation
Browse files Browse the repository at this point in the history
corrected some errors on the pins
  • Loading branch information
MyrddinoptRoodt authored Nov 17, 2021
2 parents e562f3d + 3c1cc56 commit e15cbc8
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,9 @@ String Damagex2 = "10";
String Damagex3 = "11";
int buzzer = 0; // pin D3
const uint16_t ChangeTeams_Button = 12; //d6
int button_Shoot = 13; // pushbutton connected to digital pin D4
const uint16_t button_Shoot = 13; // pushbutton connected to digital pin D7
int val = 0; // variable to store the read value
const uint8_t ChangeGuns_Button = 16;//D3 button to change the gun type
const uint8_t ChangeGuns_Button = 16;//D0 button to change the gun type
const uint8_t Reload_Button = A0;//reload button on A0
int bullets = 6;//amount of bullets for default gun
int Health = 9; //you start with 9hp
Expand Down Expand Up @@ -231,9 +231,7 @@ void setup() {
irrecv.enableIRIn(); // Start the receiver


//setup_wifi();
//client.setServer(mqtt_server, 1883);
//client.setCallback(callback);

ui.setTargetFPS(10);

// You can change this to
Expand Down Expand Up @@ -344,7 +342,7 @@ String ChangeTeams(int teams){
ownTeam.concat("Green");
break;
case 4:
leds[1] = CRGB::White;
leds[1] = CRGB::White;
eigenteam = White;
gun = WhiteGunx1;
guns = 40;
Expand Down Expand Up @@ -652,6 +650,7 @@ void loop() {
Serial.print("reload gun: ");
Serial.println(bullets);
Serial.println(analogRead(Reload_Button));


}
switch (Health)//just a check to change the led colour depenging on the remaining health points
Expand Down Expand Up @@ -744,5 +743,4 @@ void loop() {
FastLED.show();
delay(50);
}

}
}

0 comments on commit e15cbc8

Please sign in to comment.