MCPcopy Create free account
hub / github.com/alliedmodders/sourcemod / UnlinkConCommandBase

Method UnlinkConCommandBase

core/concmd_cleaner.cpp:99–125  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

97 }
98
99 void UnlinkConCommandBase(ConCommandBase *pBase)
100 {
101 ConCommandInfo *pInfo;
102 List<ConCommandInfo *>::iterator iter = tracked_bases.begin();
103
104 IConCommandLinkListener *listener = IConCommandLinkListener::head;
105 while (listener)
106 {
107 listener->OnUnlinkConCommand(pBase);
108 listener = listener->next;
109 }
110
111 while (iter != tracked_bases.end())
112 {
113 if ((*iter)->pBase == pBase)
114 {
115 pInfo = (*iter);
116 iter = tracked_bases.erase(iter);
117 pInfo->cls->OnUnlinkConCommandBase(pBase, pBase->GetName());
118 delete pInfo;
119 }
120 else
121 {
122 iter++;
123 }
124 }
125 }
126
127 void AddTarget(ConCommandBase *pBase, IConCommandTracker *cls)
128 {

Callers 1

Calls 6

beginMethod · 0.45
OnUnlinkConCommandMethod · 0.45
endMethod · 0.45
eraseMethod · 0.45
GetNameMethod · 0.45

Tested by

no test coverage detected