Game_player_hurt Created 19 years ago2005-08-13 06:19:37 UTC by Elon Yariv Elon Yariv

Created 19 years ago2005-08-13 06:19:37 UTC by Elon Yariv Elon Yariv

Posted 19 years ago2005-08-13 06:19:37 UTC Post #127377
How do you make a game_player_hurt heal the player like what Pyroclasm did in his example map! :
I understood the part about the negative damage but I did it and it doesn't work. :nervous:

I have trigger_relays that target that game_player_hurt and they kill some models. They aren't the problem for they kill the models but the game_player_hurt doesn't work! :cry:

Game_Player_Hurt:

Name: heal1
Damage To Apply: -15

Flags:
Remove On Fire: Not ticked

The trigger_relays target fields are right,the trigger state is on and there aren't any other entities exept the button that targets a train that targets those trigger_relays! :nervous:
Posted 19 years ago2005-08-13 12:18:16 UTC Post #127451
trigger_hurt for one.

and don't target it at all, you ust have to step in it to have the effect
Posted 19 years ago2005-08-13 13:47:52 UTC Post #127464
Yes but it won't work in my case for I'm making a new medkit! :nervous: So please answer my quastion about the game_player_hurt. :roll:
Posted 19 years ago2005-08-13 14:03:24 UTC Post #127470
so why the hell you need hurt if you making a medkit?

weird medkits - you use one and die :|
Posted 19 years ago2005-08-13 14:08:22 UTC Post #127473
SpaG he is using the trigger_hurt to heal by writing -1...

Just build a block, tie to trigger_hurt, type in damage: -15 and compile.

In theory it should work...
Sometimes things go wrong for unknown reasons and making it again in a new map solves bugs ;)
Habboi HabboiSticky White Love Glue
Posted 19 years ago2005-08-13 14:09:39 UTC Post #127474
meh, thought of that but didn't know this was posible :D
Posted 19 years ago2005-08-13 14:31:46 UTC Post #127477
You guys aren't listening! :x I don't won't to make a healing fountain or anything like it I want to make a button that when you push it it increases the health of the player just like what Pyroclasm did!! :furious: I can use trigger_hurt and turn his master on and off quickly but it wont work as good as using game_player_hurt! :confused: So please can someone look at his map and figure out what he did! :tired:
Posted 19 years ago2005-08-14 06:18:20 UTC Post #127549
Why don't you look at it :
Or ask him :
Habboi HabboiSticky White Love Glue
Posted 19 years ago2005-08-14 06:22:49 UTC Post #127552
I sent him a PM and I looked at it and couldn't figure it out! :nervous:
Posted 19 years ago2005-08-14 06:25:03 UTC Post #127553
Ok well copy the room where it happens and try that...
Then delete entities you think are not used and compile that and so on.
Habboi HabboiSticky White Love Glue
Posted 19 years ago2005-08-14 06:55:12 UTC Post #127564
Well I'll do it the with trigger_hurt but I still want to know for it will work better! So please don't close this thread! :(
Posted 19 years ago2005-08-14 07:40:50 UTC Post #127572
Are you sure that you've typed everything in correctly in the Target/Name fields etc?

Doublecheck, just to be safe :)
Posted 19 years ago2005-08-14 07:56:12 UTC Post #127574
The trigger_relays trigger the game_player_hurt for sure and there is no problem with the train that targets them too for the killtarget thingy works! :confused:
Posted 19 years ago2005-08-14 10:39:34 UTC Post #127605
I looked at his map. It has a game_player_hurt with a name and negative damage.

I built a quick map with a trigger_hurt (to give some damage to play with) and a button which triggers a game_player_hurt with negative damage.

It works as advertised.

Your problem must be in your logic, Elon.
Posted 19 years ago2005-08-14 10:42:59 UTC Post #127606
stubborn bastard, why don't you make like everybody sais. You could have done that long time ago. But nooo make it your way...
Posted 19 years ago2005-08-14 11:09:55 UTC Post #127608
BJ if I'll send you the prefab will you fix it for me? : Please tell me what is your Email adress?
Posted 19 years ago2005-08-14 11:15:09 UTC Post #127609
Nevermind about Elon's logic SpaG. Even if he does avoid pure logic. Hes just making his unique :)
38_98 38_98Lord
Posted 19 years ago2005-08-14 11:21:13 UTC Post #127611
PM sent, Elon. Hopefully, you know that by now! ;)
Posted 19 years ago2005-08-14 12:17:39 UTC Post #127624
If I would give up on everything I'm trying to do but I didn't manage then I wont and maybe never know how to do it! Thats why I want to do it with game_player_hurt. :P
Posted 19 years ago2005-08-14 16:00:17 UTC Post #127669
As relayed to Elon, the problem is with the game_player_hurt.

In Elon's medkit, it's triggered by a path_corner. However, a game_player_hurt, to apply health to a player (or hurt them), has to "know" who triggered the hurt event. By using a path_corner's fire-on-pass, it's the func_train and not the player that initiates the event.

It's pretty subtle, but the entity description for game_player_hurt says it's applied to the player triggering the event. Not obvious at all, but logical.

I gave Elon some suggestions, such as naming a master for the game_player_hurt, triggering the game_player_hurt directly and disabling the master when the last path_corner is reached.
You must be logged in to post a response.