Get off raft flag
#1
Posted 07 March 2012 - 09:22 PM
I will be the first to admit I know absolutely nothing about scripting - except that it can do many miracles.
I need a custom flag that stops link when he is on the raft and returns him to the normal walking mode - just like when he ordinarily stops when there are no more flag 8's in a raft path. The only difference is that even if there are rafting flags (8 and 12) adjacent to this flag Link should not continue rafting to them. He simply gets off his raft and starts walking again.
If this isn't asking for too much from anyone, can anyone help me out? If it is asking too much can someone tell me that what I'm asking for is too much,it would take forever and that I shouldn't bother with this idea?
I have started reading Saffith's basic scripting tutorial and my head hurts
Many thanks.
#2
Posted 07 March 2012 - 11:56 PM
#3
Posted 08 March 2012 - 12:08 AM
Edited by James24, 08 March 2012 - 12:10 AM.
#4
Posted 08 March 2012 - 12:54 AM
#5
Posted 08 March 2012 - 01:12 AM
#6
Posted 08 March 2012 - 01:29 AM
const int LA_RAFTING = 6;
was the idea to change the action to
const int LA_WALKING = 1;
i dont know how to make it a flag but it could be an ffc.
i couldnt change linkaction rafting to walking with code there might be a way to do if item using = raft and distance =<5.
Edited by tox_von, 08 March 2012 - 02:05 AM.
#7
Posted 08 March 2012 - 02:22 AM
Thanks for the help guys and if it works, I'll send you a special Liberation Quest version with a very interesting rafting section as a token of my appreciation.
#8
Posted 08 March 2012 - 02:26 AM
#9
Posted 08 March 2012 - 03:25 AM
I looked at Russ's script file and from what I can tell the thing that acts on the flags is a global function inside a while(true) loop that runs every frame. He uses
screen->comboi to get the flag ID and then an if statement to decide how to change things.
Edited by James24, 08 March 2012 - 03:42 AM.
#10
Posted 08 March 2012 - 03:39 AM
ffc script RaftEnd {
void run() {
while(true) {
int com = Screen->ComboI[ComboAt(Link->X, Link->Y)];
if (com == raftyflag && Link->Action == 6) {
Link->Action = 1;
}
Waitframe();
}
}
}
Okay, that wasn't actually too hard. I haven't tested it in the player, but it compiles fine, and I don't see any reason why it shouldn't work. Just set the number at the top to whatever flag you want to be the "Get off raft" flag, and you're good to go.
Edit: Oh right! Make you sure you assign that script to a FCC on the screen. You don't have to put the FFC anywhere, just set it to a blank FFC that isn't combo 0 on every screen you want the flag to work on.
#11
Posted 08 March 2012 - 04:34 AM
Hmm...doesn't work because the normal rafting flags (8 and 12) don't recognize that as part of the raft path and hence won't send Link there. If those flags don't recognize it then the only way to get around that problem would be to design custom rafting flags. There goes that idea then.
Edited by James24, 08 March 2012 - 04:57 AM.
#12
Posted 08 March 2012 - 05:21 AM
#13
Posted 08 March 2012 - 05:34 AM
#14
Posted 08 March 2012 - 07:06 AM
#15
Posted 08 March 2012 - 08:32 AM
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users