Raised This Month: $344 Target: $400
 86%   Almost there!

Solved how to fix warning 213: tag mismatch


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
alferd
Veteran Member
Join Date: Dec 2019
Location: Iran is Always Eternal
Old 07-15-2020 , 06:21   how to fix warning 213: tag mismatch
Reply With Quote #1

warnings:
PHP Code:
//// ad_Jailbreak.sma
//
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(981) : w
arning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(1378) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(1785) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(1871) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(4132) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(4144) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(4155) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(4166) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(4177) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(4188) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(4199) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(4235) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(5969) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(9626) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(9704) :
warning 213tag mismatch
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(10176) :
 
warning 211possibly unintended assignment
// Header size:          11760 bytes
// Code size:           292340 bytes
// Data size:           237628 bytes
// Stack/heap size:      16384 bytes
// Total requirements:  558112 bytes
//
// 16 Warnings.
// Done.
//
// Compilation Time: 3.51 sec
// ---------------------------------------- 
Code:
    for(i = 0; i < iNum; i++)     {         new id = iPlayers[i]        
        if( cs_get_user_team(id) == 2 ) // Line 9626
        {             if(!get_pcvar_num(pCvarEnabled))             {                 return HAM_IGNORED             }                 if(get_pcvar_num(pCvarBlockDoorButtons) && pev(iEnt,pev_no_open))             {                 return HAM_IGNORED             }                 dllfunc(DLLFunc_Use, iEnt, iAttacker)             return HAM_IGNORED         }     }
__________________
Jailbreak AD 2.0

The greatest civilization of 🇮🇷IRAN🇮🇷

Last edited by alferd; 07-15-2020 at 06:42.
alferd is offline
Shadows Adi
AlliedModders Donor
Join Date: Aug 2019
Location: Romania
Old 07-15-2020 , 06:33   Re: how to fix warning 213: tag mismatch
Reply With Quote #2

You should use CS_TEAM_* to get team of the players.
__________________


Accepting Paid Requests, contact PM.

MVP Of The Round View project on GITHUB / AlliedModders
CSGO REMAKE ~ CSGO MOD [STABLE + SOURCE CODE]
Shadows Adi is offline
alferd
Veteran Member
Join Date: Dec 2019
Location: Iran is Always Eternal
Old 07-15-2020 , 06:38   Re: how to fix warning 213: tag mismatch
Reply With Quote #3

Quote:
Originally Posted by Shadows Adi View Post
You should use CS_TEAM_* to get team of the players.
Thanks

PHP Code:
// C:\PROGRA~1\COUNTE~4\cstrike\addons\amxmodx\SCRIPT~1\ad_Jailbreak.sma(10176) :
 
warning 211possibly unintended assignment 
Code:
        while( ent = engfunc(EngFunc_FindEntityByString, ent, "classname", "info_player_deathmatch") ) // Line 10176
        {                 new ent2 = 1                 pev(ent, pev_origin, origin)                 while((ent2 = engfunc(EngFunc_FindEntityInSphere, ent2, origin, radius)))  // find doors near T spawn                 {                         if(!pev_valid(ent2))                                 continue                         pev(ent2, pev_classname, class, charsmax(class))                         if(!equal(class, "func_door")) // if it's not a door, move on to the next iteration                                 continue                         pev(ent2, pev_targetname, name, charsmax(name))                         ent3 = engfunc(EngFunc_FindEntityByString, 0, "target", name) // find button that opens this door                         if(pev_valid(ent3) && (in_array(ent3, found, sizeof(found)) < 1))                         {                                 ExecuteHamB(Ham_Use, ent3, 0, 0, 1, 1.0) // zomg poosh it                                 break // break from current while loop                         }                 }         }

Do you know a way to solve this problem?
__________________
Jailbreak AD 2.0

The greatest civilization of 🇮🇷IRAN🇮🇷
alferd is offline
Shadows Adi
AlliedModders Donor
Join Date: Aug 2019
Location: Romania
Old 07-15-2020 , 06:40   Re: how to fix warning 213: tag mismatch
Reply With Quote #4

PHP Code:
ent engfunc 
-->>

PHP Code:
ent == engfunc 
__________________


Accepting Paid Requests, contact PM.

MVP Of The Round View project on GITHUB / AlliedModders
CSGO REMAKE ~ CSGO MOD [STABLE + SOURCE CODE]
Shadows Adi is offline
alferd
Veteran Member
Join Date: Dec 2019
Location: Iran is Always Eternal
Old 07-15-2020 , 06:41   Re: how to fix warning 213: tag mismatch
Reply With Quote #5

Quote:
Originally Posted by Shadows Adi View Post
PHP Code:
ent engfunc 
-->>

PHP Code:
ent == engfunc 
Thanks a lot ;)
__________________
Jailbreak AD 2.0

The greatest civilization of 🇮🇷IRAN🇮🇷
alferd is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 07-15-2020 , 07:49   Re: how to fix warning 213: tag mismatch
Reply With Quote #6

Actually no. You should put the entire condition in () and leave =, not ==
__________________

Last edited by HamletEagle; 07-15-2020 at 07:50.
HamletEagle is offline
Shadows Adi
AlliedModders Donor
Join Date: Aug 2019
Location: Romania
Old 07-15-2020 , 08:10   Re: how to fix warning 213: tag mismatch
Reply With Quote #7

Quote:
Originally Posted by HamletEagle View Post
Actually no. You should put the entire condition in () and leave =, not ==
Yea, lol, forgot about that =))
__________________


Accepting Paid Requests, contact PM.

MVP Of The Round View project on GITHUB / AlliedModders
CSGO REMAKE ~ CSGO MOD [STABLE + SOURCE CODE]
Shadows Adi is offline
alferd
Veteran Member
Join Date: Dec 2019
Location: Iran is Always Eternal
Old 07-15-2020 , 08:24   Re: how to fix warning 213: tag mismatch
Reply With Quote #8

Quote:
Originally Posted by HamletEagle View Post
Actually no. You should put the entire condition in () and leave =, not ==

Thanks for pointing me to this

PHP Code:
while( engfunc(EngFunc_FindEntityByStringent"classname""info_player_deathmatch") ) 
?
__________________
Jailbreak AD 2.0

The greatest civilization of 🇮🇷IRAN🇮🇷

Last edited by alferd; 07-15-2020 at 08:26.
alferd is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 07-15-2020 , 11:06   Re: how to fix warning 213: tag mismatch
Reply With Quote #9

That's not what I said. You have an example in the second while loop.

PHP Code:
while((var = something)) 
This is the equivalent of:
PHP Code:
var = something
while(var)
{
    
//code that uses var
    
var = something

__________________

Last edited by HamletEagle; 07-15-2020 at 11:10.
HamletEagle is offline
Natsheh
Veteran Member
Join Date: Sep 2012
Old 07-15-2020 , 11:08   Re: how to fix warning 213: tag mismatch
Reply With Quote #10

PHP Code:
while( (ent engfunc(EngFunc_FindEntityByStringent"classname""info_player_deathmatch")) > 0
__________________
@Jailbreak Main Mod v2.6.6 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !

Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
Reply


Thread Tools
Display Modes

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 22:14.


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