Jump to content

Photo

Can't get *text --> warp* script to work. (combo id?)


  • Please log in to reply
26 replies to this topic

#1 Aegix Drakan

Aegix Drakan

    Newbie

  • Members

Posted 25 January 2010 - 10:50 AM

Right, I'm trying to get This Script to work. (it's supposed to play a string, and then warp link away)

But I'm having trouble getting it to work....

(posts instructions)

1.Make a transparent 'Autowarp A' combo, and set its combo ID to the constant at the top of the script

By auto warp, they mean the *auto side warp A* combo type, right? And...what combo ID are they referring to? The one of the actual combo (1129 in my case), or the "#" of the Freeform combo I'm applying the script to?

2.Set your sidewarp A to where you want to warp to

did, that, no problem.

3.Apply the script to the screen

...What do they want me to do here? Set the Freeform combo and choose the *message warp* script for it? Or do I need to apply it elsewhere?

4.D0 is the message to play, Link will warp immediately after the message is finished
5.D1 is number of frames to wait before playing the message


Got that, no problem.


Could someone please gimme a hand with this? I spent another half hour looking through the pinned topics (including the one talking about FFCs) and I didn't get any information that helped me out of this problem.

#2 MoscowModder

MoscowModder

    Sometimes lurking. Rarely posting.

  • Members
  • Location:Wisconsin

Posted 25 January 2010 - 10:59 AM

I assume you just make an FFC with that script applied. I have never used that script, so just experiment or wait until someone who has used it before comes to help.

#3 Aegix Drakan

Aegix Drakan

    Newbie

  • Members

Posted 25 January 2010 - 09:44 PM

QUOTE(MoscowModder @ Jan 25 2010, 09:59 AM) View Post

I assume you just make an FFC with that script applied. I have never used that script, so just experiment or wait until someone who has used it before comes to help.


I tried just applying it to the FCC, but it didn't work.

I spent a good 45 minutes messing around with all the possibilities, and I can't seem to figure it out. It's driving me bananas!

#4 Joe123

Joe123

    Retired

  • Members

Posted 26 January 2010 - 07:30 PM

QUOTE(Aegix Drakan @ Jan 25 2010, 03:50 PM) View Post
1.Make a transparent 'Autowarp A' combo, and set its combo ID to the constant at the top of the script

By auto warp, they mean the *auto side warp A* combo type, right? And...what combo ID are they referring to? The one of the actual combo (1129 in my case), or the "#" of the Freeform combo I'm applying the script to?
You're meant to make a new combo with a transparent graphic, and then give it the 'Autowarp A' combotype. Then put that combo ID in the script.

QUOTE(Aegix Drakan @ Jan 25 2010, 03:50 PM) View Post
3.Apply the script to the screen

...What do they want me to do here? Set the Freeform combo and choose the *message warp* script for it? Or do I need to apply it elsewhere?
Make sure the ffc's Data isn't combo zero, and that you have all of your scripts in the same .z file. Otherwise, yes that's right.

QUOTE(Aegix Drakan @ Jan 25 2010, 03:50 PM) View Post
Could someone please gimme a hand with this? I spent another half hour looking through the pinned topics (including the one talking about FFCs) and I didn't get any information that helped me out of this problem.
I will endeavour to make my instructions more script-newbie friendly.


#5 Aegix Drakan

Aegix Drakan

    Newbie

  • Members

Posted 26 January 2010 - 09:41 PM

Thanks...I SORTA got it working...but not quite.

If I use the *Auto SideWarp [A]* combotype for my invisible-FFC-Combo, then I warp before the first string even appears.
(and I see no AutoWarp [A]. Just Autoside Warp [A]*)

If I use any other combo type, then the text displays just fine but I don't warp at the end of the string series.

I can go take screenshots of what my setup looks like if that'll help you understand what I'm doing wrong.

QUOTE(Joe123 @ Jan 26 2010, 06:30 PM) View Post
I will endeavour to make my instructions more script-newbie friendly.


Hey, don't worry. I'm just starting to learn programming (JAVA), and writing your instrusctions so that ANY end user can use them without fail is HARD. Our teacher made sure we learned that the hard way. >_>

Edited by Aegix Drakan, 26 January 2010 - 09:42 PM.


#6 Joe123

Joe123

    Retired

  • Members

Posted 27 January 2010 - 07:09 AM

QUOTE(Aegix Drakan @ Jan 27 2010, 02:41 AM) View Post
Thanks...I SORTA got it working...but not quite.

If I use the *Auto SideWarp [A]* combotype for my invisible-FFC-Combo, then I warp before the first string even appears.


If I use any other combo type, then the text displays just fine but I don't warp at the end of the string series.
You have to have the quest rule 'Messages Freeze All Action' checked. I'll put that in the thread.

QUOTE(Aegix Drakan @ Jan 27 2010, 02:41 AM) View Post
(and I see no AutoWarp [A]. Just Autoside Warp [A]*)
A) They used to be called AutoWarp
B) I assumed it was fairly obvious that they now refer to AutoSide Warp

QUOTE(Aegix Drakan @ Jan 27 2010, 02:41 AM) View Post
I can go take screenshots of what my setup looks like if that'll help you understand what I'm doing wrong.
Hey, don't worry. I'm just starting to learn programming (JAVA), and writing your instrusctions so that ANY end user can use them without fail is HARD. Our teacher made sure we learned that the hard way. >_>
Yeah, I think maybe the issue is that my instructions are written more for someone who's fairly well acquainted with the betas but perhaps not yet with scripting. So someone like yourself who's suddenly got however many other new features thrown at them at once might find that to be a bit of an issue.

#7 Aegix Drakan

Aegix Drakan

    Newbie

  • Members

Posted 27 January 2010 - 09:30 AM

QUOTE(Joe123 @ Jan 27 2010, 06:09 AM) View Post

You have to have the quest rule 'Messages Freeze All Action' checked. I'll put that in the thread.


...I do have that checked.It still warps me as soon as I enter the screen.

Do I need to have something in particular done on the side-warp screen too?

Ach...alright, when I get back from school I'll get some screenshots up. I don't get where I went wrong (but knowing me, it's probably something silly)



EDIT: Screenshots up!

IPB Image
The combo editor

IPB Image
Page one of the FFC editor (I made sure that the right FFC is selected.

Page 2 of the FFC editor is has nothing checked, so I did not take a picture.

IPB Image
Page 3 of the FFC editor

IPB Image
My sidewarp setup.

IPB Image
My "quest rules".

Hopefully that points out whatever obvious error I made.

Also of note is that I'm using an overworld Dmap, but made it so that strings can be played on it. (unchecked "guys are caves only")


Edited by Aegix Drakan, 27 January 2010 - 03:19 PM.


#8 Aegix Drakan

Aegix Drakan

    Newbie

  • Members

Posted 30 January 2010 - 07:51 PM

Right, so I put some screenshots up *SEE ABOVE POST*.

I've kept experimenting but I keep always warping away before the string even plays.

Does the script only work in certain ZC versions, or something?

#9 Joe123

Joe123

    Retired

  • Members

Posted 01 February 2010 - 12:22 PM

icon_confused2.gif
Can you post the exact script you're using?

#10 Aegix Drakan

Aegix Drakan

    Newbie

  • Members

Posted 01 February 2010 - 05:07 PM

oooook, here it is. The whole script file I'm using:

CODE
import "std.zh"

const int CMB_AUTOWARPA = 1012; //Only include this once in the script file
ffc script MessageWarp{
    void run(int m, int dly){
        Waitframes(dly);
        Screen->Message(m);
        Waitframe();
        this->Data = CMB_AUTOWARPA;
    }
}

ffc script RealNPC{
    void run(int m, int sfx, int defdir, int d, int ffcnumber, int input){
        ffc NPC = this;
        if(ffcnumber != 0) Screen->LoadFFC(ffcnumber);
        int dx; int dy; int ax; int ay;
        int orig = NPC->Data;

        if(d == 0) d = 40;
        while(true){
            dx = NPC->X-Link->X; ax = Abs(dx);
            dy = NPC->Y-Link->Y; ay = Abs(dy);
            if(defdir != 0){
                if(ax < d && ay < d){
                    if(ax <= ay){
                        if(dy >= 0) NPC->Data = orig;
                        else NPC->Data = orig+1;
                    }else{
                        if(dx >= 0) NPC->Data = orig+2;
                        else NPC->Data = orig+3;
                    }
                }else NPC->Data = orig+(defdir-1);
            }
            if(SelectPressInput(input) && ax < 24 && ay < 24 && Link->Z == 0){
                SetInput(input,false);
                if(sfx != 0) Game->PlaySound(sfx);
                Screen->Message(m);
            }
        Waitframe();
        }
    }
    bool SelectPressInput(int input){
        if(input == 0) return Link->PressA;
        else if(input == 1) return Link->PressB;
        else if(input == 2) return Link->PressL;
        else if(input == 3) return Link->PressR;
    }
    void SetInput(int input, bool state){
        if(input == 0) Link->InputA = state;
        else if(input == 1) Link->InputB = state;
        else if(input == 2) Link->InputL = state;
        else if(input == 3) Link->InputR = state;
    }
}

item script Message{
    void run(int m){
        Screen->Message(m);
    }
}


Hope that helps.

#11 Joe123

Joe123

    Retired

  • Members

Posted 01 February 2010 - 07:31 PM

I understand if you don't want to, but if you could send me your quest file I can have a look and find out what's going wrong.
I apologise for the inconvenience, using a script this simple wouldn't usually cause such an issue.

#12 Aegix Drakan

Aegix Drakan

    Newbie

  • Members

Posted 01 February 2010 - 08:09 PM

QUOTE(Joe123 @ Feb 1 2010, 06:31 PM) View Post

I understand if you don't want to, but if you could send me your quest file I can have a look and find out what's going wrong.
I apologise for the inconvenience, using a script this simple wouldn't usually cause such an issue.


S-SERIOUSLY?! You'd look at through quest file to find out my problem?

You're a really nice guy, Joe! I got no problems with sending it to you. If anything you're the one I'm inconveniancing.

Mind if I send it to you over email, or something?

Edited by Aegix Drakan, 01 February 2010 - 08:17 PM.


#13 Joe123

Joe123

    Retired

  • Members

Posted 01 February 2010 - 08:12 PM

Yeah sure, it's not that much effort.
Email would be great seeing as my uni's proxy blocks file upload sites, it's on my profile.

#14 catfriedrice

catfriedrice

    Experienced Forumer

  • Members

Posted 15 March 2010 - 10:30 PM

Ok, it says I can bump this no matter how old:

Joe, I'm having the same issue on mine with build 1121. Did you ever figure out the answer to why his did this?

#15 Joe123

Joe123

    Retired

  • Members

Posted 16 March 2010 - 05:29 AM

Well, kinda...
I got it to work on my computer but it wouldn't on his I think.

Anyway, you need Messages Freeze All Action and Messages Disappear both checked.


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users