dkforest

A forum and chat platform (onion)
git clone https://git.dasho.dev/n0tr1v/dkforest.git
Log | Files | Refs | LICENSE

commit 0fb2677856f58732b4205d59bede7fd58a5c6d31
parent 8c6804d32c0a6f1133d922d95178edf8715ef835
Author: n0tr1v <n0tr1v@protonmail.com>
Date:   Mon, 11 Dec 2023 21:40:32 -0500

cleanup

Diffstat:
Mpkg/web/handlers/poker/poker.go | 16+++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/pkg/web/handlers/poker/poker.go b/pkg/web/handlers/poker/poker.go @@ -25,6 +25,8 @@ const MinTimeAfterGame = 10 const BackfacingDeg = "-180deg" const BurnStackX = 400 const BurnStackY = 30 +const DealX = 155 +const DealY = 130 const DealerStackX = 250 const DealerStackY = 30 const NbCardsPerPlayer = 2 @@ -749,8 +751,8 @@ func dealerThread(db *database.DkfDB, g *PokerGame, roomID string) { ID: "card" + itoa(idx), Name: card, Idx: idx, - Top: 130, - Left: 155 + (dealCardIdx * 55), + Top: DealY, + Left: DealX + (dealCardIdx * 55), Reveal: true, } PokerPubSub.Pub(roomTopic, evt) @@ -1660,11 +1662,11 @@ body { .dev_seat5_card2 {} .dev_seat6_card1 { top: 270px; left: 70px; transform: rotateZ(10deg); width:50px; height:70px; background-color: white; position: absolute; } .dev_seat6_card2 {} -.dev_community_card1 {top: 130px; left: calc(155px + 1 * 55px); width:50px; height:70px; background-color: white; position: absolute; } -.dev_community_card2 {top: 130px; left: calc(155px + 2 * 55px); width:50px; height:70px; background-color: white; position: absolute; } -.dev_community_card3 {top: 130px; left: calc(155px + 3 * 55px); width:50px; height:70px; background-color: white; position: absolute; } -.dev_community_card4 {top: 130px; left: calc(155px + 4 * 55px); width:50px; height:70px; background-color: white; position: absolute; } -.dev_community_card5 {top: 130px; left: calc(155px + 5 * 55px); width:50px; height:70px; background-color: white; position: absolute; } +.dev_community_card1 {top: ` + itoa(DealY) + `px; left: calc(` + itoa(DealX) + `px + 1 * 55px); width:50px; height:70px; background-color: white; position: absolute; } +.dev_community_card2 {top: ` + itoa(DealY) + `px; left: calc(` + itoa(DealX) + `px + 2 * 55px); width:50px; height:70px; background-color: white; position: absolute; } +.dev_community_card3 {top: ` + itoa(DealY) + `px; left: calc(` + itoa(DealX) + `px + 3 * 55px); width:50px; height:70px; background-color: white; position: absolute; } +.dev_community_card4 {top: ` + itoa(DealY) + `px; left: calc(` + itoa(DealX) + `px + 4 * 55px); width:50px; height:70px; background-color: white; position: absolute; } +.dev_community_card5 {top: ` + itoa(DealY) + `px; left: calc(` + itoa(DealX) + `px + 5 * 55px); width:50px; height:70px; background-color: white; position: absolute; } #seat1 { position: absolute; top: 80px; left: 690px; } #seat2 { position: absolute; top: 200px; left: 700px; }