29.03.2017, 16:30
You certainly cannot if you declare your array like that. If you declare it like this instead then you can :
It is mandatory in pawn to know array size before compilation therefore dynamic memory allocation is not possible through pawn directly.
You can use plugin if you really want dynamic memory allocation, here is one i found https://sampforum.blast.hk/showthread.php?tid=364285
Quote:
new arr[50] = {1, 3, 5, 7}; |
You can use plugin if you really want dynamic memory allocation, here is one i found https://sampforum.blast.hk/showthread.php?tid=364285