Author Topic: Danmakufu Q&A/Problem Thread II  (Read 180614 times)

Iryan

  • Ph?nglui mglw?nafh
  • Cat R?lyeh wgah?nagl fhtagn.
Re: Danmakufu Q&A/Problem Thread II
« Reply #60 on: October 25, 2009, 05:31:56 PM »
Well, I just cannot fathom why you would need to keep increasing the variable beyond 360 instead of setting it back to 0 and start again from there, unless you really want to unleash number of bullets at once that may look cool but will crash an/or slow down the game to a degree that the look isn't worth it.
Old Danmakufu stuff can be found here!

"As the size of an explosion increases, the numbers of social situations it is incapable of solving approaches zero."

Fujiwara no Mokou

  • Hourai Incarnate
  • Oh, so this trial of guts is for ME?
    • Profile
Re: Danmakufu Q&A/Problem Thread II
« Reply #61 on: October 25, 2009, 05:39:48 PM »
Alright, here's another question.

How can I make an effect object both move at a desired angle and rotate at a desired speed at the same time?  Because I've only found one way to do that, and it's through object creation and deletion frame by frame.  I admit, it's a lot of work, but fully customizable.

EDIT: And no, not type in angle etc frame by frame, I mean setting X and Y coordinates and ObjEfffect_SetAngle(x,y,z) through a loop, with the object deletion at the end of the loop so it creates new x y and z every time it spawns.
« Last Edit: October 25, 2009, 05:42:55 PM by Fujiwara no Mokou »

Iryan

  • Ph?nglui mglw?nafh
  • Cat R?lyeh wgah?nagl fhtagn.
Re: Danmakufu Q&A/Problem Thread II
« Reply #62 on: October 25, 2009, 05:47:06 PM »
I've never used effect objects before, but if they work similar to bullet objects you can just let the regular angle rotate and simulate the actual movement trough a relative SetPosition command:

Set the movement speed to 0.
Create a variable speed and a variable angle
Now, inside the loop that occurs once every frame, put:
Obj_SetPosition(obj, Obj_GetX(obj) + speed*cos(angle), Obj_GetY(obj) + speed*sin(angle) );

There you go.  8)
Old Danmakufu stuff can be found here!

"As the size of an explosion increases, the numbers of social situations it is incapable of solving approaches zero."

Fujiwara no Mokou

  • Hourai Incarnate
  • Oh, so this trial of guts is for ME?
    • Profile
Re: Danmakufu Q&A/Problem Thread II
« Reply #63 on: October 25, 2009, 05:52:41 PM »

Obj_SetPosition(obj, Obj_GetX(obj) + speed*cos(angle), Obj_GetY(obj) + speed*sin(angle) );

Well, that's what I came out with.  The object loop, frame by frame. I mean without doing that.

Nevermind, found it.  WOOOOoow... I can't believe I didn't see it earlier.
« Last Edit: October 25, 2009, 05:58:01 PM by Fujiwara no Mokou »

Re: Danmakufu Q&A/Problem Thread II
« Reply #64 on: October 25, 2009, 06:39:27 PM »
Well i dont see the point in ascent, it works less often than (let variable; loop(number){do stuff; variable++;}variable=0;) for some reason, and if you want an infinite loop you can just use loop{do stuff}, ionno in one spellcard i used ascent and didnt work, then made a loop and it worked, so idk but i will just stay with loops for now

Azure Lazuline

  • Looooove!!
  • PM me for free huggles and love!
    • Entanma Project - indie game development
Re: Danmakufu Q&A/Problem Thread II
« Reply #65 on: October 25, 2009, 08:35:01 PM »
Quick question, is there any way to change the enemy death sound for a script, without using the "put this file in this directory to overwrite the default" trick?

Re: Danmakufu Q&A/Problem Thread II
« Reply #66 on: October 25, 2009, 08:56:32 PM »
why isn't the lasers firing the bullets?ive messed around with it for days and i cant figure it out.
Code: [Select]
#TouhouDanmakufu
#Title[new74570253]
#Text[「」]
#Player[FREE]
#ScriptVersion[2]

