flat assembler
Message board for the users of flat assembler.

Index > Macroinstructions > struct what wrong ? Invalid macro arguments.

Author
Thread Post new topic Reply to topic
Roman



Joined: 21 Apr 2012
Posts: 2079
Roman 01 Aug 2026, 16:36
fasmw 1.73
How fixing this ?
Code:
struct b3Vec3
       x dd 0
       y dd 0
       z dd 0
ends
struct b3Matrix3
       cx b3Vec3
       cy b3Vec3
       cz b3Vec3
ends

struct b3MassData
        ; The shape mass
        mass    dd 0 ;float 

        ; The local center of mass position.
        center  b3Vec3 

        ; The inertia tensor about the shape center of mass.
        inertia b3Matrix3
ends

masssa          b3MassData 10f,0,0,0,1f,0,0,0,1f,0,0,0,1f  ;fasm error: Invalid macro arguments.
    
Post 01 Aug 2026, 16:36
View user's profile Send private message Reply with quote
macomics



Joined: 26 Jan 2021
Posts: 1228
Location: Russia
macomics 01 Aug 2026, 17:33
Code:
struc b3Vec3 x,y,z {
       .x dd x
       .y dd y
       .z dd z
}
struc b3Matrix3 x,y,z {
       .cx b3Vec3 x
       .cy b3Vec3 y
       .cz b3Vec3 z
}
struc b3MassData m,c,x,y,z {
        ; The shape mass
        .mass    dd m ;float 

        ; The local center of mass position.
        .center  b3Vec3 c

        ; The inertia tensor about the shape center of mass.
        .inertia b3Matrix3 <x>,<y>,<z>
}

masssa          b3MassData 10f,<0,0,0>,<1f,0,0>,<0,1f,0>,<0,0,1f>      
Post 01 Aug 2026, 17:33
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 2079
Roman 01 Aug 2026, 18:08
Thanks.

This work too.
Code:
struct b3Vec3  
       x dd 0
       y dd 0
       z dd 0
ends

struct b3Matrix3 
       cx b3Vec3 
       cy b3Vec3 
       cz b3Vec3 
ends

struc b3MassData m,c,x,y,z {
        ; The shape mass
        .mass    dd m ;float 

        ; The local center of mass position.
        .center  b3Vec3 c

        ; The inertia tensor about the shape center of mass.
        .inertia b3Matrix3 <x>,<y>,<z>
}

masssa          b3MassData 10f,<0,0,0>,<1f,0,0>,<0,1f,0>,<0,0,1f> 
    
Post 01 Aug 2026, 18:08
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 2079
Roman 05 Aug 2026, 16:23
Post 05 Aug 2026, 16:23
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
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 vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2026, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.