≡
Products
▼
Support
▼
Company
▼
Forum
Ambiera Forum
Discussions, Help and Support.
Create a new account
,
Search
, or Login:
Create reply in
third person And sm third person has this..
Posted by:
(you are not logged in)
Enter the missing letter in: "?nternational"
(you are not logged in)
Text:
[quote][b]VP[/b] wrote: There are a few plugins that allow one node to follow another. Probably the easiest in this case is the "Move AI towards node" plugin. To do this, just add a game behaviour to the camera and the player nodes and set the "move AI towards node" on the player node to move towards the camera node every few milliseconds..... /* <action jsname="action_MoveAIM" description="Move AI in direction of a Node"> <property name="TargetNode" type="scenenode" /> <property name="AOffset" type="float" default="5." /> </action> */ action_MoveAIM = function() {}; action_MoveAIM.prototype.execute = function(currentNode) { var position = ccbGetSceneNodeProperty(currentNode, "Position"); var newpos = ccbGetSceneNodeProperty(this.TargetNode, "Position"); ccbAICommand(currentNode, "moveto", newpos); var moveto = (newpos); var mvec = moveto.substract(position); mvec.normalize(); mvec.x=Math.round(mvec.x*this.AOffset); mvec.y=Math.round(mvec.y*this.AOffset); mvec.z=Math.round(mvec.z*this.AOffset); ccbAICommand(currentNode, "moveto", moveto.add(mvec)); } /* Action created by: Dude */[/quote]
Possible Codes
Feature
Code
Link
[url] www.example.com [/url]
Bold
[b]bold text[/b]
Image
[img]http://www.example.com/image.jpg[/img]
Quote
[quote]quoted text[/quote]
Code
[code]source code[/code]
Emoticons
Copyright© Ambiera e.U. all rights reserved.
Privacy Policy | Terms and Conditions | Imprint | Contact