Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "zcommon.acs"
- function int Clamp(int i, int min, int max)
- {
- if (i < min) return min;
- if (i > max) return max;
- return i;
- }
- script "DPartSide" (int cx, int cy, int cz, int sang)
- {
- int topz = cz+64.0;
- for (int i = 0; i < 128; i++)
- {
- int x = sin(sang)*32 + cx;
- int y = cos(sang)*32 + cy;
- int z = topz-(i<<16);
- SpawnParticle(0x00FF00, true, 35, 9, x, y, z, 0, 0, 0, 0, 0, 0, Clamp(i*6, 0, 255), -1);
- sang += 0.01*2;
- if ((i%4)==0) Delay(1);
- }
- }
- script "DPartBottom" (int cx, int cy, int cz)
- {
- int angf = 360/2;
- int angdst = 65535/angf;
- for (int j = 0; j < 64; j+=2)
- {
- for (int i = 0; i < angf; i++)
- {
- int x = sin(angdst*i)*j + cx;
- int y = cos(angdst*i)*j + cy;
- int z = cz;
- if (j == 32) SpawnParticle(0x00FF00, true, 35, 8, x, y, z, 0, 0, 0, 0, 0, 0, 255, -1);
- else SpawnParticle(0x00FF00, true, 1, 4, x, y, z, 0, 0, 0, 0, 0, 0, 64-j, 0);
- }
- Delay(1);
- }
- }
- script "DSpawnScript" (int tag, int mons)
- {
- int cx = GetActorX(tag);
- int cy = GetActorY(tag);
- int cz = GetActorZ(tag);
- ACS_NamedExecuteWithResult("DPartBottom", cx, cy, cz, 0);
- ACS_NamedExecuteWithResult("DPartSide", cx, cy, cz, 0.25);
- ACS_NamedExecuteWithResult("DPartSide", cx, cy, cz, 0.75);
- Delay(15);
- SpawnForced("TeleportFog", cx, cy, cz);
- SpawnForced(mons, cx, cy, cz, 0, GetActorAngle(tag)>>8);
- }
- script 1 (void)
- {
- ACS_NamedExecuteWithResult("DSpawnScript", 1, "DoomImp", 0, 0);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement