Skocz do zawartości

Featured Replies

Napisano

Mam box'a :-) Chce by mozna go bylo przesuwac w viewport'cie maksymalnie np. o 10 jednostek w kazdej osi.

 

when transform $box01 changes do (

if $box01.pos.X>10 then $box01.pos.X=10

)

 

Taka postac skryptu dziala, ale tylko wzgledem osi X (oczywscie ogranicza ruch tylko w prawo). Gdy dopisuje:

 

if $box01.pos.Y>10 then $box01.pos.Y=10

 

i alternatywnie dla Z to nie dziala. O co chodzi?

  • Odpowiedzi 4
  • Wyświetleń 1,8k
  • Created
  • Ostatniej odpowiedzi

Top Posters In This Topic

Napisano

Napisałeś tak:

if $box01.pos.Y>10 then $box01.pos.X=Y

 

Nie powinno być:

if $box01.posY>10 then $box.posY=10

?

Napisano
  • Autor

posY -taka skladnia nie wystepuje

Napisano

Faktycznie dziwne. Rzucilem to pytanie na forum cgtalku, zobaczymy co tam wymysla.

Napisano

Dostalem taka odpowiedz:

This might not be exactly an error, but it is a limitation. I *assume* it is caused by the way interactive manipulations are applied to the controller hierarchy and the notifications sent to the system and MAXScript.

 

A workaround I found is to assign a Bezier Position controller to the Position track - when there are no sub-controllers, all 3 axes are being processed correctly.

 

Another workaround is to use the handerAt:#redrawViews option. The object does not stop when the Y reaches the limit, but as soon as the view is redrawn, the object jumps back to the limit.

 

And of course the Limit controller in Max 8 would be the clean solution to the problem.

Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto

Powiadomienie o plikach cookie

Wykorzystujemy cookies. Przeczytaj więcej Polityka prywatności Umieściliśmy na Twoim urządzeniu pliki cookie, aby pomóc Ci usprawnić przeglądanie strony. Możesz dostosować ustawienia plików cookie, w przeciwnym wypadku zakładamy, że wyrażasz na to zgodę.

Account

Navigation

Szukaj

Szukaj

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.