script_enemy_main{
#include_function "lib\SHOT_REPLACE\shot_replace.dnh"
let frame = 0;
let frame2 = 0;
let angle = 0;
let ahoaha = 0;
let n = rand(0, 360);
@Initialize{
SetLife(800);
SetMovePosition02(GetCenterX,GetCenterY,0);
SetTimer(90);
shotinit;

}

@MainLoop{
SetCollisionA(GetX,GetY,16);
SetCollisionB(GetX,GetY,16);
frame++;
if(frame%70==0){
CreateLaserA(0, GetX, GetY, 400, 60, BLUE60, 30);
SetLaserDataA(0, 0, GetAngleToPlayer, 0, 0, 1, 180);
SetLaserDataA(0, 30, NULL, 0, 0, 0, 180);
SetShotKillTime(0, 60);
FireShot(0);

CreateLaserA(1, GetX, GetY, 400, 60, BLUE60, 30);
SetLaserDataA(1, 0, GetAngleToPlayer, 0, 0, -1, 180);
SetLaserDataA(1, 30, NULL, 0, 0, 0, 180);
SetShotKillTime(1, 60);
FireShot(1);

AddShot(50, 0,2, 30);
CreateShotA(2, 0, 0, 0);
SetShotDataA(2, 0, 3, rand(0, 360), 1, 0, 0, AQUA02);

AddShot(50, 1,3, 30);
CreateShotA(3, 0, 0, 0);
SetShotDataA(3, 0, 3, rand(0, 360), 1, 0, 0, AQUA02);


}}

@DrawLoop{

}

@BackGround{

}

@Finalize{

}



}

CK Crash

  • boozer
Re: Danmakufu Q&A/Problem Thread II
« Reply #67 on: October 25, 2009, 09:03:44 PM »
The Addshots have to be before the FireShot of the "creating" bullet. Treat Addshot bullets as a property of a CreateShot (put them where the SetShotData stuff is).

Re: Danmakufu Q&A/Problem Thread II
« Reply #68 on: October 25, 2009, 09:09:01 PM »
why isn't the lasers firing the bullets?ive messed around with it for days and i cant figure it out.
Code: [Select]
#TouhouDanmakufu
#Title[new74570253]
#Text[「」]
#Player[FREE]
#ScriptVersion[2]

script_enemy_main{
#include_function "lib\SHOT_REPLACE\shot_replace.dnh"
let frame = 0;
let frame2 = 0;
let angle = 0;
let ahoaha = 0;
let n = rand(0, 360);
@Initialize{
SetLife(800);
SetMovePosition02(GetCenterX,GetCenterY,0);
SetTimer(90);
shotinit;

}

@MainLoop{
SetCollisionA(GetX,GetY,16);
SetCollisionB(GetX,GetY,16);
frame++;
if(frame%70==0){
CreateLaserA(0, GetX, GetY, 400, 60, BLUE60, 30);
SetLaserDataA(0, 0, GetAngleToPlayer, 0, 0, 1, 180);
SetLaserDataA(0, 30, NULL, 0, 0, 0, 180);
SetShotKillTime(0, 60);
FireShot(0);

CreateLaserA(1, GetX, GetY, 400, 60, BLUE60, 30);
SetLaserDataA(1, 0, GetAngleToPlayer, 0, 0, -1, 180);
SetLaserDataA(1, 30, NULL, 0, 0, 0, 180);
SetShotKillTime(1, 60);
FireShot(1);

AddShot(50, 0,2, 30);
CreateShotA(2, 0, 0, 0);
SetShotDataA(2, 0, 3, rand(0, 360), 1, 0, 0, AQUA02);

AddShot(50, 1,3, 30);
CreateShotA(3, 0, 0, 0);
SetShotDataA(3, 0, 3, rand(0, 360), 1, 0, 0, AQUA02);


}}

@DrawLoop{

}

@BackGround{

}

@Finalize{

}



}

The correct way to do it is, CreateShot, SetShotData, CreateShot (diff ID), SetShotData, AddShot(the one in the 2nd CreateShot), FireShot.

