Please login or register.

Login with username, password and session length
Advanced search  

News:

This forum provides RSS feed. To query recent posts use this url. More...


Author Topic: Making Objects move by Script  (Read 2291 times)

0 Members and 1 Guest are viewing this topic.

mickey1691

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 10
    • View Profile
Making Objects move by Script
« on: May 05, 2010, 09:18:29 AM »

I want to make an object move just by clicking on it... How do I do it using the script?
Logged

robot

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 38
    • View Profile
Re: Making Objects move by Script
« Reply #1 on: May 08, 2010, 06:14:01 PM »

you need to implement a event on "LeftClick" in your object script.

then if you want to move it to other position use entity.X=<new x coordinate> and entity.Y=<new y coordinate> methods.
if your object is an actor use actor.GoTo() or actor.SkipTo()

i suggest looking into documentation
« Last Edit: May 08, 2010, 06:15:52 PM by robot »
Logged
 

Page created in 0.093 seconds with 23 queries.