Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Use Line special "121" to identify the line you want to break through. Give it a middle texture and set to "impassible"
- //Make the line triggered by "projectile hits" or "projectile hits or crosses" or by "use" if you want it triggered by "use"-ing
- //you will also need to place a map spot for the quake epicentre (ideally on the line), and some map spots to spawn rocks / debris
- Script 1 OPEN
- {
- Setlinespecial(1,80,2,0,0,0,0); //sets the identified line to execute script 2 when triggered
- }
- script 2 (void) //wall breaking script
- {
- int x; //set to whatever letter is free, or leave as "x", this is just a timer for spawning debris
- x=0;
- Setlinespecial(1,0,0,0,0,0,0); //deactivates the line, so it can't be triggered again
- Radius_Quake(1,60,0,30,98); //earthquake
- ambientsound("rocks",1.0); //sound of rocks, you will need to define your wall collapsing sound in SNDINFO
- setlinetexture(1,SIDE_FRONT,TEXTURE_MIDDLE,"BLANK"); //set the front of the line to be see-through
- setlinetexture(1,SIDE_BACK,TEXTURE_MIDDLE,"BLANK"); //set the back of the line to be see-through
- Line_setblocking(1,0,1); //set the line to no longer block anything
- while( x < 30) //spawn some rocks and debris
- {
- Thing_projectile(98, random(41,49), random(0,255), random(10,50), random(30,-255)); //"98" here is the map spot to spawn at. "random(41,49)" is a whole lot of rocks (this is from a hexen based mod, so check the spawn numbers of whatever debris you want to spawn by looking up spawn numbers of your selected base wad)
- Thing_projectile(99, random(41,49), random(0,255), random(10,50), random(30,-255)); //more debris to spawn at a different location (map spot 99)
- delay(1);
- x++;
- }
- }
- //you can have a few different map spots littered around your wall, up to 4 or 5 if you like, just add more Thing_projectile lines with the right spot ID in them
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement