Registers new requester type.
438{
441
443
477
483
485
487 {
489
492
494 }
495
497 {
499 {
502 }
503 }
504
512 {
513 if (!type)
514 {
515 Error(
"Requested type is NULL!");
516 return null;
517 }
518
522 {
524 if (temp.Type() == type)
525 {
527 break;
528 }
529 }
530
531 if (!ret)
532 {
533 Debug.
Log(
"'" + type.ToString() +
"' not found in bank! Register first in 'RegisterRequester' method.");
534 }
535 return ret;
536 }
537
545 {
547
548 if (!ret)
549 {
550 Debug.
Log(
"Requester idx '" + index +
"' not found in bank! Register first in 'RegisterRequester' method.");
551 }
552 return ret;
553 }
554
562 {
563 int ret = -1;
565
567 {
569 if (temp.Type() == type)
570 {
572 }
573 }
574
575 if ( ret == -1 )
576 {
577 Debug.
Log(
"Requester instance of the '" + type.ToString() +
"' type not found in bank! Register first in 'RegisterRequester' method.");
578 }
579 return ret;
580 }
581
588 {
589 typename ret;
591 if ( !temp )
592 {
593 Debug.
Log(
"No requester exists under idx '" + index +
"' in bank! Register first in 'RegisterRequester' method.");
594 }
595 else
596 {
597 ret = temp.Type();
598 }
599
600 return ret;
601 }
602
608 {
611
613 {
614
615 Debug.
Log(
"Trying to register an already existing requester type: " + type);
616 return -1;
617 }
618
620
625
627 }
628
631 {
633 {
634 return true;
635 }
636
639 {
641 if (temp == req)
642 {
643 return true;
644 }
645 }
646
647
648 Debug.
Log(
"Requester instance '" + req +
"' not valid! Please use registered instances from PPERequesterBank.");
649 return false;
650 }
651
654 {
656 if (req)
657 {
659 }
660 else
661 {
662 Debug.
Log(
"'" + type.ToString() +
"' not found in bank! Register first in 'RegisterRequester' method.");
663 }
664
665 return false;
666 }
667
670 {
672 if (req)
673 {
675 }
676 else
677 {
678 Debug.
Log(
"Requester idx '" + index +
"' not found in bank! Register first in 'RegisterRequester' method.");
679 }
680
681 return false;
682 }
683
684
685
686
687
688
689
690
691
692
693}
694
697{
699 {
701 }
702
704 {
705
706 }
707}
708
709
710
711
712
713
714
715
static const int REQ_HEALTHHITEFFECTS
static const int REQ_GLASSESTACTICAL
static const int REQ_CONTROLLERDISCONNECT
static const int REQ_LATENCYBLUR
static const int REQ_GLASSESSPORTBLACK
void RegisterAdditionalRequesters()
static ref map< int, ref PPERequesterBase > m_Instances
static const int REQ_FEEDBACKBLUR
static const int REQ_INTROCHROMABB
static const int REQ_CONTROLLERBLUR
static const int REQ_GLASSESDESIGNER
class PPERequesterBank extends Managed PPERequesterRegistrations()
Mod this, if you wish to register custom requesters inside 'RegisterAdditionalRequesters' override.
static const int REQ_BURLAPSACK
static const int REQ_INVENTORYBLUR
static const int REQ_CONTAMINATEDAREA
static const int REQ_GLASSESAVIATOR
static const int REQ_MOTOHELMETBLACK
static bool VerifyRequester(PPERequesterBase req)
Verifies the instance.
static const int REQ_GLASSESSPORTORANGE
static const int REQ_CAMERANV
static const int REQ_SHOCKHITEFFECTS
static const int REQ_FEVEREFFECTS
static int RegisterRequester(typename type)
Registers new requester type.
static const int REQ_DROWNING
static int GetRequesterID(typename type)
Returns an ID of a requester type.
static const int REQ_TUTORIALEFFECTS
static ref PPERequesterRegistrations m_Registrations
static const int REQ_DEATHEFFECTS
static GetRequesterTypename(int index)
Returns a typename from a requester ID.
static const int REQ_SQUINT
static const int REQ_UNCONEFFECTS
static const int REQ_SANDSTORMEFFECT
static const int REQ_TUNELVISSION
static const int REQ_BLOODLOSS
static const int REQ_HMP_GHOST
static const int REQ_GLASSESWELDING
static const int REQ_PAINBLUR
static const int REQ_FLASHBANGEFFECTS
static const int REQ_CAMERAADS
static const int REQ_MENUEFFECTS
static const int REQ_UNDERGROUND
static const int REQ_GLASSESSPORTBLUE
static const int REQ_SERVERBROWSEREFFECTS
static const int REQ_GLASSESSPORTGREEN
static const int REQ_SPOOKYAREA
PPERUndergroundAcco GetRequester()
Super root of all classes in Enforce script.
static void Log(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Prints debug message with normal prio.
bool IsRequesterRunning()
void SetRequesterIDX(int idx)
automatically assigned by PPERequesterBank
void Error(string err)
Messagebox with error message.
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.