AddShots are like FireShots, except makes them being fired from another bullet, so you have to set their data before using AddShot, and their data has to be input before FireShot, hope i didnt cofuse you more, you can also read and check the examples on the tutorials at the wiki

Cabble

  • Ask me about my Cat.
  • Not unwilling to shank you.
Re: Danmakufu Q&A/Problem Thread II
« Reply #69 on: October 25, 2009, 10:42:44 PM »
BLEGH

Ok shotdata V4 isn't working for me.

How do I brighten up a bullet ingame?
« Last Edit: October 25, 2009, 10:46:46 PM by Seven Orange Clouds »
I had a teacher who used to play radiohead during class once.

ONCE.

Chronojet ⚙ Dragon

  • The Oddity
  • 今コソ輝ケ、我ガ未来、ソノ可能性!!
Re: Danmakufu Q&A/Problem Thread II
« Reply #70 on: October 26, 2009, 12:10:16 AM »
BLEGH

Ok shotdata V4 isn't working for me.

How do I brighten up a bullet ingame?

Hmmm... If it's an added bullet (from LoadUserShotData;) then you can put
Code: [Select]
render = ADD in the shot replacement script.

I dunno what you're talking about.

Re: Danmakufu Q&A/Problem Thread II
« Reply #71 on: October 26, 2009, 05:06:31 AM »
So, effect objects. It's my first time using them, so I've been sure to read how the functions work and everything. I decided to test a script, and got an error. Here's the MainLoop from my code; it's really the only relevant part:
Code: [Select]
    @MainLoop {
SetCollisionA(GetX, GetY, 32);
SetCollisionB(GetX, GetY, 16);

if (frame == 0) {
let ID = Obj_Create(OBJ_EFFECT);
ObjEffect_SetTexture(ID, Texture);
ObjEffect_SetPrimitiveType(ID, PRIMITIVE_TRIANGLESTRIP);
ObjEffect_CreateVertex(ID, 4);
ObjEffect_SetVertexXY(ID, 0, 150, 0);
ObjEffect_SetVertexXY(ID, 1, 234, 0);
ObjEffect_SetVertexXY(ID, 2, 150, 448);
ObjEffect_SetVertexXY(ID, 3, 234, 448);
ObjEffect_SetVertexUV(ID, 0, 0, 0);
ObjEffect_SetVertexUV(ID, 1, 84, 0);
ObjEffect_SetVertexUV(ID, 2, 0, 448);
ObjEffect_SetVertexUV(ID, 3, 84, 448);
ObjEffect_SetVertexColor(ID, 0, 150, 150, 0, 150);
ObjEffect_SetVertexColor(ID, 1, 150, 150, 0, 150);
ObjEffect_SetVertexColor(ID, 2, 150, 150, 0, 150);
ObjEffect_SetVertexColor(ID, 3, 150, 150, 0, 150);
}
if (frame == 120) {
Obj_Delete(ID);
frame = -120;
}
frame++;

    }
The error in question would be the Obj_Delete(ID) near the end. The only reason I can think of for it messing up is that it's in a different if statement, but I can't just let the object stack on top of itself for the entire script. Any advice?

RavenEngie

  • Now how'm I supposed to stop those mean ol' Mother Hubbards from tearin' me a structurally superfluous new behind? The answer, use a gun. If that don't work...
  • Gaming-Obsessed Illusionist
Re: Danmakufu Q&A/Problem Thread II
« Reply #72 on: October 26, 2009, 06:01:02 PM »
So, effect objects. It's my first time using them, so I've been sure to read how the functions work and everything. I decided to test a script, and got an error. Here's the MainLoop from my code; it's really the only relevant part:

      code goes here

The error in question would be the Obj_Delete(ID) near the end. The only reason I can think of for it messing up is that it's in a different if statement, but I can't just let the object stack on top of itself for the entire script. Any advice?

Delete that chunk of object stuff, and paste this outside MainLoop, DrawLoop, etc.

