Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
OotTheMonk committed May 7, 2024
2 parents c4b2161 + 2d7c258 commit f64eb1e
Show file tree
Hide file tree
Showing 123 changed files with 152 additions and 90 deletions.
Binary file added public/cardimages/CBThePlagueHive.webp
Binary file not shown.
Binary file modified public/cardimages/MST001.webp
Binary file not shown.
Binary file modified public/cardimages/MST002.webp
Binary file not shown.
Binary file modified public/cardimages/MST010.webp
Binary file not shown.
Binary file modified public/cardimages/MST025.webp
Binary file not shown.
Binary file modified public/cardimages/MST026.webp
Binary file not shown.
Binary file modified public/cardimages/MST032.webp
Binary file not shown.
Binary file modified public/cardimages/MST046.webp
Binary file not shown.
Binary file modified public/cardimages/MST047.webp
Binary file not shown.
Binary file modified public/cardimages/MST053.webp
Binary file not shown.
Binary file modified public/cardimages/MST080.webp
Binary file not shown.
Binary file modified public/cardimages/MST087.webp
Binary file not shown.
Binary file modified public/cardimages/MST088.webp
Binary file not shown.
Binary file modified public/cardimages/MST089.webp
Binary file not shown.
Binary file modified public/cardimages/MST090.webp
Binary file not shown.
Binary file modified public/cardimages/MST095.webp
Binary file not shown.
Binary file modified public/cardimages/MST096.webp
Binary file not shown.
Binary file modified public/cardimages/MST097.webp
Binary file not shown.
Binary file modified public/cardimages/MST098.webp
Binary file not shown.
Binary file modified public/cardimages/MST099.webp
Binary file not shown.
Binary file modified public/cardimages/MST100.webp
Binary file not shown.
Binary file modified public/cardimages/MST101.webp
Binary file not shown.
Binary file modified public/cardimages/MST102.webp
Binary file not shown.
Binary file modified public/cardimages/MST225.webp
Binary file not shown.
Binary file modified public/cardimages/MST226.webp
Binary file not shown.
Binary file modified public/cardimages/MST232.webp
Binary file not shown.
Binary file modified public/cardimages/MST233.webp
Binary file not shown.
Binary file modified public/cardimages/MST453.webp
Binary file not shown.
Binary file modified public/cardimages/MST495.webp
Binary file not shown.
Binary file added public/cardimages/WTR092-T.webp
Binary file not shown.
Binary file added public/cardimages/WTR098-T.webp
Binary file not shown.
Binary file added public/cardimages/WTR099-T.webp
Binary file not shown.
Binary file added public/cardimages/WTR100-T.webp
Binary file not shown.
Binary file added public/cardimages/WTR172-T.webp
Binary file not shown.
Binary file added public/cardsquares/BLOODDEBT.webp
Binary file not shown.
Binary file added public/cardsquares/CBThePlagueHive.webp
Binary file not shown.
Binary file modified public/cardsquares/MST001.webp
Binary file not shown.
Binary file modified public/cardsquares/MST002.webp
Binary file not shown.
Binary file modified public/cardsquares/MST010.webp
Binary file not shown.
Binary file modified public/cardsquares/MST025.webp
Binary file not shown.
Binary file modified public/cardsquares/MST026.webp
Binary file not shown.
Binary file modified public/cardsquares/MST032.webp
Binary file not shown.
Binary file modified public/cardsquares/MST046.webp
Binary file not shown.
Binary file modified public/cardsquares/MST047.webp
Binary file not shown.
Binary file modified public/cardsquares/MST053.webp
Binary file not shown.
Binary file modified public/cardsquares/MST080.webp
Binary file not shown.
Binary file modified public/cardsquares/MST087.webp
Binary file not shown.
Binary file modified public/cardsquares/MST088.webp
Binary file not shown.
Binary file modified public/cardsquares/MST089.webp
Binary file not shown.
Binary file modified public/cardsquares/MST090.webp
Binary file not shown.
Binary file modified public/cardsquares/MST095.webp
Binary file not shown.
Binary file modified public/cardsquares/MST096.webp
Binary file not shown.
Binary file modified public/cardsquares/MST097.webp
Binary file not shown.
Binary file modified public/cardsquares/MST098.webp
Binary file not shown.
Binary file modified public/cardsquares/MST099.webp
Binary file not shown.
Binary file modified public/cardsquares/MST100.webp
Binary file not shown.
Binary file modified public/cardsquares/MST101.webp
Binary file not shown.
Binary file modified public/cardsquares/MST102.webp
Binary file not shown.
Binary file modified public/cardsquares/MST225.webp
Binary file not shown.
Binary file modified public/cardsquares/MST226.webp
Binary file not shown.
Binary file modified public/cardsquares/MST232.webp
Binary file not shown.
Binary file modified public/cardsquares/MST233.webp
Binary file not shown.
Binary file modified public/cardsquares/MST453.webp
Binary file not shown.
Binary file modified public/cardsquares/MST495.webp
Binary file not shown.
Binary file added public/cardsquares/WTR092-T.webp
Binary file not shown.
Binary file added public/cardsquares/WTR172-T.webp
Binary file not shown.
Binary file modified public/crops/MST001_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST002_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST010_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST025_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST026_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST032_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST046_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST047_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST053_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST080_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST087_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST088_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST089_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST090_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST095_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST096_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST097_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST098_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST099_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST100_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST101_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST102_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST225_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST226_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST232_cropped.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/crops/MST233_cropped.png
Binary file modified public/crops/MST453_cropped.png
Binary file added public/crops/WTR092-T_cropped.png
Binary file added public/crops/WTR098-T_cropped.png
Binary file added public/crops/WTR099-T_cropped.png
Binary file added public/crops/WTR100-T_cropped.png
Binary file added public/crops/WTR172-T_cropped.png
2 changes: 1 addition & 1 deletion src/app/ParseGameState.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ function ParseEquipment(input: any) {

export default function ParseGameState(input: any) {
const result: GameState = {
gameInfo: { gameID: 0, playerID: 0, authKey: '', isPrivate: false },
gameInfo: { gameID: 0, playerID: 0, authKey: '', isPrivateLobby: false },
gameDynamicInfo: {},
playerOne: {},
playerTwo: {},
Expand Down
2 changes: 1 addition & 1 deletion src/features/GameStaticInfo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ export default interface GameStaticInfo {
gameID: number;
playerID: number;
authKey: string;
isPrivate: boolean;
isPrivateLobby: boolean;
roguelikeGameID?: number;
altArts?: AltArt[];
isRoguelike?: boolean;
Expand Down
4 changes: 2 additions & 2 deletions src/features/game/GameSlice.ts
Original file line number Diff line number Diff line change
Expand Up @@ -479,8 +479,8 @@ export const gameSlice = createSlice({
state.isUpdateInProgress = false;
state.isPlayerInputInProgress = false;

state.gameInfo.isPrivate =
action.payload.isPrivateLobby ?? state.gameInfo.isPrivate;
state.gameInfo.isPrivateLobby =
action.payload.isPrivateLobby ?? state.gameInfo.isPrivateLobby;
state.gameDynamicInfo.lastUpdate = action.payload.lastUpdate;
state.chatLog = action.payload.gameLog?.split('<br>');
state.playerTwo.Name = action.payload.theirName;
Expand Down
3 changes: 2 additions & 1 deletion src/features/options/cardBacks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ export const CARD_BACK = {
'75': 'CBColdFoilControl',
'76': 'CBDailyFab',
'77': 'CBRighteousGaming',
'78': 'CBRighteousGaming2'
'78': 'CBRighteousGaming2',
'79': 'CBThePlagueHive'
} as { [key: string]: string };

export const PLAYMATS = {
Expand Down
1 change: 1 addition & 0 deletions src/interface/API/GetLobbyInfo.php.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ export interface Deck {
quiverSB?: Weapon[];
handsSB: Weapon[];
demiHero?: string[];
modular?: string[];
cardDictionary?: CardData[];
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export default function CardPopUp({
const [windowWidth, windowHeight] = useWindowDimensions();

const handleMouseEnter = () => {
if (ref.current === null || isHidden === true || cardNumber === "ENDSTEP" || cardNumber === "ENDTURN" || cardNumber === "RESUMETURN" || cardNumber === "PHANTASM" || cardNumber === "MIRAGE" || cardNumber === "FINALIZECHAINLINK" || cardNumber === "DEFENDSTEP" || cardNumber == "ATTACKSTEP" || cardNumber == "CardBack" || cardNumber == "NONE00") {
if (ref.current === null || isHidden === true || cardNumber === "ENDSTEP" || cardNumber === "ENDTURN" || cardNumber === "RESUMETURN" || cardNumber === "PHANTASM" || cardNumber === "MIRAGE" || cardNumber === "FINALIZECHAINLINK" || cardNumber === "DEFENDSTEP" || cardNumber == "ATTACKSTEP" || cardNumber == "CardBack" || cardNumber == "NONE00" || cardNumber == "BLOODDEBT") {
return;
}
const rect = ref.current.getBoundingClientRect();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ const ChainLinkSummary = ({
<h3 className={styles.title}>{'Chain Link Summary'}</h3>
</div>
<div className={styles.cardListCloseIcon} onClick={closeCardList}>
<FaTimes title="close dialog" />
<FaTimes title="Close Dialog" />
</div>
</div>
{content}
Expand Down
4 changes: 2 additions & 2 deletions src/routes/game/components/elements/chatBox/ChatBox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ export default function ChatBox() {
})
.map((message) => {
return message
.replace('Player 1', `<b>${amIPlayerOne ? myName : oppName}</b>`)
.replace('Player 2', `<b>${amIPlayerOne ? oppName : myName}</b>`);
.replace('Player 1', `<b>${amIPlayerOne ? myName.substring(0, 15) : oppName.substring(0, 15)}</b>`)
.replace('Player 2', `<b>${amIPlayerOne ? oppName.substring(0, 15) : myName.substring(0, 15)}</b>`);
});

useEffect(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,15 @@
.quickChatButton {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 1em;
gap: 0.5em;
}

.quickChatButton button {
font-size: 0.85em;
font-weight: 550;
padding: 0;
padding: 0.3em;
margin: 0;
margin-top: 0.1rem;
}

.popOver {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@
.fullLog {
overflow-y: scroll;
font-size: medium;
-moz-user-select: text;
-khtml-user-select: text;
-webkit-user-select: text;
-ms-user-select: text;
user-select: text;
}

.cardListBox.reduced {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ function OptionsMenuToggle() {
aria-label="Toggle main menu"
title="Options Menu"
onClick={() => toggleMenu()}
data-tooltip="Options Menu"
data-tooltip="Settings Menu"
data-placement="bottom"
>
<GiHamburgerMenu aria-hidden="true" fontSize={'1.75em'} />
Expand Down
30 changes: 17 additions & 13 deletions src/routes/game/components/elements/optionsMenu/OptionsMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ import OptionsSettings from './OptionsSettings';
import { shallowEqual } from 'react-redux';

const OptionsContent = () => {
const { gameID, playerID, isPrivate } = useAppSelector(
const { gameID, playerID, isPrivateLobby } = useAppSelector(
getGameInfo,
shallowEqual
);
const dispatch = useAppDispatch();
const navigate = useNavigate();
const [allowSpectator, setAllowSpectator] = useState(false);

const gameURL = `http://fe.talishar.net/game/play/${gameID}`;
const gameURL = `http://talishar.net/game/play/${gameID}`;

const clickCloseOptionsHandler = () => {
dispatch(closeOptionsMenu());
Expand All @@ -38,11 +38,11 @@ const OptionsContent = () => {
dispatch(submitButton({ button: { mode: PROCESS_INPUT.CONCEDE_GAME } }));
};

const clickPlayLegacyHandler = async (e: React.MouseEvent) => {
/* const clickPlayLegacyHandler = async (e: React.MouseEvent) => {
e.preventDefault;
await screenfull.exit();
window.location.href = `https://legacy.talishar.net/game/NextTurn4.php?gameName=${gameID}&playerID=${playerID}`;
};
}; */

// going to main menu means you concede the game
const handleClickMainMenuButton = async (e: React.MouseEvent) => {
Expand Down Expand Up @@ -108,16 +108,13 @@ const OptionsContent = () => {
<OptionsSettings />
</div>
<div className={styles.column}>
<h3>Navigation</h3>
<h3>General</h3>
<div className={styles.buttonColumn}>
<button className={styles.buttonDiv} onClick={clickPlayLegacyHandler}>
Legacy Talishar Client
</button>
<button
className={styles.buttonDiv}
onClick={handleClickMainMenuButton}
>
Home Page
Homepage
</button>
{playerID !== 3 && ( // If not a spectator then can change options
<>
Expand All @@ -141,7 +138,14 @@ const OptionsContent = () => {
>
Report Player
</button>
<button
</>
)}
</div>
<h3>Gamestate Correction</h3>
<div className={styles.buttonColumn}>
{playerID !== 3 && ( // If not a spectator then can change options
<>
<button
className={styles.buttonDiv}
onClick={clickUndoButtonHandler}
>
Expand All @@ -164,7 +168,7 @@ const OptionsContent = () => {
</div>
<h3>Invite Spectators</h3>
<div className={styles.buttonColumn}>
{isPrivate && allowSpectator ? (
{isPrivateLobby && !allowSpectator ? (
<>
<button
style={{ marginTop: '0.5em' }}
Expand Down Expand Up @@ -214,15 +218,15 @@ export default function OptionsMenu() {
>
<div className={styles.optionsTitleContainer}>
<hgroup className={styles.optionsTitle}>
<h2 className={styles.title}>Main Options</h2>
<h2 className={styles.title}>Settings Menu</h2>
<h4></h4>
</hgroup>
<div
className={styles.optionsMenuCloseIcon}
onClick={closeOptions}
data-testid="close-button"
>
<FaTimes title="close options menu" />
<FaTimes title="Close Settings Menu" />
</div>
</div>
<OptionsContent />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ const OptionsSettings = () => {
</fieldset>
<fieldset>
<legend>
<strong>Skip overrides</strong>
<strong>Skip Overrides</strong>
</legend>
<label className={styles.optionLabel}>
<input
Expand Down Expand Up @@ -331,7 +331,7 @@ const OptionsSettings = () => {
})
}
/>
Enable Manual Mode (for board state corrections)
Enable Manual Mode
</label>
<label className={styles.optionLabel}>
<input
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ export default function PlayerInputPopUp() {
</div>
{inputPopUp.popup?.canClose ? (
<div className={styles.inputPopUpCloseIcon} onClick={onPassTurn}>
<FaTimes title="close popup" />
<FaTimes title="Close Popup" />
</div>
) : null}
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export default function PlayerName(player: Player) {
title="I am a patron of PvtVoid!"
/>
) : null}
{playerName}
{playerName?.substring(0, 30)}
</div>
);
}
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export const CardListZone = () => {
<h3 className={styles.title}>{cardList?.name}</h3>
</div>
<div className={styles.cardListCloseIcon} onClick={closeCardList}>
<FaTimes title="close dialog" />
<FaTimes title="Close Dialog" />
</div>
</div>
{cardList?.apiCall ? (
Expand Down
7 changes: 6 additions & 1 deletion src/routes/game/create/CreateGame.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@
color: red;
}

.disclaimer {
padding: 1px;
text-align: center;
}

.button {
color: var(--primary-inverse);
margin-top: 32px;
Expand All @@ -27,5 +32,5 @@
}

.formContainer > h3 {
margin-bottom: 0.75em;
margin-bottom: 0.5em;
}
21 changes: 12 additions & 9 deletions src/routes/game/create/CreateGame.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -115,14 +115,17 @@ const CreateGame = () => {
<div>
<article className={styles.formContainer}>
<h3>Create New Game</h3>
{/* <p className={styles.fieldError}>
<FaExclamationCircle /> Warning - In 1h at 11:00 AM CET a push for the new MST keyword <b>Cloaked</b> will be pushed to the live servers. The games in progress will crash and new games will be required.
</p> */}
<p>
<small>
Talishar is an open-source, fan-made platform not associated with
LSS. It may not be a completely accurate representation of the Rules
as Written. If you have questions about interactions or rulings,
please contact the judge community for clarification.
</small>
</p>
<small className={styles.disclaimer}>
Talishar is an open-source, fan-made platform not associated with
LSS. It may not be a completely accurate representation of the Rules
as written. If you have questions about interactions or rulings,
please contact the judge community for clarification.
</small>
</p>
<form onSubmit={handleSubmit(onSubmit)}>
<div className={styles.formInner}>
{isLoggedIn && !isLoading && (
Expand Down Expand Up @@ -160,7 +163,7 @@ const CreateGame = () => {
/>
<fieldset>
<label>
Deck Link:
Deck Link
<input
type="text"
id="fabdb"
Expand Down Expand Up @@ -264,8 +267,8 @@ const CreateGame = () => {
}
/>
Single Player 🤖
<div>&nbsp;</div>
</label>

{isLoggedIn && (isPatron == "1") && (
<label>
AI Deck
Expand Down
4 changes: 2 additions & 2 deletions src/routes/game/lobby/Lobby.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
}

.smallButton {
gap: 1em;
gap: 0.5em;
font-size: 0.85em;
font-weight: 550;
padding: 0;
padding: 0.3em;
margin: 0;
}

Expand Down
Loading

0 comments on commit f64eb1e

Please sign in to comment.