egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Change the Encoding so it shows "Å" [SOLVED]
Goto page 1, 2  Next
 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help
View previous topic :: View next topic  
Author Message
Fire-Fox
Master


Joined: 23 Sep 2006
Posts: 270
Location: /dev/null

PostPosted: Mon Sep 17, 2007 7:11 pm    Post subject: Change the Encoding so it shows "Å" [SOLVED] Reply with quote

how can i change the Encoding so it shows "Å"
_________________
GreatZ
Fire-Fox | Denmark

Scripts: Relay | Store Text | TvMaze


Last edited by Fire-Fox on Thu Sep 20, 2007 10:34 am; edited 2 times in total
Back to top
View user's profile Send private message MSN Messenger
Alchera
Revered One


Joined: 11 Aug 2003
Posts: 3344
Location: Ballarat Victoria, Australia

PostPosted: Mon Sep 17, 2007 8:05 pm    Post subject: Reply with quote

encoding problems

Using the forum Search function is such a joyous thing. Very Happy
_________________
Add [SOLVED] to the thread title if your issue has been.
Search | FAQ | RTM
Back to top
View user's profile Send private message Visit poster's website
Fire-Fox
Master


Joined: 23 Sep 2006
Posts: 270
Location: /dev/null

PostPosted: Mon Sep 17, 2007 8:17 pm    Post subject: Reply with quote

have you searched for "iso8859-1" in src/tcl.c i can't find this i my eggdrop :O
_________________
GreatZ
Fire-Fox | Denmark

Scripts: Relay | Store Text | TvMaze
Back to top
View user's profile Send private message MSN Messenger
awyeah
Revered One


Joined: 26 Apr 2004
Posts: 1580
Location: Switzerland

PostPosted: Mon Sep 17, 2007 8:21 pm    Post subject: Reply with quote

Take a look at this thread:
http://forum.egghelp.org/viewtopic.php?t=11325
_________________
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Fire-Fox
Master


Joined: 23 Sep 2006
Posts: 270
Location: /dev/null

PostPosted: Mon Sep 17, 2007 8:31 pm    Post subject: Reply with quote

can see any salution but it's me hehe im not hardcore to eggdrop....

but i have this code here:

i need the "aa" replaced with "å"

Code:
########################
###     SKÅL        ###
######################
set chans "#aliasfm"
set schelptrigger "skaal"

bind pub - $schelptrigger pub_skaal

proc pub_skaal {nick uhost hand chan text} {
putserv "privmsg $chan $nick :4RÅBER 4SSSSSS7K3Å11Å13Å12Å4Å9Å3Å6Å7Å4Å10å8å9å14å13å5L5L5L5L5L5L - 4AliasFM!!!"
}

_________________
GreatZ
Fire-Fox | Denmark

Scripts: Relay | Store Text | TvMaze
Back to top
View user's profile Send private message MSN Messenger
awyeah
Revered One


Joined: 26 Apr 2004
Posts: 1580
Location: Switzerland

PostPosted: Mon Sep 17, 2007 8:43 pm    Post subject: Reply with quote

You can use this then:

Code:

set chans "#aliasfm"
set schelptrigger "skaal"
set mytext "afdasgfaagfsaaasgfryuitkaaaarsgtrdythgftrrqw"

bind pub - $schelptrigger pub_skaal

proc pub_skaal {nick uhost hand chan text} {
 regsub -all {aa} [encoding convertfrom iso8859-1 $::mytext] "\354" mynewtext
 putserv "PRIVMSG $chan :$mynewtext"
}


Not tested, but this should do it hopefully.
Edited: Fixed error
_________________
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================


Last edited by awyeah on Mon Sep 17, 2007 9:14 pm; edited 1 time in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Fire-Fox
Master


Joined: 23 Sep 2006
Posts: 270
Location: /dev/null

PostPosted: Mon Sep 17, 2007 8:53 pm    Post subject: Reply with quote

awyeah wrote:
You can use this then:

Code:

set chans "#aliasfm"
set schelptrigger "skaal"
set mytext "afdasgfaagfsaaasgfryuitkaaaarsgtrdythgftrrqw"

bind pub - $schelptrigger pub_skaal

proc pub_skaal {nick uhost hand chan text} {
 regsub -all {aa} [encoding convertfrom iso8859-1 $::mytext] "\354" $mynewtext
 putserv "PRIVMSG $chan :$mynewtext"
}


Not tested, but this should do it hopefully.


set mytext shell i replace that with this:
RÅBER 4SSSSSS7K3Å11Å13Å12Å4Å9Å3Å6Å7Å4Å10å8å9å14å13å5L5L5L5L5L5L - 4AliasFM!!!
_________________
GreatZ
Fire-Fox | Denmark

