setDvar("camera_thirdperson", 0);
setDvar("camera_firstperson", 1);
thirdPersonToggle()
{
self endon ( "death" );
self notifyOnPlayerCommand( "dpad_down", "+actionslot 2" );
thirdPersonElem = self createFontString( "default", 1.5 );
thirdPersonElem setPoint( "TOPRIGHT", "TOPRIGHT", 0, 72 + 260 );
thirdPersonElem setText( "3rd Person: " + getDvarInt( "camera_thirdPerson" ) + " [{+actionslot 2}]" );
self thread destroyOnDeath( thirdPersonElem );
for ( ;; )
{
self waittill( "dpad_down" );
setDvar( "camera_thirdPerson", !getDvarInt( "camera_thirdPerson" ) );
thirdPersonElem setText( "3rd Person: " + getDvarInt( "camera_thirdPerson" ) + " [{+actionslot 2}]" );
}
}