Top

$getasc


mIRC Code
+ 0 likes
Please Register to submit score.
Average Score  4.0
Scores Submitted  3
Date Added  Oct 03, 2007
Last Updated  Oct 03, 2007
Tags  asc  character  format  number 
  Bookmark and Share

Introduction

; $getasc - Roy_
; Credits
; -------
; This snippet may appear similar to Lindrian's $asc_ snippet, part of the snippet actually does what Lindrian's snippet does.
; I give credit to Lindrian for the original idea of the $chr demo.
; -------
; Usage
; -------
; $getasc(string).dem/chrform or nothing at all
; dem returns the string in a (chr) = (chr num) format
; chrform returns the string $chr(chr num) format
; or you can just get the chr values with no property
; -------
; --Roy

; See in-code examples for a better idea on how to use it.

Grab the Code

Comments

  (8)  RSS
Scakk
Comments: 237
 
mIRC Snippet:  $getasc
Posted on Oct 3, 2007 10:31 pm
I tried the examples you gave and got

Code:

* Invalid format: $+ (line 33, WaiterJohn)
-
* Invalid format: $+ (line 25, WaiterJohn)
-
* Invalid format: $+ (line 41, WaiterJohn)
-
Scakk
Comments: 237
 
mIRC Snippet:  $getasc
Posted on Oct 3, 2007 10:33 pm
Change the

Code:

var %t $+


to

Code:

var %t = $+


And it will work.
Roy_
Comments: 12
 
mIRC Snippet:  $getasc
Posted on Oct 3, 2007 10:34 pm
Interesting, they all seemed to work fine for me. I'll check the code again and find the issue.
Roy_
Comments: 12
 
mIRC Snippet:  $getasc
Posted on Oct 3, 2007 10:39 pm
Hmm, alright. But that shouldn't really make a difference. As far as I know at least. Will do Scakk.

--Roy
Scakk
Comments: 237
 
mIRC Snippet:  $getasc
Posted on Oct 3, 2007 10:45 pm
After I added the " = " in all three places it worked.

/me shrugs
RubixCube
Comments: 51
 
mIRC Snippet:  $getasc
Posted on Oct 3, 2007 10:48 pm
Nice, but I don't see a use for this other than retrieving values of characters. That can easily be done manually, but good job nonetheless .
KuTsuM
Comments: 139
 
mIRC Snippet:  $getasc
Posted on Oct 3, 2007 10:54 pm
You should shorten this:
if ($isid) {
if ($1-) {
to
if ($isid) && ($1-) {

Also using the = in the var command I beleive allows you to add more length to variable (I heard this somewhere on here a while back)
mountaindew
Comments: 1,636
 
mIRC Snippet:  $getasc
Posted on Oct 4, 2007 2:38 pm
u could shorten it eve more by doin

Code:

if ($isid && $1) {

Please Register or Login to start posting comments.
Bottom