Code: [Select]
task effect {
      let ID = Obj_Create(OBJ_EFFECT);
      ObjEffect_SetTexture(ID, Texture);
      ObjEffect_SetPrimitiveType(ID, PRIMITIVE_TRIANGLESTRIP);
      ObjEffect_CreateVertex(ID, 4);
      ObjEffect_SetVertexXY(ID, 0, 150, 0);
      ObjEffect_SetVertexXY(ID, 1, 234, 0);
      ObjEffect_SetVertexXY(ID, 2, 150, 448);
      ObjEffect_SetVertexXY(ID, 3, 234, 448);
      ObjEffect_SetVertexUV(ID, 0, 0, 0);
      ObjEffect_SetVertexUV(ID, 1, 84, 0);
      ObjEffect_SetVertexUV(ID, 2, 0, 448);
      ObjEffect_SetVertexUV(ID, 3, 84, 448);
      ObjEffect_SetVertexColor(ID, 0, 150, 150, 0, 150);
      ObjEffect_SetVertexColor(ID, 1, 150, 150, 0, 150);
      ObjEffect_SetVertexColor(ID, 2, 150, 150, 0, 150);
      ObjEffect_SetVertexColor(ID, 3, 150, 150, 0, 150);

      while(Obj_BeDeleted(ID) == false){
            if(frame == 120){
                  Obj_Delete(ID);
                  frame = -120;
            }
            yield;
      }
}

And put in @MainLoop...

Code: [Select]
if(frame == 0){
      effect;
}
WALUIGI BACK! NOW THIS SIG IS FUNNY AGAIN!
Mah arts! :3

Blargel

  • RAWR!
  • I'M AN ANGRY LOLI!
Re: Danmakufu Q&A/Problem Thread II
« Reply #73 on: October 26, 2009, 07:33:09 PM »
The problem is indeed the delete being in a different block of code. Once the first if statement is done, any variables that were created in it are cleared from the memory so the ID variable doesn't exist anymore in the second if statement.

I'm not too familiar with microthreading but from my knowledge of them, Ravenlock's solution works fine. If you don't like microthreads (like me lol), you can always use arrays to manage objects.
<WorkingKeine> when i get home i just go to the ps3 and beat people up in blazblue with a loli
<Azure> Keine: Danmakufu helper by day, violent loli by night.

Re: Danmakufu Q&A/Problem Thread II
« Reply #74 on: October 26, 2009, 08:09:01 PM »
Putting the object's variables in a task fixed the error, and also stopped it from constantly building upon itself. Thanks for the help!

Re: Danmakufu Q&A/Problem Thread II
« Reply #75 on: October 26, 2009, 10:36:08 PM »
Is there a way to fire CreateShotAs over time, but have them activate/change all at once?

Blargel

  • RAWR!
  • I'M AN ANGRY LOLI!
Re: Danmakufu Q&A/Problem Thread II
« Reply #76 on: October 26, 2009, 11:20:17 PM »
There are two ways to do that.

1.) Using the standard frame or count variable to modify the activation time:
Code: [Select]
if(count%5 == 0 && count >=60 && count <=120){
  CreateShotA(0, GetX, GetY, 10);
  SetShotDataA(0, 0, 2, 90, 0, 0, 0, RED01);
  SetShotDataA(0, 180-count, 2, 180, 0, 0, 0, RED01);
  FireShot(0);
}

2.) Using an ascent statement coupled with varying delay times:
Code: [Select]
ascent(i in 0..13){
  CreateShotA(0, GetX, GetY, i*5+10);
  SetShotDataA(0, 0, 2, 90, 0, 0, 0, RED01);
  SetShotDataA(0, 120-i*5, 2, 180, 0, 0, 0, RED01);
  FireShot(0);
}

Both of these would create approximately the same behavior with slightly different visual effects with the delay.
« Last Edit: October 26, 2009, 11:23:44 PM by Blargel »
<WorkingKeine> when i get home i just go to the ps3 and beat people up in blazblue with a loli
<Azure> Keine: Danmakufu helper by day, violent loli by night.

Azure Lazuline

  • Looooove!!
  • PM me for free huggles and love!
    • Entanma Project - indie game development
