Jump to content
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. Los Santos Drug Wars
      2. Updates
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Red Dead Online

      1. Blood Money
      2. Frontier Pursuits
      3. Find Lobbies & Outlaws
      4. Help & Support
    3. Crews

    1. Grand Theft Auto Series

      1. Bugs*
      2. St. Andrews Cathedral
    2. GTA VI

    3. GTA V

      1. Guides & Strategies
      2. Help & Support
    4. GTA IV

      1. The Lost and Damned
      2. The Ballad of Gay Tony
      3. Guides & Strategies
      4. Help & Support
    5. GTA San Andreas

      1. Classic GTA SA
      2. Guides & Strategies
      3. Help & Support
    6. GTA Vice City

      1. Classic GTA VC
      2. Guides & Strategies
      3. Help & Support
    7. GTA III

      1. Classic GTA III
      2. Guides & Strategies
      3. Help & Support
    8. Portable Games

      1. GTA Chinatown Wars
      2. GTA Vice City Stories
      3. GTA Liberty City Stories
    9. Top-Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    1. Red Dead Redemption 2

      1. PC
      2. Help & Support
    2. Red Dead Redemption

    1. GTA Mods

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Red Dead Mods

      1. Documentation
    3. Mod Showroom

      1. Scripts & Plugins
      2. Maps
      3. Total Conversions
      4. Vehicles
      5. Textures
      6. Characters
      7. Tools
      8. Other
      9. Workshop
    4. Featured Mods

      1. Design Your Own Mission
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Rockstar Games

    2. Rockstar Collectors

    1. Off-Topic

      1. General Chat
      2. Gaming
      3. Technology
      4. Movies & TV
      5. Music
      6. Sports
      7. Vehicles
    2. Expression

      1. Graphics / Visual Arts
      2. GFX Requests & Tutorials
      3. Writers' Discussion
      4. Debates & Discussion
    1. Announcements

    2. Support

    3. Suggestions

Happy Holidays from the GTANet team!

store player coords help


ShadowCoderKing
 Share

Recommended Posts

ShadowCoderKing

hello

can someone please tell me how to get a ped to walk or run to certain points in cleo

Link to comment
Share on other sites

Dutchy3010

First you have to get a handle (variable) of a pedestrian.

 

0AB5: store_actor $PLAYER_ACTOR closest_vehicle_to [email protected] closest_ped_to [email protected]

 

or

 

089E: get_actor_in_sphere [email protected] [email protected] [email protected] radius 5.0 handle_as [email protected] // versionB

 

(For this last opcode you first need to check the player coords with 00A0)

 

Then for the running/walking:

 

05F5: AS_actor [email protected] goto_point 2516.686 -1675.861 13.1227 mode 4 5500 ms // versionB 

 

The handle has to be the handle you got from the first opcodes. The point is the point you want. The mode is walking/running, I believe you need 4 and 6. Just test this. smile.gif

 

When you finished with a ped, just use:

 

01C2: remove_references_to_actor [email protected] // Like turning an actor into a random pedestrian 

 

Then it will become a random ped again.

Link to comment
Share on other sites

ShadowCoderKing

once i get the actor to go to the first point he stops there and wont go to another one please help

 

i am using

 05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB 
Link to comment
Share on other sites

 

once i get the actor to go to the first point he stops there and wont go to another one please help

 

i am using

 05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB

If I put bread and cheese on to the table I have also no sandwich

I must put the cheese on to the bread and only if I eat it then I have good effect

 

same with your code

if you write here 05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms

nothing happens

 

sorry for irony but without context nobody can help

Link to comment
Share on other sites

ShadowCoderKing

here is my script

 

{$CLEO .cs}:Actor_103A4: name_thread 'Actor':Actor_20001: wait  0 ms00D6: if  00256:   player $PLAYER_CHAR defined004D: jump_if_false @Actor_200D6: if  000FF:   actor $PLAYER_ACTOR  1 (in-sphere)near_point_on_foot 2223.5566 -1642.454 15.4587 radius  2.0  2.0  2.0 004D: jump_if_false @Actor_20247: request_model 120:Load_models_check0001: wait  0 ms00D6: if  and0248:   model 120 available 004D: jump_if_false @Load_models_check009A: [email protected] = create_actor  24 120 at  2236.9417 -1610.0242 16.45610173: set_actor [email protected] z_angle_to 156.9815 02E2: set_actor [email protected] weapon_accuracy_to  1000446: set_actor [email protected] immune_to_headshots 00223: set_actor [email protected] health_to  4000//05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR:walkpoint05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB 05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB  :Loop_10001: wait  0 ms00D6: if  08118:   NOT   actor [email protected] dead004D: jump_if_false @Cleanup_100D6: if  00104:   actor $PLAYER_ACTOR near_actor [email protected] radius  80.0  80.0  10.0 sphere  0004D: jump_if_false @Cleanup_10002: jump @Loop_1:Cleanup_101C2: remove_references_to_actor [email protected] // Like turning an actor into a random pedestrian0002: jump @Actor_2

 

Link to comment
Share on other sites

the actors walks on paths and must first go to a path before they go to a destination, same for cars

(ped paths and car paths are stored in the nodesX.dat in gta3.img)

 

the opcode to define scm paths let the actor go everywhere

 

:walkpoint//05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB//05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB  05D6: clear_scmpath05D7: add_point_to_scmpath 2224.1702 -1640.783 15.44605D8: AS_assign_scmpath to_actor [email protected] flags 6 1

 

 

forthermore can be use AS-packs to define more scm_paths

 

0615: define_AS_pack_begin [email protected] 05D6: clear_scmpath 05D7: add_point_to_scmpath 2224.1702 -1640.783 15.44605D7: add_point_to_scmpath 2227.342 -1628.7476 15.5823 05D7: add_point_to_scmpath 2232.9329 -1625.8437 15.493105D8: AS_assign_scmpath to_actor -1 flags 6 3 0616: define_AS_pack_end [email protected] 0618: assign_actor [email protected] to_AS_pack [email protected]

 

 

AS_pack opcodes are used like container or brackets

(clear task

scmpath1 x y z

scmpath2 x y z

scmpath3 x y z)

actor [email protected] do ()

 

last parameter of

05D8: AS_assign_scmpath to_actor -1 flags 6 3

gives the amount of scmpaths

 

opcode 0643: let the AS_pack repeat allways

0643: set_AS_pack [email protected] loop 1

 

opcode 061B: disable the AS_pack but for one time will it work

061B: remove_references_to_AS_pack [email protected]

can be set directly after the AS_pack

Edited by ZAZ
Link to comment
Share on other sites

here is my script

 

:walkpoint05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB 05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB  

 

They're both at the same coordinate... mercie_blink.gif

Link to comment
Share on other sites

ShadowCoderKing
here is my script

 

:walkpoint05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB 05F5: AS_actor [email protected] goto_point 2223.5566 -1642.454 15.4587 mode 6 7000 ms // versionB  

 

They're both at the same coordinate... mercie_blink.gif

yes i know but is just an example

Link to comment
Share on other sites

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
 Share

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.