Image angel change with lua

  • #1, by UmonMonday, 08. July 2013, 21:36 11 years ago
    Hat jemand eine Ahnung wie ich die Position einer Grafik auf Grund der Position des Modells verändern kann ?
    So wie auf dem Bild, wenn das Modell an Position 1 ist soll die Statue ebenfalls dahin sehen usw.
    Mit den action areas kann man zwar die Position schon angeben aber die Statue soll auf Position 2 sehen (alos gerade aus) wenn das Modell Richtung Statue läuft oder hinsieht.

    Ich wäre für jeden Hinweis dankbar.

    Does anybody knows if it is possible to change a image with the angel(position) of an model?
    Like at the picture ... if the charakter walks at position 1 then the image (in the circle) change to 1 and so on.
    Ok action areas will work to change, but i want also the image to be at position 2 (look straight) if the model looks at the statue or walks up to it.

    Any hind will be welcome.

    Umon

    Newbie

    80 Posts


  • #2, by afrlmeMonday, 08. July 2013, 21:48 11 years ago
    check out the volume slider & kompass scripts in the German shop.

    they both use percentages to animate the position of something on the scene based on a calculation made between 2 points or rather the kompass one is based on mouse position but still...

    action areas should work fine I should think?
    although you could get a more realistic head turn/follow with percentages & a fair amount of animation frames to make it look smooth.

    Imperator

    7278 Posts

  • #3, by UmonMonday, 08. July 2013, 21:54 11 years ago
    Hey this was a very fast answer thank you smile

    I will take a look at the scripts and also try again the action areas. They worked good but i dont know how to have the staue look straight if i look at it or walk in front of it, if i use areas and allready in there.

    Newbie

    80 Posts

  • #4, by afrlmeMonday, 08. July 2013, 22:36 11 years ago
    ahh you want to make it so the statue only turns/follows when outside of your characters field of vision?

    hmm... you could do something like if character is over/under x percent or is in x action area & isn't facing x direction then statue follow else statue default position...

    very quick & very vague idea...
    but yes I know what you are wanting to do wink

    for Lua: essentially we define 2 points & then we calculate them by characters position & then you combine queries based on percentage & character direction to determine what should happen. Quick note (we wouldn't use actual direction degreesº as they tend to vary a lot based on where you click mouse, instead you would use current character animation (character_walk_east or whatever)

    P.S: if you plan on writing your forum posts in both German & English in the same thread, could you please set the forum post language as English as most German/German speakers have view English posts ticked in their settings but most non-German speakers (apart from a small minority of us) probably don't have show German posts enabled. Much appreciated, Cheers smile

    Imperator

    7278 Posts

  • #5, by UmonMonday, 08. July 2013, 23:01 11 years ago
    Yes this is what i wanted. Somethimes i dont know how to explain the right way red

    But i think i can test it with this and get it to work.

    I will first build the scene almost ready cause there will be doors they open and at the end should look similar like the image. Just wanted to test if it works before i build the whole scene. But it is allready close with only the action areas to make it run. I´ll try it again and show the result if it is finished or i run into problems.

    Again very helpfull tips from you. Thank you very much smile

    Newbie

    80 Posts

  • #6, by afrlmeMonday, 08. July 2013, 23:10 11 years ago
    welcome & no worries smile

    Imperator

    7278 Posts

  • #7, by mac-lionheartWednesday, 10. July 2013, 10:19 11 years ago
    Hey du, nehme an du hast dein Problem mittlerweile lösen können oder?

    Werde sicherheitshalber auch mal einen Deutschen Beitrag dazusteuern....

    Also im Grunde ist dein problem ganz Simple,

    Du möchtest das die Ausstehenden Kreuze (mit statuen? menschen?) der Person zuschauen jenachdem wo sie sich befindet. Was du mit 1-2-3 schon gut makiert hast.

    Was du jetzt nur tun musst, zu diesen 1-2-3 makierten stellen!
    --> Auf der Kulisse ---> ein Objekt erstellen! (es reicht namenlos) _Bereich erstellen nicht vergessen_

    Diesen Objekt stellst du nun ein, das eine Aktion gestartet wird. (Sobald sich die Figur in Objekt Bereich befindet)

    In dem Fall, Animation Abspielen sobald figur in Objekt bereich --> Blick auf die Figur (Gerichtet auf bereich 1)

    Dieses machste für dein bsp exakt 3 mal !!! und wenn du jetzt Spielerisch die 3 bereiche betrittst
    Wird sich automatisch die Animation oder ein Bild
    aktivieren was für dein Bsp wirkt als würden die Kreuze (mit statuen? menschen?) der Person zublicken...

    Du kannst hier jetzt naklar noch mehr als 3 Bereiche erstellen (wenn bilder vorhanden) und es so gestalten... Das kurz aufeinanderfolgende Bereiche Aktivieren und Reallisieren das man förmlich meint, bei jeden Schritt /winkel ändere sich die position der Kreuze und würden einen verfolgen.

    Soviel dazu : )

    Mit freundlichem Gruß

    Mac

    Newbie

    42 Posts

  • #8, by UmonWednesday, 10. July 2013, 12:42 11 years ago
    Danke für den Tipp Mac, so in etwa habe ich es gemacht. Das mit dem folgen durch die Areas klappt wunderbar.
    Ich bin gerade dabei andere Möglichkeiten zu testen.
    Alles mit Hebeln hoch / runter / und zur Seite fahren.
    Was dann schon etwas komplizierter wird ist scheinbar das mit den Partikeln.
    Ich wollte etwas mit, ich sage einfach mal Strahlen machen mit denen man etwas aktiviert wenn die Figuren richtig eingestellt sind. Das mit Bilder zu machen ist scheinbar nicht machbar da die Entfernungen zu groß sind und die Fläche der Animation einfach zu groß werden würde.
    Deswegen versuche ich gerade so etwas wie einen Strahl durch die Partikel hinzubekommen, aber damit habe ich bisher noch gar nichts gemacht.

    Edit:
    Und wegen - Menschen - Statue ... da wir in Deutschland mit Gewaltdarstellungen ja schon immer ein kleines Problem hatten, bin ich noch am überlegen ob ich wie ursprünglich geplant Menschen mit Blut usw. da benutzen soll. Das kann man ja jederzeit ändern.

    Gruß
    Umon

    Newbie

    80 Posts