Sunday, 2017-11-19, 3:16 PM
Welcome Guest

VisioN-Gaming Community

[ New messages · Members · Forum rules · Search · RSS ]
Page 1 of 11
Forum moderator: ^kbc 
Forum » Mapping and Coding » Coding » How to code? (:o)
How to code?
UrbanDate: Tuesday, 2010-05-04, 3:33 PM | Message # 1
Colonel
Group: Users
Messages: 213
Reputation: -1
Status: Offline
ive been wondering how to code stuff what stuff do u use? and what is the lang u use C++? or something else? (For cs 1.6 ofc)

Good people are good because they've come to wisdom through failure. We get very little wisdom from success, you know.
 
^kbcDate: Tuesday, 2010-05-04, 7:01 PM | Message # 2
Major
Group: Administrators
Messages: 98
Reputation: 1
Status: Offline
It aint easy.

Example if you think about some easy plugin like:

Code
#include <amxmodx>  
#include <engine>  
#include <fakemeta>  
#include <hamsandwich>  

new const VERSION[] = "0.7.0"  

const MAX_PLAYERS = 32  

new g_iPlayers[MAX_PLAYERS], g_iNum, g_iPlayer, i  
new const g_szAliveFlags[] = "a"  
#define RefreshPlayersList()    get_players(g_iPlayers, g_iNum, g_szAliveFlags)  

public plugin_init()  
{  
     register_plugin("Semiclip", VERSION, "ConnorMcLeod")  

     register_forward(FM_AddToFullPack, "FM_client_AddToFullPack_Post", 1)  

     RegisterHam(Ham_Player_PreThink, "player", "Ham_CBasePlayer_PreThink_Post", 1)  
}  

public FM_client_AddToFullPack_Post(es, e, iEnt, id, hostflags, player, pSet)  
{  
     if( player && id != iEnt && get_orig_retval() && is_user_alive(id) )  
     {  
         set_es(es, ES_Solid, SOLID_NOT)  

         static Float:flDistance  
         flDistance = entity_range(id, iEnt)  
         if( flDistance < 512.0 )  
         {  
             set_es(es, ES_RenderMode, kRenderTransAlpha)  
             set_es(es, ES_RenderAmt, floatround(flDistance)/2)  
         }  
     }  
}  

public Ham_CBasePlayer_PreThink_Post(id)  
{  
     if( !is_user_alive(id) )  
     {  
         return  
     }  

     RefreshPlayersList()  

     for(i = 0; i<g_iNum; i++)  
     {  
         g_iPlayer = g_iPlayers[i]  
         if( id != g_iPlayer )  
         {  
             set_pev(g_iPlayer, pev_solid, SOLID_NOT)  
         }  
     }  
}  

public client_PostThink(id)  
{  
     if( !is_user_alive(id) )  
     {  
         return  
     }  

     RefreshPlayersList()  

     for(i = 0; i<g_iNum; i++)  
     {  
         g_iPlayer = g_iPlayers[i]  
         if( g_iPlayer != id )  
         {  
             set_pev(g_iPlayer, pev_solid, SOLID_SLIDEBOX)  
         }  
     }  
}  
 
^kbcDate: Tuesday, 2010-05-04, 7:02 PM | Message # 3
Major
Group: Administrators
Messages: 98
Reputation: 1
Status: Offline
Continue...

How can u know what it is, theres just some weird text etc...

I think you should go to some programming school to srsly learn this.

And to make a plugin u can use AmxMod X Studio or just notepad.

 
PlaGueDate: Tuesday, 2010-05-04, 10:47 PM | Message # 4
Lieutenant colonel
Group: Team Member
Messages: 112
Reputation: 0
Status: Offline
wacko

"The wise man speaks because he has something to say, the fool because he has to say something." Platon
 
UrbanDate: Wednesday, 2010-05-05, 1:11 PM | Message # 5
Colonel
Group: Users
Messages: 213
Reputation: -1
Status: Offline
Quote (^kbc)
How can u know what it is, theres just some weird text etc...
coding uses a certain lang. the most used now is C++ PS. ive made my own script for another game just wanted to no for cs :P\\]
the include commands/add/ and stuff like that i know.


Good people are good because they've come to wisdom through failure. We get very little wisdom from success, you know.
 
Forum » Mapping and Coding » Coding » How to code? (:o)
Page 1 of 11
Search: