XeNTaX Forum Index
Forum MultiEx Commander Tools Tools Home
It is currently Wed Aug 23, 2017 6:54 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: MaxScript alignment function
PostPosted: Sun Jan 18, 2015 5:53 pm 
Offline
veteran

Joined: Wed Jun 04, 2014 7:48 pm
Posts: 106
Location: Netherlands
Has thanked: 19 times
Have thanks: 29 times

Since I couldn't find anything like this on the web, I figured I'd write one myself and share it here so others can find it.

Code:
fn AlignOffset fstream relativeoffset alignment = (
   align = (alignment - (mod relativeoffset alignment as integer))
   align = fseek fstream align #seek_cur
   return align
)


usage eg:

Code:
fseek f PBChunkSize #seek_set
AlignOffset f PBChunkSize 0x40


You can make the ads go away by registering





Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: wanglata and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group