AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   What is the problem? (https://forums.alliedmods.net/showthread.php?t=62134)

elpouletorange 10-19-2007 09:54

What is the problem?
 
There is a problem when i compile it with webcompiler:

PHP Code:

public frag_heal_user(id)
{
    
set_user_health (idget_user_health(id) + get_user_frags(id) * 10);
    
set_user_frags (id0);
}
 
public 
plugin_init()
{
     
register_plugin("Frag_Heal""1.0""elpouletorange")
     
register_clcmd("say /fragheal""frag_heal_user")



Arkshine 10-19-2007 10:00

Re: What is the problem?
 
set_user_health (id, get_user_health(id) + get_user_frags(id) * 10);

ConnorMcLeod 10-19-2007 10:02

Re: What is the problem?
 
To write in a box, use the small tag

[ s m a l l ]new var //Your code here[ / s m a l l ]

Same without spaces :

Code:
new var //Your code here

[ --<-@ ] Black Rose 10-19-2007 10:04

Re: What is the problem?
 

[pawn]text[/pawn]
[small]text[/small]

[php]text[/php]

[code]text[/code]

@connorr
Have you heard about [noparse][/noparse]?

elpouletorange 10-19-2007 17:55

Re: What is the problem?
 
I got an error again in line 3 ... is it possible my include are not good or something like that ?

[ --<-@ ] Black Rose 10-19-2007 18:05

Re: What is the problem?
 
If that is your full script you need to add
Code:
#include <amxmodx> #include <fun>

M249-M4A1 10-19-2007 18:07

Re: What is the problem?
 
So basically to sum up everyone's stuff, you should have:

PHP Code:

#include <amxmodx>
#include <amxmisc>
#include <fun>

#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "M249-M4A1"

public plugin_init()
{
    
register_plugin("Frag_Heal""1.0""elpouletorange")
    
register_clcmd("say /fragheal""frag_heal_user")
}  

public 
frag_heal_user(id)
{
    
set_user_health (idget_user_health(id) + get_user_frags(id) * 10);
    
set_user_frags (id0);



[ --<-@ ] Black Rose 10-19-2007 18:09

Re: What is the problem?
 
Not really...
1. amxmisc isn't used.
2. defines aren't used.

elpouletorange 10-19-2007 18:24

Re: What is the problem?
 
Your plugin successfully compiled!
Use the link below to download your plugin.
It will be valid for ten minutes.

Welcome to the AMX Mod X 1.76-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team
Header size: 288 bytes
Code size: 320 bytes
Data size: 236 bytes
Stack/heap size: 16384 bytes; estimated max. usage=175 cells (700 bytes)
Total requirements: 17228 bytesDone.

M249-M4A1 10-19-2007 20:18

Re: What is the problem?
 
Quote:

Originally Posted by [ --<-@ ] Black Rose (Post 544029)
Not really...
1. amxmisc isn't used.
2. defines aren't used.

You're right. I pasted the code into AMXX Studio and it had all that default crap on there.


All times are GMT -4. The time now is 01:15.

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