Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue on displaying board on Ubuntu OS #1

Open
nikhiljangra264 opened this issue May 8, 2024 · 6 comments
Open

Issue on displaying board on Ubuntu OS #1

nikhiljangra264 opened this issue May 8, 2024 · 6 comments

Comments

@nikhiljangra264
Copy link

Description:
I have successfully run the chess-cli program on the terminal. The program provides options such as play vs human, play vs AI, and load. However, after selecting the play vs AI option and providing my name and other details, the program fails to display the board and doesn't accept any inputs. Similarly, the same issue persists when selecting play vs human. As a result, I had to forcefully close the program.

Details:
Operating System:
Ubuntu 22.04.4 LTS (Jammy Jellyfish)
PRETTY_NAME: Ubuntu
VERSION_ID: 22.04
VERSION: 22.04.4 LTS (Jammy Jellyfish)
VERSION_CODENAME: jammy
ID: ubuntu
ID_LIKE: debian

Terminal:
GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)
Copyright: © 2020 Free Software Foundation, Inc.

Issue Summary:
After selecting play vs AI or play vs human options in the chess-cli program, the board is not displayed.
The program fails to accept any inputs after selecting these options, leading to an unresponsive state.
This issue persists across both play vs AI and play vs human modes.

@rikkoder
Copy link
Owner

rikkoder commented May 8, 2024

I just tested it on an ubuntu based system, I couldn't reproduce the issue.
Can you try deleting build files and recompiling by running make. Also can you tell me the ncurses libraries installed on your system. (apt list --installed *ncurses*)

@nikhiljangra264
Copy link
Author

The issue still persist after rebuilding the program. Here is the output of apt list --installed *ncurses*

Listing... Done
libncurses-dev/jammy-updates,jammy-security,now 6.3-2ubuntu0.1 amd64 [installed,automatic]
libncurses5-dev/jammy-updates,jammy-security,now 6.3-2ubuntu0.1 amd64 [installed]
libncurses6/jammy-updates,jammy-security,now 6.3-2ubuntu0.1 amd64 [installed,automatic]
libncursesw5-dev/jammy-updates,jammy-security,now 6.3-2ubuntu0.1 amd64 [installed]
libncursesw6/jammy-updates,jammy-security,now 6.3-2ubuntu0.1 amd64 [installed,automatic]
ncurses-base/jammy-updates,jammy-updates,jammy-security,jammy-security,now 6.3-2ubuntu0.1 all [installed]
ncurses-bin/jammy-updates,jammy-security,now 6.3-2ubuntu0.1 amd64 [installed]

@rikkoder
Copy link
Owner

rikkoder commented May 9, 2024

can you share a picture of the board ? is the window completely blank or only pieces are missing ?
if only pieces are not showing you can try pressing 'a' which will change the pieces into ascii character (like 'N' for Knight)

@nikhiljangra264
Copy link
Author

I think the main issue is when you are clearing the display after start button.
( can you please mention the specific code that does this )
This is screencast of the program
Screencast from 09-05-24 12:40:34 PM IST.webm

@rikkoder
Copy link
Owner

can you try the latest commit on your machine ?
if you want to debug yourself ig what u want to look at is main_menu.c file, game_settings_menu func call is where the options are set and init_game func call starts the game.
if still the prob exists can u tell me if u r able to open load menu ?

@nikhiljangra264
Copy link
Author

nikhiljangra264 commented May 13, 2024

it's working but only if the terminal size above a specific size
but resizing cause segmentation fault.
Screenshot from 2024-05-13 14-25-06

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants