User Tag List

Page 2 of 4 FirstFirst 1 2 3 4 LastLast
Results 11 to 20 of 34

Thread: Making Link Invisible

  1. #11
    &&
    ZC Developer
    Joe123's Avatar
    Join Date
    Sep 2006
    Age
    32
    Posts
    3,061
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    7,303
    Level
    26
    vBActivity - Bars
    Lv. Percent
    8.74%

    Re: Making Link Invisible

    Why are you posting binary at me
    I'm afraid I don't understand that at all.

    I have Link with no shield, wooden, big and mirror, then I have climbing tiles for each. Each set of Links takes up three rows, plus I have a labelling row before each row of Links. Thus 3 sheets. I think I might be able to squeeze in an extra sheet for invisible Link though, especially if I remove the label rows.

  2. #12
    The Time-Loop Continues ZC Developer
    Gleeok's Avatar
    Join Date
    Apr 2007
    Posts
    4,826
    Mentioned
    259 Post(s)
    Tagged
    10 Thread(s)
    vBActivity - Stats
    Points
    12,959
    Level
    33
    vBActivity - Bars
    Lv. Percent
    26.21%

    Re: Making Link Invisible

    Well what I was getting at was you could alter your invisibility script for one, to check Link's current equipment before assigning a Link tile mod to him. (Although it'd still be easier to free up more tilepages...jeez, that's ridiculous...)

    ..I'm assuming it's an invisibility cloak or something.
    This post contains the official Gleeok seal of approval. Look for these and other posts in an area near you.

  3. #13
    &&
    ZC Developer
    Joe123's Avatar
    Join Date
    Sep 2006
    Age
    32
    Posts
    3,061
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    7,303
    Level
    26
    vBActivity - Bars
    Lv. Percent
    8.74%

    Re: Making Link Invisible

    No no, I want to play an animation via drawtile when you play the whistle. The script doesn't seem to do anything at the moment though...

  4. #14
    Octorok
    Join Date
    May 2007
    Posts
    331
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    1,506
    Level
    13
    vBActivity - Bars
    Lv. Percent
    11.25%

    Re: Making Link Invisible

    I want to play an animation via drawtile when you play the whistle. The script doesn't seem to do anything at the moment
    You should post the script, another pair (or better yet many pairs) of eyes often help see the *kicks self* type mistakes that we all make when looking at something too closely and for too long.

  5. #15
    Wizrobe C-Dawg's Avatar
    Join Date
    Jan 2002
    Posts
    4,205
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    6,611
    Level
    24
    vBActivity - Bars
    Lv. Percent
    99.9%

    Re: Making Link Invisible

    Quote Originally Posted by ShadowMancer View Post
    You should post the script, another pair (or better yet many pairs) of eyes often help see the *kicks self* type mistakes that we all make when looking at something too closely and for too long.
    I've typed: " state_counter == 3;" when I meant "state_counter = 3" waaaay to many times. Hard to find, won't generate an error message, royally fucks up the code.

  6. #16
    &&
    ZC Developer
    Joe123's Avatar
    Join Date
    Sep 2006
    Age
    32
    Posts
    3,061
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    7,303
    Level
    26
    vBActivity - Bars
    Lv. Percent
    8.74%

    Re: Making Link Invisible

    Dyu know what possibly the best thing ever for mistakes like that is?

    The 'Replace' tool on notepad.

    It seriously saved me about 2 hours writing that snow combo script.

    Code:
    item script whistle{
    	void run(){
    		int timer = 20;
    		int tile = 54793;
    		int cset = 6;
    		while(timer > 0){
    			timer--;
    			Screen->DrawTile(3, Link->X, Link->Y, tile, 1, 1, cset, 1, 0, 0, 0, 3, true, 128);
    		}
    	}
    }
    Anyway, that's what I have so far for the whistle script. I haven't made Link invisible or put in the animation on the drawtile function yet, but what I have there doesn't seem to want to do anything at all...

    I think I might be putting it on the item wrong though, I'm not very familliar with item scripts.

  7. #17
    Octorok
    Join Date
    May 2007
    Posts
    331
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    1,506
    Level
    13
    vBActivity - Bars
    Lv. Percent
    11.25%

    Re: Making Link Invisible

    Your problem is that item scripts only execute for one frame.. well a couple of problems actually. The script you have (even if it was an FFC or Global script) has no waitframe so it goes through and draws what you want until the timer reaches 0 then *poof* disapears at the next call of Waitframe. Drawing functions only draw for each frame they are called then the screen is refreshed.. sooo you probley want to have the item script set a global varible to 'true' then do the animation (put a waitframe in the while loop) and just set the global var back to 'false' at the end of the loop.


    Also, if you only want Link invisible durring the animation, just draw something on say Layer 6 above him, and freeze movement by setting all the input keys to false until the animation is over, but if that is not what you want then just ignore this :)

  8. #18
    Gibdo beefster09's Avatar
    Join Date
    Mar 2006
    Age
    31
    Posts
    699
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    2,710
    Level
    16
    vBActivity - Bars
    Lv. Percent
    97.39%

    Re: Making Link Invisible

    You don't need LTMs if link is invisible for a whole screen. Use one of the settings that was in V1.92- Invisible Link in the screen flags menu.
    Avatar: Just who the SPAAAACE do you think I am?

  9. #19
    &&
    ZC Developer
    Joe123's Avatar
    Join Date
    Sep 2006
    Age
    32
    Posts
    3,061
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    7,303
    Level
    26
    vBActivity - Bars
    Lv. Percent
    8.74%

    Re: Making Link Invisible

    Ahhh, thankyou ShadowMancer.
    I knew Waitframe(); didn't work for item scripts, so I thought - I know, I'll have a while loop which loops for 20 frame via the timer, but obviously that doesn't work. I'll have a go at adding into the global script then. Thankyou.

    EDIT: oh, but of course that doesn't make it wait a frame though, because there's no waitframe. It just loops 20 times. >_<

    EDIT:
    Code:
    		while(usewhistle == 1){
    			Game->PlaySound(33);
    			Link->Item[invis] = true;
    			Screen->ComboT[ComboAt(0,0)] = thisType;
    			if(timer > 10){Screen->DrawTile(2, Link->X, Link->Y, tile, 1, 1, 6, 1, 0, 0, 0, 0, true, 128);}
    			if(timer > 20 && timer <= 10){Screen->DrawTile(2, Link->X, Link->Y, tile+1, 1, 1, 6, 1, 0, 0, 0, 0, true, 128);}
    			if(timer > 30 && timer <= 20){Screen->DrawTile(2, Link->X, Link->Y, tile+2, 1, 1, 6, 1, 0, 0, 0, 0, true, 128);}
    			if(timer > 40 && timer <= 30){Screen->DrawTile(2, Link->X, Link->Y, tile+3, 1, 1, 6, 1, 0, 0, 0, 0, true, 128);}
    			if(timer == 40){usewhistle = 0; Link->Item[invis] = false; Screen->ComboT[ComboAt(0,0)] = thisType;}
    			timer++;
    		Waitframe();
    		}
    So now I have this while loop added into my global script, and
    Code:
    item script whistle_animation{
    	void run(){
    		usewhistle = 1;
    	}
    }
    this as the item script.

    I have the whistle's sound effect set to 0, because if you don't the script doesn't activate till after it's played.

    However what happens at the moment is:
    when you play the whistle the first time, Link dissapears for a frame, then the first tile only of the animation appears, the sound effect plays, then Link becomes visible again.

    then when you play it the second time, Link becomes permanently invisible, no sound effect plays, and you get the first tile of the drawtile animation stuck on Link enabling you to walk around as a graphic of Link playing the ocarina. Oh dear...

  10. #20
    Octorok
    Join Date
    May 2007
    Posts
    331
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    1,506
    Level
    13
    vBActivity - Bars
    Lv. Percent
    11.25%

    Re: Making Link Invisible

    timer > 20 && timer <= 10 ??? Can timer be greater then 20 And less then 10 at the same time.. Common mistakes check all your logic, seems like the script should work with the proper logic.
    Also, make sure you set timer back to 0 before running the loop again. (this is why Link stays invisibal, timer is already greater then 40 so: if(timer == 40){usewhistle = 0; Link->Item[invis] = false; never gets called)

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Armageddon Games is a game development group founded in 1997. We are extremely passionate about our work and our inspirations are mostly drawn from games of the 8-bit and 16-bit era.
Social