Raised This Month: $51 Target: $400
 12% 

Jetpack


Post New Thread Reply   
 
Thread Tools Display Modes
waylaidwanderer
SourceMod Donor
Join Date: Aug 2012
Old 11-14-2012 , 20:26   Re: Jetpack
Reply With Quote #171

Quote:
Originally Posted by Skippy View Post
Okay you aren't getting what I'm asking.

I want this for a donator benefit. When I give the donators access to the jetpack give command they can give it to other people too. I don't want everyone to spawn with it because then it will give it to non-donators. I want the donators to type !jetpack and it turns on the jetpack then they type !jetpack again to turn off the jetpack.
Ah, that makes a lot more sense. I had the same problem too. I solved it by changing the default flag for the convar sm_jetpack_adminonly to the "a" or "reservation" flag, and enabling onspawn and adminonly.

I've uploaded the source code and the compiled plugin to this post.
Attached Files
File Type: smx jetpack.smx (34.8 KB, 1145 views)
File Type: sp Get Plugin or Get Source (jetpack.sp - 1413 views - 83.5 KB)

Last edited by waylaidwanderer; 11-16-2012 at 00:17. Reason: Reuploaded plugin to fix the problem where jetpack_give and take was enabled for donators.
waylaidwanderer is offline
Skippy
Senior Member
Join Date: Nov 2011
Old 11-14-2012 , 20:44   Re: Jetpack
Reply With Quote #172

Quote:
Originally Posted by waylaidwanderer View Post
Ah, that makes a lot more sense. I had the same problem too. I solved it by changing the default flag for the convar sm_jetpack_adminonly to the "a" or "reservation" flag, and enabling onspawn and adminonly.

I've uploaded the source code and the compiled plugin to this post.
But with that don't the donators have access to give the jetpack to other people? I don't want that. I want it so they type a /jetpack and it turns on for them then they type /jetpack again and it turns off.
Skippy is offline
waylaidwanderer
SourceMod Donor
Join Date: Aug 2012
Old 11-15-2012 , 14:10   Re: Jetpack
Reply With Quote #173

Quote:
Originally Posted by Skippy View Post
But with that don't the donators have access to give the jetpack to other people? I don't want that. I want it so they type a /jetpack and it turns on for them then they type /jetpack again and it turns off.
No, the flag for jetpack_give and jetpack_take is admin_generic.
waylaidwanderer is offline
Skippy
Senior Member
Join Date: Nov 2011
Old 11-15-2012 , 19:56   Re: Jetpack
Reply With Quote #174

Quote:
Originally Posted by waylaidwanderer View Post
No, the flag for jetpack_give and jetpack_take is admin_generic.
Okay I know that... I'm saying. Is there a way to get a command to type /jetpack and it only turns on for yourself then you type /jetpack again and it turns off. Also for the people who have access to the /jetpack, I don't want them to be able to turn jetpack on for other people.
Skippy is offline
waylaidwanderer
SourceMod Donor
Join Date: Aug 2012
Old 11-15-2012 , 20:09   Re: Jetpack
Reply With Quote #175

Quote:
Originally Posted by Skippy View Post
Okay I know that... I'm saying. Is there a way to get a command to type /jetpack and it only turns on for yourself then you type /jetpack again and it turns off. Also for the people who have access to the /jetpack, I don't want them to be able to turn jetpack on for other people.
And I'm saying you don't need to type /jetpack to have it turn on for yourself, which without further modification would be hard to do. Using the modified plugin I uploaded, if you enable the onspawn and adminonly cvar, anybody with the "reservation" flag (I assume these would be your donators) would automatically get jetpack as soon as they spawn in your server. To use it, they would only need to bind a key to +jetpack. It won't activate otherwise. They won't be able to give jetpack to others either because you need the ADMFLAG_GENERIC for that, which your donators shouldn't have. Does that make things clearer?

Last edited by waylaidwanderer; 11-15-2012 at 20:10.
waylaidwanderer is offline
Skippy
Senior Member
Join Date: Nov 2011
Old 11-15-2012 , 20:48   Re: Jetpack
Reply With Quote #176

Yeah Yeah... I tested it and I got what you mean. But when I joined the server I had f binded to +jetpack so I could use that to jetpack but then space also worked for jetpack and I want to be able to jump. But is it possible for a command to enable the jetpack on for you? Then because when it's off you could use jump. Right now with the plugin you can't jump. When you use space it jetpacks.

Last edited by Skippy; 11-15-2012 at 20:56.
Skippy is offline
waylaidwanderer
SourceMod Donor
Join Date: Aug 2012
Old 11-15-2012 , 22:10   Re: Jetpack
Reply With Quote #177

Quote:
Originally Posted by Skippy View Post
Yeah Yeah... I tested it and I got what you mean. But when I joined the server I had f binded to +jetpack so I could use that to jetpack but then space also worked for jetpack and I want to be able to jump. But is it possible for a command to enable the jetpack on for you? Then because when it's off you could use jump. Right now with the plugin you can't jump. When you use space it jetpacks.
Here we go back to my very first reply to you:

Quote:
Originally Posted by waylaidwanderer View Post
Why would you need to toggle it? Just bind +jetpack to a key you don't press a lot. If the problem is that jetpack is activated by jumping, you can type "sm_settings" to turn that off.
waylaidwanderer is offline
Skippy
Senior Member
Join Date: Nov 2011
Old 11-15-2012 , 22:31   Re: Jetpack
Reply With Quote #178

Quote:
Originally Posted by waylaidwanderer View Post
Here we go back to my very first reply to you:
My bad... Okay thanks. But in the setting menu to enable jump or not. Are those commands or just values? Because if they are commands it would really help me out.
Skippy is offline
waylaidwanderer
SourceMod Donor
Join Date: Aug 2012
Old 11-16-2012 , 00:13   Re: Jetpack
Reply With Quote #179

Quote:
Originally Posted by Skippy View Post
My bad... Okay thanks. But in the setting menu to enable jump or not. Are those commands or just values? Because if they are commands it would really help me out.
I am pretty sure they're just values, so you can only disable it through clientprefs. However, I've modified the plugin again to set the minimum jump time (before jetpack activates) to 99.9 seconds, so that should fix your problem.
You'll want to use this plugin because in the previous one I uploaded, I accidentally enabled jetpack_give and jetpack_take for donators as well, but I just caught the mistake and fixed it.
I'll be editing my previous post to include the updated plugin as well.
Attached Files
File Type: smx jetpack.smx (34.8 KB, 364 views)
File Type: sp Get Plugin or Get Source (jetpack.sp - 532 views - 83.5 KB)
waylaidwanderer is offline
Skippy
Senior Member
Join Date: Nov 2011
Old 11-16-2012 , 00:48   Re: Jetpack
Reply With Quote #180

So there is no way that a command could change these clientpref?
Skippy 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 10:57.


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