PDA

View Full Version : Shotgun editing


Guest
08-19-2000, 09:13 PM
If i wanted to have explosive shotgun shells and everytime i try something it finds something wrong with the rest of the coding! can someone tell me how to do it? I tried and it is making me mad now so im done fooling with it! The cons are a serious pain if you don't know what to do!

Guest
08-19-2000, 09:44 PM
Simple way is as follows

Change the shotgun strength to -10
in the actor SHOTSPARK1
add this in the top of its code
ifstrength 0 { hitradius 1000 50 50 50 50 spawn EXPLOSION }
Save, start the game, get out the shotgun, walk up to a wall and hit fire.
www.dukeworld.com/oglbt/h_confaq.htm (http://www.dukeworld.com/oglbt/h_confaq.htm)

Guest
08-19-2000, 09:44 PM
how come when ever I download a con file it and try to run it duke always finds something wrong with it?

Guest
08-19-2000, 09:57 PM
THANK YOU! That worked! Is it to much to ask for an explination? I think I'm pushing it. sorry!

Guest
08-21-2000, 04:03 AM
Okay,
Well firstly, the Shotgun, the Pistol and the Chaingun ALL use the same code, and this is under the actor caleld SHOTSPARK1.
Okay, secondly, we need to make sure that we can detect that the weapon was fired by the SHOTGUN and not the other two guns. The only way to do this is by using the ifstrength command. This is a if strength is less than or equal too function. The strenght of all bullets has a random 1 to 7 added to it, so we make sure that since we are testing for 0 or below, we make the shotgun less than -7. I use -10 just to make sure. http://www.3drealms.com/ubb/images/icons/smile.gif
Now, since we have detected which weapon it is, in this code we can now add the bit for the explosion. This is a simple hitradius radius strength1 strength2 strength3 strength4 to damage whatever is near it and a spawn EXPLOSION to make the image.
That is basically how it works.
For reference, use http://www.dukeworld.com/oglbt/h_confaq.htm

Hope that helped.

Guest
08-21-2000, 05:25 PM
You have no idea how greatful I am! Thank you VERY much! I figured out with that explination how to make exploding chaingun bullets and hangun bullets as well. Thank you.