Re: Danmakufu Q&A/Problem Thread II
« Reply #77 on: October 27, 2009, 03:11:12 AM »
I asked this a little while ago but got no response (sorry if it seems like I'm attention hogging; this just seems like it should be very simple, yet I can't find the answer). Is there any way to remove or replace the default sound effect made by destroyed enemies (the one that sounds like paper ripping)? Also, is there a way to make the enemy do something when destroyed by your character, but not when you call VanishEnemy? @Finalize{} seems to run for both.

Chronojet ⚙ Dragon

  • The Oddity
  • 今コソ輝ケ、我ガ未来、ソノ可能性!!
Re: Danmakufu Q&A/Problem Thread II
« Reply #78 on: October 27, 2009, 03:56:19 AM »
I asked this a little while ago but got no response (sorry if it seems like I'm attention hogging; this just seems like it should be very simple, yet I can't find the answer). Is there any way to remove or replace the default sound effect made by destroyed enemies (the one that sounds like paper ripping)? Also, is there a way to make the enemy do something when destroyed by your character, but not when you call VanishEnemy? @Finalize{} seems to run for both.

Default Sound effect for destroyed enemy would  be found in your se folder. Then put in a "seEnemyExplode01.wav" which is whatever sound you want to be played when your enemy is defeated.
Also, if you want to have something done in @Finalize only when you enemy is DEFEATED, and not VANISHED, you use:
Code: [Select]
@Finalize { if(!BeVanished) { DoSomething(put, parameters, here); } }

Azure Lazuline

  • Looooove!!
  • PM me for free huggles and love!
    • Entanma Project - indie game development
Re: Danmakufu Q&A/Problem Thread II
« Reply #79 on: October 27, 2009, 04:09:40 AM »
Default Sound effect for destroyed enemy would  be found in your se folder. Then put in a "seEnemyExplode01.wav" which is whatever sound you want to be played when your enemy is defeated.
Is there any way to do that without telling the user of the script to put this file in that directory (I.E., somehow override the file with something from the script directory)? If not, it's not too big of a deal, but it would simplify things a little. As for the other answer, thanks, I must have overlooked that function when going through the list...

Re: Danmakufu Q&A/Problem Thread II
« Reply #80 on: October 27, 2009, 04:15:29 AM »
Is there any way to do that without telling the user of the script to put this file in that directory (I.E., somehow override the file with something from the script directory)?

No.

Drake

  • *
Re: Danmakufu Q&A/Problem Thread II
« Reply #81 on: October 27, 2009, 04:22:52 AM »
You just put all the replaced files in a separate folder and tell everyone to set it as default, pretty much.

A Colorful Calculating Creative and Cuddly Crafty Callipygous Clever Commander
- original art by Aiけん | ウサホリ -

Re: Danmakufu Q&A/Problem Thread II
« Reply #82 on: October 27, 2009, 04:36:23 AM »
Or just upload your whole danmakufu folder onto mediafire instead of just the script.

Nimble

  • Broken English Fox
  • Rushing toward the bullet!
    • Viewmix
Re: Danmakufu Q&A/Problem Thread II
« Reply #83 on: October 27, 2009, 02:34:54 PM »
May I ask about original image file from th_dnh.dat in danmakufu?

I look in old thread and find that I can change GUI by replace new file in img / sfx danmakufu root folder. So I think about change something a bit.

Working with 32*32 grid number png feel like trapped in reimu's last spell.


Henry

  • The observer
  • Exploring to the new world of Danmaku
Re: Danmakufu Q&A/Problem Thread II
« Reply #84 on: October 27, 2009, 02:45:25 PM »
oh, there is a thread about this, but it is quite hard to do the puzzle, in fact. (none of us had considerable result of that)

By the way, is there a way to make Byakuren's & Shinki's Curved Laser (Fixed position)?
« Last Edit: October 27, 2009, 02:48:33 PM by Henry »
Old/Forgotten member.

Old Patchouli Project was outdated but new one is in progress.

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: Danmakufu Q&A/Problem Thread II
« Reply #85 on: October 27, 2009, 03:04:05 PM »
May I ask about original image file from th_dnh.dat in danmakufu?

