Index: /trunk/nv/core/resource.hh
===================================================================
--- /trunk/nv/core/resource.hh	(revision 478)
+++ /trunk/nv/core/resource.hh	(revision 479)
@@ -63,5 +63,5 @@
 		template < typename T >
 		friend class resource_lock;
-		//		friend class resource_manager;
+//		friend class resource_manager;
 	};
 
@@ -72,6 +72,7 @@
 	public:
 		resource() : m_id(0), m_handler( nullptr ) {}
-		bool is_valid() const { return m_id.valid() && m_handler != nullptr;  }
 		resource_id id() const { return m_id; }
+		constexpr bool is_valid() const { return m_id && m_handler; }
+		constexpr explicit operator bool() const { return is_valid(); }
 		~resource()
 		{
@@ -184,10 +185,10 @@
 // 		}
 // 
-// 		virtual const void* create( resource_id id, resource_type_id type_hash )
-// 		{
-// 			auto handler = m_handlers.find( type_hash );
-// 			NV_ASSERT( handler != m_handlers.end(), "Handler not registered!" );
-// 			return handler->second->create( id, type_hash );
-// 		}
+// // 		virtual const void* create( resource_id id, resource_type_id type_hash )
+// // 		{
+// // 			auto handler = m_handlers.find( type_hash );
+// // 			NV_ASSERT( handler != m_handlers.end(), "Handler not registered!" );
+// // 			return handler->second->create( id, type_hash );
+// // 		}
 // 
 // 		virtual void unlock( resource_id id, resource_type_id type_hash )
Index: /trunk/nv/engine/resource_system.hh
===================================================================
--- /trunk/nv/engine/resource_system.hh	(revision 478)
+++ /trunk/nv/engine/resource_system.hh	(revision 479)
@@ -115,5 +115,4 @@
 		}
 
-
 		virtual void clear()
 		{
@@ -124,4 +123,10 @@
 			}
 			m_store.clear();
+		}
+
+		resource_type add( shash64 id, stored_type resource )
+		{
+			m_store[id] = resource;
+			return create< T >( id );
 		}
 
@@ -139,9 +144,4 @@
 		virtual void release( stored_type ) {}
 
-		void add( stored_type resource, shash64 id )
-		{
-			m_store[id] = resource;
-		}
-
 		hash_store< shash64, stored_type > m_store;
 	};
Index: /trunk/nv/gfx/skeleton_instance.hh
===================================================================
--- /trunk/nv/gfx/skeleton_instance.hh	(revision 478)
+++ /trunk/nv/gfx/skeleton_instance.hh	(revision 479)
@@ -59,5 +59,5 @@
 
 		dynamic_array< mat4 > m_transform;
-};
+	};
 
 
Index: /trunk/nv/stl/functional/hash.hh
===================================================================
--- /trunk/nv/stl/functional/hash.hh	(revision 478)
+++ /trunk/nv/stl/functional/hash.hh	(revision 479)
@@ -176,5 +176,6 @@
  		constexpr hash_value( const hash_value& ) = default;
 
-		constexpr bool valid() const { return m_value != 0; }
+		constexpr bool is_valid() const { return m_value != 0; }
+		constexpr explicit operator bool() const { return is_valid(); }
 
 		template < typename H2, typename Tag2 >
Index: /trunk/nv/stl/handle.hh
===================================================================
--- /trunk/nv/stl/handle.hh	(revision 478)
+++ /trunk/nv/stl/handle.hh	(revision 479)
@@ -30,24 +30,26 @@
 		typedef T value_type;
 		typedef TAG tag_type;
