Home    LittleBigPlanet 2 - 3 - Vita - Karting    LittleBigPlanet 3    [LBP3] Help!!
#1

Creating a Melee Weapon

Archive: 8 posts


How do you create a working melee weapon?

I want to use a wrench and have it swing when you press L1 and destroy specific objects marked with a tag.
2014-12-03 16:35:00

Author:
Nick930930
Posts: 878


I used to find that I had to dephysicalise things to get them to work, perhaps tweaking the weight would help too - whats not working exactly?2014-12-03 17:58:00

Author:
rialrees
Posts: 1015


You can try slapping a blaster handle on it, but it wouldn't swing with L1 in that case: it would swing with the right thumbstick.

Otherwise, you rig up a follower and some rotators connected to a controllinator and so on to get it to do the specific movement you want.
2014-12-03 22:18:00

Author:
Sehven
Posts: 2188


You can try slapping a blaster handle on it, but it wouldn't swing with L1 in that case: it would swing with the right thumbstick.

Otherwise, you rig up a follower and some rotators connected to a controllinator and so on to get it to do the specific movement you want.


Yeah I tried the blaster handle, and failed to get it to do anything even after adding a controllinator to the microchip that popped up on the handle.

They do a pretty poor job of explaining how these new blaster handle tools work.
2014-12-04 05:00:00

Author:
Nick930930
Posts: 878


Hi Nick930930,
The blaster handle is only of use if you want something to be a power up objecr.
For a standard melee object, create your object (eg. a wrench) and where the player holds it, place a blaster handle.
Now, on the blaster handle chipboard place a controllinator. As it stands, you will only be able to pick up the object and swing it about.
You need to wire up some logic to make it a weapon.
Decide which part of the object will be the point that 'hits' things. exactly here (say, the head of the wrench, place a microchip. On this place 2 tags (one labelled 'hit objects', one labelled 'hit enemy&apos
Next, Wire the L1 of the controller into the 'hit objects; tag, so when you press L1 it will make that tag on the head of the wrench, 'on'.
When you make objects to break, simply have an impact sensor to a destroyer on each separate breakable object.
Dephysicalise the entire 'wrench' and save it as a power-up.

When you collect the wrench powerup, you can swing it about, but holding L1 will make the tag on its head active and will trigger anything with a matching tag sensor. (ie. breaking objects)


Also notice the other tag labelled, 'hit enemy'?. THis has nothing connected to its input, so its always on, so if the wrench collides with baddies with matching tag sensors it will trigger them. To make it look more realistic, wire the left sticks up/down and left/right to a 2 port OR gate, and wire this to the 'hit enemy' tag. Now the wrench wont actually activate the tag until you move the stick.

Hope this helps mate.
2014-12-04 13:41:00

Author:
Sean88
Posts: 662


I made a sword similarly to the above, but I used a rotation sensor to detect whether the sword was moving rather than rely on button input. That way attacking just involved rotating the sword back and forth a bit with the right stick. It worked pretty well.2014-12-04 19:36:00

Author:
peabodyman
Posts: 38


Couldn't you use the animations to swing the weapon, and not have the character just flailing the sword like a mad-sack?2014-12-05 02:46:00

Author:
Devious_Oatmeal
Posts: 1799


Thanks for the tips guys, I like the idea of using an impact sensor + key setup.

I was hoping there was a way to actually have a swing animation forced whenever you press L1, but I guess it's more work than I thought it would be with these new tools. I've been developing my level now for a week and so far there's no REAL need to make the melee weapon, but I can still add it in if I get it working the way I want. Again, thanks for the help
2014-12-05 05:37:00

Author:
Nick930930
Posts: 878


LBPCentral Archive Statistics
Posts: 1077139    Threads: 69970    Members: 9661    Archive-Date: 2019-01-19

Datenschutz
Aus dem Archiv wurden alle persönlichen Daten wie Name, Anschrift, Email etc. - aber auch sämtliche Inhalte wie z.B. persönliche Nachrichten - entfernt.
Die Nutzung dieser Webseite erfolgt ohne Speicherung personenbezogener Daten. Es werden keinerlei Cookies, Logs, 3rd-Party-Plugins etc. verwendet.