Maguh1488 Posted January 17, 2015 Share Posted January 17, 2015 hi ... i would like to build a topview vertical scrolled spaceshooter.. in my projekt i have add the game area with space skybox , a spaceship as playermodel this works good so far but now im stuck on the weapon's ... i would like to add a weapon on the left and right side at the ship, how can i make this ?!?!? so i need help to build a double gun for an spaceship. is there anybody who can help me ... ? i can attach the source code if needed... for anyone who like to build game's in this style thx Maggi_Maguh Quote Link to comment Share on other sites More sharing options...
Imchasinyou Posted January 18, 2015 Share Posted January 18, 2015 I dont know if having one gun and settign another as a child and attaching a script to the main one would work. i dont think that would be the solution. Quote Asus sabertooth 990FX, AMD FX 9590 , Windows 7 Home Premium 64 Bit, 4 HDD's Western Digital Caviar Black set in Raid 0, 16 GB Crucial Ballistix Elite, Asus Radeon R9 270 X 4GB, Corsair CM750M, Link to comment Share on other sites More sharing options...
beo6 Posted January 18, 2015 Share Posted January 18, 2015 Do you have a script for a single gun ready and working? If yes it should be relatively easy to change it so you can have two guns. Quote Link to comment Share on other sites More sharing options...
Maguh1488 Posted January 18, 2015 Author Share Posted January 18, 2015 as first ... thank you for your answers. =) yes i have the standard autopistol.lua ... i think i have to change the bullet creation ?! ... two bullets instead of one and these two in a distance of my choise. but i'm no lua crack this are my first steps with lua. i try to change the bullet creation but i only get nil-error.... now i also start experimenting with a turret.lua and bullet.lua script that i have found here in the Download --> Scripts --> Turret and missile scripts. many thank's Quote Link to comment Share on other sites More sharing options...
Maguh1488 Posted January 18, 2015 Author Share Posted January 18, 2015 update ... eureka !! =) maybe i got a solution for my problem ... i have add the turrent script and the bullet, then i have add a flowgraph input function to it (timer disabled.. and only fire if there have an "Fire" input) then i have add an output function to my ShipPlayerController for the fire button event. now i can copy and paste so much weapons as i needed ... only bind the weapons to the player and .. it looks like good ... p.s. Leadwerks rules =) Quote Link to comment Share on other sites More sharing options...
YouGroove Posted January 18, 2015 Share Posted January 18, 2015 Download --> Scripts --> Turret and missile scripts. This version uses PhysicSetposition and you update the position physics each loop in the program. I made another version using SetVelociy, so your bullet velocity is constant and just initiated at start. Both methods have their advantages, like moving the bullet manually with physiSetposition to make any trajectory you want , or SetVelocity when you need a direct streightforward trajectory. http://www.leadwerks.com/werkspace/files/file/512-turret-v2-setvelocity-physics/ Quote Stop toying and make games Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.