I look in old thread and find that I can change GUI by replace new file in img / sfx danmakufu root folder. So I think about change something a bit.

Working with 32*32 grid number png feel like trapped in reimu's last spell.

The thread is called: "Unraveveling the mysteries of danmakufu"

And I only found a few things with that 32x32 sheet I made ( which you seem to mention ).

Nobody has cracked the file yet and neither anything is to be found on google/internet.

Nimble

  • Broken English Fox
  • Rushing toward the bullet!
    • Viewmix
Re: Danmakufu Q&A/Problem Thread II
« Reply #86 on: October 27, 2009, 05:14:29 PM »
Seem like I'm really sleepy while searching about GUI replace in whole Rika's Garage & Old Q&A thread yesterday..... How can I miss that thread.

I did the same thing from hex to all tool I found on Drake's thread.

Then, I'll try keep working on grip :V


while (mystery != solve) { edit; save; restart danmakufu; }

(Sorry for my bad language too, bow)

Blargel

  • RAWR!
  • I'M AN ANGRY LOLI!
Re: Danmakufu Q&A/Problem Thread II
« Reply #87 on: October 27, 2009, 07:07:53 PM »
By the way, is there a way to make Byakuren's & Shinki's Curved Laser (Fixed position)?

Isn't that just a solid stream of bullets waving back and forth?
<WorkingKeine> when i get home i just go to the ps3 and beat people up in blazblue with a loli
<Azure> Keine: Danmakufu helper by day, violent loli by night.

CK Crash

  • boozer
Re: Danmakufu Q&A/Problem Thread II
« Reply #88 on: October 27, 2009, 07:38:31 PM »
oh, there is a thread about this, but it is quite hard to do the puzzle, in fact. (none of us had considerable result of that)

By the way, is there a way to make Byakuren's & Shinki's Curved Laser (Fixed position)?

Assuming you're not talking about the actual curved lasers (which are made with LaserC functions):

Code: [Select]
task byaphase
{
let angle = 0;
let anglechange = 0.5;
loop
   {
   CreateShot01(GetX-64,GetY-96,4,angle+95,BLUE21,30); //top left
   CreateShot01(GetX-64,GetY-96,4,angle+155,BLUE21,30);
   CreateShot01(GetX-64,GetY-96,4,angle+35,BLUE21,30);

   CreateShot01(GetX+64,GetY-96,4,-angle+85,BLUE21,30); //top right
   CreateShot01(GetX+64,GetY-96,4,-angle+145,BLUE21,30);
   CreateShot01(GetX+64,GetY-96,4,-angle+25,BLUE21,30);


   CreateShot01(GetX-128,GetY+32,4,-angle+80,BLUE21,30); //bottom left
   CreateShot01(GetX-128,GetY+32,4,-angle+140,BLUE21,30);
   CreateShot01(GetX-128,GetY+32,4,-angle+20,BLUE21,30);

   CreateShot01(GetX+128,GetY+32,4,angle+100,BLUE21,30); //bottom right
   CreateShot01(GetX+128,GetY+32,4,angle+160,BLUE21,30);
   CreateShot01(GetX+128,GetY+32,4,angle+40,BLUE21,30);

   if (angle > 12 || angle < -12){anglechange = -anglechange;}
   angle += anglechange;
   loop(4){yield;}
   }
}

You may want to tweak the positions they spawn from and the exact angle, but this matches fairly well.

Chronojet ⚙ Dragon

  • The Oddity
  • 今コソ輝ケ、我ガ未来、ソノ可能性!!
Re: Danmakufu Q&A/Problem Thread II
« Reply #89 on: October 28, 2009, 02:23:47 AM »
Code: [Select]
#TouhouDanmakufu
#Title[Sakuya Scarlet]
#Text[Remilia Izayoi]
#Player[FREE]
#ScriptVersion[2]

