God Mode Trigger

broken avatar :(
Created 1086 days ago
by hajhaka
0 Members and 1 Guest are viewing this topic.
2,331 views
broken avatar :(
×
broken avatar :(
Location: se
Date Registered: 1 November 2013
Last active: 959 days ago
Posts
61
Respect
Forum Rank
Rotting Walker
Primary Group
Member
×
hajhaka's Groups
hajhaka's Contact & Social Links
Hello guys and zombie modders!
Today im gonna release my god mode script
What it does is it gives the player ability to buy god mod for 10 minutes
You can edit the time for how long you want the player to have god mode
and edit the price
Thanks to natesmithzombies for fixing the script and helping me


Make sure to add
#using scripts\zm\_zm_score;

at the top of your mapname.gsc

Installation add the script down below to your mapname.gsc

go to
zm_usermap::main();
and add
level thread givegod();

Then open radiant make a trigger_use and simpely use the target name GetGod


function givegod()
{
    trigger = GetEnt("GetGod", "targetname");
    trigger SetHintString("Press ^3&&1^7 For GOD MODE");
    trigger SetCursorHint("HINT_NOICON");
    GodCost = 1000; // Edit the value to change how mutch points its gonna cost

     
    while(1)
    {
        trigger waittill("trigger", player);
   
        if(player.score >= GodCost && !isDefined(player.is_god))
        {
            player zm_score::minus_to_player_score(GodCost);
            player PlayLocalSound( "cha_ching" );
            player EnableInvulnerability();
            player.is_god = true;
            trigger SetHintStringForPlayer( player, "You Are Already in God Mode" );
            player thread god_cooldown(trigger);
            wait(2);
        }
        else if( isDefined(player.is_god) && player.is_god )
        {
             
        }
        else
        {
            trigger SetHintStringForPlayer( player, "You Need "+GodCost+" points to Enable God Mode" );
            trigger PlayLocalSound ( "deny" );
            wait(2);
            trigger SetHintStringForPlayer(player, "Press ^3&&1^7 For GOD MODE");
        }
    }
}
 
function god_cooldown(trigger)
{
    wait(600); // Edit this for the cooldown value 1 = 1 second
    trigger SetHintStringForPlayer(self, "Press ^3&&1^7 For GOD MODE");
    self.is_god = undefined;
    self DisableInvulnerability();
    self iprintlnbold( "God Mode Disabled" );
}

Thats it it would be nice with a credit but up to you lol  :nyan:
Have Fun!
If ur gonna credit me use name "m1cke"
Last Edit: November 27, 2016, 01:18:18 am by hajhaka
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 18 February 2015
Last active: 841 days ago
Posts
63
Respect
Forum Rank
Rotting Walker
Primary Group
Member
My Contact & Social Links
More
×
Blink-420's Groups
Blink-420's Contact & Social LinksBlink-420
Didnt natesmithzombies make this script????

Double Post Merge: November 24, 2016, 05:04:55 pm
Didnt natesmithzombies make this script????

Nevermind I didnt read the whole post lol... my bad
Last Edit: November 24, 2016, 05:04:55 pm by Blink-420
broken avatar :(
×
broken avatar :(
Location: se
Date Registered: 1 November 2013
Last active: 959 days ago
Posts
61
Respect
Forum Rank
Rotting Walker
Primary Group
Member
×
hajhaka's Groups
hajhaka's Contact & Social Links
he did help getting me started but i made the start  :'(
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 18 February 2015
Last active: 841 days ago
Posts
63
Respect
Forum Rank
Rotting Walker
Primary Group
Member
My Contact & Social Links
More
×
Blink-420's Groups
Blink-420's Contact & Social LinksBlink-420
he did help getting me started but i made the start  :'(

Yeah I saw and replied to modme but you have a different username so I thought someone was taking credit..lol good job :)
broken avatar :(
×
broken avatar :(
Location: se
Date Registered: 1 November 2013
Last active: 959 days ago
Posts
61
Respect
Forum Rank
Rotting Walker
Primary Group
Member
×
hajhaka's Groups
hajhaka's Contact & Social Links
Thanks :)
broken avatar :(
×
broken avatar :(
Location: at
Date Registered: 26 November 2016
Last active: 443 days ago
Posts
45
Respect
Forum Rank
Legless Crawler
Primary Group
Member
My Contact & Social Links
More
Signature
12 year old music critic, quadrasexual Minecrafter, Linkin Park fan, Hentai enthusiast, intelligent atheist and vegan.
×
Cxwh's Groups
Cxwh's Contact & Social LinksCxwhModsGodAspire
Why did you call 'giveGod' on level? You can also do
thread giveGod();
broken avatar :(
×
broken avatar :(
Location: se
Date Registered: 1 November 2013
Last active: 959 days ago
Posts
61
Respect
Forum Rank
Rotting Walker
Primary Group
Member
×
hajhaka's Groups
hajhaka's Contact & Social Links
Does that really matter obviously i know you can
thread
insted of
level thread
Its my first script and i used another script as reference so sorry if i used it the wrong way
broken avatar :(
×
broken avatar :(
Location: at
Date Registered: 26 November 2016
Last active: 443 days ago
Posts
45
Respect
Forum Rank
Legless Crawler
Primary Group
Member
My Contact & Social Links
More
×
Cxwh's Groups
Cxwh's Contact & Social LinksCxwhModsGodAspire
Sorry, I didn't want to be rude, I just want to help people get the idea of ents and what they're here for
broken avatar :(
×
broken avatar :(
Location: se
Date Registered: 1 November 2013
Last active: 959 days ago
Posts
61
Respect
Forum Rank
Rotting Walker
Primary Group
Member
×
hajhaka's Groups
hajhaka's Contact & Social Links
Yea i understand that but if u check my speed trigger u can se that i use
thread speedmode()

 

Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Twitch
Loading ...