Raised This Month: $ Target: $400
 0% 

Need help with a simple plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 10-22-2007 , 14:15   Re: Need help with a simple plugin
Reply With Quote #1

Quote:
Originally Posted by Claw View Post
Could you maybe show me how to do that, not really the best at scripting ^^
First, we need to define a new variable. So, the line under where you are giving player a value, put this
PHP Code:
new health get_user_health(player); 
Then, in each if block that is setting the health, replace the set_user_health with this
PHP Code:
health += 100;
set_user_health(player,health); 
Then, just change the 100 to how ever much the user is gaining in that block.



Quote:
and would this work fine?
Yeah, that should work fine
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
Claw
Member
Join Date: Sep 2004
Old 10-22-2007 , 14:57   Re: Need help with a simple plugin
Reply With Quote #2

Okey, it seems to be working just great, thanks alot mate ;)

Just one thing, do you think it would be possible to not make players loose their extra health when they go on a block called "Healer" from the Blockmaker 3.51 plugin? If you've ever tested that one.
Claw 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 01:14.


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