Raising the warning lvl produces a shitload of warnings..

Discuss about anything related to the Irrlicht Engine, or read announcements about any significant features or usage changes.
Post Reply
MasterGod
Posts: 2061
Joined: Fri May 25, 2007 8:06 pm
Location: Israel
Contact:

Raising the warning lvl produces a shitload of warnings..

Post by MasterGod »

I've tried raising the warning level from 3 to 4 to get better warnings on MY code and when I tried compile I got a lot of warnings from Irrlicht.
Now I guess they wont be fixed so how can I use the higher warning level on my code only and have the normal level 3 on Irrlicht?

P.S
That much warnings:
http://d6.tomer.googlepages.com/BuildLog.htm
Image
Dev State: Abandoned (For now..)
Requirements Analysis Doc: ~87%
UML: ~0.5%
CuteAlien
Admin
Posts: 9736
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

That should be two different projects... I can't see how you could even put that in one. So right now I'm just confused why the project settings of Irrlicht are influencing the project settings of your own project. Each project usually has it's own settings.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
MasterGod
Posts: 2061
Joined: Fri May 25, 2007 8:06 pm
Location: Israel
Contact:

Post by MasterGod »

To be clear that build log is from a solution that has only Irrlicht (the main from the SDK).
When I build my solution which does NOT has the Irrlicht project in it, only mine I get about 1000 warnings less but still about 2000 of them.. :?

Ok wait a second I'm rebuilding my solution to have the exact number..
O.K, I get exactly "1>NUSoftware Game Engine - 0 error(s), 2379 warning(s)" warnings just from the headers under the include directory of the SDK.
Image
Dev State: Abandoned (For now..)
Requirements Analysis Doc: ~87%
UML: ~0.5%
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Well, you can disable these warnings conditionally, just add the proper pragmas in IrrCompileConfigs and disable them after including irrlicht.h n your application.
At least the "formal parameter" warning is pretty much nonsense. I saw this warning also with the Intel Compiler, but it's really silly. You could remove all named parameters from these methods (and make them anonymouse), that would solve these warnings. But IMHO this is the job of the compiler, and he should be quiet about this. The SColor.h warning is indeed due to lack of casts, but the code was already checked, no harm will be caused.
Oh, and the warnings are given because the code is inlined from headers, hence it's actually compiled in the user app, not in the engine.
MasterGod
Posts: 2061
Joined: Fri May 25, 2007 8:06 pm
Location: Israel
Contact:

Post by MasterGod »

Thanks hybrid.
I did this:

Code: Select all

#ifndef __IRRLICHT_H_INCLUDED__
#define __IRRLICHT_H_INCLUDED__

#pragma warning( push, 3 )

#include "IrrCompileConfig.h"

Code: Select all

/*! \file irrlicht.h
    \brief Main header file of the irrlicht, the only file needed to include.
*/

#pragma warning( pop )

#endif
And it seems I have only those "formal parameter" warnings in my project which I'm gonna disable too :)
Image
Dev State: Abandoned (For now..)
Requirements Analysis Doc: ~87%
UML: ~0.5%
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Post by rogerborg »

I approve! I'm very impressed with that. Warning as errors, right? ;)
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Post by rogerborg »

There's not that many. Warnings 4, MS C++ 8 (2005):

[UPDATE: apologies, this patch contains spaces, like the Baby Jesus used, rather than Irrlicht demon-spawned tabs]

Code: Select all

Index: include/IAttributeExchangingObject.h
===================================================================
--- include/IAttributeExchangingObject.h	(revision 1305)
+++ include/IAttributeExchangingObject.h	(working copy)
@@ -55,12 +55,12 @@
 	//! Writes attributes of the object.
 	//! Implement this to expose the attributes of your scene node animator for 
 	//! scripting languages, editors, debuggers or xml serialization purposes.
-	virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const {}
+	virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const { out = out; options = options; }
 
 	//! Reads attributes of the object.
 	//! Implement this to set the attributes of your scene node animator for 
 	//! scripting languages, editors, debuggers or xml deserialization purposes.
-	virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0) {}
+	virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0) { in = in; options = options; }
 
 };
 
Index: include/IGUIElement.h
===================================================================
--- include/IGUIElement.h	(revision 1305)
+++ include/IGUIElement.h	(working copy)
@@ -795,6 +795,7 @@
 	//! scripting languages, editors, debuggers or xml serialization purposes.
 	virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const
 	{
+        options = options; // Satisfies strict compiler warnings
 		out->addInt("Id", ID );
 		out->addString("Caption", getText());
 		out->addRect("Rect", DesiredRect);
@@ -818,6 +819,7 @@
 	//! scripting languages, editors, debuggers or xml deserialization purposes.
 	virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0)
 	{
+        options = options; // Satisfies strict compiler warnings
 		setID(in->getAttributeAsInt("Id"));
 		setText(in->getAttributeAsStringW("Caption").c_str());
 		setVisible(in->getAttributeAsBool("Visible"));
Index: include/IMaterialRenderer.h
===================================================================
--- include/IMaterialRenderer.h	(revision 1305)
+++ include/IMaterialRenderer.h	(working copy)
@@ -47,7 +47,13 @@
 	\param services: Interface providing some methods for changing advanced, internal
 	states of a IVideoDriver. */
 	virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
-		bool resetAllRenderstates, IMaterialRendererServices* services) {};
+		bool resetAllRenderstates, IMaterialRendererServices* services)
+    {
+        (void)material; // Satisfies strict compiler warnings
+        (void)lastMaterial; // Satisfies strict compiler warnings
+        resetAllRenderstates = resetAllRenderstates; // Satisfies strict compiler warnings
+        services = services; // Satisfies strict compiler warnings
+    };
 
 	//! Called every time before a new bunch of geometry is being drawn using this material with
 	//! for example drawIndexedTriangleList() call.
@@ -63,7 +69,12 @@
 	The material renderer can choose to return false for example if he doesn't support the
 	specified vertex type. This is actually done in D3D8 and D3D9 when using a 
 	normal mapped material with a vertex type other than EVT_TANGENTS.  */
