Raised This Month: $ Target: $400
 0% 

[REQ] Lock doors


Post New Thread Reply   
 
Thread Tools Display Modes
Joce93
Senior Member
Join Date: Feb 2016
Old 07-27-2016 , 13:46   Re: [REQ] Lock doors
Reply With Quote #21

Quote:
Originally Posted by JusTGo View Post
you don't have hamsandwich modules intalled/activated go to modules.ini and remove the ";" before hamsandwich
Even if I remove it, i have the same message...
Joce93 is offline
JusTGo
Veteran Member
Join Date: Mar 2013
Old 07-27-2016 , 17:45   Re: [REQ] Lock doors
Reply With Quote #22

Quote:
Originally Posted by Joce93 View Post
Even if I remove it, i have the same message...
write "amxx modules" in your server consol and give us what it tells you.
__________________
JusTGo is offline
Joce93
Senior Member
Join Date: Feb 2016
Old 07-28-2016 , 11:14   Re: [REQ] Lock doors
Reply With Quote #23

Quote:
Originally Posted by JusTGo View Post
write "amxx modules" in your server consol and give us what it tells you.
It says:


Currently loaded modules:
name version author status
[ 1] Ham Sandwich 1.8.2 AMX Mod X Dev Team running
[ 2] Fun 1.8.2 AMX Mod X Dev Team running
[ 3] Engine 1.8.2 AMX Mod X Dev Team running
[ 4] MySQL 1.8.2 AMX Mod X Dev Team running
[ 5] FakeMeta 1.8.2 AMX Mod X Dev Team running
5 modules, 5 correct


So I believe Ham Sandwich is working, but not the plugin...
Joce93 is offline
klippy
AlliedModders Donor
Join Date: May 2013
Location: Serbia
Old 07-28-2016 , 13:09   Re: [REQ] Lock doors
Reply With Quote #24

Either pev or base fields aren't set, so natives aren't registered. Check your AMXX log (not the error log) somewhere around the mapchange and look for any logs created by Hamsandwich. It's possible that something is wrong with your hamdata.ini or it doesn't even exist.

Also, type
Code:
ham list
into the server console and show us the output.

Last edited by klippy; 07-28-2016 at 13:10.
klippy is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 07-28-2016 , 13:10   Re: [REQ] Lock doors
Reply With Quote #25

If you are using sven coop 5, you need updated hamdata.ini file, that's why it fails. Check this post: https://forums.alliedmods.net/showpo...7&postcount=12
Download the right file and rename it to "hamdata.ini", then copy it inside configs folder.
__________________
HamletEagle is offline
Joce93
Senior Member
Join Date: Feb 2016
Old 07-28-2016 , 21:05   Re: [REQ] Lock doors
Reply With Quote #26

The plugin is running fine. When typing the key for closing door i have the message "Doors were locked by an admin!", but they still keep opening :/
Joce93 is offline
addons_zz
Veteran Member
Join Date: Aug 2015
Location: Dreams, zz
Old 07-28-2016 , 22:45   Re: [REQ] Lock doors
Reply With Quote #27

Quote:
Originally Posted by KliPPy View Post
Either pev or base fields aren't set, so natives aren't registered. Check your AMXX log (not the error log) somewhere around the mapchange and look for any logs created by Hamsandwich. It's possible that something is wrong with your hamdata.ini or it doesn't even exist.

Also, type
Code:
ham list
into the server console and show us the output.
Quote:
Originally Posted by HamletEagle View Post
If you are using sven coop 5, you need updated hamdata.ini file, that's why it fails. Check this post: https://forums.alliedmods.net/showpo...7&postcount=12
Download the right file and rename it to "hamdata.ini", then copy it inside configs folder.
__________________
Plugin: Sublime Text - ITE , Galileo
Multi-Mod: Manager / Plugin / Server

Support me on Patreon, Ko-fi, Liberapay or Open Collective
addons_zz is offline
Joce93
Senior Member
Join Date: Feb 2016
Old 07-29-2016 , 14:36   Re: [REQ] Lock doors
Reply With Quote #28

Thanks it works.

Only problem: I don't want that the other players see the "/closedoors and /opendoors" thing in the chat.

Possible to hide it ?

Last edited by Joce93; 07-29-2016 at 14:36.
Joce93 is offline
addons_zz
Veteran Member
Join Date: Aug 2015
Location: Dreams, zz
Old 07-29-2016 , 18:47   Re: [REQ] Lock doors
Reply With Quote #29

Quote:
Originally Posted by Joce93 View Post
Thanks it works.

Only problem: I don't want that the other players see the "/closedoors and /opendoors" thing in the chat.

Possible to hide it ?
Change it:
Code:
public Open(used, user) 
{ 
    if(unlocked) 
        return HAM_IGNORED 
    else 
    { 
        //This allows to block only player or button attempts to use 
        //so triggers will still open normally 
        //comment this portion of code if you want to completely lock them 
        new classname[32] 
        pev(user,pev_classname, classname, sizeof(classname)) 
        if(!equal("player", classname) && !equal("func_button", classname)) 
            return HAM_IGNORED 
        //end of portion of code 
        return HAM_SUPERCEDE 
    } 
} 

public CloseDoors() 
{ 
    client_print(0, print_chat, "Doors were locked by an admin!") 
    unlocked = 0 
} 

public OpenDoors() 
{ 
    client_print(0, print_chat, "Doors were unlocked by an admin!") 
    unlocked = 1 
}
-->
Code:
public Open(used, user) 
{ 
    if(unlocked) 
        return HAM_IGNORED 
    
    //This allows to block only player or button attempts to use 
    //so triggers will still open normally 
    //comment this portion of code if you want to completely lock them 
    new classname[32] 
    pev(user,pev_classname, classname, sizeof(classname)) 
    if(!equal("player", classname) && !equal("func_button", classname)) 
        return HAM_IGNORED 
    //end of portion of code 
    return HAM_SUPERCEDE 
} 

public CloseDoors() 
{ 
    client_print(0, print_chat, "Doors were locked by an admin!") 
    unlocked = 0
    return PLUGIN_HANDLED_MAIN
} 

public OpenDoors() 
{ 
    client_print(0, print_chat, "Doors were unlocked by an admin!") 
    unlocked = 1
    return PLUGIN_HANDLED_MAIN
}
__________________
Plugin: Sublime Text - ITE , Galileo
Multi-Mod: Manager / Plugin / Server

Support me on Patreon, Ko-fi, Liberapay or Open Collective
addons_zz is offline
Joce93
Senior Member
Join Date: Feb 2016
Old 07-29-2016 , 19:08   Re: [REQ] Lock doors
Reply With Quote #30

Thanks ;)
Joce93 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 00:26.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode