Bug 2023051 - non-integers passed to game_setScreenShift in "engine"
Summary: non-integers passed to game_setScreenShift in "engine"
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: fillets-ng-data
Version: 39
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Nikolay Nikolov
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-11-14 10:52 UTC by Björn Persson
Modified: 2023-08-16 07:05 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-11-30 16:11:06 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Round the coordinates. (638 bytes, patch)
2023-05-01 07:46 UTC, Björn Persson
no flags Details | Diff

Description Björn Persson 2021-11-14 10:52:43 UTC
Description of problem:
The "engine" room crashes by passing non-integers to game_setScreenShift. Apparently the parameters need to be either rounded or truncated.

Version-Release number of selected component (if applicable):
fillets-ng-data-1.0.1-17.fc33.noarch

How reproducible:
Always.

Steps to Reproduce:
1. Load the room "Brm... Brm...", alias "engine".
2. Place a fish left of the engine.
3. Push the clock key into the engine.

Actual results:
main.cpp:117: ERROR script failure; error='/usr/share/fillets-ng/script/engine/code.lua:65: bad argument #1 to 'game_setScreenShift' (number has no integer representation)
stack traceback:
	[C]: in function `game_setScreenShift'
	/usr/share/fillets-ng/script/engine/code.lua:65: in function `subupdate'
	/usr/share/fillets-ng/script/engine/code.lua:250: in function `prog_update'
	/usr/share/fillets-ng/script/share/level_start.lua:81: in function `script_update'
	[string "script_update()"]:1: in main chunk'

Expected results:
No crash.

Comment 1 Ben Cotton 2021-11-30 16:11:06 UTC
Fedora 33 changed to end-of-life (EOL) status on 2021-11-30. Fedora 33 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 2 Ben Cotton 2022-02-08 21:24:11 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 36 development cycle.
Changing version to 36.

Comment 3 Ben Cotton 2023-04-25 16:46:03 UTC
This message is a reminder that Fedora Linux 36 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora Linux 36 on 2023-05-16.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
'version' of '36'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, change the 'version' 
to a later Fedora Linux version. Note that the version field may be hidden.
Click the "Show advanced fields" button if you do not see it.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora Linux 36 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora Linux, you are encouraged to change the 'version' to a later version
prior to this bug being closed.

Comment 4 Björn Persson 2023-05-01 07:46:49 UTC
Created attachment 1961386 [details]
Round the coordinates.

I looked up how to round numbers in Lua. Here's a patch to fix this crash.

Comment 5 Fedora Release Engineering 2023-08-16 07:05:03 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 39 development cycle.
Changing version to 39.


Note You need to log in before you can comment on or make changes to this bug.