Quantcast

Jump to content

» «
Photo

Change attached object rotation

1 reply to this topic
HeresOtis
  • HeresOtis

    The SCM Undergrad

  • Feroci Racing
  • Joined: 29 Apr 2011
  • United-States

#1

Posted 09 April 2013 - 04:54 PM

How can I change an object's angle/rotation after it's been attached to an actor's bone?
CODE
while true
   wait 0
   if
       0AB0:  key_pressed 52
   then
       while not Model.Available(#COLT45)
           Model.Load(#COLT45)
           wait 0
       end
       0107: 17@ = create_object #COLT45 at 0.8 0.8 100.8
       070A: AS_actor $PLAYER_ACTOR attach_to_object 17@ offset 0.0 0.0 0.0 on_bone 8 16 perform_animation "NULL" IFP_file "NULL" time 1
       0177: set_object 17@ Z_angle_to 270.0       
       Object.CollisionDetection(17@) = False
       wait 500
   end
end

ZAZ
  • ZAZ

    Kernlochbohrer

  • Members
  • Joined: 10 Jan 2005
  • European-Union

#2

Posted 09 April 2013 - 08:08 PM Edited by ZAZ, 09 April 2013 - 08:11 PM.

Only the param which have now 16 in your 070A code have an effect to the rotation.
I tried a lot in the past and could only get 2 different rotationpostions
can't remember exactly for the value, it was 1 , 4 or 8 instead 16




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users