Game Development Community

Weapon fires, No projectile

by Geoffrey Cain · in Technical Issues · 07/11/2007 (9:05 pm) · 2 replies

Hi, I'm still learning programming in college. while trying to create a new weapon, i copied the crossbow files and renamed it the Autocrossbow. I can pick it up, switch to it, and fire, but no crossbow bolt projectile fires. I'm guessing i need some additional file name changes, but i don't know how many. the original crossbow is still in the game, so those paths exist, as well as the new Autocrossbow .cs and shapes folder. this is part of my graduation project so help is greatly appriciated.


Geoff

About the author

Recent Threads


#1
07/12/2007 (10:08 pm)
1. Is the maxInv[] field set in the player datablock for both the ammo and weapon?
2. Is every occurance of Crossbow changed to AutoCrossbow in your new script file?
3. Is autocrossbow.cs exec'd in game.cs?
4. Go into camera fly mode, look at your player up close, go into the World Editor (f11), and get his ID number. In the console, type:
echo( [i]PLAYERID[/i].getInventory(AutoCrossbowAmmo) );
If that returns zero or a blank line, something's wrong with the ammo or the ::onFire(...) method.
#2
07/16/2007 (7:30 pm)
Thank you BrYcE, I had missed one Crossbow Refrence.