Hit a wall, read through funcs and stuff before post
Server says im flooding and join teams doesn't work lol, im new to pawn/small amxmodx my logic here is prob wrong is there anyone that can help me out thank you
PHP Code:
|
Re: Hit a wall, read through funcs and stuff before post
40 views and no one has bothered to leave a comment :down: how hard can it be to just say....
oh look ur syntax or logic is wrong or this ".." doesn't work like that for example I've read some of the tutorials http://wiki.alliedmods.net/index.php/Pawn_Tutorial http://wiki.alliedmods.net/Advanced_...X_Mod_X)#Tasks and used http://www.amxmodx.org/funcwiki.php so it isn't through lazyness I can't get this to work.. so please be kind enough to leave a helpfull comment or suggestion. |
Re: Hit a wall, read through funcs and stuff before post
|
Re: Hit a wall, read through funcs and stuff before post
Thank you and I'll use firefox next time, nullification so team[0] would be 'null' and team[1] = what I set it to right?
When comparing the jointeam argument you use integers instead of characters. You must either compare them to characters or convert the array cell to an integer. so either I set team[1] to a/b/c or convert them to numbers? it would be in ascii right? so what will I have to use to convert them, or is there another method to store numbers without converting etc I plan on adding other say commands in the same plugin to compact it abit for when I make my other plugins which is why I've gone the long way round :wink: |
Re: Hit a wall, read through funcs and stuff before post
Quote:
Code:
Quote:
Simply: Code:
Quote:
This is a VERY common misconception to most beginners. Often it is perceived that it is much nicer and more stylistic to compact everything, being able to add things in whenever you decide to make a new command. There is nothing wrong with registering new clcmds and though it may be more efficient (not even sure about that one), it is more confusing for you and you should not try doing this until you have learned the basics. No one will scold you for having many clcmds. I can tell you'll like API's. ;) EDIT: Also, in jointeam use the argument of 1 to get the team #, as 0 is the actual jointeam command itself. |
Re: Hit a wall, read through funcs and stuff before post
amxx took my API virginity :D, not so much now but the possibilities of what I'll be able to do with my favourite game!
PHP Code:
debug results: test team = 0 = 3 which tells me cs_get_user_team isn't returning anything at all, not what func wiki says, thank you so much wrecked EDIT: Also, in jointeam use the argument of 1 to get the team #, as 0 is the actual jointeam command itself. so team[0] = jointeam, team[1] = team, team[2] = null? my debug comes out fine with the team numbers though |
Re: Hit a wall, read through funcs and stuff before post
Quote:
A full list:
Quote:
Quote:
|
Re: Hit a wall, read through funcs and stuff before post
Quote:
http://www.cplusplus.com/reference/c...cstdio/printf/ The * is probably the coolest thing I've seen for formatting. |
Re: Hit a wall, read through funcs and stuff before post
PHP Code:
cs_set_user_team was returning 0 (no team choosen) 1 Terrorist, 2 CT, 3 Spec edit: found cs_user_spawn skimmed past it |
Re: Hit a wall, read through funcs and stuff before post
Quote:
Never knew about the e's, those sound like they'd be cool. :wink: |
| All times are GMT -4. The time now is 02:12. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.