summaryrefslogtreecommitdiff
path: root/src/simulation
diff options
context:
space:
mode:
authorSimon Robertshaw <simon@hardwired.org.uk>2012-10-26 14:58:39 (GMT)
committer Simon Robertshaw <simon@hardwired.org.uk>2012-10-26 14:58:39 (GMT)
commit9b4f710e28bd7d14bec0ce67d19d75cb6a67c5a6 (patch)
tree1d46987563b4446e052fde7ce7afcae458599e9d /src/simulation
parentc3ba809806481912b895a12b2d70df7c3dc16476 (diff)
downloadpowder-9b4f710e28bd7d14bec0ce67d19d75cb6a67c5a6.zip
powder-9b4f710e28bd7d14bec0ce67d19d75cb6a67c5a6.tar.gz
Menu icon for sensors menu and fix for VIBR std::max args
Diffstat (limited to 'src/simulation')
-rw-r--r--src/simulation/SimulationData.cpp2
-rw-r--r--src/simulation/elements/VIBR.cpp6
2 files changed, 4 insertions, 4 deletions
diff --git a/src/simulation/SimulationData.cpp b/src/simulation/SimulationData.cpp
index 7a0ba43..e338e2f 100644
--- a/src/simulation/SimulationData.cpp
+++ b/src/simulation/SimulationData.cpp
@@ -150,7 +150,7 @@ menu_section * LoadMenus(int & menuCount)
{"\xC1", "Walls", 0, 1},
{"\xC2", "Electronics", 0, 1},
{"\xD6", "Powered Materials", 0, 1},
- {"\xD6", "Sensors", 0, 1},
+ {"\x99", "Sensors", 0, 1},
{"\xE2", "Force", 0, 1},
{"\xC3", "Explosives", 0, 1},
{"\xC5", "Gasses", 0, 1},
diff --git a/src/simulation/elements/VIBR.cpp b/src/simulation/elements/VIBR.cpp
index 8252a8d..370c69f 100644
--- a/src/simulation/elements/VIBR.cpp
+++ b/src/simulation/elements/VIBR.cpp
@@ -193,9 +193,9 @@ int Element_VIBR::update(UPDATE_FUNC_ARGS) {
//#TPT-Directive ElementHeader Element_VIBR static int graphics(GRAPHICS_FUNC_ARGS)
int Element_VIBR::graphics(GRAPHICS_FUNC_ARGS)
{
- float maxtemp = fmax(cpart->tmp,cpart->temp);
- int gradient = max(cpart->ctype/12.0f, cpart->tmp);
- gradient = max(gradient, cpart->tmp2);
+ float maxtemp = std::max((float)cpart->tmp, cpart->temp);
+ int gradient = std::max(cpart->ctype/12.0f, (float)cpart->tmp);
+ gradient = std::max(gradient, cpart->tmp2);
if (gradient >= 100 || cpart->life)
{
*pixel_mode = PMODE_NONE;