-	virtual bool OnRender(IMaterialRendererServices* service, E_VERTEX_TYPE vtxtype) { return true; };
+	virtual bool OnRender(IMaterialRendererServices* service, E_VERTEX_TYPE vtxtype)
+    { 
+        service = service; // Satisfies strict compiler warnings
+        vtxtype = vtxtype; // Satisfies strict compiler warnings
+        return true;
+    };
 
 	//! Called by the IVideoDriver to unset this material.
 	/** Called during the 
Index: include/IParticleAffector.h
===================================================================
--- include/IParticleAffector.h	(revision 1305)
+++ include/IParticleAffector.h	(working copy)
@@ -58,7 +58,11 @@
 	//! Writes attributes of the object.
 	//! Implement this to expose the attributes of your scene node animator for
 	//! scripting languages, editors, debuggers or xml serialization purposes.
-	virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const {}
+	virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const
+    {
+        out = out; // Satisfies strict compiler warnings
+        options = options; // Satisfies strict compiler warnings
+    }
 
 	//! Reads attributes of the object.
 	//! Implement this to set the attributes of your scene node animator for
@@ -67,7 +71,13 @@
 	//! \param in: The attributes to work with.
 	//! \param options: Additional options.
 	//! \return: returns last index of an attribute read by this affector
-	virtual s32 deserializeAttributes(s32 startIndex, io::IAttributes* in, io::SAttributeReadWriteOptions* options=0) { return 0; }
+	virtual s32 deserializeAttributes(s32 startIndex, io::IAttributes* in, io::SAttributeReadWriteOptions* options=0)
+    { 
+        startIndex = startIndex; // Satisfies strict compiler warnings
+        in = in; // Satisfies strict compiler warnings
+        options = options; // Satisfies strict compiler warnings
+        return 0;
+    }
 
 	//! Get emitter type
 	virtual E_PARTICLE_AFFECTOR_TYPE getType() const = 0;
Index: include/IParticleEmitter.h
===================================================================
--- include/IParticleEmitter.h	(revision 1305)
+++ include/IParticleEmitter.h	(working copy)
@@ -88,7 +88,11 @@
 	//! Writes attributes of the object.
 	//! Implement this to expose the attributes of your scene node animator for
 	//! scripting languages, editors, debuggers or xml serialization purposes.
-	virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const {}
+	virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const
+    {
+        out = out; // Satisfies strict compiler warnings
+        options = options; // Satisfies strict compiler warnings
+    }
 
 	//! Reads attributes of the object.
 	//! Implement this to set the attributes of your scene node animator for
@@ -97,7 +101,13 @@
 	//! \param in: The attributes to work with.
 	//! \param options: Additional options.
 	//! \return: returns last index of an attribute read by this affector
-	virtual s32 deserializeAttributes(s32 startIndex, io::IAttributes* in, io::SAttributeReadWriteOptions* options=0) { return 0; }
+	virtual s32 deserializeAttributes(s32 startIndex, io::IAttributes* in, io::SAttributeReadWriteOptions* options=0)
+    { 
+        startIndex = startIndex; // Satisfies strict compiler warnings
+        in = in; // Satisfies strict compiler warnings
+        options = options; // Satisfies strict compiler warnings
+        return 0;
+    }
 
 	//! Get emitter type
 	virtual E_PARTICLE_EMITTER_TYPE getType() const { return EPET_POINT; }
Index: include/irrAllocator.h
===================================================================
--- include/irrAllocator.h	(revision 1305)
+++ include/irrAllocator.h	(working copy)
@@ -50,6 +50,7 @@
 	//! destruct an element
 	void destruct(T* ptr)
 	{
+        ptr = ptr;  // Satisfies spurious strict compiler warnings: MSVC thinks ptr is unused!
 		ptr->~T();
 	}
 
Index: include/ISceneNode.h
===================================================================
--- include/ISceneNode.h	(revision 1305)
+++ include/ISceneNode.h	(working copy)
@@ -339,6 +339,7 @@
 		//! \return The material at that index.
 		virtual video::SMaterial& getMaterial(u32 num)
 		{
+            num = num; // Satisfies strict compiler warnings
 			return *((video::SMaterial*)0);
 		}
 
@@ -600,6 +601,7 @@
 		//! \param options Additional options which might influence the serialization.
 		virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const
 		{
+            options = options; // Satisfies strict compiler warnings
 			if (!out)
 				return;
 			out->addString	("Name", Name.c_str());
@@ -623,6 +625,7 @@
 		//! \param options Additional options which might influence the deserialization.
 		virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0)
 		{
+            options = options; // Satisfies strict compiler warnings
 			if (!in)
 				return;
 			Name = in->getAttributeAsString("Name");
@@ -647,6 +650,7 @@
 		//! \return The newly created clone of this node.
 		virtual ISceneNode* clone(ISceneNode* newParent=0, ISceneManager* newManager=0) 
 		{ 
+            newParent = newParent; newManager = newManager; // Satisfies strict compiler warnings
 			return 0; // to be implemented by derived classes
 		}
 
Index: include/ISceneNodeAnimator.h
===================================================================
--- include/ISceneNodeAnimator.h	(revision 1305)
+++ include/ISceneNodeAnimator.h	(working copy)
@@ -43,6 +43,7 @@
 		the returned pointer after calling this. */
 		virtual ISceneNodeAnimator* createClone(ISceneNode* node, ISceneManager* newManager=0) 
 		{
+            node = node; newManager = newManager; // Just satisfies strict compiler warnings
 			return 0; // to be implemented by derived classes.
 		}
 
Index: include/IShaderConstantSetCallBack.h
===================================================================
--- include/IShaderConstantSetCallBack.h	(revision 1305)
+++ include/IShaderConstantSetCallBack.h	(working copy)
@@ -44,7 +44,10 @@
 	}
 	\endcode
 	*/
