~Hakurei Shrine~ > Rika and Nitori's Garage Experiments
I'm really lost @_@
<< < (2/12) > >>
Naut:
Unfortunately, that doesn't tell us much. You can post your script here and we can troubleshoot it for you, if you like.
Halca:
Ok, here's what my script looks like:


--- Code: ---#TouhouDanmakufu
#Title[Attack Name]
#Text[Attack Description]
#BGM[.\bgm.mp3]
#PlayLevel[Normal]
#Player[FREE]
#ScriptVersion[2]

script_enemy_main {
    let BossImage = ".\img\moe.png";
    let BossCutIn = ".\img\moetancut.png";
    @Initialize {
        LoadGraphic(BossImage);
        SetLife(1000);
        SetDamageRate(10, 10);
        SetTimer(50);
        SetInvincibility(30);
        CutIn(YOUMU, "Learning Sign"\"Magic Pencil"\", BossCutIn, 0, 0, 512, 512);
        SetScore(500000);
        SetEnemyMarker(true);
        SetDurableSpellCard;
        LastSpell;
        Concentration01(60);
        Concentration02(0);
        MagicCircle(false);
        SetEffectForZeroLife(180, 100, 1);
    }

    @MainLoop {
    }

    @DrawLoop {
       SetTexture(BossImage);
       SetGraphic(0, 0, 64, 64);
       DrawGraphic(GetX, GetY);
       
    }

    @Finalize {
    }
}
--- End code ---

When I try to run it, it bugs out.
Drake:
SetGraphicRect(0, 0, 64, 64);
Naut:
Your CutIn script is missing a quotation for it's name declaration. It should be:

--- Code: ---CutIn(YOUMU, "Learning Sign "\""Magic Pencil"\", BossCI, 0, 0, 512, 512);
--- End code ---

Notice the extra quotation between "\" and Magic Pencil. Don't ask how this works out, it's just a really confusing way of writing quotations in a text string. It works, no need to confuse you on why it's like this.


It should also be noted, in your @DrawLoop, "SetGraphic" doesn't exist, you left out the "Rect" part. So it should be:


--- Code: ---SetGraphicRect(0, 0, 64, 64);
--- End code ---

PFF Drake noticed this too.

Your code should run properly without any errors if you make these adjustments.

When you see a pop-up error message, it usually features a little snippet of code where the problem originates. Be sure to check for quotations, semi-colons, and proper brackets, as they're the most common problems that you'll see. The next most common is the one doesn't give you any code snippets, but instead has the characters {...} in it. This means that your squiggly braces {} don't pair up with eachother and need to be changed.

If the snippet of code is small, then I recommend just re-typing it out. If it's large, or you just don't know what's going on, then you should probably look for help. We'll be happy to assist you.
Halca:
Thank you very much :D

But still there's an issue @_@
The script runs fine now but the cut in image is completely white and the boss image does not appear on screen.  Help?

EDIT!:

Figured it out!
According to what I did it seems that scripts like to take images out of the scriptimg folder.
Correct?

I'm going to start scripting the bullets now! <3
Navigation
Message Index
Next page
Previous page

Go to full version