Is it possible? I’m making a combine apc with the combine gun, but since it’s only prop_vehicle_jeep/prop_vehicle_airboat. Airboat doesn’t even work. I’ve already scripted up a vehicle (http://www.garrysmod.org/downloads/?a=view&id=90782) But I can’t get it to use the apc gun or shoot rockets. If you want a good example go check out Human Error on Moddb. I tried using prop_vehicle_apc but since the It isn’t apparently scripted like the rest of the vehices, Because after you get in, you can’t get back out, shoot, or drive around. :arghfist::saddowns:
Isn’t the APC an NPC?
You’ll probably have to script the shooting too. That means using lua to control the turret and the projectiles.
It is, but in some places you can walk up to them, and if you try to enter, it gives you the default “No.” Combine sound.
Ughhhhhhh but this is the newbies thread.
Posting in the newbie forum doesn’t change the requirements of your project. If you want a feature, script it. Guns aren’t built into Lua-based entities
edit: didn’t notice this was a prop_vehicle_jeep . The jeep & airboat do have guns,but doing it using the same method might be more complicated than just doing it in LUA
I’ve rigged a tank model to have rotating turrets before, so I know that part can be done within the model easily. All you need to do is code the firing
The only scripted vehicle I’ve seen implemented are the hoverboards.
Well he doesn’t really need to code the movement, from what I understand all he needs is the bullets. You don’t need to script a vehicle for that.
I can script the bullets, I already have a vehicle script, not the lua script, ready. I don’t know about the rockets or the combine bullets though…:saddowns:
there is a lua function for bullets i think and you can find it in the data structure page on the wiki i think
Combine bullets just use a different sound and tracer, for the homing rocket I think the swep bases project has a working one you can use.
Well thanks for all the advice. It’ll take a while though…I know how to script bullets but not really a mouse-aimed turret in a vehicle. How do you call the XYZ of the mouse position, or is that even the correct value to call?