Author Topic: NPC  (Read 16003 times)

0 Members and 2 Guests are viewing this topic.

Offline Ron

NPC
« on: October 11, 2004, 08:43:31 AM »
Hi, Its me again :P
I just couldnt figure out on my own how to create those npcs.
I tried to learn from other games logics but i didnt understand it..
Is there any tuturial for this ?
Or can anyone please teach me how ?
or just write the code or something ?
Thanks alot.
Ron



Offline Oliver

Re:NPC
« Reply #1 on: October 11, 2004, 11:16:20 AM »
I don't know much so I'm just gonna ask, what's an NPC? ???
You got it!
The New website of Extime is ready!
http://www.hot.ee/extime
Also, there is a message-board at:
http://www.zone.ee/eostuff/forum/index.php

Offline Ron

Re:NPC
« Reply #2 on: October 11, 2004, 11:32:20 AM »
Non Player Character,
how to move an object (in this case man animation) from point to point.. and when it reachs its destination it stop the animation..
I also read almost all the topics of the forum.. non of them helped me..

Offline Eigen

Re:NPC
« Reply #3 on: October 11, 2004, 11:45:19 AM »
I suppose you know how to load a view and set it to a object. Then just use:

start.cycling(object); //will start the animation (walking)
move.obj(object, x, y, step, flag);  

x & y are the positions to walk to. When char. reaches that point the glaf is set. The step is a number that shows how many pixels it will move in one cycle. Usually it's 1.

to check if player reached the x & y, use:

if(isset(flag)){
reset(flag)
stop.cycling(object);
print("You have reached your destination.");
}


-Eigen

Artificial Intelligence Competition

Offline Ron

Re:NPC
« Reply #4 on: October 11, 2004, 05:43:35 PM »
Hey !
Its working!
Thanks alot man !!
I couldnt continue my game without it!!
thanks again.


SMF 2.0.19 | SMF © 2021, Simple Machines
Simple Audio Video Embedder

Page created in 0.107 seconds with 20 queries.