Raised This Month: $ Target: $400
 0% 

[L4D2] player_transitioned hook not working?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
n3wton
Senior Member
Join Date: Mar 2010
Old 04-16-2010 , 13:03   [L4D2] player_transitioned hook not working?
Reply With Quote #1

Hello,
I'm currently writting a mod, that needs to do something as soon as the player is in first person camera mode, previously I've being using a timer the length of the cinematic, but thats not too accurate, and lets be honest, terrible coding.

SO I figured there must be an event for it, and found
player_transitioned

Perfect right?

But it doesn't seem to be working, has anyone else got this event working?
Im using sourcemod 1.4

Yours
N3wton
n3wton is offline
exvel
SourceMod Donor
Join Date: Jun 2006
Location: Russia
Old 04-16-2010 , 14:18   Re: [L4D2] player_transitioned hook not working?
Reply With Quote #2

Well, AFAIK there are many events that actually do not fire at all. This is Valve's fault.
__________________
For admins: My plugins

For developers: Colors library
exvel is offline
Send a message via ICQ to exvel
Dusty1029
Junior Member
Join Date: Mar 2010
Old 04-17-2010 , 00:25   Re: [L4D2] player_transitioned hook not working?
Reply With Quote #3

player_transitioned I believe fires when players join maps in coop.

Eg. You beat the hotel stage, then go to the next level. After players connect to the next level, player_transitioned fires off.

You are probably looking for player_first_spawned or player_spawned something of that sort
Dusty1029 is offline
n3wton
Senior Member
Join Date: Mar 2010
Old 04-17-2010 , 20:39   Re: [L4D2] player_transitioned hook not working?
Reply With Quote #4

Oh ok, it's just that on the wiki it said
"Note: When campaign cinematics end and player is transitioned to first person view"

Cos I need my code to run straight after the starting cinemtaics.

At the moment I've changed it so it runs my code when a player presses W,A,S or D but thats a terrible waay of doing it.

Yours
N3wton
n3wton is offline
FaTony
Veteran Member
Join Date: Aug 2008
Old 04-18-2010 , 02:19   Re: [L4D2] player_transitioned hook not working?
Reply With Quote #5

You can try watching other SendProps OnGameFrame.
FaTony is offline
n3wton
Senior Member
Join Date: Mar 2010
Old 04-18-2010 , 07:13   Re: [L4D2] player_transitioned hook not working?
Reply With Quote #6

What I've done now is, watch the entityflags, and when it is set to the correct flag (the one straight after being unfrozen from the cinematics) it pauses.
Thanks for everyones suggestions
Yours
N3wton
n3wton is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 12:21.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode