AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Read all public (https://forums.alliedmods.net/showthread.php?t=162632)

Diegorkable 07-21-2011 07:42

Read all public
 
PHP Code:

public test1()
{
       
// part 1 of code

       
test2()

       
// part 2 of code
}

public 
test2()
{
       
// some code


MY question is, will part 2 of code in public test1 be read?

Arkshine 07-21-2011 07:44

Re: Read all public
 
Yes. Something you could test yourself easily.

Diegorkable 07-21-2011 08:05

Re: Read all public
 
And what if there's a recoursive set_task(1.0, "test2") in public test2, will it (part 2 of code of public test1) still be read?

Arkshine 07-21-2011 08:09

Re: Read all public
 
set_task don't pause the server, it's a timer which will execute your function at t time. So yes, part2 will be read.


All times are GMT -4. The time now is 00:46.

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