Raised This Month: $ Target: $400
 0% 

[HELP] Some questions to ask :D


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 05-14-2009 , 10:38   Re: [HELP] Some questions to ask :D
Reply With Quote #7

1. static acts like a global var but the variable is local to the function. 'new' initializes the var each time where 'static' is created one time and is kept in the memory. In a forward called very often static should be used. Actually it's useful for large array because initializing a big array means write a zero for every byte and in a callback called often the performance could be decreased drastically.

2. It's just a label. g as 'global'. You should read this tuto about the Code Styling.

3. Playing with entity's velocity. There are a lot of examples on this forum.

4. If you know both origin, you could calculated the direction ( origin2 - origin1 ), then you could use some velocity in this direction. ( direction * velocity wanted )

5. Don't fully understand.

6. Using emit_sound(). Actually if you want to place in a know origin, use EngFunc_EmitAmbientSound from fakemeta and passing 0 as entity.

7. There are severals plugins you could take a look, like Tower Defense, there is also Bot API.

8. A weaponbox entity doesn't think. ( only touch ). If you do think a weaponbox entity, it will disappear. ( If I'm remember well )

9. See all the includes ( *.inc files ) in scripting/includes/ folder.

10. A function with the label 'stock' means that this function will not be included in the compilation if not used. You can get a good description for the usage of public/stock.
Arkshine is offline
 



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:28.


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