Post: How do i stop a code after killing someone / the game is finished?
08-30-2015, 12:54 PM #1
akse
Do a barrel roll!
(adsbygoogle = window.adsbygoogle || []).push({}); So i got a code that im using and i want it to stop working after i kill someone OR the game is finished. e.g. when i play ffa and kill the last person (30 points) and the game ends i want the code to stop working right there. otherwise you will see it in the killcam too and i dont want that.. hope i could explain this good..

Thanks for your help!
(adsbygoogle = window.adsbygoogle || []).push({});
08-30-2015, 02:13 PM #2
-Numb
You talkin to me?
Originally posted by akse View Post
So i got a code that im using and i want it to stop working after i kill someone OR the game is finished. e.g. when i play ffa and kill the last person (30 points) and the game ends i want the code to stop working right there. otherwise you will see it in the killcam too and i dont want that.. hope i could explain this good..

Thanks for your help!


To make it end after the game just simply add level endon("game_ended"); on the top of the function.
To make it end after you kill someone is a little bit harder you need to add this function and thread it at the first spawned thing
    monitorKills()
{
self endon("disconnect");
kills = self.pers["kills"];

for(;Winky Winky
{
if(self.pers["kills"] != kills)
{
kills++;
self notify("killed_enemy_player");
}
wait 0.02;
}
}
Then you can add self endon("killed_enemy_player"); on the top together with the other endon function
08-30-2015, 02:41 PM #3
akse
Do a barrel roll!
Originally posted by Numb View Post
To make it end after the game just simply add level endon("game_ended"); on the top of the function.
To make it end after you kill someone is a little bit harder you need to add this function and thread it at the first spawned thing
    monitorKills()
{
self endon("disconnect");
kills = self.pers["kills"];

for(;Winky Winky
{
if(self.pers["kills"] != kills)
{
kills++;
self notify("killed_enemy_player");
}
wait 0.02;
}
}
Then you can add self endon("killed_enemy_player"); on the top together with the other endon function


thanks! Smile i am new to coding so i dont really know how to put that in my eb.. do i need to put it in my eb function or in the monitorkills function i have in my menu?
08-30-2015, 02:46 PM #4
akse
Do a barrel roll!
Originally posted by Numb View Post
To make it end after the game just simply add level endon("game_ended"); on the top of the function.
To make it end after you kill someone is a little bit harder you need to add this function and thread it at the first spawned thing
    monitorKills()
{
self endon("disconnect");
kills = self.pers["kills"];

for(;Winky Winky
{
if(self.pers["kills"] != kills)
{
kills++;
self notify("killed_enemy_player");
}
wait 0.02;
}
}
Then you can add self endon("killed_enemy_player"); on the top together with the other endon function


also when i put that level endon("game_ended"); on top of my function just like this:
Originally posted by another user
eb()
{
self endon("disconnect");
level endon("game_ended");
self endon("death");
self endon("NewLoc");
for(;Winky Winky
{


it freezes my ps3 for some reason :/ i had self endon("game_ended"); in there and changed it to level but that self one didnt really end the function :/
08-30-2015, 03:14 PM #5
-Numb
You talkin to me?
Originally posted by akse View Post
also when i put that level endon("game_ended"); on top of my function just like this:


it freezes my ps3 for some reason :/ i had self endon("game_ended"); in there and changed it to level but that self one didnt really end the function :/


It needs to be level endon not self endon for the "game_ended" the others is self endon.. And the level endon("game_ended"); can not be the reason ur ps3 freeze.. it must be something else you have added.
08-30-2015, 03:26 PM #6
akse
Do a barrel roll!
Originally posted by Numb View Post
It needs to be level endon not self endon for the "game_ended" the others is self endon.. And the level endon("game_ended"); can not be the reason ur ps3 freeze.. it must be something else you have added.


yea i changed some stuff and it stoped freezing. i also put the monitorkill() thingy in my menu and now it just stops my eb after i kill 1 person (even if i kill them without eb) and after that i cant turn it on anymore
08-30-2015, 03:31 PM #7
-Numb
You talkin to me?
Originally posted by akse View Post
yea i changed some stuff and it stoped freezing. i also put the monitorkill() thingy in my menu and now it just stops my eb after i kill 1 person (even if i kill them without eb) and after that i cant turn it on anymore


Why do you want the eb to end after you kill someone? You should only have the game ended thing there.
08-30-2015, 03:39 PM #8
akse
Do a barrel roll!
Originally posted by Numb View Post
Why do you want the eb to end after you kill someone? You should only have the game ended thing there.


its not the eb. its the bullet trail i dont want it to show 2 bullet trails in the killcam. it also shows 2 in the raw clip (after i shoot and before the game ends) i am trying to fix that but it doesnt seem to work with this method.. need to find something else
08-30-2015, 04:26 PM #9
itsSorrow
In my man cave
Originally posted by akse View Post
its not the eb. its the bullet trail i dont want it to show 2 bullet trails in the killcam. it also shows 2 in the raw clip (after i shoot and before the game ends) i am trying to fix that but it doesnt seem to work with this method.. need to find something else


Thats impossible.. Sadly enough you cannot delete the real bullet trail...
08-30-2015, 04:35 PM #10
-Numb
You talkin to me?
Originally posted by GentleSlugger View Post
Thats possible.. Sadly enough you cannot delete the real bullet trail...


Maybe you could? I found this in a mw2 dvar list cg_drawDamageDirection "1"
Try set it as a dvar with a 0 behind it and it may work, I have not tested it yet..

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo