285 Commits
Author SHA1 Message Date
Mercury233 1b35981929 header updates (#3157) 2026-08-11 08:21:50 +08:00
Mercury233 172c86d1fe update Irrlicht and CGUITTFont headers (#3151) 2026-08-07 08:52:34 +08:00
Mercury233 d305daf77b utilize setting card list label text and color (#3141) 2026-07-27 08:44:34 +08:00
Mercury233 ae44c1689d auto trim text after pasted (#2283) 2026-07-17 16:38:38 +08:00
Mercury233 e0d69a3f31 fix clicking LISTBOX_LOG (#3138) 2026-07-11 09:40:55 +08:00
Mercury233 8bd16d5727 revert locking mutex in EGET_SCROLL_BAR_CHANGED (#3092) 2026-05-22 09:29:40 +08:00
Mercury233 ca74565578 add & update options (#3045)
* add myclamp

* change gameConf.sound_volume to int

* add resize popup menu

* add resize select window option

* add swap yes no button
2026-04-24 09:49:25 +08:00
Mercury233 9fa42dd103 move global vars from gframe to member of mainGame (#3041) 2026-04-11 08:57:44 +08:00
Mercury233 afbf2a802a Replace CGUIImageButton with CGUIButton, handle resize and rotation (#3014) 2026-04-09 09:21:38 +08:00
Mercury233 65e1850082 fix drawing of LPBar & LPFrame (#3034) 2026-03-31 06:01:52 +08:00
salix5 78c1a9b390 Remove unnecessary header files from config.h (#3036) 2026-03-29 22:44:32 +08:00
Mercury233 2172fbdba3 add constexpr GAME_WINDOW_WIDTH & HEIGHT (#3032) 2026-03-29 19:24:38 +08:00
salix5 6378795a52 Use %zu for size_t values in printf (#3023) 2026-03-23 08:31:21 +08:00
salix5andMercury233 373a07f15a Refactor key event handling to reduce redundancy (#3017)
* Simplify key event handling

* Refactor key event handling for improved readability

* Refactor key event handling to reduce redundancy

* add static_assert

Co-authored-by: Mercury233 <me@mercury233.me>

---------

Co-authored-by: Mercury233 <me@mercury233.me>
2026-03-22 17:23:00 +08:00
mercury233 501d07b2dc fix selectable_cards location info didn't refresh correctly when EGET_SCROLL_BAR_CHANGED and cant_check_grave 2026-02-27 15:58:38 +08:00
salix5 39475480a0 Refactor class DataManager (#2956) 2026-01-28 19:02:46 +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
salix5 d921cd0fc0 DataManager: change unknown_string, FileSystem to instance member (#2907) 2025-08-23 14:53:58 +08:00
Mercury233 e7ebb75fa0 update forced in MSG_SELECT_CHAIN (#2797) 2025-06-29 17:40:43 +08:00
salix5 c7b674da2b Remove ocgcore/common.h includes from multiple files (#2843) 2025-06-14 17:03:44 +08:00
salix5 c41aa28972 left shit on unsigned (#2821) 2025-06-01 20:32:37 +08:00
salix5 b5bf7990e9 replace irr::s32, irr::u32 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 8f9fcbd6ed fix namespace irr::gui 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
Nanahira 937c214bf3 client MSG_SELECT_SUM: cancellable & better display (#2643)
* client MSG_SELECT_SUM: cancellable & better display

* fix
2025-02-08 16:12:47 +08:00
salix5 377824c5ba remove additional texts for cards in deck (#2657)
* clear data before adding to deck

* keep the order in deck

* remove additional texts for cards in deck

* set mark to false before adding to deck

* update ClientField::Initial
2025-02-04 00:58:25 +08:00
salix5 d376ed0e65 use <cwchar> function (#2651) 2025-01-17 19:50:59 +08:00
salix5 fb4580f93d Patch1 (#2635)
* update include in network.h

* format
2024-12-15 15:15:24 +08:00
salix5 f2278ae751 use vector rbegin (#2628)
* use vector rbegin

* const reference

* use vector assign

* minor update

* init
2024-12-06 23:50:39 +08:00
salix5 85793b7105 replace intN macro (#2627)
* remove int32

* replace uint32_t

* remove uint8
2024-12-05 19:29:41 +08:00
salix5 51929625b3 BufferIO: add CopyCharArray (#2616)
array length is determined by reference to array
2024-11-16 11:51:18 +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 40d77767ac fix ClientField::SetResponseSelectedCards (#2605) 2024-10-12 15:01:11 +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
Nanahira 1b1fb66437 fix chat player name display (#2542)
* fix after change side chat reverse

* fix

* fix

* fix

* Update replay_mode.cpp

* fix tag

* simplify

* fix
2024-05-07 16:13:39 +08:00
salix5 e3155746c5 fix: check response size before writing (#2514)
* update DuelClient::response_buf[]

* fix: check response size before writing
2024-02-14 04:03:07 +08:00
salix5 c8fd63357e fix: deprecated szone[7] 2024-01-05 20:40:05 +08:00
salix5 88e3f5a3c5 fix ClientField::GetHoverField()
If the opponent's mzone[6] is selectable:
Select opponent, mzone[6]

Otherwise:
Select self, mzone[5]
2023-11-19 19:25:34 +08:00
Mercury233 64003a70fd add hide player name option (#2476) 2023-05-18 15:17:27 +08:00
Mercury233 27e06722c5 add RACE_ILLUSION, RACES_COUNT (#2494) 2023-05-03 14:36:42 +08:00
Mercury233 022914dc92 add hint for player go first in the 1st turn (#2469) 2022-11-17 16:11:56 +08:00
Mercury233 ab8f41a5e3 disable BP M2 EP buttons on showing menu (#2449)
* disable BP M2 EP buttons on showing menu

* fix BP button conflict with Last Will
2022-09-08 17:09:04 +08:00