Raised This Month: $135 Target: $400
 33% 

[TUT] Compiling AMXX plugins with Sublime Text


Post New Thread Reply   
 
Thread Tools Display Modes
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 08-04-2018 , 09:01   Re: [TUT] Compiling AMXX plugins with Sublime Text
Reply With Quote #121

Ugh, I just noticed that the multi compilers still aren't behaving 100% correct. Here's what happened. I created an include file called "asdddd.inc" in my Dust2+Respawn server and I compiled it with the Dust2+Respawn compiler - it worked. That's okay, but then I tried compiling it with my Deathrun compiler and it worked as well? The Deathrun server doesn't have an "asdddd.inc" file so it shouldn't have compiled it at all. Here's the log:

PHP Code:
E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>for /%i in ('date /T') do set CURRENT_DATE=%

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set CURRENT_DATE=04.08.2018 

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>echo.


E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>echo Compiling crx_playerextras... Current time is14:59:01.25 04.08.2018 
Compiling crx_playerextras
... Current time is14:59:01.25 04.08.2018

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>echo.


E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "folders_list[0]=E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "AMXX_COMPILER_PATH=E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\scripting\amxxpc.exe" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>for /"tokens=1-4 delims=:.," %a in ("14:59:01.26") do (set /"start=(((%a*60)+1%b % 100)*60+1%c % 100)*100+1%d % 100" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>(set /"start=(((14*60)+159 % 100)*60+101 % 100)*100+126 % 100" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "PLUGIN_SOURCE_CODE_FILE_PATH="E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting\crx_playerextras.sma"" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "PLUGIN_SOURCE_CODE_FILE_PATH=E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting\crx_playerextras.sma" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "SOURCE_CODE_FOLDER="E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting"" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "SOURCE_CODE_FOLDER=E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "SOURCE_CODE_INCLUDE_FOLDER=E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting\include" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "PLUGIN_BASE_FILE_NAME=crx_playerextras" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "PLUGIN_BASE_FILE_NAME=crx_playerextras" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "PLUGIN_BINARY_FILE_PATH=E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>IF "crx_playerextras" == "" echo You must to save the plugin before to compile it.   & goto end 

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>FOR /"delims=" %i IN ("E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\scripting\amxxpc.exe") DO (set "AMXX_COMPILER_FOLDER=%~pi" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>(set "AMXX_COMPILER_FOLDER=\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\scripting\" ) 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "
COMPILER_INCLUDE_FOLDER_PATH=\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\scripting\include" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>IF EXIST "E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx" del "E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>"E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\scripting\amxxpc.exe" -i"\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\scripting\include" -i"E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting\include" -o"E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx" "E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting\crx_playerextras.sma" 
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c1997-2013 ITB CompuPhaseAMX Mod X Team

Header size
:           1560 bytes
Code size
:            12016 bytes
Data size
:            24424 bytes
Stack
/heap size:      16384 bytesestimated maxusage=781 cells (3124 bytes)
Total requirements:   54384 bytes
Done
.

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>IF NOT EXIST "E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx" echo There was an compilation errorExiting...   & goto end 

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>echo.


E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>echo 1 File(scopiedto the folder E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx 
1 File(scopiedto the folder E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set "currentIndex=0" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set /"currentIndex+=1" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>if defined folders_list[1] (
setlocal EnableDelayedExpansion  
 
IF NOT EXIST "!folders_list[1]!" (
echo 
ErrorThe destine folder does not exists: !folders_list[1]!  
 goto :
SymLoop 
)  
 IF 
EXIST "!folders_list[1]!\crx_playerextras.amxx" del "!folders_list[1]!\crx_playerextras.amxx"  
 
for /"delims=" %a in ('xcopy /S /Y "E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx"  "!folders_list[1]!"|find /v "crx_playerextras"') do echo %ato the folder !folders_list[1]!  
 goto :
SymLoop 


E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>for /"tokens=1-4 delims=:.," %a in ("14:59:01.39") do (set /"end=(((%a*60)+1%b % 100)*60+1%c % 100)*100+1%d % 100" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>(set /"end=(((14*60)+159 % 100)*60+101 % 100)*100+139 % 100" 

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set /A elapsed=end-start 

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>set /A hh=elapsed/(60*60*100), rest=elapsed%(60*60*100), mm=rest/(60*100), rest%=60*100ss=rest/100cc=rest%100 

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>if 0 LSS 10 set mm=00 

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>if 0 LSS 10 set ss=00 

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>if 13 LSS 10 set cc=013 

E
:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>echo.


E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>echo Took 0:00:00,13 seconds to run this script
Took 0:00:00,13 seconds to run this script.

E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>echo.


E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>if "E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting\crx_playerextras.sma" == "" pause   
[Finished in 0.2s
PS: I also experience huge lag spikes every 1-2 minutes - the entire Sublime editor completely freezes for 2-3 seconds. Is it possible for this plugin to be causing this?
__________________

Last edited by OciXCrom; 08-04-2018 at 10:15.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
addons_zz
Veteran Member
Join Date: Aug 2015
Location: Dreams, zz
Old 08-04-2018 , 16:04   Re: [TUT] Compiling AMXX plugins with Sublime Text
Reply With Quote #122

Quote:
Originally Posted by OciXCrom View Post
Ugh, I just noticed that the multi compilers still aren't behaving 100% correct. Here's what happened. I created an include file called "asdddd.inc" in my Dust2+Respawn server and I compiled it with the Dust2+Respawn compiler - it worked. That's okay, but then I tried compiling it with my Deathrun compiler and it worked as well? The Deathrun server doesn't have an "asdddd.inc" file so it shouldn't have compiled it at all. Here's the log:
When you compile it a `.sma` plugin, it also captures any `\include` directory the `.sma` plugin has close to it.
Then when you are compiling it, it is finding the include because the `.sma` is close its `\include` directory.

Just look into the `amxx_pc.exe` command line:
Code:
E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn\cstrike\addons\amxmodx\scripting>
  "E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\scripting\amxxpc.exe" 
-i"E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\scripting\include" 
-i"E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn          \cstrike\addons\amxmodx\scripting\include" 
-o"E:\OciXCrom\Servers\iPlay.bg Deathrun Unique [#4FUN]\cstrike\addons\amxmodx\plugins\crx_playerextras.amxx" 
  "E:\OciXCrom\Servers\iPlay.bg Dust2+Respawn          \cstrike\addons\amxmodx\scripting\crx_playerextras.sma"
Quote:
Originally Posted by OciXCrom View Post
PS: I also experience huge lag spikes every 1-2 minutes - the entire Sublime editor completely freezes for 2-3 seconds. Is it possible for this plugin to be causing this?
It could be related to this setting:
PHP Code:
    // ( 0.5 ~ 5.0 ~ 60.0 ) Delay before regenerating auto-completion snippets
    
"live_refresh_delay"60.0 
Perhaps there are too much files to parse and it is causing it to lag.
Try disabling this plugin and see if it helps.

To disable a package you can press `Ctrl+Shift+P` and type `Disable Package`, press enter, then select the `AmxxEditor` plugin.
You should be able to build your plugins because this is done with `.bat` file on your user directory.
__________________
Plugin: Sublime Text Studio , Galileo
Multi-Mod: Manager / Plugin / Server

Help the AlliedModders' website stay online!

Last edited by addons_zz; 08-04-2018 at 16:14.
addons_zz is offline
CrazY.
Veteran Member
Join Date: May 2015
Location: Brazil 🇧🇷
Old 08-04-2018 , 16:18   Re: [TUT] Compiling AMXX plugins with Sublime Text
Reply With Quote #123

Autocomplete doesn't catch enum of global_get.

Code:
/* Used with global_get()
 */
enum
{
	glb_start_int = 0, 
	glb_trace_hitgroup, 
	glb_trace_flags, 
	glb_msg_entity, 
	glb_cdAudioTrack, 
	glb_maxClients, 
	glb_maxEntities, 
	glb_end_int, 
	glb_start_float, 
	glb_time, 
	glb_frametime, 
	glb_force_retouch, 
	glb_deathmatch, 
	glb_coop, 
	glb_teamplay, 
	glb_serverflags, 
	glb_found_secrets, 
	glb_trace_allsolid, 
	glb_trace_startsolid, 
	glb_trace_fraction, 
	glb_trace_plane_dist, 
	glb_trace_inopen, 
	glb_trace_inwater, 
	glb_end_float, 
	glb_start_edict, 
	glb_trace_ent, 
	glb_end_edict, 
	glb_start_vector, 
	glb_v_forward, 
	glb_v_up, 
	glb_v_right, 
	glb_trace_endpos, 
	glb_trace_plane_normal, 
	glb_vecLandmarkOffset,
	glb_end_vector,
	glb_start_string, 
	glb_mapname, 
	glb_startspot, 
	glb_end_string, 
	glb_start_pchar, 
	glb_pStringBase, 
	glb_end_pchar
};
As far as I can see, this happens because of the bracket. I've changed to the following and now it's working.

Code:
enum {
	glb_start_int = 0, 
	glb_trace_hitgroup, 
	glb_trace_flags, 
	glb_msg_entity, 
	glb_cdAudioTrack, 
	glb_maxClients, 
	glb_maxEntities, 
	glb_end_int, 
	glb_start_float, 
	glb_time, 
	glb_frametime, 
	glb_force_retouch, 
	glb_deathmatch, 
	glb_coop, 
	glb_teamplay, 
	glb_serverflags, 
	glb_found_secrets, 
	glb_trace_allsolid, 
	glb_trace_startsolid, 
	glb_trace_fraction, 
	glb_trace_plane_dist, 
	glb_trace_inopen, 
	glb_trace_inwater, 
	glb_end_float, 
	glb_start_edict, 
	glb_trace_ent, 
	glb_end_edict, 
	glb_start_vector, 
	glb_v_forward, 
	glb_v_up, 
	glb_v_right, 
	glb_trace_endpos, 
	glb_trace_plane_normal, 
	glb_vecLandmarkOffset,
	glb_end_vector,
	glb_start_string, 
	glb_mapname, 
	glb_startspot, 
	glb_end_string, 
	glb_start_pchar, 
	glb_pStringBase, 
	glb_end_pchar
};
__________________
Working with $$$ paid plugins. Contact below (ONLY FOR NEGOTIATIONS)
  • Skype: crazy.770
  • Steam: crazy770
  • Discord: CrazY.#5317
Check my Aliens vs. Predator: 177.54.156.162:27018

Last edited by CrazY.; 08-04-2018 at 16:22.
CrazY. is offline
addons_zz
Veteran Member
Join Date: Aug 2015
Location: Dreams, zz
Old 08-04-2018 , 18:53   Re: [TUT] Compiling AMXX plugins with Sublime Text
Reply With Quote #124

I think I fixed it. You should receive the update in a few hours.
__________________
Plugin: Sublime Text Studio , Galileo
Multi-Mod: Manager / Plugin / Server

Help the AlliedModders' website stay online!
addons_zz is offline
CrazY.
Veteran Member
Join Date: May 2015
Location: Brazil 🇧🇷
Old 08-09-2018 , 15:18   Re: [TUT] Compiling AMXX plugins with Sublime Text
Reply With Quote #125

Autocomplete doesn't work with stock bool or any other stock (weird, because before, it worked) and I got this following console error.

Code:
/* Tests if given string contains only digits. Also, returns false for zero-length strings. */ stock bool:is_str_num(const sString[]) {     new i = 0;         while (sString[i] && isdigit(sString[i]))         ++i;         return sString[i] == 0 && i != 0; }

Code:
16:17:31:278.320074 5.66e+00 - AmxxEditor.AmxxEditor.load_from_file:854 - (analyzer) Include File Not Found: VexdUM
__________________
Working with $$$ paid plugins. Contact below (ONLY FOR NEGOTIATIONS)
  • Skype: crazy.770
  • Steam: crazy770
  • Discord: CrazY.#5317
Check my Aliens vs. Predator: 177.54.156.162:27018

Last edited by CrazY.; 08-09-2018 at 15:23.
CrazY. is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 08-09-2018 , 15:37   Re: [TUT] Compiling AMXX plugins with Sublime Text
Reply With Quote #126

How can I disable the huge red lines that appear in the file when there's a compilation error? I didn't find such an option in the preferences, you should definitely add that. I'm talking about these:

__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
addons_zz
Veteran Member
Join Date: Aug 2015
Location: Dreams, zz
Old 08-09-2018 , 15:55   Re: [TUT] Compiling AMXX plugins with Sublime Text
Reply With Quote #127

Quote:
Originally Posted by CrazY. View Post
Autocomplete doesn't work with stock bool or any other stock (weird, because before, it worked) and I got this following console error.
Opened a issue for tracking this: #issues/11

Quote:
Originally Posted by OciXCrom View Post
How can I disable the huge red lines that appear in the file when there's a compilation error? I didn't find such an option in the preferences, you should definitely add that. I'm talking about these:
Disable this settings on your user preferences file.
Quote:
// Shows build errors just under the line on which they occur.
"show_errors_inline": true,
__________________
Plugin: Sublime Text Studio , Galileo
Multi-Mod: Manager / Plugin / Server

Help the AlliedModders' website stay online!
addons_zz is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 08-10-2018 , 07:37   Re: [TUT] Compiling AMXX plugins with Sublime Text
Reply With Quote #128

Thanks!
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Reply


Thread Tools
Display Modes

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 00:17.


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