8,484
edits
Paradox-01 (talk | contribs)  (+ OnValueChange event)  | 
				Paradox-01 (talk | contribs)  m (improved example of obj/camera movement tracking)  | 
				||
| Line 204: | Line 204: | ||
  if instr(cstr(in_ctxt.GetAttribute("Object")), ".kine.global") > 0 then  |   if instr(cstr(in_ctxt.GetAttribute("Object")), ".kine.global") > 0 then  | ||
   if firstValue = false then  | |||
 ' add more exit conditions here  | |||
 ' e.g. selection mode  | |||
 ' selection count  | |||
 ' if obj is not an Oni obj or camera  | |||
     if selection.count > 0 and not replace(cstr(in_ctxt.GetAttribute("Object")),".kine.global", "") = "Camera_Interest" then  | |||
        logmessage "Object at: " & selection(0).posx.value & " " & selection(0).posy.value & " " & selection(0).posz.value  | |||
     end if  | |||
     if replace(cstr(in_ctxt.GetAttribute("Object")),".kine.global", "") = "Camera_Interest" then  | |||
        logmessage GetValue("Camera_Interest.kine.global.posx") & " " & _  | |||
          GetValue("Camera_Interest.kine.global.posy") & " " & _  | |||
          GetValue("Camera_Interest.kine.global.posz")  | |||
   	logmessage "Obj is cam"  | |||
     end if  | |||
     firstValue = true  | |||
    else  |     else  | ||
     firstValue = false  | |||
    end if  |     end if  | ||
  end if  |   end if  | ||
edits