Commit Graph
171 Commits
Author SHA1 Message Date
salix5 170123f02b Refactor data_manager.h includes (#3039) 2026-05-09 16:10:57 +08:00
Mercury233 1e45da773a upgrade irrlicht to 1.9 (#3063)
* upgrade irrlicht to 1.9

* fix material ZWriteEnable

* add archive file name in errmsg

* use IImage::getData instead of lock
2026-04-23 14:03:23 +08:00
Mercury233 afbf2a802a Replace CGUIImageButton with CGUIButton, handle resize and rotation (#3014) 2026-04-09 09:21:38 +08:00
Mercury233 39d5c6d252 remove glu and xxf86vm (#3040) 2026-04-03 11:21:43 +08:00
Mercury233 65e1850082 fix drawing of LPBar & LPFrame (#3034) 2026-03-31 06:01:52 +08:00
Mercury233 4f85fd75ef use u32 color in operations shifting (#3033) 2026-03-29 19:24:53 +08:00
Mercury233 2172fbdba3 add constexpr GAME_WINDOW_WIDTH & HEIGHT (#3032) 2026-03-29 19:24:38 +08:00
Mercury233 1918623c2e cleanup drawing (#3031)
* move Draw2DImageQuad

* add SetImageButtonDrawing

* fix Draw2DImageQuad signature

both Irrlicht and ImageManager don't use const

* rename linePattern

* update DrawSelectionLine signature

use u32 color directly to simplify calling

* minor performance

* dead code

* cleanup mainGame arrow operator
2026-03-29 19:20:04 +08:00
salix5 6fea874dac Change Deck to (const CardDataC*) vector (#3006) 2026-03-25 09:34:16 +08:00
salix5 bd326e20d9 Add datas.rule_code (#3000) 2026-03-15 18:21:01 +08:00
salix5 86a9ca5d6e fix location after selecting continuous effect (#2924) 2025-09-14 14:09:07 +08:00
salix5 d552e27657 Use const references for formatting (#2923) 2025-09-09 21:52:16 +08:00
salix5 a5ce265b01 fix dangling pointer (#2920) 2025-09-08 20:22:43 +08:00
Mercury233 0a96956ad0 fix animation of card moving to extra (#2856) 2025-08-07 15:30:58 +08:00
salix5 c9573debfd use uint32_t code as key (#2874) 2025-07-06 16:13:11 +08:00
Mercury233 b28b64927f add config for image load background thread and multi thread (#2822)
* add gameConf.use_image_load_background_thread

* preformance

* fix config not saving

* add gameConf.use_image_scale_multi_thread

* fix default use_image_load_background_thread
2025-06-19 11:04:12 +08:00
salix5 c7b674da2b Remove ocgcore/common.h includes from multiple files (#2843) 2025-06-14 17:03:44 +08:00
Mercury233 e677985c35 update imageScaleNNAA, add OpenMP (#2779)
* update imageScaleNNAA, add OpenMP

* fix

* disable thumb load thread

* use std::snprintf

* don't preload search result

* typo
2025-05-21 09:51:39 +08:00
Mercury233 5d5e7f9c4f update grave_act and so on to support opponent (#2712) 2025-03-17 17:39:59 +08:00
salix5 a1188835b3 replace core to irr::core 2025-03-14 19:10:07 +08:00
salix5 b5bf7990e9 replace irr::s32, irr::u32 2025-03-14 19:10:07 +08:00
salix5 95fb099724 replace video to irr::video 2025-03-14 19:10:07 +08:00
salix5 b891f85c97 fix namespace irr::core 2025-03-14 19:10:07 +08:00
salix5 8b3744840d replace irr::core::vector2df 2025-03-14 19:10:07 +08:00
salix5 bb72c00f56 replace irr::core::vector3df 2025-03-14 19:10:07 +08:00
salix5 006d973d19 replace irr::core::rect<s32> 2025-03-14 19:10:07 +08:00
salix5 194608f8f0 replace irr::core::recti 2025-03-14 19:10:07 +08:00
salix5 cfc3a919b1 fix namespace irr::scene 2025-03-14 19:10:07 +08:00
salix5 296c0d757e fix namespace irr::video 2025-03-14 19:10:07 +08:00
salix5 d06a9096fd rename: GetLFListContent -> GetLFList (#2715)
* update DeckManager::GetLFListContent

* change DeckBuilder::filterList into const LFList*

* update Game::DrawThumb

* rename: GetLFListContent -> GetLFList

* update the signature of DeckManager::GetLFListName

* change code to unsigned
2025-03-08 15:22:53 +08:00
salix5 ffc6aee169 replace position2d with vector2d (#2709)
* update MenuHandler

* update DeckBuilder

* replace position2di with irr::core::vector2di

* replace position2di with vector2di

* replace core::position2d with irr::core::vector2d

* replace position2d with vector2d
2025-03-02 12:22:54 +08:00
salix5 53d951c7d1 update signature of ClientCard::SetCode (#2655)
* update signature of ClientCard::SetCode

* ClientField: fix AddCard, RemoveCard

* minor fix

* use int counter variable
2025-01-28 05:35:26 +08:00
salix5 b57b331b65 move struct CardDataC, deck sort functions to data_manager.h (#2647)
* move struct CardDataC to data_manager.h

* update struct CardDataC

* move deck sort functions to DataManager

* update DeckBuilder::filter_effect
2025-01-14 13:25:16 +08:00
salix5 7721bfe017 remove NULL (#2626) 2024-12-04 23:19:51 +08:00
salix5 4423a82c4a Game: add static function DrawShadowText (#2614)
* add static function DrawShadowText

* add static function DrawShadowText

* reorder
2024-11-14 20:13:28 +08:00
salix5 48b01b838c remove wcscpy, wcscat (#2602)
* use wcsncpy

* fix FileSystem::TraversalDir

* avoid wcscat

* remove wcscat

* add BufferIO::CopyWideString

* struct Config: path string changed to wchar_t[256]

* Revert "use wcsncpy"

This reverts commit b05e0c96a3.

* check lastcategory, lastdeck

* fix Game::LoadConfig

max length of filename should be determined by file system

* remove wcscpy

* use BufferIO::CopyWideString

* fix UpdateDeck

* myfilesystem: use std functions

* DataManager: fix GetNumString (#2603)

* DataManager: fix FormatAttribute, FormatRace

* update FormatAttribute, FormatRace

* DataManager: fix FormatType

* update FormatType

* DataManager: fix FormatSetName

* DataManager: fix FormatLinkMarker

* merge

* DataManager: fix GetNumString

* rebuild class ustring16 from edopro version

* add stringw conversion

core::stringw in current version does not have data()

* add CGUITTFont::drawUstring

* use drawUstring

* update DrawShadowText

* fix Game::lpcstring

* fix DuelInfo::vic_string

* add PACK_MAX_SIZE

* add IsExtension (#2604)

* CGUITTFont: use override

* ustring16: only accept basic_string
2024-11-06 08:34:12 +08:00
salix5 080d7781f0 clean config.h (#2568)
* move header files to game.h

* include mutex when necessary

* include myfilesystem.h when necessary

* include thread when necessary

* include string

* include GL when necessary

* remove #pragma once

* rename guard macro to YGOPRO_CONFIG_H

* fix warning C4456, C4458

* move GL to game.h

* use <cstring> functions

* include <wchar.h>
2024-08-11 05:05:20 +08:00
salix5 e209e77502 disconnect when the packet is too large (#2551)
* use memcpy in DuelClient, NetServer

* NetServer: discard too large packet

* DuelClient: discard too large packet

* replace memcpy with std::memcpy

* disconnect when the packet is too large

* check packet_len

* check len in HandleCTOSPacket()

* check len in HandleSTOCPacketLan()

* remove bool type in HostInfo

* check len in packet handling

* add boundary check to STOC_CHAT packet

* use memcpy in DuelMode::JoinGame

* add DECK_MAX_SIZE, DECK_MIN_SIZE

* fix DuelMode::UpdateDeck()

* fix

* fix Manager::OpenDeckFile()

* update DuelMode init

* update DuelMode::JoinGame

* update DuelMode::GetResponse

* Revert "check len in packet handling"

This reverts commit 2b5c12f360.

* use memcpy in GetPosition

* check struct size by static_assert

* update DuelMode::UpdateDeck

* check if the struct is trivially copyable

* replace unsigned short to uint16_t

* replace unsigned int to uint32_t

* add padding member to STOC_HS_PlayerEnter

* workaround: use STOC_HS_PlayerEnter_size
2024-05-31 21:52:06 +08:00
Mercury233 0a7a4745f7 add STOC_TEAMMATE_SURRENDER (#2548) 2024-05-21 15:17:32 +08:00
Mercury233 b7dcae4ef1 change side chat drawing (#2545)
* fix CGUITTFont lineBreak

* change side chat drawing

* fix

* fix

* update normal chat

* less changement

* fix
2024-05-11 09:55:47 +08:00
salix5 2491768e8d add boundary check to network buffer (#2517)
* fix warning

* add boundary check to network buffer

* update submodule
2024-03-12 02:52:18 +08:00
salix5 92c957928d fix xyz material drawing (#2506)
normal card: 0.010f
xyz material: 0.003f
2023-11-26 22:23:24 +08:00
Mercury233 64003a70fd add hide player name option (#2476) 2023-05-18 15:17:27 +08:00
Nanahira cdad9616d1 multi layer LP for over start LP (#2460) 2022-12-06 08:55:21 +08:00
salix5 7f1e1135df fix Game::DrawGUI() 2022-09-27 14:44:59 +08:00
Nanahira 55536b64a1 update max value of LP bar (#2459) 2022-09-25 08:49:37 +08:00
salix5 4a1b52e51c fix Game::DrawGUI() (#2458) 2022-09-25 08:49:25 +08:00
Mercury233 fed41b69c3 update showing pack lists (#2434) 2022-09-22 10:45:51 +08:00
mercury233 a0ca3ca89f fix ot mark 2021-09-04 16:29:40 +08:00
Mercury233 c0bb37190a update Simplified Chinese ot rule (#2368) 2021-09-02 15:56:33 +08:00