fix: syntax error
This commit is contained in:
		
							parent
							
								
									ad5a9ed52f
								
							
						
					
					
						commit
						775e1075c8
					
				|  | @ -69,13 +69,9 @@ void e2d::Game::Start() | |||
| 			last = now; | ||||
| 			input->Update(); | ||||
| 
 | ||||
| 			if (!paused_) | ||||
| 			{ | ||||
| 				timer->Update(); | ||||
| 				UpdateScene(); | ||||
| 			} | ||||
| 			 | ||||
| 			UpdateScene(); | ||||
| 			DrawScene(); | ||||
| 
 | ||||
| 			window->Poll(); | ||||
| 		} | ||||
| 		else | ||||
|  | @ -168,6 +164,9 @@ bool e2d::Game::IsTransitioning() const | |||
| 
 | ||||
| void e2d::Game::UpdateScene() | ||||
| { | ||||
| 	if (paused_) | ||||
| 		return; | ||||
| 
 | ||||
| 	if (transition_) | ||||
| 	{ | ||||
| 		transition_->Update(); | ||||
|  |  | |||
|  | @ -160,7 +160,7 @@ bool e2d::Image::Preload(const Resource& res) | |||
| 
 | ||||
| 	IWICImagingFactory *imaging_factory = Renderer::GetImagingFactory(); | ||||
| 	ID2D1HwndRenderTarget* render_target = Renderer::GetInstance()->GetRenderTarget(); | ||||
| 	IWICBitmadecoder *decoder = nullptr; | ||||
| 	IWICBitmapDecoder *decoder = nullptr; | ||||
| 	IWICBitmapFrameDecode *source = nullptr; | ||||
| 	IWICStream *stream = nullptr; | ||||
| 	IWICFormatConverter *converter = nullptr; | ||||
|  | @ -172,8 +172,8 @@ bool e2d::Image::Preload(const Resource& res) | |||
| 
 | ||||
| 	// ¶¨Î»×ÊÔ´
 | ||||
| 	res_handle = ::FindResourceW( | ||||
| 		HINST_THISCOMPONENT,  | ||||
| 		MAKEINTRESOURCE(res.id),  | ||||
| 		HINST_THISCOMPONENT, | ||||
| 		MAKEINTRESOURCE(res.id), | ||||
| 		(LPCWSTR)res.type | ||||
| 	); | ||||
| 
 | ||||
|  | @ -292,7 +292,7 @@ bool e2d::Image::Preload(const String & file_name) | |||
| 
 | ||||
| 	IWICImagingFactory *imaging_factory = Renderer::GetImagingFactory(); | ||||
| 	ID2D1HwndRenderTarget* render_target = Renderer::GetInstance()->GetRenderTarget(); | ||||
| 	IWICBitmadecoder *decoder = nullptr; | ||||
| 	IWICBitmapDecoder *decoder = nullptr; | ||||
| 	IWICBitmapFrameDecode *source = nullptr; | ||||
| 	IWICStream *stream = nullptr; | ||||
| 	IWICFormatConverter *converter = nullptr; | ||||
|  |  | |||
|  | @ -69,6 +69,11 @@ e2d::Node::~Node() | |||
| 		SafeRelease(action); | ||||
| 	} | ||||
| 
 | ||||
| 	for (auto task : tasks_) | ||||
| 	{ | ||||
| 		SafeRelease(task); | ||||
| 	} | ||||
| 
 | ||||
| 	for (auto child : children_) | ||||
| 	{ | ||||
| 		SafeRelease(child); | ||||
|  |  | |||
|  | @ -23,6 +23,9 @@ e2d::File::~File() | |||
| 
 | ||||
| bool e2d::File::Open(const String & file_name) | ||||
| { | ||||
| 	if (file_name.IsEmpty()) | ||||
| 		return false; | ||||
| 
 | ||||
| 	auto FindFile = [=](const String & path) -> bool | ||||
| 	{ | ||||
| 		if (::_waccess((const wchar_t*)path, 0) == 0) | ||||
|  |  | |||
|  | @ -80,7 +80,7 @@ bool e2d::Music::Open(const e2d::String & file_path) | |||
| 	} | ||||
| 
 | ||||
| 	File music_file; | ||||
| 	if (!music_file.Open(file_name)) | ||||
| 	if (!music_file.Open(file_path)) | ||||
| 	{ | ||||
| 		WARN("Music::Open error: File not found."); | ||||
| 		return false; | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue