Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
tag_flash.origin
#1
Hello guys.
Is it possible to get origin and angles of player's weapon tag_flash?
Reply

#2
Maybe,
Code:
org = self GetTagOrigin( "tag_flash" );
? I'm not completely sure if this will work.
[Image: MaEIQ.png]
Reply

#3
(08-09-2012, 07:48)Pozzuh Wrote: Maybe,
Code:
org = self GetTagOrigin( "tag_flash" );
? I'm not completely sure if this will work.

It won't work, because player's world model doesn't have such tag. This is viewmodel's(weapon) tag. Is it possible to get reference to viewmodel?
Reply

#4
Try this, might work. I found this function (which was commented out) in MW2. Might work on Black Ops....
Code:
viewModel = self getViewModel();
pos = viewModel getTagPos("tag_flash");

Are you sure what Pozzuh posted doesn't work? I looked in Black Ops' GSC and found that in zombies, GetTagPos does work on "tag_flash".
[Image: 30xhrep.png]

A casual conversation between barata and I about Nukem.
Reply

#5
I already sent you the way Big Grin
Reply

#6
(08-09-2012, 08:17)master131 Wrote: Try this, might work. I found this function (which was commented out) in MW2. Might work on Black Ops....
Code:
viewModel = self getViewModel();
pos = viewModel getTagPos("tag_flash");

Are you sure what Pozzuh posted doesn't work? I looked in Black Ops' GSC and found that in zombies, GetTagPos does work on "tag_flash".

I forgot to mention that I am modding CoD 4. GetTagPos - unknown function.

(08-09-2012, 13:48)Yamato Wrote: I already sent you the way Big Grin

It woks only if you have reference to entity.model. I don't know how to get reference to entity.viewmodel. self getviewmodel won't help. It only returns model name.
Reply

#7
(08-09-2012, 14:20)GenaSG Wrote:
(08-09-2012, 08:17)master131 Wrote: Try this, might work. I found this function (which was commented out) in MW2. Might work on Black Ops....
Code:
viewModel = self getViewModel();
pos = viewModel getTagPos("tag_flash");

Are you sure what Pozzuh posted doesn't work? I looked in Black Ops' GSC and found that in zombies, GetTagPos does work on "tag_flash".

I forgot to mention that I am modding CoD 4. GetTagPos - unknown function.

(08-09-2012, 13:48)Yamato Wrote: I already sent you the way Big Grin

It woks only if you have reference to entity.model. I don't know how to get reference to entity.viewmodel. self getviewmodel won't help. It only returns model name.

The viewmodel angles should be same as:

Code:
self getPlayerAngles();

I dont know about origin, I found this function on MW2, I havent tried it but I guess it will return the height of your eye respect to your origin

Code:
self getPlayerViewHeight();

So the origin of the viewmodel would be:

Code:
( self getOrigin()[0], self getOrigin()[1], self getOrigin()[2] + self getPlayerViewHeight() )

I am not really sure.
Reply

#8
Ok. I'll try to describe why do I need tag_flash origin.
I am developer of ProjectileWeapons mod for call of duty 4. I want to improve realism of the mod. I want to make so that bullets will "shoot" from weapon's barrel. I see two alternatives here:
1)Get origin and angles of weapon's tag flash and spawn bullet using those values(But I don't know how to get those values).
2)I can spawn models using muzzleflash effect(like brickblaster_mp) but I can't get origin of those "bricks". Is it possible to get origin of those "bricks"?
Reply

#9
(08-09-2012, 15:18)GenaSG Wrote: Ok. I'll try to describe why do I need tag_flash origin.
I am developer of ProjectileWeapons mod for call of duty 4. I want to improve realism of the mod. I want to make so that bullets will "shoot" from weapon's barrel. I see two alternatives here:
1)Get origin and angles of weapon's tag flash and spawn bullet using those values(But I don't know how to get those values).
2)I can spawn models using muzzleflash effect(like brickblaster_mp) but I can't get origin of those "bricks". Is it possible to get origin of those "bricks"?

I think it's not possible to get bullets, but it is possible to get rockets/noob tube shots. Look into it, search through the gsc files on something like "weapon_fired".
[Image: MaEIQ.png]
Reply

#10
(08-09-2012, 16:03)Pozzuh Wrote:
(08-09-2012, 15:18)GenaSG Wrote: Ok. I'll try to describe why do I need tag_flash origin.
I am developer of ProjectileWeapons mod for call of duty 4. I want to improve realism of the mod. I want to make so that bullets will "shoot" from weapon's barrel. I see two alternatives here:
1)Get origin and angles of weapon's tag flash and spawn bullet using those values(But I don't know how to get those values).
2)I can spawn models using muzzleflash effect(like brickblaster_mp) but I can't get origin of those "bricks". Is it possible to get origin of those "bricks"?

I think it's not possible to get bullets, but it is possible to get rockets/noob tube shots. Look into it, search through the gsc files on something like "weapon_fired".

I ment projectiles. I am using "classname" "grenade" in my mod for almost all weapons. I can get them with grenades = getentarray("grenade","classname"). And how about my second question? I mean is it possible to get array of those brickblaster's "bricks"?
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  [Request] ServerClient.Origin archit 4 3,542 09-19-2012, 01:35
Last Post: DidUknowiPwn
  Help Teleporting via Flags/Origin/Location yokai134 2 2,961 09-06-2012, 12:19
Last Post: yokai134
  [News] Origin still cracked d0h! 19 15,277 08-10-2012, 11:13
Last Post: d0h!
  I HATE ORIGIN!!! Arteq 10 6,856 03-17-2012, 22:30
Last Post: Pozzuh
  Distance(self.origin, location) not working? xplosiff 3 3,278 01-05-2012, 17:39
Last Post: xplosiff
  [Release] Battlefield 3 RETAIL/ORIGIN PLUS 14 TRAiNER dEViATED 2 4,688 11-19-2011, 12:56
Last Post: d0h!
  [Release] Battlefield 3 Multiplayer Without Origin Internal d0h! 13 26,551 11-02-2011, 01:02
Last Post: House
  How to change your Origin ID williamadinata 3 5,540 10-31-2011, 14:23
Last Post: OrangePL
  [Release] One Click - Kill Origin after BF3 has started d0h! 6 5,183 10-31-2011, 09:56
Last Post: d0h!
  Fucking Origin Pozzuh 13 12,557 10-05-2011, 15:11
Last Post: Pozzuh

Forum Jump:


Users browsing this thread:
2 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.