[skip all navigation]

Swapping weapons as part of a buff?

Creator: Anogio
Time: Sep 9 2010, 5:45 pm

Post #1     Anogio Sep 9 2010, 5:45 pm

[Avatar]
offlinecontact
Rank: Member
I am trying to create an ability that will swap from the primary weapon to a predefined "buff" weapon for the duration of the buff, allowing (via the weapon behaviour/effect) to hit multiple targets in a cone in front of the unit.

I have succeded in creating the weapon, and creating the ability, but getting the ability to swap the weapon is proving troublesome.

Any help would be greatly appreciated.

Additionally: I would like some advice on changing the weapon model on the unit (if possible), when the ability is used.

Top

Post #2     Biophysicist Sep 9 2010, 7:51 pm

[Avatar]
:(){ :|:& };:
onlinecontact
Rank: Regular
To change the weapon, you'd need to give the unit both weapons and disable the "buff weapon", and have a behavior that enables it and disables the default one. Specifics will be posted when I get home and can use GE.

Changing the unit's model will require actually you to have the normal model and a copy with the "buff weapon" instead of the standard one. If you have that, then it's easy: In the actor, define events for when the behavior starts and stops that use "Model Swap" to change the model. (I believe it would be something like "Behavior.WeaponSwap.On" for the start event, and "Behavior.WeaponSwap.Off" for the end event, but I can't check that right now.)

Your trolltag is twinArmageddons and you tend two 2peak wiith a biit of a lii2p.
Top

Post #3     Anogio Sep 9 2010, 8:01 pm

[Avatar]
offlinecontact
Rank: Member
I managed to figure out the weapon swapping mechanism, and it was exactly as you said. Thanks!

Regarding changing models, it is a swap between a marine and the tychus model, with minigun, however I want to retain colour if at all possible.

Top

Post #4     Biophysicist Sep 9 2010, 8:07 pm

[Avatar]
:(){ :|:& };:
onlinecontact
Rank: Regular
Okay. Have an actor event that switches the marine to Tychus when the buff is activated and turns him back when it ends.

@retaining color: What do you mean by that? ;o

Your trolltag is twinArmageddons and you tend two 2peak wiith a biit of a lii2p.
Top

Post #5     Anogio Sep 9 2010, 9:33 pm

[Avatar]
offlinecontact
Rank: Member
By retaining colour, I mean that if the player colour is red, then the new model will also be red. i don't know if this happens by default as i don't know how to swap models in the first place lol

Top

Post #6     Project100 Sep 9 2010, 9:51 pm

[Avatar]
offlinecontact
Rank: Member
I believe tychus' armor stays blue no matter what, he has no player color flags.

Top

Post #7     Jack[RCDF Sep 11 2010, 4:03 am

[Avatar]
Understanding breeds empathy.
offlinecontact
Rank: Regular
You can, of course, change his emit(I think it's emit at least) dds alpha to change the player colour.

Unless no player colour flags means that no matter what the texture is, he still doesn't change colour.

Red classic.


VRAEL = 뱃맨!!!
Top
0 members in this topic (italic members are currently writing a reply): None
+ guest(s)


[03:04 am]
TiKels -- he did
[03:03 am]
Sand Wraith -- LOL
[03:03 am]
Biophysicist -- ...Hearts should remain in people, not in walls. Thanks a lot, imagination. Thanks a lot. That was gross.
[03:03 am]
Sand Wraith -- what kind of shitty university accepts ME into their science department
[03:03 am]
Sand Wraith -- ROFL what the fuck
[03:03 am]
SmE(Raitaki -- Or torturing my brain so hard it starts hallucinating
[03:03 am]
SmE(Raitaki -- Now I wonder how to do that without getting high
Please log in to shout.