#GTA LIKE CAR SCRIPTS

1 messages · Page 1 of 1 (latest)

hushed owl
#

anyone who know where to find car model with Gta NPC car like scripts or just scripts alone? SERIOUS HELP NEEDED

rain fulcrum
#

How do gta cars work

hushed owl
#

@rain fulcrum following lane, NPC throw out, following other car and honking at people

cinder bearBOT
#

studio** You are now Level 1! **studio

rain fulcrum
#

No one here is gonna write a full script for all that plus you need more than just a script to set all that up

#

Or I can help give the idea on how it works

urban pier
#

What you want to do, right

#

Is you make a cat

#

Car

#

And you give it the ability to choose where to go

rain fulcrum
#

You could set up the roads in a grid

#

That would make it really easy

#

Even if it's not a grid as long as the roads arent completely curve it shouldnt be to hard

#

You could set a node on each road and where it connects write a pathfinding alg based on that and it shouldnt be too expensive

#

And then make the car follow it based the road

#

Have the straight part of the road one part and the intersection or turn another

#

And based on that you could make it all stitch together based of the length and width and position of the roads

hushed owl
#

Pathfinding worked for straight line but During turn it messed up

rain fulcrum
#

Did you do it like i said?

#

What do you mean

hushed owl
#

So, it was hefty process, is there any assets with city roads and car?

rain fulcrum
hushed owl
#

Mine is grid too, but it has to turn left or right

rain fulcrum
#

Pic of road

#

And code

hushed owl
#

code has tonnes of line with different with different files

rain fulcrum
#

What are the green and red boxes

hushed owl
#

it's going to be a big map

#

it's to detect NPC, player, car and traffic

#

It becomes invisible during play

rain fulcrum
#

Just let me see the pathfinding

cinder bearBOT
#

studio** You are now Level 14! **studio

hushed owl
#

I know how to code (intermedite) btw, pathfinding is not implemented in this, I tried that before not much help, so i changed to point based

#

car moves based on points

rain fulcrum
hushed owl
#

straight line works with pathfinding, but car never turns 180* perfectly

#

felt so robotic

rain fulcrum
rain fulcrum
hushed owl
#

Pathfinding i replaced unfortunately

#

so no code

rain fulcrum
#

...

hushed owl
#

i just have for waypoints

#

do you know any city assets with car?

rain fulcrum
#

Bro it's not that hard

#

Google exists

#

And there the tool box