script_enemy_main {
    let BossImage = "script\img\ExRumia.png";
    let IsSelectingColour = true; let delaystart = -120;
    let startingplayercoordinates = [GetPlayerX, GetPlayerY];
    let destinycolour = 0; let destinytext = ["Red", "Orange", "Yellow", "Green", "Aqua", "Blue", "Purple", "White"];
    let destinyfont = [[255, 0, 0], [255, 192, 128], [255, 255, 0], [0, 255, 0], [128, 192, 255], [0, 0, 255], [255, 0, 255], [255, 255, 255]];
    let frame = -180;
    let a = rand(0, 360);
    let num = 5;
    let graphic_knife = [RED32, ORANGE32, YELLOW32, GREEN32, AQUA32, BLUE32, PURPLE32, WHITE32];
    let graphic_bubble = [RED03, ORANGE03, YELLOW03, GREEN03, AQUA03, BLUE03, PURPLE03, WHITE03];
    @Initialize {
        SetLife(2400); SetDamageRate(40, 0);
        SetEnemyMarker(true);
        SetTimer(60);
        LoadGraphic(BossImage);
        SetMovePosition02(GetCenterX, GetClipMinY+100, 60);
        CutIn(KOUMA,"「Destiny-Defined Colour」", "", 0, 0, 0, 0);
        SetScore(1000000); SetDurableSpellCard;
    }

    @MainLoop {
        if(frame > 0) {
loop(num) {
CreateShot01(GetX, GetY, 3, a+rand(-3, 3), graphic_knife[destinycolour], 10);
CreateShot01(GetX, GetY, 3, -a+rand(-3, 3), graphic_knife[destinycolour], 10);
a+=360/num;
}
a+=num/2+3;
        }
        if(frame == 180) {
loop(40) {
CreateShot01(GetX, GetY, 3, a, graphic_bubble[destinycolour], 10);
a+=360/40;
}
        }
        if(frame == 180) {
frame = -120;
a = rand(0, 360);
SetMovePosition03(rand(GetClipMinX+50, GetClipMaxX-50), rand(GetClipMinY+50, GetCenterY-50), 10, 2);
        }
        if(IsSelectingColour) {
SetTimer(GetTimer+1); ForbidShot(true); ForbidBomb(true);
SetPlayerX(startingplayercoordinates[0]); SetPlayerY(startingplayercoordinates[1]);
if(GetKeyState(VK_DOWN) == KEY_PUSH) { destinycolour++; }
if(GetKeyState(VK_UP) == KEY_PUSH) { destinycolour--; }
if(destinycolour < 0) { destinycolour = 0; } if(destinycolour > 7) { destinycolour = 7; }
if(GetKeyState(VK_SHOT) == KEY_PUSH && delaystart >= 0){ ForbidShot(false); ForbidBomb(false); IsSelectingColour = false; }
if(delaystart < 60) { delaystart++; }
        }
        if(!IsSelectingColour) {
SetCollisionA(GetX, GetY, 32); //32 for boss, 10 for fairy
SetCollisionB(GetX, GetY, 24);//24 for boss, 5 for fairy
frame++;
        }
    }

    @DrawLoop {
        if(IsSelectingColour) {
        DrawText("Select Colour.", GetClipMaxX/4, GetClipMaxY*3/4-12, 12, 255);
        SetFontColor(destinyfont[destinycolour][0], destinyfont[destinycolour][1], destinyfont[destinycolour][2], destinyfont[destinycolour][0], destinyfont[destinycolour][1], destinyfont[destinycolour][2]);
        DrawText(destinytext[destinycolour], GetClipMaxX/4, GetClipMaxY*3/4, 24, 255);
        }
        SetFontColor(destinyfont[destinycolour][0], destinyfont[destinycolour][1], destinyfont[destinycolour][2], destinyfont[destinycolour][0], destinyfont[destinycolour][1], destinyfont[destinycolour][2]);
        DrawText("海龍 爾夜知", 40, 36, 12, 255);
        SetTexture(BossImage);
        SetGraphicRect(0, 0, 64, 64);
        DrawGraphic(GetX, GetY);
    }

    @Finalize {
        DeleteGraphic(BossImage);
    }
}
Rate. Now. Is tidiness even necessary when you make a game??

edit: POST #⑨0! Yes!!
« Last Edit: October 28, 2009, 02:28:41 AM by AlwaysThe⑨ »