-	virtual void OnSetMaterial(const SMaterial& material) { }
+	virtual void OnSetMaterial(const SMaterial& material)
+    {
+        (void)material;  // Satisfies strict compiler warnings
+    }
 
 	//! Called by the engine when the vertex and/or pixel shader constants for an material renderer should be set.
 	/**
Index: include/SAnimatedMesh.h
===================================================================
--- include/SAnimatedMesh.h	(revision 1305)
+++ include/SAnimatedMesh.h	(working copy)
@@ -65,6 +65,9 @@
 		//! \return Returns the animated mesh based on a detail level.
 		virtual IMesh* getMesh(s32 frame, s32 detailLevel, s32 startFrameLoop=-1, s32 endFrameLoop=-1)
 		{
+            detailLevel = detailLevel; // Satisfies strict compiler warnings
+            startFrameLoop = startFrameLoop; // Satisfies strict compiler warnings
+            endFrameLoop = endFrameLoop; // Satisfies strict compiler warnings
 			if (Meshes.empty())
 				return 0;
 
Index: include/SColor.h
===================================================================
--- include/SColor.h	(revision 1305)
+++ include/SColor.h	(working copy)
@@ -15,7 +15,7 @@
 	//! Creates a 16 bit A1R5G5B5 color
 	inline u16 RGBA16(u32 r, u32 g, u32 b, u32 a)
 	{
-		return ((a & 0x80) << 8 |
+		return (u16)((a & 0x80) << 8 |
 			(r & 0xF8) << 7 |
 			(g & 0xF8) << 2 |
 			(b & 0xF8) >> 3);
@@ -41,7 +41,7 @@
 	//! Converts a 32 bit (X8R8G8B8) color to a 16 A1R5G5B5 color
 	inline u16 X8R8G8B8toA1R5G5B5(u32 color)
 	{
-		return (	0x8000 |
+		return (u16)(	0x8000 |
 			( color & 0x00F80000) >> 9 |
 			( color & 0x0000F800) >> 6 |
 			( color & 0x000000F8) >> 3);
@@ -51,7 +51,7 @@
 	//! Converts a 32 bit (A8R8G8B8) color to a 16 A1R5G5B5 color
 	inline u16 A8R8G8B8toA1R5G5B5(u32 color)
 	{
-		return (( color & 0x80000000) >> 16|
+		return (u16)(( color & 0x80000000) >> 16|
 			( color & 0x00F80000) >> 9 |
 			( color & 0x0000F800) >> 6 |
 			( color & 0x000000F8) >> 3);
@@ -61,7 +61,7 @@
 	//! Converts a 32 bit (A8R8G8B8) color to a 16 R5G6B5 color
 	inline u16 A8R8G8B8toR5G6B5(u32 color)
 	{
-		return (( color & 0x00F80000) >> 8 |
+		return (u16)(( color & 0x00F80000) >> 8 |
 			( color & 0x0000FC00) >> 5 |
 			( color & 0x000000F8) >> 3);
 	}
@@ -192,22 +192,22 @@
 		//! Returns the alpha component of the color. The alpha component
 		//! defines how transparent a color should be.
 		//! 0 means not transparent (opaque), 255 means fully transparent.
-		inline u32 getAlpha() const { return color>>24; }
+		inline u8 getAlpha() const { return (u8)(color>>24); }
 
 		//! Returns the red component of the color.
 		//! \return Returns a value between 0 and 255, specifying how red the color is.
 		//! 0 means no red, 255 means full red.
-		inline u32 getRed() const { return (color>>16) & 0xff; }
+		inline u8 getRed() const { return (u8)((color>>16) & 0xff); }
 
 		//! Returns the green component of the color.
 		//! \return Returns a value between 0 and 255, specifying how green the color is.
 		//! 0 means no green, 255 means full green.
-		inline u32 getGreen() const { return (color>>8) & 0xff; }
+		inline u8 getGreen() const { return (u8)((color>>8) & 0xff); }
 
 		//! Returns the blue component of the color.
 		//! \return Returns a value between 0 and 255, specifying how blue the color is.
 		//! 0 means no blue, 255 means full blue.
-		inline u32 getBlue() const { return color & 0xff; }
+		inline u8 getBlue() const { return (u8)(color & 0xff); }
 
 		//! Returns the luminance of the color.
 		inline f32 getLuminance() const
@@ -216,7 +216,7 @@
 		}
 
 		//! Returns the average intensity of the color.
-		inline u32 getAverage() const
+		inline u8 getAverage() const
 		{
 			return ( getRed() + getGreen() + getBlue() ) / 3;
 		}
@@ -225,22 +225,22 @@
 		//! defines how transparent a color should be.
 		//! \param a: Has to be a value between 0 and 255.
 		//! 0 means not transparent (opaque), 255 means fully transparent.
-		inline void setAlpha(u32 a) { color = ((a & 0xff)<<24) | (color & 0x00ffffff); }
+		inline void setAlpha(u8 a) { color = (a <<24) | (color & 0x00ffffff); }
 
 		//! Sets the red component of the Color.
 		//! \param r: Has to be a value between 0 and 255.
 		//! 0 means no red (=black), 255 means full red.
-		inline void setRed(u32 r) { color = ((r & 0xff)<<16) | (color & 0xff00ffff); }
+		inline void setRed(u8 r) { color = (r <<16) | (color & 0xff00ffff); }
 
 		//! Sets the green component of the Color.
 		//! \param g: Has to be a value between 0 and 255.
 		//! 0 means no green (=black), 255 means full green.
-		inline void setGreen(u32 g) { color = ((g & 0xff)<<8) | (color & 0xffff00ff); }
+		inline void setGreen(u8 g) { color = (g <<8) | (color & 0xffff00ff); }
 
 		//! Sets the blue component of the Color.
 		//! \param b: Has to be a value between 0 and 255.
 		//! 0 means no blue (=black), 255 means full blue.
-		inline void setBlue(u32 b) { color = (b & 0xff) | (color & 0xffffff00); }
+		inline void setBlue(u8 b) { color = b | (color & 0xffffff00); }
 
 		//! Calculates a 16 bit A1R5G5B5 value of this color.
 		//! \return Returns the 16 bit A1R5G5B5 value of this color.
@@ -489,7 +489,7 @@
 		f32 Luminance;
 
 		private:
-			inline u32 toRGB1(f32 rm1, f32 rm2, f32 rh) const;
+			inline u8 toRGB1(f32 rm1, f32 rm2, f32 rh) const;
 
 	};
 
@@ -523,7 +523,7 @@
 	}
 
 
-	inline u32 SColorHSL::toRGB1(f32 rm1, f32 rm2, f32 rh) const
+	inline u8 SColorHSL::toRGB1(f32 rm1, f32 rm2, f32 rh) const
 	{
 		while ( rh > 2.f * core::PI )
 			rh -= 2.f * core::PI;
@@ -535,7 +535,7 @@
 		else if (rh < 180.0f * core::DEGTORAD ) rm1 = rm2;
 		else if (rh < 240.0f * core::DEGTORAD ) rm1 = rm1 + (rm2 - rm1) * ( ( 240.0f * core::DEGTORAD ) - rh) / (60.0f * core::DEGTORAD);
 		                
-		return (u32) (rm1 * 255.f);
+		return (u8) (rm1 * 255.f);
 	}
 
 } // end namespace video
Index: include/SSkinMeshBuffer.h
===================================================================
--- include/SSkinMeshBuffer.h	(revision 1305)
+++ include/SSkinMeshBuffer.h	(working copy)
@@ -261,10 +261,19 @@
 
 
 	//! append the vertices and indices to the current buffer
-	virtual void append(const void* const vertices, u32 numVertices, const u16* const indices, u32 numIndices) {}
+	virtual void append(const void* const vertices, u32 numVertices, const u16* const indices, u32 numIndices)
+    {
+        (void)vertices; // Satisfies strict compiler warnings
+        numVertices = numVertices; // Satisfies strict compiler warnings
+        (void)indices; // Satisfies strict compiler warnings
+        numIndices = numIndices; // Satisfies strict compiler warnings
+    }
 
 	//! append the meshbuffer to the current buffer
-	virtual void append(const IMeshBuffer* const other) {}
+	virtual void append(const IMeshBuffer* const other)
+    {
+        (void)other; // Satisfies strict compiler warnings
+    }
 
 
 
@@ -282,7 +291,11 @@
 
 
 	//! flags the mesh as changed, reloads hardware buffers
-	virtual void setDirty(E_BUFFER_TYPE Buffer=EBT_VERTEX_AND_INDEX) {ChangedID++;}
+	virtual void setDirty(E_BUFFER_TYPE Buffer=EBT_VERTEX_AND_INDEX)
+    {
+        Buffer = Buffer; // Satisfies strict compiler warnings
+        ChangedID++;
+    }
 
 	virtual const u32 getChangedID() const {return ChangedID;}
 
Index: source/Irrlicht/CImageLoaderWAL.cpp
===================================================================
--- source/Irrlicht/CImageLoaderWAL.cpp	(revision 1305)
+++ source/Irrlicht/CImageLoaderWAL.cpp	(working copy)
@@ -70,10 +70,10 @@
 	// Try to get the color palette from elsewhere (usually in a pak along with the WAL).
 	// If this fails we use the DefaultPaletteQ2.
 	static s32 * palette = 0;
-	s32 loadedPalette[256];
 	if (!palette)
 	{
 #if TRY_LOADING_PALETTE_FROM_FILE
+    	s32 loadedPalette[256];
 		IImage * paletteImage;
 		// Look in a couple different places...
 		paletteImage = createImageFromFile("pics/colormap.pcx");
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
MasterGod
Posts: 2061
Joined: Fri May 25, 2007 8:06 pm
Location: Israel
Contact:

Post by MasterGod »

Thanks.
Seems it's not that off topic can you help me resolve that warning please?
warning C4512: 'nge::game::StateCredits' : assignment operator could not be generated.
see declaration of 'nge::game::StateCredits'
StateCredits Class:

Code: Select all

// Copyright (c) 2007-2008 Tomer Nosrati
// This file is part of the "NUSoftware Game Engine".
// For conditions of distribution and use, see copyright notice in nge.hpp

#pragma once
#ifndef __STATE_CREDITS_H__
#define __STATE_CREDITS_H__

#include "GameState.hpp"

namespace nge
{
	namespace game
	{

		//! Time based
		class StateCredits : public GameState  
		{
		public:
			virtual void Init(GameManager* pManager) = 0;
			virtual void Update(GameManager* pManager) = 0;
			virtual void Clear(GameManager* pManager) = 0;
			virtual void OnEvent(GameManager* pManager) = 0;

			virtual ~StateCredits();

		protected:
			StateCredits();

			virtual void addCreditItem(stringw item);

			//! \param KerningHeight : Height distance between letters.
			virtual void ScrollCredits(GameManager* pManager, GameState* NextState, f32 Speed = 15.f, s32 KerningHeight = 23);

			virtual void loadCredits(GameManager* pManager, SColor const& CreditColor = SColor(138,215,215,215));

			const s32 LINE_SPACE;
			const s32 LEFT_MARGIN;
			const s32 RIGHT_MARGIN;
			const s32 END_CREDITS;

		private:
			array<stringw> m_aCredits;
			array<IGUIStaticText*> m_aCreditItems;
			IGUIStaticText* m_pCreditItem;

			f32 m_Time;
			s32 m_Position;
		};

	} // namespace game
} // namespace nge

#endif // __STATE_CREDITS_H__
Image
Dev State: Abandoned (For now..)
Requirements Analysis Doc: ~87%
UML: ~0.5%
bitplane
Admin
Posts: 3204
Joined: Mon Mar 28, 2005 3:45 am
Location: England
Contact:

Post by bitplane »

I guess it's complaining about having no copy constructor, one that constructs itself from another StateCredits object.
Submit bugs/patches to the tracker!
Need help right now? Visit the chat room
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

But what would cause that to happen? Is it because of the const members?
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
MasterGod
Posts: 2061
Joined: Fri May 25, 2007 8:06 pm
Location: Israel
Contact:

Post by MasterGod »

BlindSide wrote:But what would cause that to happen? Is it because of the const members?
Yup that was it, thanks.

Another warning:
warning C4127: conditional expression is constant

Code: Select all

		bool CLevelManager::primitiveCollisionCheckBasedOnBoundingBox(ISceneNode* n1, ISceneNode* n2)
		{
			_NGE_DEBUG_BREAK_IF(true); // That line gives the warning;
			return n1->getBoundingBox().intersectsWithBox(n2->getBoundingBox());
		}

Code: Select all

//! Define a break macro for debugging.
#if BUILD_TYPE == DEBUG_BUILD
#	define _NGE_DEBUG_BREAK_IF( _CONDITION_ ) _IRR_DEBUG_BREAK_IF( _CONDITION_ )
#else
#	define _NGE_DEBUG_BREAK_IF( _CONDITION_ )
#endif
Image
Dev State: Abandoned (For now..)
Requirements Analysis Doc: ~87%
UML: ~0.5%
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

Wow that was a lucky guess :P
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Post Reply