Raised This Month: $ Target: $400
 0% 

How do I convert a BYTE array to LONG in AMXX?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 09-17-2013 , 00:21   Re: How do I convert a BYTE array to LONG in AMXX?
Reply With Quote #2

Add bytes together displacing them 1 by 1 ?

PHP Code:
longVariable byte0 byte1<<byte2<<16 byte3<<24 
PHP Code:
    new bytes_array[4 char], longVariable;

    
longVariable bytes_array[0] | bytes_array[1]<<bytes_array[2]<<16 bytes_array[3]<<24

PHP Code:
    new bytes_array[4 char], longVariable;

    
longVariable bytes_array[3] | bytes_array[2]<<bytes_array[1]<<16 bytes_array[0]<<24
__________________
- tired and retired -

- my plugins -

Last edited by ConnorMcLeod; 09-17-2013 at 00:23.
ConnorMcLeod is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:48.


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