Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
lol, I was afraid Dirichlet's theorem was needed. I don't handle square-free techniques well, so I supposed there were infinite solutions n = 13²*p such that n + 1 = 2*3³*q , where p and q are both primes. This might be the case...
So, we can conclude that 54q - 169p =1, a diophantine equation that has solutions:
q = 169*x + 72 ; p = 54*x + 23
According to Dirichlet's theorem, there're infinitely many x's such that q are prime and p are prime. However, I can't know if both conditions are met simultaneously infinitely many times :( .
I will try to write FractalFusion's solution in a paper. BTW, there must be some clever solution, because the smallest n is 13013, kinda big to discover without a computer within 1.5 hours (3 problems/4.5 hours).
EDIT: typo.
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
My script is not working properly with the latest version of BizHawk (1.11.3), if you use the Direct3D9 display method. If you wanna a simple script, with only the hitboxs (some are wrong, though), there's one at the BizHawk folder > Lua > SNES > Super Mario World.lua
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
Hello and welcome to TASVideos!
You forgot to say what hack you are playing, but the name of the file seems to indicate this one. The ROM is not identical to yours, but luckly the movie didn't desync.
This glitch is described here:
BTW,
1) this post would be better at the SMW thread:
http://tasvideos.org/forum/viewtopic.php?t=1571
2) When uploading BizHawk's movies, it's better to share the bk2 file, not huge tasproj ones.
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
Sorry for the confusion, you were right. Global variables are stored in _G and are slower. Tables are slightly faster in the array part, if compared to the hash part. Anything that's not [1, n] (i.e., outside the reach of ipairs) will be hashed.
But I don't think it's a nice idea to optimize this at the cost of a dirty code.
Little experiment: without this Lua script, I get 67-70 fps (SNEShawk). With it, the fps drops to 62-65, which is really small after 10 thousand loops per frame.
Language: Lua
local tab = {entry = "value"}
local val
while true do
for i = 1, 10000 do
val = tab.entry
end
gui.text(0, 80, val)
emu.frameadvance()
end
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
EDIT: Table and string creation every frame can slowdown things. Table access, no matter the type of the key entry, is pretty optimized. Every local variable is internally stored in a table anyway, so you don't need to worry about it.
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
Thanks. Another thing:
1) The function client.SetGameExtraPadding(a, b, c, d) is causing problems to client.bufferheight() and client.bufferwidth(), whenever a, b, c or d are different from 0. Instead of returning the dimensions of the game area, they return 0. However, client.SetClientExtraPadding doesn't cause this.
2) Typos in the description:
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
1) When the display method is Direct3D9, some arithmetic operations go nuts. For instance, the following command will print false, not true, like it correctly did before.
This is responsible for messing up the colours I was using. Does not seem to be specific to any core and doesn't happen with OpenGL or GDI+ methods!
2) (old, but less problematic) When you print something using the console, the string "\nNULL" is appended at the end.
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
I make like this:
Language: Lua
while true do
--- code
-- Frame advance: hack for performance
if client.ispaused() then
emu.yield()
gui.clearGraphics()
gui.cleartext()
else
emu.frameadvance()
end
end
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
This happens because you need to create another table and copy the values, one by one.
To copy a table, use the functions of this tutorial:
http://lua-users.org/wiki/CopyTable
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
Some exits, in the small-only category, can only be gotten if Mario uses an enemy to access a hard area, that normally would require the cape or Yoshi.
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
Welcome to TASVideos, CatlyNat. A few comments on:
1) Timing:
It begins when the video game is turned on, not when you gain control over Mario (as in RTA). You lost time in the initial menu.
2) Goal:
Your goal isn't very good, because it gives the impression that you won't hurt any enemy, not even the bosses. When you say "I didn't want to touch the enemy, as I also wanted to try and not bother with enemies at all",you make things more arbitrary yet.
3) Optimization:
You should use frame advance all the time inside the level, because SMW runs are already very optimized. For instance, in Yoshi Island 3 you finished the level with clock 258, but it's easy to end with 259 in RTA.
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
It crashes more if your machine is less powerful, indeed. Or if it's full of worms diminishing the performance.
Laggy means the emulator speed is slow? There's no way to make cycle accurate emulation as fast as Snes9x, which uses speedhacks. But if you mean more lag in-game, it is quite the same of the console. By the way, Snes9x 1.5x has about the same lag.
BizHawk/lsnes at least offer memory domains, instead of the absolute address of Snes9x, which require the 7E,7F banks. You can use absolute addresses too in lsnes, but it's not recommended.
Example:
Language: lua
local some_address = memory.readbyte(0x7e0013) -- Snes9x
local some_address = memory.readbyte("WRAM", 0x0013) -- lsnes
local some_address = mainmemory.readbyte(0x0013) -- BizHawk
The domains are specially fine if you wanna investigate outside WRAM.
SNEShawk updates the values sooner than Snes9x/lsnes. For instance, if you press B and do a frame advance, the character might be with "jumping" vertical speed immediately, instead of requiring another frame advance. Plus, Biz/lsnes can run the script when the game is paused, which is awesome!
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
People sometimes remember the christian God when they proclaim atheistic views. While I'm pretty convinced that Bible's God doesn't exist, this doesn't exclude all sorts of possible Gods.
Specially a God that isn't benevolent (the problem of evil) or isn't omnipotent/omniscient (to avoid possible ontological problems). For this kinds of God, I think atheist can't provide arguments against.
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
The game I'm playing is faster in some parts, if the there's no memory card to save the game. I didn't find, in the Virtual Pads tool, the possibility to remove the memory card or to start a movie without it. Can it be currently done?
Editor, Experienced Forum User, Published Author, Player
(158)
Joined: 1/10/2012
Posts: 673
Location: Brazil
Let f(n) be √n - log(n), for n > 0, n real. I assume log is the decimal logarithm.
So, f'(n) = 1/(2*√n) - 1/(ln(10)*n)
Since
f is continuous;
f' has only one zero at n = 4/(ln10)², at which f(n) > 0 (a global maximum or minimum);
f(100), for instance, is known to be bigger than f(4/(ln10)²);
We can conclude that n = 4/(ln10)² is a minimum of f and that f > 0 for all n's.
Edit: tags/grammar