diff options
author | krzys-h <krzys_h@interia.pl> | 2013-05-01 13:19:10 +0200 |
---|---|---|
committer | krzys-h <krzys_h@interia.pl> | 2013-05-01 13:19:10 +0200 |
commit | 9e1870f6bdb24e278c06929b8bd13225a7fdf8d3 (patch) | |
tree | e95cb1832a1584ff2e6c5e02941a2d1f80c83bcd /src/script | |
parent | 293376b82d8fa313b17685b73c110a33123f9077 (diff) | |
download | colobot-9e1870f6bdb24e278c06929b8bd13225a7fdf8d3.tar.gz colobot-9e1870f6bdb24e278c06929b8bd13225a7fdf8d3.tar.bz2 colobot-9e1870f6bdb24e278c06929b8bd13225a7fdf8d3.zip |
Removed some warnings
+ fix for previous commit
Diffstat (limited to 'src/script')
-rw-r--r-- | src/script/script.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/script/script.cpp b/src/script/script.cpp index a9cebe6..5c430d7 100644 --- a/src/script/script.cpp +++ b/src/script/script.cpp @@ -617,9 +617,10 @@ bool CScript::rRadar(CBotVar* var, CBotVar* result, int& exception, void* user) RadarFilter filter; float best, minDist, maxDist, sens, iAngle, angle, focus, d, a; int type, oType, i; - bool bArray; + bool bArray = false; type = OBJECT_NULL; + array = 0; angle = 0.0f; focus = Math::PI*2.0f; minDist = 0.0f*g_unit; @@ -836,7 +837,7 @@ bool CScript::rDetect(CBotVar* var, CBotVar* result, int& exception, void* user) RadarFilter filter; float bGoal, best, minDist, maxDist, sens, iAngle, angle, focus, d, a; int type, oType, i; - bool bArray; + bool bArray = false; Error err; exception = 0; @@ -844,6 +845,7 @@ bool CScript::rDetect(CBotVar* var, CBotVar* result, int& exception, void* user) if ( script->m_primaryTask == 0 ) // no task in progress? { type = OBJECT_NULL; + array = 0; angle = 0.0f; focus = 45.0f*Math::PI/180.0f; minDist = 0.0f*g_unit; |