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

How do I make a hitbox?

Archive: 11 posts


I'm working on making a sackbot for an RPG, but the biggest problem is how do I make a hitbox? How do I also make it so if some other sackbot hits the player, then they move back as if hit or vice-versa? Thanks for your help.2011-07-15 20:03:00

Author:
PetStars
Posts: 91


For a hit-box, you'd need to make some holo with an impact sensor on it. Have the impact sensor require a tag, and turn on "include touching." Make the holo follow the player sackbot. Anything that can deal damage has the tag on it that activates the holo's impact sensor, which in turn triggers your damage logic.

The hit back thing is probably gonna require a lot of fiddling and tweaking to get just right, but the easiest way I could think to do it would be that when the sackbot recognizes that it's been hit, turn off the controllinator that's controlling it and turn on a follower that's set to flee from the source of the damage for a second or so, then turn it off and the controllinator back on.
2011-07-15 20:17:00

Author:
Speed Racer
Posts: 156


For a hit-box, you'd need to make some holo with an impact sensor on it. Have the impact sensor require a tag, and turn on "include touching." Make the holo follow the player sackbot. Anything that can deal damage has the tag on it that activates the holo's impact sensor, which in turn triggers your damage logic.

The hit back thing is probably gonna require a lot of fiddling and tweaking to get just right, but the easiest way I could think to do it would be that when the sackbot recognizes that it's been hit, turn off the controllinator that's controlling it and turn on a follower that's set to flee from the source of the damage for a second or so, then turn it off and the controllinator back on.
This is exactly what I've done / would do. Should work (going to implement the knockback probably ).

Also, the include touching just means that it will 'impact' the layers it is adjacent to. With holo, it impacts other holo on the same layer even if these are turned off. May be a recent change, or maybe I'm mistaken, since I do seem to remember it being the opposite before (you'd require 'touching' to be on for holo to impact anything).
2011-07-15 20:34:00

Author:
SSTAGG1
Posts: 1136


oh, really? Yeah I remembered holo not cooperating unless you had "include touching" turned on. Guess that's been changed!2011-07-15 20:43:00

Author:
Speed Racer
Posts: 156


How would I turn off the contronlinator and set a follower on flee? and thank you by the way!2011-07-15 21:08:00

Author:
PetStars
Posts: 91


Easiest way would be to put the controlinator inside of a microchip, and turn off the microchip.

Followers have a toggle that's called "Flee rather than follow." Just turn that on.
2011-07-15 21:09:00

Author:
Speed Racer
Posts: 156


Can you explain with more detail, because I cant seem to get the sackbot to "get hit" (flee) when hit.2011-07-15 21:26:00

Author:
PetStars
Posts: 91


just to be clear I'm talking about the follower mover, not the follow waypoint setting on a sackbot brain.

Set the follower to "follow tag instead," and pick whatever tag the damage-dealing thing has on it, probably the same tag that triggers your impact sensor. Then, set it to "flee rather than follow." Have the impact sensor on the hollow trigger a timer set to "start the countdown" that lasts as long as you want the sackbot to be knocked back. The timer is hooked into the follower.
2011-07-15 21:40:00

Author:
Speed Racer
Posts: 156


Do you also know how to make a sackbot "attack" from both sides depending on what side I am facing?

Also, the sackbot only flees sometimes...
2011-07-15 21:58:00

Author:
PetStars
Posts: 91


Also, the sackbot only flees sometimes...

Yeah, that's why I said you'd have to fiddle with it. Just mess with it it'll work out eventually.
2011-07-16 00:46:00

Author:
Speed Racer
Posts: 156


Put an impact sensor on. Put R2+side on right stick, and also the other way with L2. Put the R2 and side on stick on an and sensor for both, put is on a controlinator and connect the or sensors to an or sensor (set to closest player). Then make an and sensor, attach the previous or sensor and the impact sensor. The and is your output for the whole thing. Put the whole thing on a microchip, and sticker it to make me pretty!2011-07-16 02:07:00

Author:
lark98-2
Posts: 116


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.