-		static const int INDEX_BITS   = IBITS;
-		static const int COUNTER_BITS = IBITS;
-		static const T MAX_INDEX   = (1 << IBITS) - 1;
-		static const T MAX_COUNTER = (1 << CBITS) - 1;
-
-		handle() : m_index(0), m_counter(0) {}
-
-		inline bool operator==(const handle& rhs) const {return m_index == rhs.m_index && m_counter == rhs.m_counter; }
-		inline bool operator!=(const handle& rhs) const {return !(*this == rhs);}
-
-		bool is_nil() const { return m_index == 0 && m_counter == 0; }
-		bool is_valid() const { return !is_nil(); }
-		T index() const { return m_index; }
+		static constexpr int INDEX_BITS   = IBITS;
+		static constexpr int COUNTER_BITS = IBITS;
+		static constexpr T MAX_INDEX   = (1 << IBITS) - 1;
+		static constexpr T MAX_COUNTER = (1 << CBITS) - 1;
+
+		constexpr handle() : m_index(0), m_counter(0) {}
+
+		constexpr inline bool operator==(const handle& rhs) const {return m_index == rhs.m_index && m_counter == rhs.m_counter; }
+		constexpr inline bool operator!=(const handle& rhs) const {return !(*this == rhs);}
+
+		constexpr bool is_nil() const { return m_index == 0 && m_counter == 0; }
+		constexpr bool is_valid() const { return !is_nil(); }
+		constexpr operator bool() const { return is_valid(); }
+
+		constexpr T index() const { return m_index; }
 		//size_t hash() const { return hash<T>()( T( m_counter << IBITS | m_index ) ); }
-		size_t hash() const { NV_ASSERT( false, "UNIMPLEMENTED!" ); return 0; }
+		constexpr size_t hash() const { NV_ASSERT( false, "UNIMPLEMENTED!" ); return 0; }
 	protected:
 		T m_index   : IBITS;
 		T m_counter : CBITS;
 
-		handle( T a_index, T a_counter ) : m_index( a_index ), m_counter( a_counter ) {}
+		constexpr handle( T a_index, T a_counter ) : m_index( a_index ), m_counter( a_counter ) {}
 		template < typename H >
 		friend class handle_operator;
Index: /trunk/src/engine/particle_engine.cc
===================================================================
--- /trunk/src/engine/particle_engine.cc	(revision 478)
+++ /trunk/src/engine/particle_engine.cc	(revision 479)
@@ -303,5 +303,5 @@
 {
 	shash64 id = table.get_string_hash_64( "id" );
-	if ( !id.valid() )
+	if ( !id )
 	{
 		NV_LOG_ERROR( "Bad table passed to particle_engine!" )
Index: /trunk/src/engine/program_manager.cc
===================================================================
--- /trunk/src/engine/program_manager.cc	(revision 478)
+++ /trunk/src/engine/program_manager.cc	(revision 479)
@@ -36,5 +36,5 @@
 	}
 
-	add( m_context->get_device()->create_program( vsource, fsource ), id );
+	add( id, m_context->get_device()->create_program( vsource, fsource ) );
 	return true;
 }
Index: /trunk/src/gfx/skeletal_mesh.cc
===================================================================
--- /trunk/src/gfx/skeletal_mesh.cc	(revision 478)
+++ /trunk/src/gfx/skeletal_mesh.cc	(revision 479)
@@ -15,25 +15,17 @@
 void nv::skeletal_animation_entry::update_skeleton( skeleton_instance& data, uint32 a_ms_time ) const
 {
-	float  fframe   = ( a_ms_time * 0.001f ) * m_fps;
-	uint32 frame    = uint32( math::floor( fframe ) );
-	float  reminder = fframe - static_cast<float>( frame );
+	float  fframe = ( a_ms_time * 0.001f ) * m_fps;
+	float  nframe = nv::floor( fframe );
 	uint32 duration = get_frame_count();
 	if ( duration == 0 )
 	{
-		frame  = get_start_frame();
-		fframe = static_cast<float>( frame );
+		fframe = static_cast<float>( get_start_frame() );
 	}
-	else if ( frame >= duration )
+	else if ( nframe >= duration )
 	{
 		if ( is_looping() )
-		{
-			frame  = frame % duration;
-			fframe = static_cast<float>( frame ) + reminder;
-		}
+			fframe = nv::fmodf( fframe, nv::f32( duration ) );
 		else
-		{
-			frame  = get_end_frame();
-			fframe = static_cast<float>( frame );
-		}
+			fframe = static_cast<float>( get_end_frame() );
 	}
 
