Hey,
Lets make this the first script to show off, yea! Even though the dll was not made by me..hm.
Alias Code -
alias vcmp.cpu {
var %ram = $round($calc($dll(ProcInfo.dll,GetRam,memory) / 1023),0), %ramfree = $round($calc($dll(ProcInfo.dll,GetRam,memoryavail) / 1023),0), %ram.p $dll(ProcInfo.dll,GetRam,p100use), %ram.pfree $dll(ProcInfo.dll,GetRam,p100avail)
var %ut.mir = $duration($calc($uptime(mirc)/1000),2), %ut.ser = $duration($calc($uptime(server)/1000),2), %ut.sys = $duration($calc($uptime(system)/1000),2)
var %cpu.proc = $dll(ProcInfo.dll,GetCpu,.), %cpu.mnu = $dll(ProcInfo.dll,GetCpuVendor,.) %cpu.speed = $dll(ProcInfo.dll,GetCpuSpeed,mhz), %cpu.use = $dll(ProcInfo.dll,GetCpuUsage,.)
vcmp.say Ram - Totall: %ram $+ MB $+ , Free: %ramfree $+ MB $+ , Free: %ram.pfree $+ %
vcmp.say Uptime - mIRC: %ut.mir $+ , System: %ut.sys
vcmp.say CPU - Type: $gettok(%cpu.mnu,1,32) $+ , Speed: $round($calc($gettok(%cpu.mnu,3,32) / 1000),2) $+ GHz $+ , Usage: %ram.p $+ %
}
Command Code -
elseif (!comp* iswm $2) || (!pmcomp* iswm $2) {
if (%timer.status) vcmp.say Error - This Command can only be used Once every 2 Seconds
else {
vcmp.cpu
set %timer.status 1
!timer 1 2 unset %timer.status
}
}
Uses the Procinfo.dll, you can download from mircscripts.org i believe it is
Cya,
Tommis
Tbh it's useless :P But anyway you and Vrocker did a really good job.
Thanks :)
good, but PAWN is easier :/ anyway, good job ;)
PAWN easy?
I like the mIRC language
Depends on the complexity of the mIRC script. :P
Hey,
Its not really useless, you can use this script for many others things.. =p (Atleast the dll and the alias)
Cya,
Tommis
Quote from: Vecis on June 12, 2007, 03:42:20 PM
good, but PAWN is easier :/ anyway, good job ;)
I don't think PAWNO is easier. I think you just don't know mIRC scripting.
Yeah, Pawn is more complicated language than mIRC Scripting.
In my opinion Pawn is harder to learn and to understand.
It's different for everybody. I myself find Pawn easy and mIRC hard. I find C# easy and C++ hard. It's just how your brain wants to work with different languages.
Where can I find a PAWN tutorial..?
There are no PAWN tutorials for VC-MP yet.
http://wiki.sa-mp.com/wiki/PAWN_tutorial_1
http://wiki.sa-mp.com/wiki/PAWN_tutorial_2
http://wiki.amxmodx.org/index.php/Pawn_Tutorial
Quote from: adamale on July 04, 2007, 02:33:08 AM
There are no PAWN tutorials for VC-MP yet.
http://wiki.sa-mp.com/wiki/PAWN_tutorial_1
http://wiki.sa-mp.com/wiki/PAWN_tutorial_2
http://wiki.amxmodx.org/index.php/Pawn_Tutorial
Thanks adamale :)
hey i play sa-mp and i script using pawno and once you learn a few things other things are easy but im going to give vc-mp and mIRC scripting a try.
WeeDarr
Thanks i need this actually i am modifying GUS and WSV..... :-*
Can someone convert it to WSV?
Nice work rulk..
Regards
Amenine
Quote from: rulk on November 26, 2008, 11:43:18 AM
alias vcmp.cpu {
var %ram = $round($calc($dll(ProcInfo.dll,GetRam,memory) / 1023),0), %ramfree = $round($calc($dll(ProcInfo.dll,GetRam,memoryavail) / 1023),0), %ram.p $dll(ProcInfo.dll,GetRam,p100use), %ram.pfree $dll(ProcInfo.dll,GetRam,p100avail)
var %ut.mir = $duration($calc($uptime(mirc)/1000),2), %ut.ser = $duration($calc($uptime(server)/1000),2), %ut.sys = $duration($calc($uptime(system)/1000),2)
var %cpu.proc = $dll(ProcInfo.dll,GetCpu,.), %cpu.mnu = $dll(ProcInfo.dll,GetCpuVendor,.) %cpu.speed = $dll(ProcInfo.dll,GetCpuSpeed,mhz), %cpu.use = $dll(ProcInfo.dll,GetCpuUsage,.)
vcmp.say $1 Ram - Totall: %ram $+ MB $+ , Free: %ramfree $+ MB $+ , Free: %ram.pfree $+ %
vcmp.say $1 Uptime - mIRC: %ut.mir $+ , System: %ut.sys
vcmp.say $1 CPU - Type: $gettok(%cpu.mnu,1,32) $+ , Speed: $round($calc($gettok(%cpu.mnu,3,32) / 1000),2) $+ GHz $+ , Usage: %ram.p $+ %
}
elseif (!comp* iswm $3) {
if (%timer.status) vcmp.say $1 Error - This Command can only be used Once every 2 Seconds
else {
vcmp.cpu $1
set %timer.status 1
!timer 1 2 unset %timer.status
}
}
I think it must be somthing like:
alias vcmp.cpu {
var %ram = $round($calc($dll(ProcInfo.dll,GetRam,memory) / 1023),0), %ramfree = $round($calc($dll(ProcInfo.dll,GetRam,memoryavail) / 1023),0), %ram.p $dll(ProcInfo.dll,GetRam,p100use), %ram.pfree $dll(ProcInfo.dll,GetRam,p100avail)
var %ut.mir = $duration($calc($uptime(mirc)/1000),2), %ut.ser = $duration($calc($uptime(server)/1000),2), %ut.sys = $duration($calc($uptime(system)/1000),2)
var %cpu.proc = $dll(ProcInfo.dll,GetCpu,.), %cpu.mnu = $dll(ProcInfo.dll,GetCpuVendor,.) %cpu.speed = $dll(ProcInfo.dll,GetCpuSpeed,mhz), %cpu.use = $dll(ProcInfo.dll,GetCpuUsage,.)
vcmp.say Ram - Totall: %ram $+ MB $+ , Free: %ramfree $+ MB $+ , Free: %ram.pfree $+ %
vcmp.say Uptime - mIRC: %ut.mir $+ , System: %ut.sys
vcmp.say CPU - Type: $gettok(%cpu.mnu,1,32) $+ , Speed: $round($calc($gettok(%cpu.mnu,3,32) / 1000),2) $+ GHz $+ , Usage: %ram.p $+ %
}
and Command:
elseif (comp* iswm $3) {
if (%timer.status) vcmp.say Error - This Command can only be used Once every 2 Seconds
else {
vcmp.cpu
set %timer.status 1
!timer 1 2 unset %timer.status
}
}