Thread
: [Solved]
Set pack position on end not working
View Single Post
headline
SourceMod Moderator
Join Date: Mar 2015
09-18-2017 , 21:57 Re: Set pack position on end not working
#
2
Quote:
Originally Posted by
Peace-Maker
You shouldn't be using SetPackPosition. It's setting the position of the internal char* stream
to some offset
. You'd need to calculate the offset yourself which will likely break easily.
WritePackCell first "pushes" the size of a cell (4 bytes) on the stream then the cell itself (4 bytes again). So you'd need to set the pack position to 5*8=40. It gets trickier with strings in the pack.. You'd be better off with an
adt_trie
. SetPackPosition should be deprecated as it's of no practical use.
headline
View Public Profile
Send a private message to headline
Visit headline's homepage!
Find More Posts by headline