Conitec 3d gamestudio-source development User Manual

Page of 21
3D Gamestudio Programmer's Manual
                        
© Conitec July 2002
                       14
Command
Bytecode
Arguments
Description
svc_update3 0xc0..0xff Short Entity_Index
(Parameters see below)
Update entity parameters 3 (UDP).
For the 3 entity parameter update messages, bits 0..5 of the
svc_update
bytecode give the
parameter combination to be sent or received, in the order given below. All parameters are sent
through the UDP protocol.
Parameter
Update.Bit
Arguments
Remarks
position
1.0
CPosition Pos[3]
XYZ position
pan
1.1
Angle Pan
scale
1.2
Short Scale[3]
XYZ scale*0.25
type
1.3
String File_Name
Name of the mdl, wmb, pcx, etc. file
frame
1.4
Short Frame_Int
Scale(1) Frame_Frc
Frame number, and tweening factor
flags1
1.5
Byte Flags
ambient
2.0
Scale(100) Ambient
albedo
2.1
Scale(255) Albedo
skin
2.2
Byte Skin
Skin number 
tilt
2.3
Angle Tilt
roll
2.4
Angle Roll
nextframe
2.5
Short Nextframe
Frame number for tweening target
lightrange
3.0
Scale(2000) Lightrange
color
3.1
Scale(255)
Blue,Green,Red
RBG colour packed in 3 bytes
alpha
3.2
Scale(100) Alpha
uv
3.3
Short U,V
UV offset/16 for map entities
flags2
3.4
Byte Flags
For instance, the code sequence
0x43 0x07 0x00 0x80 0x00 0x00 0x00 0x01 0x00 0x80 0x01 0x00 0x80 0x00
 
updates position and pan angle (
0x43
has bits 0 and 1 set) of entity 7 (
0x07 0x00
). The position
uses the packed format and is set at coordinates x=1 (
0x80 0x00 0x00)
, y=2 (
0x00 0x01
0x00
) and z=3 (
0x80 0x01 0x00
), and the pan angle is set at 180 degrees (
0x80 0x00
).