AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Sharing the cellarray handler with two plugins. (https://forums.alliedmods.net/showthread.php?t=243471)

11922911 07-05-2014 02:51

Sharing the cellarray handler with two plugins.
 
Is it possible to sharing the cellarray handler with two different plugins?

For example:
Plugin A has created an cellarray handler, Plugin B wants to use the handler which Plugin A created, when Plugin B makes change to the handler (using ArraySet.., ArrayPush.., etc.) that also affect to the Plugin A.

Backstabnoob 07-05-2014 05:04

Re: Sharing the cellarray handler with two plugins.
 
Yes it is, you can simply return it as an integer via natives. See my database ORM, I do it all the time (all natives tagged with Array)

Nextra 07-05-2014 09:10

Re: Sharing the cellarray handler with two plugins.
 
Also this is possible with every handle. SQL Handles, Cellarrays, Tries, Cvars, Datapacks, HamHooks. It doesn't matter. The handle system in AMXX is very simplistic and does not restrict you in this way.

klippy 07-05-2014 11:20

Re: Sharing the cellarray handler with two plugins.
 
XVars may be really suitable here if he hasn't made an cellarray handler array, i.e:
PHP Code:

new Array: aArray[10]; 



All times are GMT -4. The time now is 21:11.

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