projects
/
zefram
/
minetest
/
minetest_engine.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a91eb36
)
Silly MSVC doesn't know how to handle type conversions for parameters of pow(). Help it.
author
Perttu Ahola
<celeron55@gmail.com>
Mon, 28 Nov 2011 19:50:14 +0000
(21:50 +0200)
committer
Perttu Ahola
<celeron55@gmail.com>
Tue, 29 Nov 2011 17:13:57 +0000
(19:13 +0200)
src/environment.cpp
patch
|
blob
|
history
diff --git
a/src/environment.cpp
b/src/environment.cpp
index ce25b0fe7f71eadb18ede0da35071d58130faf6c..1951996a23135f0330aa6c40f1dc4e313e03e56d 100644
(file)
--- a/
src/environment.cpp
+++ b/
src/environment.cpp
@@
-592,7
+592,7
@@
public:
float chance = abm->getTriggerChance();
if(chance == 0)
chance = 1;
- aabm.chance = 1.0 / pow(
1.0 / chance,
intervals);
+ aabm.chance = 1.0 / pow(
(float)1.0/chance, (float)
intervals);
if(aabm.chance == 0)
aabm.chance = 1;
std::set<std::string> contents_s = abm->getTriggerContents();