Advertisement
Guest User

Untitled

a guest
Apr 10th, 2016
132
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.84 KB | None | 0 0
  1. //Use Line special "121" to identify the line you want to break through. Give it a middle texture and set to "impassible"
  2. //Make the line triggered by "projectile hits" or "projectile hits or crosses" or by "use" if you want it triggered by "use"-ing
  3.  
  4. //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
  5.  
  6.  
  7. Script 1 OPEN
  8. {
  9. Setlinespecial(1,80,2,0,0,0,0); //sets the identified line to execute script 2 when triggered
  10. }
  11.  
  12.  
  13.  
  14.  
  15.  
  16.  
  17. script 2 (void) //wall breaking script
  18. {
  19. int x; //set to whatever letter is free, or leave as "x", this is just a timer for spawning debris
  20. x=0;
  21. Setlinespecial(1,0,0,0,0,0,0); //deactivates the line, so it can't be triggered again
  22. Radius_Quake(1,60,0,30,98); //earthquake
  23. ambientsound("rocks",1.0); //sound of rocks, you will need to define your wall collapsing sound in SNDINFO
  24. setlinetexture(1,SIDE_FRONT,TEXTURE_MIDDLE,"BLANK"); //set the front of the line to be see-through
  25. setlinetexture(1,SIDE_BACK,TEXTURE_MIDDLE,"BLANK"); //set the back of the line to be see-through
  26. Line_setblocking(1,0,1); //set the line to no longer block anything
  27. while( x < 30) //spawn some rocks and debris
  28. {
  29. 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)
  30. 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)
  31. delay(1);
  32. x++;
  33. }
  34. }
  35.  
  36. //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