Jump to content

Walk Ped?


Recommended Posts

Posted

Created actor:

ped1 =  createPed ( 120, 1959.55, -1714.46, 20)

As his(its) force to go on coordinates;

Here is opcode for scm (from INI):

07CD=6,AS_actor %1d% walk_to %2d% %3d% %4d% stop_with_angle %5d% within_radius %6d%

The Boys help please. :)

Posted

do not use "setPedControlState" for making peds walk!

they will not walk in right direction - it depends some way on local player rotation and keypress i think.. anyway - its buggy

you have to use setPedAnimation

Posted

Really? It has always worked fine for me. In

video peds use getPedCameraRotation and setPedControlState to walk. They follow path nodes with no problems.
Posted

rly..

when i was scriptign peds for 1st time i tried to use setPedControllState - but it failed (as descripted above) - then i changed to animations - then i saw that zombies resource is also using this method - and somewhere on forums somebody was complaing about setPedControlState on peds too..

Posted

This is what I made in Nov 29 2008 with setPedControlState:

It was before MTA 1.0.

If you calculate the walk angle for peds correctly then you are fine.

Posted

there are quite a few problems when using control state, it works, but you have to set the angle and the controlstate clientside to avoid the problem of the zombie going off in its own direction. my Slothbot ai script uses control states. the only reason i use animations with zombies is to get the speed and look of a zombie.

50p's script with the peds that follow you works well because its done onclientredender, so the peds dont have a chance to turn away.

Posted

So you can set destination coordinates serverside and use them clientside. Then every client will control the ped separately, but the results will be the same. Peds work in this way in the video I posted.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...