mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-29 19:00:33 +02:00
fix mistake in EMP.cpp, add license header in Probability.cpp
This commit is contained in:
@@ -1,3 +1,17 @@
|
|||||||
|
/*
|
||||||
|
* This program is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
#include <numeric>
|
#include <numeric>
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
|
@@ -124,7 +124,7 @@ int Element_EMP::Trigger(Simulation *sim, int triggerCount)
|
|||||||
{
|
{
|
||||||
if (rand()%5 < 2)
|
if (rand()%5 < 2)
|
||||||
sim->part_change_type(r, rx, ry, PT_BREC);
|
sim->part_change_type(r, rx, ry, PT_BREC);
|
||||||
else if (!(rand()%120))
|
else
|
||||||
sim->part_change_type(r, rx, ry, PT_NTCT);
|
sim->part_change_type(r, rx, ry, PT_NTCT);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user