Raised This Month: $51 Target: $400
 12% 

[TUT] Enumerations (enum)


Post New Thread Reply   
 
Thread Tools Display Modes
Clauu
Senior Member
Join Date: Feb 2008
Location: RO
Old 05-14-2013 , 08:14   Re: [TUT] Enumerations (enum)
Reply With Quote #101

Quote:
Originally Posted by YamiKaitou View Post
Just note that AMXX is unlikely to incorporate any new features they add to Pawn. I do not know what version of Pawn is used by AMXX, but I highly doubt it is the latest
The latest version is from june last year, once a year it will be a reasonable period for amxx to update his pawn version.
Clauu is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 05-14-2013 , 08:54   Re: [TUT] Enumerations (enum)
Reply With Quote #102

It won't happen. If I remember the version used has been modified for AMXX (a castrated version of the real Pawn, you could say) and if you look at 4.0.4548 it breaks many things, resulting all plugins would need to be recompiled and most won't work anymore. You can be sure BAILOPAN won't allow that.
That's said, it would be cool for sure the full Pawn and latest version but considering AMXX is marked as mature project and there aren't really maintainers anymore behind, you can't expect a change.
__________________
Arkshine is offline
Xablau
Member
Join Date: Dec 2014
Old 01-07-2015 , 11:11   Re: [TUT] Enumerations (enum)
Reply With Quote #103

How to use, exemple:

g_ePlayerData[ id ][ Player_Kills ] = 2
g_ePlayerData[ id ][ Player_Kills ] [ Round ] = 10

In the tenth round the player killed 2

How is the structure?

Last edited by Xablau; 01-07-2015 at 11:12.
Xablau is offline
RateX
Veteran Member
Join Date: Jun 2012
Location: 0o. SEA .o0
Old 01-07-2015 , 12:29   Re: [TUT] Enumerations (enum)
Reply With Quote #104

Explain exactly what you're trying to achieve.
Beside, wouldn't this be simpler:
g_ePlayerData[id][playerkill][10] = 2
RateX is offline
Xablau
Member
Join Date: Dec 2014
Old 01-07-2015 , 13:02   Re: [TUT] Enumerations (enum)
Reply With Quote #105

g_ePlayerData[id][playerkill] = 2 // Work
g_ePlayerData[id][playerkill][10] = 2 // Not Work

I want to inform more than 1 value in only one array.
Xablau is offline
Xablau
Member
Join Date: Dec 2014
Old 01-07-2015 , 13:15   Re: [TUT] Enumerations (enum)
Reply With Quote #106

I got

PHP Code:
enum _:PlayerData 
{
   
playerkill
}
enum _:PlayerDataValue 
{
   
round,
   
kills
}
new 
p_Data[33][PlayerData][PlayerDataValue
g_ePlayerData[id][playerkill][round] = 2
g_ePlayerData[id][playerkill][kills] = 10
Xablau is offline
FromTheFuture
Senior Member
Join Date: Jan 2013
Old 02-03-2015 , 15:41   Re: [TUT] Enumerations (enum)
Reply With Quote #107

PHP Code:
enum data
{
    
CVARLIMIT_CT,
    
CVARLIMIT_T
}

new 
eWpn[33][data]; 
I want to set eWpn[*all*][CVARLIMIT_CT] to 5 by default for everyone. How to do it?
FromTheFuture is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 02-03-2015 , 18:52   Re: [TUT] Enumerations (enum)
Reply With Quote #108

With a for loop. But because it's player data, it would be better to set the value on client_connect() or client_putinserver().
__________________

Last edited by fysiks; 02-03-2015 at 18:52.
fysiks is offline
georgik57
Veteran Member
Join Date: Oct 2008
Location: 🎧Music World
Old 06-21-2015 , 09:34   Re: [TUT] Enumerations (enum)
Reply With Quote #109

Thank you.
__________________
georgik57 is offline
Send a message via MSN to georgik57 Send a message via Yahoo to georgik57 Send a message via Skype™ to georgik57
Xalus
Veteran Member
Join Date: Dec 2009
Location: Belgium
Old 06-28-2015 , 15:30   Re: [TUT] Enumerations (enum)
Reply With Quote #110

PHP Code:
    enum data 
    

        
CVARLIMIT_CT
        
CVARLIMIT_T 
    

    
    new 
eWpn[data][33];  
    
    
arrayset(eWpn[CVARLIMIT_CT], 532)
    
arrayset(eWpn[CVARLIMIT_T], 532
But like fysiks says, if its possible, just use player connect.
__________________
Retired.

Last edited by Xalus; 06-28-2015 at 15:31.
Xalus 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 03:40.


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