Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsCog Forum → Projectile ignoring (then not) fireoffset in FireProj().......
Projectile ignoring (then not) fireoffset in FireProj().......
2002-01-27, 9:29 PM #1
I've got an actor/projectile hybrid thing goin on, and when I use FireProjectile(), it always ignores the fireoffset and fires it from the center of the player. So to work around this, I fire a custom ghost in front of the player and fire the projectile from there. I mistakenly messed up one time and left the fireoffset in for the projectile when firing from the ghost, and it didn't ignore it! [http://forums.massassi.net/html/confused.gif]

I wouldn't have a problem at all with this if it wasn't for the fact that I need to use GetThingParent on the projectile to do some stuff and it doesn't work right. If nobody can come up with a solution for the "ignoring fireoffset when firing from the player" I'll go into my GetThingParent() problem in another post.
-Hell Raiser
2002-01-27, 10:04 PM #2
I don't see why it ignores fireoffset. I know that you can't use FireProjectile from a non-player/ai thing, but when used from the player it must work - all the weapon cogs use it. Check other weapon cogs, maybe you forgot something.

As for firing from the ghost... add SetThingLook(ghost, GetThingLVec(player)) followed by CreateThing(projectile_template, ghost), that should pretty much cover firing the projectile in the right direction.
Dreams of a dreamer from afar to a fardreamer.
2002-01-27, 10:11 PM #3
FireProjectile does work with any thing, it's not eclusive to the player. I've done it pleny of times in plenty of cogs with no problems what so ever. Even LEC used it in the Nar Shaddar MP level with those turret thingies. (m2_turrettrap.cog) Where ever you got that tidbit of knowledge from is wrong.....
-Hell Raiser
2002-01-28, 3:20 AM #4
I remember something from a cog of mine... but it's been a while, and I may have forgotten the details. Maybe the problem is that when the thing is not an AI thing, FireProjectile ignores the look vector of the player and fires in the direction (1, 0, 0).
Dreams of a dreamer from afar to a fardreamer.
2002-01-28, 5:17 PM #5
Not even close to what I need. =\

*bump* Anyone else have any ideas?
-Hell Raiser
2002-01-29, 9:30 AM #6
FireProjectile() offsets from the player have always worked for me. If you'd post some code that has the error, I'll be better able to help you. [http://forums.massassi.net/html/wink.gif]

------------------
Each cog better than the next
Author of the JK DataMaster, Parsec, Scribe, and the EditPlus Cog Files.

↑ Up to the top!