Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-2pick
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
ygopro-2pick
Commits
ed87ef93
Commit
ed87ef93
authored
Oct 27, 2018
by
mercury233
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'fh' into resize
parents
143588c9
2047a67a
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
3 deletions
+15
-3
gframe/event_handler.cpp
gframe/event_handler.cpp
+13
-2
gframe/game.cpp
gframe/game.cpp
+1
-1
gframe/game.h
gframe/game.h
+1
-0
No files found.
gframe/event_handler.cpp
View file @
ed87ef93
...
@@ -995,6 +995,9 @@ bool ClientField::OnEvent(const irr::SEvent& event) {
...
@@ -995,6 +995,9 @@ bool ClientField::OnEvent(const irr::SEvent& event) {
mainGame
->
ClearCardInfo
(
mcard
->
controler
);
mainGame
->
ClearCardInfo
(
mcard
->
controler
);
}
}
}
}
if
(
id
==
TEXT_CARD_LIST_TIP
)
{
mainGame
->
stCardListTip
->
setVisible
(
true
);
}
break
;
break
;
}
}
case
irr
:
:
gui
::
EGET_ELEMENT_LEFT
:
{
case
irr
:
:
gui
::
EGET_ELEMENT_LEFT
:
{
...
@@ -1010,6 +1013,9 @@ bool ClientField::OnEvent(const irr::SEvent& event) {
...
@@ -1010,6 +1013,9 @@ bool ClientField::OnEvent(const irr::SEvent& event) {
SetShowMark
(
mcard
,
false
);
SetShowMark
(
mcard
,
false
);
mainGame
->
stCardListTip
->
setVisible
(
false
);
mainGame
->
stCardListTip
->
setVisible
(
false
);
}
}
if
(
id
==
TEXT_CARD_LIST_TIP
)
{
mainGame
->
stCardListTip
->
setVisible
(
false
);
}
break
;
break
;
}
}
default:
default:
...
@@ -2281,9 +2287,14 @@ void ClientField::ShowCardInfoInList(ClientCard* pcard, irr::gui::IGUIElement* e
...
@@ -2281,9 +2287,14 @@ void ClientField::ShowCardInfoInList(ClientCard* pcard, irr::gui::IGUIElement* e
irr
::
core
::
rect
<
s32
>
ePos
=
element
->
getRelativePosition
();
irr
::
core
::
rect
<
s32
>
ePos
=
element
->
getRelativePosition
();
s32
x
=
(
ePos
.
UpperLeftCorner
.
X
+
ePos
.
LowerRightCorner
.
X
)
/
2
;
s32
x
=
(
ePos
.
UpperLeftCorner
.
X
+
ePos
.
LowerRightCorner
.
X
)
/
2
;
s32
y
=
ePos
.
LowerRightCorner
.
Y
;
s32
y
=
ePos
.
LowerRightCorner
.
Y
;
mainGame
->
SetStaticText
(
mainGame
->
stCardListTip
,
16
0
,
mainGame
->
guiFont
,
str
.
c_str
());
mainGame
->
SetStaticText
(
mainGame
->
stCardListTip
,
32
0
,
mainGame
->
guiFont
,
str
.
c_str
());
irr
::
core
::
dimension2d
<
unsigned
int
>
dTip
=
mainGame
->
guiFont
->
getDimension
(
mainGame
->
stCardListTip
->
getText
())
+
irr
::
core
::
dimension2d
<
unsigned
int
>
(
10
,
10
);
irr
::
core
::
dimension2d
<
unsigned
int
>
dTip
=
mainGame
->
guiFont
->
getDimension
(
mainGame
->
stCardListTip
->
getText
())
+
irr
::
core
::
dimension2d
<
unsigned
int
>
(
10
,
10
);
mainGame
->
stCardListTip
->
setRelativePosition
(
recti
(
x
-
dTip
.
Width
/
2
,
y
-
10
,
x
+
dTip
.
Width
/
2
,
y
-
10
+
dTip
.
Height
));
s32
w
=
dTip
.
Width
/
2
;
if
(
x
-
w
<
10
)
x
=
w
+
10
;
if
(
x
+
w
>
670
)
x
=
670
-
w
;
mainGame
->
stCardListTip
->
setRelativePosition
(
recti
(
x
-
w
,
y
-
10
,
x
+
w
,
y
-
10
+
dTip
.
Height
));
mainGame
->
stCardListTip
->
setVisible
(
true
);
mainGame
->
stCardListTip
->
setVisible
(
true
);
}
}
}
}
...
...
gframe/game.cpp
View file @
ed87ef93
...
@@ -703,7 +703,7 @@ bool Game::Initialize() {
...
@@ -703,7 +703,7 @@ bool Game::Initialize() {
stTip
->
setTextAlignment
(
irr
::
gui
::
EGUIA_CENTER
,
irr
::
gui
::
EGUIA_CENTER
);
stTip
->
setTextAlignment
(
irr
::
gui
::
EGUIA_CENTER
,
irr
::
gui
::
EGUIA_CENTER
);
stTip
->
setVisible
(
false
);
stTip
->
setVisible
(
false
);
//tip for cards in select / display list
//tip for cards in select / display list
stCardListTip
=
env
->
addStaticText
(
L""
,
rect
<
s32
>
(
0
,
0
,
150
,
150
),
false
,
true
,
wCardSelect
,
-
1
,
true
);
stCardListTip
=
env
->
addStaticText
(
L""
,
rect
<
s32
>
(
0
,
0
,
150
,
150
),
false
,
true
,
wCardSelect
,
TEXT_CARD_LIST_TIP
,
true
);
stCardListTip
->
setBackgroundColor
(
0xc0ffffff
);
stCardListTip
->
setBackgroundColor
(
0xc0ffffff
);
stCardListTip
->
setTextAlignment
(
irr
::
gui
::
EGUIA_CENTER
,
irr
::
gui
::
EGUIA_CENTER
);
stCardListTip
->
setTextAlignment
(
irr
::
gui
::
EGUIA_CENTER
,
irr
::
gui
::
EGUIA_CENTER
);
stCardListTip
->
setVisible
(
false
);
stCardListTip
->
setVisible
(
false
);
...
...
gframe/game.h
View file @
ed87ef93
...
@@ -599,6 +599,7 @@ extern Game* mainGame;
...
@@ -599,6 +599,7 @@ extern Game* mainGame;
#define BUTTON_CARD_4 234
#define BUTTON_CARD_4 234
#define SCROLL_CARD_SELECT 235
#define SCROLL_CARD_SELECT 235
#define BUTTON_CARD_SEL_OK 236
#define BUTTON_CARD_SEL_OK 236
#define TEXT_CARD_LIST_TIP 237
#define BUTTON_CMD_ACTIVATE 240
#define BUTTON_CMD_ACTIVATE 240
#define BUTTON_CMD_SUMMON 241
#define BUTTON_CMD_SUMMON 241
#define BUTTON_CMD_SPSUMMON 242
#define BUTTON_CMD_SPSUMMON 242
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment