-
Notifications
You must be signed in to change notification settings - Fork 5
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
Port from GObject to GLib and Python 2 to 3 #14
Conversation
Nice work, I think you can improve on your commit messages, making commits should help. Edited your opening comment, adding |
Thanks. Tested.
Having now experienced it, the toolbar adds no value that couldn't be added by a stop or quit button instead. Activity logs were noisy, frequent mentions of "keypress event" and 'WARNING: erroneous pipeline: syntax error". |
Thanks. |
Can we change the colour of letter for a loco from white to something else in order to avoid this.? |
Thanks for the update. Is 3d64076 correct way to solve this? Is the activity better always fullscreen, and never show the toolbar? We have quite a few activities that do this. My observation in earlier testing is that the toolbar did appear without being asked for, and also that it affected play. Would a better way to solve this be to find out what is causing fullscreen mode to turn off, and stop doing that? |
Thanks @quozl for review. Actually I thought you are saying the reverse of it. I thought we have to display toolbar every time. So I have done that. There was confusion.
aa9fd66 should fixed these both. |
3d64076
to
e013fd5
Compare
How do I test? Clicked and toolbar still isn't visible. |
@chimosky This was the main goal to make toolbar not visible because it was affecting the play. |
I'm not sure changing colour alone is best way. Number or letter is to be distinguished from the background image. There are several ways to do this. Here are some of them;
I'm not going to be prescriptive on which way to use. You may think up some other method. |
I'm fine with a toolbar, or without a toolbar, as long as these conditions can be satisfied;
|
I am not sure how to fix this issue but as I looked at code of game.py, it uses random.uniform for generating location of a loco, as numbers are generated randomly and uniform method having very less range, it can possibly increases chances of collapsing of two locos. and Also I found same issue during press of uppercase keys. It may be possible that increasing the range of uniform can solve this, but I am not sure about it. |
I've not examined the code. A collision detection algorithm should be used; so that when a location is randomly generated it is checked to see if it is close to another location already used, and if so the algorithm would try again. |
I've examined the code, the history of commits, and made some more tests. The collision is expected and the solution is to drag the Loco. The same for when the letter under the Loco is drawn against a white background. I've marked those test results as resolved. |
Tested e013fd5.
|
@quozl You were supposed to test the latest commit aa9fd66 .
The toolbar does not appear at the end of the game. I suggest you to check once with aa9fd66 . |
Thanks. Tested aa9fd66 on Ubuntu 20.04 on an OLPC NL3 laptop. The toolbar did not appear.
|
I am not getting as we need to fix only for 1200x900 resolution or for all other systems as well. |
I can see how you could get confused. Many Sugar activities were designed for a fixed resolution of 1200x900 on the OLPC XO laptop, with no intention at the time for the activity to be resolution independent, adaptable, or responsive. This is certainly one of those kinds of activities, as it has bitmap instead of vector graphics. The OLPC XO laptop is unlikely to run Python 3 activities because of the huge cost of upgrading the rest of the software stack; firmware, kernel, graphics drivers, and so forth. So as soon as an activity tries to transition from Python 2 to Python 3, it brings with it (a) not having to maintain the 1200x900 resolution support, and (b) having to maintain other resolutions and responsiveness. There are many ways to adapt this activity to other resolutions; best solution is one that works on all expected resolutions, by calculating where to place the pixmaps, and how to either wrap, tile, or place them within letterboxes. |
Thanks @JuiP . The second screenshot is fine and I don't know what you are
talking about.
In 1st one , the greeting message window is slightly shifted to right. I
need to fix that only.
…On Sat 6 Jun, 2020, 7:58 AM Jui Pradhan, ***@***.***> wrote:
Hi, I'm testing on a 800*600 VM and here is a screenshot of what the
display looks like. I looked at the code, the activity toolbar is defined
but it isn't visible for me. I used ctrl to exit.
[image: Loco1]
<https://user-images.githubusercontent.com/46154968/83934030-381f5a80-a7cb-11ea-9062-eec643a05e97.png>
Also, I'm not sure if the second screenshot is how it is supposed to be.
[image: locosugar]
<https://user-images.githubusercontent.com/46154968/83934045-57b68300-a7cb-11ea-9136-c5a2ed95ecff.png>
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#14 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKZH63OF77K6M3BVV7ZMAPTRVGSVFANCNFSM4LTAH3DA>
.
|
Thanks. I actually edited my comment. Can you tell me your test display size? |
Yeah , Tested on 1920X1080 . The background image is perfect displaying in yours just the problem is with greeting message window size. We need to fix that. |
@Saumya-Mishra9129 , I have fixed it in 88fadc8, you can cherry-pick the commit. :) The ghost loco happened for me too. I tested master, couldnt reproduce on master. |
Thanks I need to test it. I still don't know how it is coming. However I tested 88fadc8 . It is not working for me look Update- look into comments of 88fadc8. |
Sorry, that was a reckless mistake. Fixed in 0cc356e |
I am worried about it. I did subsequent rounds of testing, It happens sometimes, not every time. What I think is that at the end of a particular level, whenever a loco couldn't delete, It happens as a ghost logo. I don't think it could be because of Python3 changes. It happens in master as well. |
Thanks a lot @srevinsaju You did really a great work while reviewing.
Yeah I am thinking it as a good suggestion, we can do it, to increase visual impact on user. |
I agree @Saumya-Mishra9129 @srevin. What do you think @chimosky @quozl ?
Yes, you are probably right. @Saumya-Mishra9129 Have you found a way to fix it? I don't mind helping if you haven't already found a fix :) |
Thanks ,@JuiP I haven't fixed it yet. If you could do it would be great. |
@Saumya-Mishra9129 are you getting the ghost loco freqjuently; like more than 5 times while testing 10 times (approx); and is the ghost loco getting stuck at the same position? |
I have tested it 6 times, was able to reproduce it 2 times. It might be
what you are suggesting. For reference I'm using Debian buster sugar live
build
…On Fri, Jun 12, 2020, 20:42 Srevin Saju ***@***.***> wrote:
@Saumya-Mishra9129 <https://github.com/Saumya-Mishra9129> are you getting
the ghost loco freqjuently; like more than 5 times while testing 10 times
(approx); and is the ghost loco getting stuck at the same position?
I tried looking into it, but was unable to reproduce. I have strong
suspicion if its an internal library difference like how it happened in
puklanapac and FractionBounce. Are you testing it on Sugar Live Build
(debian)?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#14 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALAEJWGIXZHIQJ5EBSJ3HS3RWJAVZANCNFSM4LTAH3DA>
.
|
I have tested with both packaged and live sugar . I am able to reproduce in both systems. I haven't tested puklanapac and FractionBounce. |
@Saumya-Mishra9129 @srevinsaju Update on the ghost loco bug - I tried reproducing it again, but couldn't. I'm not sure what has changed. I also looked at the code and couldn't find a possible reason for the ghost loco. |
Thanks for Update. Actually Why ghost loco happens and even when it happens, it's highly unpredictable here. The problem is still ambiguous for me, I also tried to look at code, I couldn't also find the reason. It also happens in master as well. So I guess better way could be to open an issue here. We can look for merge here then because the work here is completed and you can look for release also then. |
My guess is a logic error, or API balance. Sprites are being created, and the list of sprites is lost in some way. It is the kind of problem that should be solved before release. If one method of finding the cause does not work, try another method. If you've not yet used the Python debugger, now is one of those times it would be of benefit to have the skills. |
Update - @JuiP I have tried 16 times not able to reproduce ghost loco even once. I don't know what has happened now. |
I found the original game trailer? at https://www.youtube .com/watch?v=0m_d8_Nfi28, the last line of the description int he site it was published says "Clicking, double-clicking, dragging and typing a few sentences makes cuckoos get better and landscapes more friendly.". Maybe the by landscapes more friendly they mean, less ghost locos? The links to the original windows executable and XO are dead. EDIT: Removed the link to the site, the page is likely infected |
Thanks. Tested. Approved. No ghost loco in two cycles tested. |
Yes I agree, No ghost loco for me too. |
Reviewed, thanks. |
Fixes #9, Fixes #15, Fixes #10
@chimosky Kindly review changes.