Variables between functions
HTML Code:
public ctwin()I mean, if I try to get Trounds in the cmdScore function, it will also add 1 to the variable value. |
Re: Variables between functions
If they are global variables, then just access them directly
|
Re: Variables between functions
Will they keep their values?
Like, if it was modified in a function, will it be modified in all the functions? |
Re: Variables between functions
There is only 1 copy of a global variable, so it will always return the same value regardless of which function you access it in. The same is true if you change the value of it in 1 function, all subsequent checks of the variable will return the new value
|
Re: Variables between functions
Thank you very much, sir!
|
| All times are GMT -4. The time now is 15:19. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.