Raised This Month: $ Target: $400
 0% 

I'm Stumbed can anyone help? code/errors below


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Shinago
Junior Member
Join Date: Mar 2011
Old 01-04-2012 , 12:39   I'm Stumbed can anyone help? code/errors below
Reply With Quote #1

#include <sourcemod>
#include <sdktools>
#include <adminmenu>


//Proplist
new Handle: PropEnable = INVALID_HANDLE;

new string:_sName[512];


public OnPluginStart()
{
/* line 16*/GetEntPropString(entity, Prop_Data, "m_iName", _sName, sizeof(_sName));
/* line 17*/PropEnable = CreateConVar(_sName,1,"Enable Prop");
AutoExecConfig(true,"PropList","configs");
}


Errors are
(16) : error 017: undefined symbol "entity"
(17) : warning 213: tag mismatch
(17) : error 035: argument type mismatch (argument 2)
(17) : warning 204: symbol is assigned a value that is never used: "PropEnable"
Shinago is offline
iNexus
Member
Join Date: May 2011
Old 01-04-2012 , 12:45   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #2

why you put GetEntPropString(entity, Prop_Data, "m_iName", _sName, sizeof(_sName)); in Onpluginstart ?
__________________
Sorry For my English, i'm French developer ;)

Last edited by iNexus; 01-04-2012 at 12:46.
iNexus is offline
Shinago
Junior Member
Join Date: Mar 2011
Old 01-04-2012 , 12:47   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #3

Quote:
Originally Posted by iNexus View Post
why you put GetEntPropString(entity, Prop_Data, "m_iName", _sName, sizeof(_sName)); in Onpluginstart ?
to create a editable cfg file for a mod menu
Shinago is offline
iNexus
Member
Join Date: May 2011
Old 01-04-2012 , 12:49   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #4

In OnPluginStart is not valide
__________________
Sorry For my English, i'm French developer ;)
iNexus is offline
Shinago
Junior Member
Join Date: Mar 2011
Old 01-04-2012 , 12:50   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #5

Quote:
Originally Posted by iNexus View Post
In OnPluginStart is not valide
ok any surgestions?
Shinago is offline
Shinago
Junior Member
Join Date: Mar 2011
Old 01-04-2012 , 12:50   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #6

Quote:
Originally Posted by Shinago View Post
ok any surgestions?
wat about on map start?
Shinago is offline
FoxMulder
Senior Member
Join Date: Jan 2009
Location: Orlando, FL
Old 01-04-2012 , 12:53   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #7

Can you post more of the code?

Also to make things a bit easier on the eyes use CODE tags

Code:
//code goes here
__________________
FoxMulder is offline
napalm00
Veteran Member
Join Date: Jun 2011
Location: Italy, sadly
Old 01-04-2012 , 12:54   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #8

Quote:
Originally Posted by Shinago View Post
wat about on map start?
You should put it in OnMapStart(), but besides that GetEntPropString refers to an entity that isn't declared.
What prop(s) are you looking for?

Quote:
Originally Posted by FoxMulder View Post
Also to make things a bit easier on the eyes use CODE tags

Code:
//code goes here
PHP Code:
Or the PHP ones ^^ 
__________________

Last edited by napalm00; 01-04-2012 at 12:55.
napalm00 is offline
Shinago
Junior Member
Join Date: Mar 2011
Old 01-04-2012 , 12:58   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #9

ok i am trying to make a prop spawn list that i can edit to enable or disable curtain props, (wanting props to shot out from your cross-hair and if they hit a player deal damage as part of a prop war, a one life realism style prop war)
Shinago is offline
Shinago
Junior Member
Join Date: Mar 2011
Old 01-04-2012 , 13:00   Re: I'm Stumbed can anyone help? code/errors below
Reply With Quote #10

Quote:
Originally Posted by Shinago View Post
ok i am trying to make a prop spawn list that i can edit to enable or disable curtain props, (wanting props to shot out from your cross-hair and if they hit a player deal damage as part of a prop war, a one life realism style prop war)
also new to soruce modding but have done c++ database/ user interface before, i can understand others code but when making something new i get confused
Shinago 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 15:48.


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