Comments (3)
mkxp uses the single-precision floating-point format for this and similar attributes while RGSS uses double-precision.
However even if it would be changed to double-precision you would still be able to find differences in very few cases. 1.8.1 is ancient and the code to convert between floating-point numbers and strings contained some bugs.
from mkxp.
Maybe a wrapper class is one possible solution?
- Rename the
Sprite
class implemented by mkxp asMkxpSprite
- Define new
Sprite
class that inherits fromMkxpSprite
- Override
zoom_x
andzoom_x=
method.
class Sprite < MkxpSprite
attr_reader :zoom_x
def zoom_x=(val)
@zoom_x = val
super
end
end
It will be nice if mkxp can implement it. Make mkxp behave more consistent with original engine.
The following is a surprising behavior I found in current implementation:
# let (xxxxx / yyyyy.to_f) to be 0.9
sprite.zoom_x = xxxxx / yyyyy.to_f
# ...
# ...
# sprite.zoom_x is 0.8999 here and fail to enter the if-condition since 0.8999 is not larger than or equals to 0.9
if sprite.zoom_x >= 0.9
# ...
# ...
end
from mkxp.
I am curious what exact in-game issues this inaccuracy is causing.
from mkxp.
Related Issues (20)
- Trouble compiling on Ubuntu with Ruby 2.6 HOT 14
- Fluidsynth-related compilation error on Arch Linux HOT 2
- Search for mkxp.conf in more paths HOT 3
- Some (maybe) helpful font size stuff!
- High-level RPG Maker MV emulation support aka "mkmv" HOT 5
- Error "The RGSS script seems to be stuck and mkxp will now quit." HOT 6
- Fonts are completely broken HOT 1
- How compile? and another dunno HOT 2
- incorrect serialization of multi-dimensional tables if {y,z}size <= 1
- BGM should not be played before ME when calling me_play and bgm_play together
- Error 'Script 'fuyllscreen' line 14: NameError occureduninitialized constant Module::Win32API' HOT 2
- Video reproduction implementation missing. HOT 5
- Best Way to Detect if Running mkxp? HOT 1
- Does mkxp recognize multiple RTPs? HOT 2
- openReadEnumCB just gives up if a closely matching filename is found
- pathCache search keeps searching even after file is found
- Window content won't draw outside of a 640x480 region HOT 2
- Sound system initialization should not be compulsory
- Error With PKGConfig and CMake HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mkxp.