OK, here's the thing; Either I still don't understand this, or it's a bug, Both are a possibility.
This time I have gathered reinforcements however:
ffc script trace_warp{ void run(){
float map;
float screen;
while(true){
Waitframes(60);
map = Game->GetCurDMap();
screen = Game->GetCurDMapScreen();
Waitframe();
Trace(screen);
Waitframes(15);
Link->PitWarp(map,screen+1);
}
}
}
ffc script trace_map{
void run(){
float map;
float screen;
map = Game->GetCurDMap();
screen = Game->GetCurDMapScreen();
Waitframe();
Trace(map);
Trace(screen);
Waitframes(10);
}
}
Allegro log for trace_warp:
11.0000
12.0000
13.0000
14.0000
15.0000
8.0000
9.0000
10.0000
11.0000
12.0000
13.0000
14.0000
15.0000
8.0000
9.0000
10.0000
11.0000
Link most certainly won't stay within the 8x8 Dmap grid, and will be stuck in an 8 screen loop, notably on the 8-f screens.
While a run of trace_map revealed that interior Dmap screens are numbered 0-63, you can't actually warp there due to the above behavior.
Screens within a dmap are numbered very oddly; see if it's fixed in the next build.
Ah, Ok. I remembered you saying that Link isn't supposed to warp outside of a 64 screen Dmap, so just to clarify this somewhat I ran this again in two Dmaps. The first is an overworld type, and the second is an NES-dungeon type. Not sure if they are supposed to differ at all from eachother, but the didn't.
So now link can warp to all 128 screens in a map on a Dmap, and the way they are numbered in columbs from top-left to bottom right is:
0-15
16-31
32-47
48-63
64-.....etc.....is this the intended result?
0.0000
1.0000
2.0000
3.0000
4.0000
5.0000
6.0000
7.0000
8.0000
9.0000
10.0000
11.0000
12.0000
13.0000
14.0000
15.0000
16.0000
17.0000
18.0000
19.0000
20.0000
21.0000
22.0000
23.0000
24.0000
25.0000
26.0000
27.0000
28.0000
29.0000
30.0000
31.0000
32.0000
33.0000
34.0000
35.0000
36.0000
37.0000
38.0000
39.0000
40.0000
41.0000
42.0000
43.0000
44.0000
45.0000
46.0000
47.0000
48.0000
49.0000
50.0000
51.0000
52.0000
53.0000
54.0000
55.0000
56.0000
57.0000
58.0000
59.0000
60.0000
61.0000
62.0000
63.0000
64.0000
65.0000
66.0000
67.0000..etc
So, bugfixed?!?..
Basically, Link->Warp should work exactly the same as setting up a tile warp in ZQuest, or using the cheat.
Moreover, Game->GetCurDMapScreen() should return a number such that, when passed to Link->Warp, Link remains on that screen.
So all 128 ARE accesible then. ah.
What I seem to have is what you described but with a different numbering system from the tilewarp dropdown box in zq.
To Link->PitWarp to screen 22, that would be:
xxxxxxxxxxxxxxxx
xxxxxoxxxxxxxxxx
.......^here
if so then bugfixed as Link can now warp to any Dmap screen without using hex.
?
Where exactly you end up will completely depend on the x-offset of the dmap slider in question.
Setting a warp to 0x22 in a ZQ insta tile-warp, and passing 0x22 to Link->Warp, should send Link to the same screen. If not, that's a bug.
Sure thing, there was no offset in my test quest. But to make sure I'll re-test this with a few different scripts right now.
Hmm well that's not what i'm getting. Here's another test script:
ffc script warpy_time{
void run(){
while(true){
Waitframes(40);
Link->PitWarp(0,11);
Waitframes(40);
Link->PitWarp(0,22);
Waitframes(40);
Link->PitWarp(0,33);
Waitframes(40);
Link->PitWarp(0,44);
Waitframes(40);
Link->PitWarp(0,55);
Waitframes(40);
Link->PitWarp(0,66);
Waitframes(40);
Link->PitWarp(0,77);
Waitframes(40);
}}}
Here's where Link warps to in order of top to bottom:
xxxxxxxxxxxoxxxx
xxxxxxoxxxxxxxxx
xoxxxxxxxxxxxoxx
xxxxxxxxoxxxxxxx....etc..
You're passing in 11, 22, etc, decimal, not hex. Try 0x11, 0x22, etc.
Decimal works, yay.
ffc script warpy_time{
void run(){
int screen;
while(true){
Waitframes(40);
Link->PitWarp(0,0x11);
screen = Game->GetCurDMapScreen();Trace(screen);
Waitframes(40);
Link->PitWarp(0,0x22);screen = Game->GetCurDMapScreen();Trace(screen);
Waitframes(40);
Link->PitWarp(0,0x33);screen = Game->GetCurDMapScreen();Trace(screen);
Waitframes(40);
Link->PitWarp(0,0x44);screen = Game->GetCurDMapScreen();Trace(screen);
Waitframes(40);
Link->PitWarp(0,0x55);screen = Game->GetCurDMapScreen();Trace(screen);
Waitframes(40);
Link->PitWarp(0,0x66);screen = Game->GetCurDMapScreen();Trace(screen);
Waitframes(40);
Link->PitWarp(0,0x77);screen = Game->GetCurDMapScreen();Trace(screen);
}}}
17.0000
34.0000
51.0000
68.0000
85.0000
102.0000
119.0000
17.0000
34.0000
51.0000
68.0000
85.0000
102.0000
119.0000
Fixed!