Scripts: Relay | Store Text | TvMaze
Back to top
View user's profile Send private message MSN Messenger
awyeah
Revered One


Joined: 26 Apr 2004
Posts: 1580
Location: Switzerland

PostPosted: Mon Sep 17, 2007 9:07 pm    Post subject: Reply with quote

This script will replace any occurences of "aa" in $mytext with "å" and assign the substituted string to $mynewtext, which will be displayed on the channel.
_________________
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Fire-Fox
Master


Joined: 23 Sep 2006
Posts: 270
Location: /dev/null

PostPosted: Mon Sep 17, 2007 9:10 pm    Post subject: Reply with quote

when i type "skål" or "skaal" in the chan

i get this i partyline

[pub_skaal]: can't read "mynewtext": no such variable

the code i have now:

Code:

set chans "#aliasfm"
set schelptrigger "skål"
set mytext "4RÅBER 4SSSSSS7K3Å11Å13Å12Å4Å9Å3Å6Å7Å4Å10å8å9å14å13å5L5L5L5L5L5L - 4AliasFM!!!"

bind pub - $schelptrigger pub_skaal

proc pub_skaal {nick uhost hand chan text} {
 regsub -all {aa} [encoding convertfrom iso8859-1 $::mytext] "\354" $mynewtext
 putserv "PRIVMSG $chan :$mynewtext"
}

_________________
GreatZ
Fire-Fox | Denmark

Scripts: Relay | Store Text | TvMaze
Back to top
View user's profile Send private message MSN Messenger
awyeah
Revered One


Joined: 26 Apr 2004
Posts: 1580
Location: Switzerland

PostPosted: Mon Sep 17, 2007 9:15 pm    Post subject: Reply with quote

Sorry my bad, the code is fixed above.
_________________
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Fire-Fox
Master


Joined: 23 Sep 2006
Posts: 270
Location: /dev/null

PostPosted: Mon Sep 17, 2007 9:17 pm    Post subject: Reply with quote

awyeah wrote:
Sorry my bad, the code is fixed above.



BIG thanks for all your help it works now Smile

once again THANKS Smile
_________________
GreatZ
Fire-Fox | Denmark

Scripts: Relay | Store Text | TvMaze
Back to top
View user's profile Send private message MSN Messenger
Fire-Fox
Master


Joined: 23 Sep 2006
Posts: 270
Location: /dev/null

PostPosted: Mon Sep 17, 2007 9:19 pm    Post subject: Reply with quote

a little offtopic here Razz

but do you know a way to add users to the bot so that get +D yes i can add with .chattr <nick> +D but it cuts the name so it not work with a name over x chars ???
_________________
GreatZ
Fire-Fox | Denmark

Scripts: Relay | Store Text | TvMaze
Back to top
View user's profile Send private message MSN Messenger
awyeah
Revered One


Joined: 26 Apr 2004
Posts: 1580
Location: Switzerland

PostPosted: Mon Sep 17, 2007 9:22 pm    Post subject: Reply with quote

I'm not sure what +D does over here. See tcl-commands.doc in the eggdrop package for the list of flags available.

As for adding users with a new flag who get the umode +D, I guess then that can be only done through a tcl script.
_________________
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Fire-Fox
Master


Joined: 23 Sep 2006
Posts: 270
Location: /dev/null

PostPosted: Mon Sep 17, 2007 9:25 pm    Post subject: Reply with quote

awyeah wrote:
I'm not sure what +D does over here. See tcl-commands.doc in the eggdrop package for the list of flags available.

As for adding users with a new flag who get the umode +D, I guess then that can be only done through a tcl script.


+D is a kind of op posion in the bot so they can use specified command when
Quote:
bind pub D $scsetdjtrigger pub_setdj

_________________
GreatZ
Fire-Fox | Denmark

Scripts: Relay | Store Text | TvMaze
Back to top
View user's profile Send private message MSN Messenger
DragnLord
Owner


Joined: 24 Jan 2004
Posts: 711
Location: C'ville, Virginia, USA

PostPosted: Tue Sep 18, 2007 2:17 am    Post subject: Reply with quote

eggdrop defaults to handles of only 9 characters
you will have to edit eggdrop.h to increase that (up to 32)

if you add a user with a long nick, the bot creates the handle from the first 9 chars and drops the rest

the following works quite well with domsen's shoutcast script from domsen.org (script in archive is outdated, website has code fixes)
Code:
.chattr <handle> +D
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help All times are GMT - 4 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber