Jump to content

Photo

Custom Dragon Boss


  • Please log in to reply
28 replies to this topic

#16 Moosh

Moosh

    Tiny Little Questmaker

  • ZC Developers

Posted 17 May 2012 - 10:33 PM

Probably not. Don't use old builds, the release canidates are much more stable. The glitchiness may be tox_von's script though which from what I see doesn't look all that stable itself.

#17 tox_von

tox_von

    Zelda Addict

  • Members
  • Real Name:Redgor
  • Location:Toxicville , Simcity

Posted 17 May 2012 - 11:22 PM

i only tried it on rc3 that i made it with why are you using 1401 and what is it?

What seems unstable about the code? it works fine on rc3.

Edited by tox_von, 17 May 2012 - 11:24 PM.


#18 MoscowModder

MoscowModder

    Sometimes lurking. Rarely posting.

  • Members
  • Location:Wisconsin

Posted 17 May 2012 - 11:54 PM

I'm pretty sure build 1401 is one of the RC's - whether 2 or 3 I'm not sure.

#19 Moosh

Moosh

    Tiny Little Questmaker

  • ZC Developers

Posted 18 May 2012 - 12:35 AM

QUOTE(tox_von @ May 17 2012, 11:22 PM) View Post

What seems unstable about the code? it works fine on rc3.

I guess unstable isn't the word. It's more...unrefined. As an example, say you're scripting a custom shop. When Link pays the shopkeeper for an item, you could just subtract the money from Link's rupee counter, but that wouldn't look very good when played out with no sound effects or anything. It would look choppy and unrefined when compared to a script that drains the rupees over time and plays a sound while doing it. In the same way, your script looks choppy and unrefined when Link collides with the enemy and teleports backwards instead of being knocked back in a fluid motion and shows no auditory or visual indication that he's been hurt, sometimes not even taking damage like he's supposed to. I believe this is what mathewIan13 was talking about when he said it "came out glitched".

#20 tox_von

tox_von

    Zelda Addict

  • Members
  • Real Name:Redgor
  • Location:Toxicville , Simcity

Posted 18 May 2012 - 07:35 AM

There arnt any working examples of other boss codes and only a handful of people have posted codes as big as mine. So there isn't really anything for me to go by to learn more so i just stumble through figuring stuff out as i go. if there is anything the code lacks people could just suggest code to add or write a better version.



CODE
Link->HitDir = 1;
Link->Action = LA_GOTHURTLAND;


also i figured out how to do link getting hurt and knocked back i will add that soon.

Edited by tox_von, 18 May 2012 - 07:41 AM.


#21 Moosh

Moosh

    Tiny Little Questmaker

  • ZC Developers

Posted 18 May 2012 - 12:00 PM

QUOTE(tox_von @ May 18 2012, 06:35 AM) View Post

There arnt any working examples of other boss codes and only a handful of people have posted codes as big as mine.

Ok then. Here, have a boss:
CODE
ffc script WaterDragon{
    void run(int enemynum, int tile, int cs1, int cs2){
        int timer=0;
        Waitframes(5);
        if(Screen->NumNPCs()>0){
            npc n=Screen->LoadNPC(enemynum);
            Ghost_Init(this, n, GHF_IGNORE_WATER);
            Ghost_Transform(this, n, tile, cs1, 4, 4);
            while(Ghost_HP>60){
                if(Distance(this->X, this->Y+16, this->X, Link->Y)>5){
                    Ghost_MoveAtAngle(Angle(this->X, this->Y+16, this->X, Link->Y), 0.1, 0);
                }
                timer++;
                if(timer>=300){
                    timer=0;
                    eweapon fireball=FireAimedEWeapon(EW_FIREBALL, this->X+8, this->Y+8+16*Rand(0, 1), 0, 100, 8, -1, SFX_FIREBALL, 0);
                    SetEWeaponLifespan(fireball, EWL_TIMER, 180);
                    SetEWeaponDeathEffect(fireball, EWD_AIM_AT_LINK, 20);
                }
                UpdateEWeapons();
                Ghost_Waitframe(this, n, false, false);    
            }
            n->CollDetection=false;
            for(int i=0; i<=50; i++){
                lweapon l=Screen->CreateLWeapon(LW_BOMBBLAST);
                l->X=Rand(this->X, this->X+48);
                l->Y=Rand(this->Y, this->Y+48);
                l->CollDetection=false;
                for(int i=0; i<2; i++){
                    Ghost_Waitframe(this, n, false, false);
                }
            }
            n->CollDetection=true;
            Ghost_Transform(this, n, tile+1, cs2, 4, 4);
            while(Ghost_HP>0){
                if(Distance(this->X, this->Y+16, this->X, Link->Y)>5){
                    Ghost_MoveAtAngle(Angle(this->X, this->Y+16, this->X, Link->Y), 0.5, 0);
                }
                timer++;
                if(timer==60||timer==120||timer==180||timer==240||timer==300){
                    eweapon fire=FireNonAngularEWeapon(EW_FIRE2, this->X+8, this->Y+8+16*Rand(0, 1), DIR_LEFT, 100, 8, -1, SFX_FIRE, 0);
                }
                else if(timer>=600){
                    timer=0;
                    Screen->Quake=60;
                    for(int i=0; i<=3; i++){
                        npc rock=Screen->CreateNPC(NPC_ROCK);
                        rock->Y=0;
                        rock->X=Link->X+Rand(-32, 32);
                    }
                }
                clearrocks();
                Ghost_Waitframe(this, n, false, false);
            }
            Ghost_Explode(this, n);
            while(true){
                clearrocks();
                Waitframe();
            }
        }
    }
    void clearrocks(){
        for(int i=1; i<=Screen->NumNPCs(); i++){
            npc rock=Screen->LoadNPC(i);
            if(rock->Y>160&&rock->ID==NPC_ROCK){
                rock->X=-1000;
                rock->HP=HP_SILENT;
            }
        }
    }
}

D0 is the number of the enemy onscreen to use for the boss script,
D1 is the combo for the dragon during the first phase of the battle the combo directly after it is the dragon in the second phase of the battle
D2 is the CSet used for the first phase of the battle
D3 is the CSet used for the second phase of the battle

This also fulfills OP's request.

Edited by Moosh, 18 May 2012 - 12:01 PM.


#22 tox_von

tox_von

    Zelda Addict

  • Members
  • Real Name:Redgor
  • Location:Toxicville , Simcity

Posted 19 May 2012 - 08:41 AM

CODE
import "std.zh"
import "ghost.zh"
import "string.zh"


other than adding that what did i need to do?

#23 Moosh

Moosh

    Tiny Little Questmaker

  • ZC Developers

Posted 19 May 2012 - 08:46 AM

QUOTE(tox_von @ May 19 2012, 07:41 AM) View Post

CODE
import "std.zh"
import "ghost.zh"
import "string.zh"


other than adding that what did i need to do?

I'm kinda confused as to what you mean? Do you mean to use my script? You set the D values as instructed and put a custom other type enemy onscreen with 120 HP (what the OP requested it for) and place the ffc where you want it to appear.

#24 tox_von

tox_von

    Zelda Addict

  • Members
  • Real Name:Redgor
  • Location:Toxicville , Simcity

Posted 19 May 2012 - 08:59 AM

when i did that nothing appeared on the screen.

#25 JSBach

JSBach

    Newbie

  • Members

Posted 19 May 2012 - 09:17 AM

If the script/boss won's work on Build 1401, could someone please link me to the VERY LATEST version of Zquest Beta so i could use it?



#26 Moosh

Moosh

    Tiny Little Questmaker

  • ZC Developers

Posted 19 May 2012 - 09:34 AM

QUOTE(mathewlan13 @ May 19 2012, 08:17 AM) View Post

If the script/boss won's work on Build 1401, could someone please link me to the VERY LATEST version of Zquest Beta so i could use it?

http://www.purezc.co...o...=53770&st=0

Edit: @tox_von: Then you're clearly doing it wrong. Did you place an enemy onscreen and set D0 to the enemy slot you set that enemy to? Did you make sure your boss tiles are 4x4 like those in the OP's post?

Edited by Moosh, 19 May 2012 - 09:37 AM.


#27 tox_von

tox_von

    Zelda Addict

  • Members
  • Real Name:Redgor
  • Location:Toxicville , Simcity

Posted 19 May 2012 - 10:19 AM

i tried on a fresh page nothing appeared is there an example qst file?

#28 Moosh

Moosh

    Tiny Little Questmaker

  • ZC Developers

Posted 19 May 2012 - 01:24 PM

QUOTE(tox_von @ May 19 2012, 09:19 AM) View Post

i tried on a fresh page nothing appeared is there an example qst file?

If you insist...
I really hate uploading stuff because it usually takes like 40 attempts before it finally goes through. File storing sites hate me.

#29 tox_von

tox_von

    Zelda Addict

  • Members
  • Real Name:Redgor
  • Location:Toxicville , Simcity

Posted 19 May 2012 - 11:01 PM

I added the damage zones to my version 2 script.

on the other code the damage zones arnt correct whenever you go near it you get hit also it doesnt move.


1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users