#1

i had a idea of detecting a bullets path, and creating icons in its path, but i really have no clue on how i would do it, so if anyone has any ideas, tell me
Reply
#2

With icons, you mean mapicons, objects, or pickups?
You will have to use the OnPlayerKeyStateChange callback to detect when someone presses the left click (that is, when he shot) and check the weapon he is currently carrying (you don't want to make trails if he is punching or throwing a grenade).
After that, you need to use the GetPlayerCameraFrontVector function, which will give you a player-relative position of where the player is aiming. You add several multipliers to the values gotten, sum the player's position to it, and create an object/pickup/mapicon.
Try to do it, if you get stuck or need further insight in this last part don't hesitate to ask.
Reply
#3

Quote:
Originally Posted by Zamaroht
Посмотреть сообщение
With icons, you mean mapicons, objects, or pickups?
You will have to use the OnPlayerKeyStateChange callback to detect when someone presses the left click (that is, when he shot) and check the weapon he is currently carrying (you don't want to make trails if he is punching or throwing a grenade).
After that, you need to use the GetPlayerCameraFrontVector function, which will give you a player-relative position of where the player is aiming. You add several multipliers to the values gotten, sum the player's position to it, and create an object/pickup/mapicon.
Try to do it, if you get stuck or need further insight in this last part don't hesitate to ask.
yeah, icons

i tried for myself, and i got stuck at the multipliers
Reply
#4

https://sampforum.blast.hk/showthread.php?tid=138791

watch the vid:

https://sampforum.blast.hk/showthread.php?tid=137869
Reply
#5

thanks
Reply
#6

For Hydras there are bullet paths (lil grey icons)
Reply
#7

lol you should have asked me ive had a script like that for ages dont no what to do with it lol but you got one now but remember youve always got my msn
Reply
#8

Quote:
Originally Posted by Tommie1331
Посмотреть сообщение
lol you should have asked me ive had a script like that for ages dont no what to do with it lol but you got one now but remember youve always got my msn
Too bad it's probably ripped like 'your' object editor is.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)