Re-download the mod, there was a bug in the first upload that causes this to happen. The pre-stripped chat variable is CHATCLEAN by the way, which should work for what you want
This is the best mod ever mumfrey! I'm just posting here to thank you for all of the hard work put into this. I use this mod almost every minute I'm playing minecraft it's really true, you wonder how you lived without it.
Would it be possible to detect if a line of text has over 50% caps or so? I attempted to do that, but it didnt seem to work for me, I tried several different variations as an attempt, but they both didnt work
Would it be possible to detect if a line of text has over 50% caps or so? I attempted to do that, but it didnt seem to work for me, I tried several different variations as an attempt, but they both didnt work
1) environment variables are all caps, CHATCLEAN, CHAT, etc.
2) Doing math on strings doesn't use their lengths.., it uses their ASCII values..., it's basically random nonsense
3) Regex default to case insensitive in this mod
4) "Match(%chatclean%,&chatfull)" needs a second parameter which is the pattern (you have the first and third)
if you just want to store the value it's Set(&chatfull,%CHATCLEAN%)
5) regex also don't need slashes around them, it knows to expect a regex as the second parameter
---
I don't have time *right now* to create it, but one way would be to do a match like (.)(.+) to remove the first letter
then use a case sensitive match to see if it's caps or not..., Inc() or Dec() a counter based on whether it is
when the string runs out, check the counter
I'll be back in about 4.5 hours, i'll try and make a working example then
(you may want to also ignore the playername from this.., do you have a chat filter script?)
1) environment variables are all caps, CHATCLEAN, CHAT, etc.
2) Doing math on strings doesn't use their lengths.., it uses their ASCII values..., it's basically random nonsense
3) Regex default to case insensitive in this mod
4) "Match(%chatclean%,&chatfull)" needs a second parameter which is the pattern (you have the first and third)
if you just want to store the value it's Set(&chatfull,%CHATCLEAN%)
5) regex also don't need slashes around them, it knows to expect a regex as the second parameter
---
I don't have time *right now* to create it, but one way would be to do a match like (.)(.+) to remove the first letter
then use a case sensitive match to see if it's caps or not..., Inc() or Dec() a counter based on whether it is
when the string runs out, check the counter
I'll be back in about 4.5 hours, i'll try and make a working example then
(you may want to also ignore the playername from this.., do you have a chat filter script?)
yea, I have a filter that can seperate the message from the rest of the chat, so thats not an issue, just getting it to detect the higher ratio of caps to non caps is the hard part
I'll be back in about 4.5 hours, i'll try and make a working example then
This will go through &message one letter at a time, and increase the counter for every capital letter A to Z, decrease for any non-capital letter A-Z.., and ignore numbers, punctuation..., anything not in that range
In the end, if there are more uppercase than lowercase, #counter will end up with a positive value
$${
// Takes &message as it's only input
Set(&buffer,%&message%) //Move message into a separate variable, &buffer
#counter = 0 // Reset counter
Do()
. IFMATCHES(%&buffer%,"..") // if there are at least two characters left
. . MATCH(%&buffer%,"(.)(.+)",{&letter,&buffer}) // Move the first character from &buffer into &letter (overwrite)
. . IFMATCHES(%&letter%,(?i)[A-Z]) // if capital
. . . Inc(#counter)
. . ENDIF
. . IFMATCHES(%&letter%,(?i)[a-z]) // if lowercase
. . . Dec(#counter)
. . ENDIF
. ELSE // If there aren't two characters left (but only one)
. . Break() // Break out of the loop
. ENDIF
Loop
// Do the last character
MATCH(%&buffer%,"(.)",{&letter}) // Move the last remaining character into &letter
IFMATCHES(%&letter%,(?i)[A-Z]) // if uppercase
. Inc(#counter)
ENDIF
IFMATCHES(%&letter%,(?i)[a-z])// if lowercase
. Dec(#counter)
ENDIF
// Gives #counter as it's only output, which is amount of uppercase minus amount of lowercase
// Punctuation was ignored
}$$
yea, I have a filter that can seperate the message from the rest of the chat, so thats not an issue, just getting it to detect the higher ratio of caps to non caps is the hard part
oops, forgot to quote you.., i just posted an example above here
Re-download the mod, there was a bug in the first upload that causes this to happen. The pre-stripped chat variable is CHATCLEAN by the way, which should work for what you want
Okay I redownloaded the mod and put in the CHATCLEAN and all I got was CHATCLEAN in the log. What am I doing wrong? Can you please write out the script the way it is suppose to be, I don't think I am typing it in right. All I want it to do is log the chat with all the proper color codes and what not. Please help.
Hello can someone help me make a quick macro for mcmmo salvaging/repair. Basically make it grab an item out of ur inventory double click the emerald block ur facing to repair it, then move to the next item. 36 times (for 36 items.) Then the same thing except for salvaging while facing a gold block.
Thanks in advance..
im using $${CRAFT(80,200)}$$ but i want to slow the process down, not between crafts but the crafting process itself, is this possible? it doesnt seem to work on survival servers as it crafts way too fast, to the point you cant eve nsee it place it into the crafting grid so it doesnt craft anything.
Rollback Post to RevisionRollBack
Dedicated Creative Server: mc.xemcorp.com Website & info at: xemcorp.com (click)
Okay I redownloaded the mod and put in the CHATCLEAN and all I got was CHATCLEAN in the log. What am I doing wrong? Can you please write out the script the way it is suppose to be, I don't think I am typing it in right. All I want it to do is log the chat with all the proper color codes and what not. Please help.
CHATCLEAN is without color codes.., CHAT is with
to replace a variable with it's value, you highlight it with percent signs.., for example
Hello can someone help me make a quick macro for mcmmo salvaging/repair. Basically make it grab an item out of ur inventory double click the emerald block ur facing to repair it, then move to the next item. 36 times (for 36 items.) Then the same thing except for salvaging while facing a gold block.
Thanks in advance..
$${
Do(4) // Do 4 times (because 4 rows)
.
. Gui(inventory) // Open inventory
. For(#i,0,8) // For each column
. . #c = 9 + #i
. . . SlotClick(%#c%) // Click on the top of the column
. . .
. . . Do(3) // Click on the other slots in the column
. . . . #c = #c + 9
. . . . SlotClick(%#c%)
. . . Loop
. . .
. . . #c = #invslot + #i
. . . SlotClick(%#c%) // Click at the top of the column again to deposit the previously bottommost item
. . Next // Repeat for next column
. Gui() // Close inventory
.
.
. For(#hotbar,1,9) // For each slot in the hotbar
. . Slot(%#hotbar%) // Select that slot
. . Key(attack) //Doubleclick attack, 1 tick delay
. . Wait(1t)
. . Key(attack)
. Next // repeat for next slot
.
. Wait(1) // A little delay to be safe
Next
}$$
copyable version:
im using $${CRAFT(80,200)}$$ but i want to slow the process down, not between crafts but the crafting process itself, is this possible? it doesnt seem to work on survival servers as it crafts way too fast, to the point you cant eve nsee it place it into the crafting grid so it doesnt craft anything.
It's way more annoying to write, but you can use SlotClick() to manually define your crafting movements and delays
It should still work though, not seeing the crafting take place is normal, and at least on a vanilla server it still works fine
Okay I redownloaded the mod and put in the CHATCLEAN and all I got was CHATCLEAN in the log. What am I doing wrong? Can you please write out the script the way it is suppose to be, I don't think I am typing it in right. All I want it to do is log the chat with all the proper color codes and what not. Please help.
Those variables are only available in onChat, are you sure you're not using an EXEC or something else that will switch the context in some way?
im using $${CRAFT(80,200)}$$ but i want to slow the process down, not between crafts but the crafting process itself, is this possible? it doesnt seem to work on survival servers as it crafts way too fast, to the point you cant eve nsee it place it into the crafting grid so it doesnt craft anything.
It won't work on servers with nocheat plus or other anti-cheat plugins. The reason it works so fast is that there currently isn't any way to inhibit user input in the gui, so it has to do entire sequences of clicks each tick to prevent accidental mouse movements from screwing it up. Until I can design some way to "lock out" the user whilst it's crafting then it has to craft at that speed, it's just not feasible any other way:
The reason is, when crafting I have to find an item in the inventory, drag it to the crafting grid, find the next item, etc. repeat, until the recipe is complete, THEN check that the output slot contains the thing we want, THEN check that the inventory isn't full and that crafting is possible. If I don't do this all in "one hit" then there's too many things that can go wrong.
I will add a slow crafting capability in the future but because it's so complex to achieve I won't be adding it any time soon. Basically if auto-crafting is blocked by an anti-cheat plugin then you will have to rely on creating SLOTCLICK macros with waits, which isn't ideal but is at least faster than crafting by hand. Sorry about that.
Those variables are only available in onChat, are you sure you're not using an EXEC or something else that will switch the context in some way?
Yes I am using it on onChat and it triess to log chat but only logs the word CHAT or CHATCLEAN or CLEANCHAT. It doesnot actually log what is being said in chat. This is what I have in the script -
If this is incorrect please revise it. I really wish to get this to work correctly. I need the correct chat format to make my other scripts work correctly. Thanks in advance.
Yes I am using it on onChat and it triess to log chat but only logs the word CHAT or CHATCLEAN or CLEANCHAT. It doesnot actually log what is being said in chat. This is what I have in the script -
If this is incorrect please revise it. I really wish to get this to work correctly. I need the correct chat format to make my other scripts work correctly. Thanks in advance.
Is that directly in the macro or is it in a file, how are you invoking the file. Are you using EXEC? (for the third time)
Okay I finally got it to work. No clue what I did, lol, but it is working. But to try and answer your questions I have it in a .txt file. Not sure what you mean by EXEC (still learning all of this), but I have it under onChat as $$<Chatlog.txt> (don't know if that helps). Anyways, it does work, I am truly sorry for all the questions and posts and I thank all of you who tried to help me out.
Re-download the mod, there was a bug in the first upload that causes this to happen. The pre-stripped chat variable is CHATCLEAN by the way, which should work for what you want
and
any help?
1) environment variables are all caps, CHATCLEAN, CHAT, etc.
2) Doing math on strings doesn't use their lengths.., it uses their ASCII values..., it's basically random nonsense
3) Regex default to case insensitive in this mod
4) "Match(%chatclean%,&chatfull)" needs a second parameter which is the pattern (you have the first and third)
if you just want to store the value it's Set(&chatfull,%CHATCLEAN%)
5) regex also don't need slashes around them, it knows to expect a regex as the second parameter
---
I don't have time *right now* to create it, but one way would be to do a match like (.)(.+) to remove the first letter
then use a case sensitive match to see if it's caps or not..., Inc() or Dec() a counter based on whether it is
when the string runs out, check the counter
I'll be back in about 4.5 hours, i'll try and make a working example then
(you may want to also ignore the playername from this.., do you have a chat filter script?)
'Cause tomorrow spring is here
It didn't get looked over, I answered it quite comprehensively...
yea, I have a filter that can seperate the message from the rest of the chat, so thats not an issue, just getting it to detect the higher ratio of caps to non caps is the hard part
This will go through &message one letter at a time, and increase the counter for every capital letter A to Z, decrease for any non-capital letter A-Z.., and ignore numbers, punctuation..., anything not in that range
In the end, if there are more uppercase than lowercase, #counter will end up with a positive value
$${
// Takes &message as it's only input
Set(&buffer,%&message%) //Move message into a separate variable, &buffer
#counter = 0 // Reset counter
Do()
. IFMATCHES(%&buffer%,"..") // if there are at least two characters left
. . MATCH(%&buffer%,"(.)(.+)",{&letter,&buffer}) // Move the first character from &buffer into &letter (overwrite)
. . IFMATCHES(%&letter%,(?i)[A-Z]) // if capital
. . . Inc(#counter)
. . ENDIF
. . IFMATCHES(%&letter%,(?i)[a-z]) // if lowercase
. . . Dec(#counter)
. . ENDIF
. ELSE // If there aren't two characters left (but only one)
. . Break() // Break out of the loop
. ENDIF
Loop
// Do the last character
MATCH(%&buffer%,"(.)",{&letter}) // Move the last remaining character into &letter
IFMATCHES(%&letter%,(?i)[A-Z]) // if uppercase
. Inc(#counter)
ENDIF
IFMATCHES(%&letter%,(?i)[a-z])// if lowercase
. Dec(#counter)
ENDIF
// Gives #counter as it's only output, which is amount of uppercase minus amount of lowercase
// Punctuation was ignored
}$$
'Cause tomorrow spring is here
*edits out CHATCLEAN in favour of &message*
'Cause tomorrow spring is here
Okay I redownloaded the mod and put in the CHATCLEAN and all I got was CHATCLEAN in the log. What am I doing wrong? Can you please write out the script the way it is suppose to be, I don't think I am typing it in right. All I want it to do is log the chat with all the proper color codes and what not. Please help.
Thanks in advance..
Dedicated Creative Server: mc.xemcorp.com Website & info at: xemcorp.com (click)
CHATCLEAN is without color codes.., CHAT is with
to replace a variable with it's value, you highlight it with percent signs.., for example
LogTo(chatlog.txt,%CHAT%)
$${
Do(4) // Do 4 times (because 4 rows)
.
. Gui(inventory) // Open inventory
. For(#i,0,8) // For each column
. . #c = 9 + #i
. . . SlotClick(%#c%) // Click on the top of the column
. . .
. . . Do(3) // Click on the other slots in the column
. . . . #c = #c + 9
. . . . SlotClick(%#c%)
. . . Loop
. . .
. . . #c = #invslot + #i
. . . SlotClick(%#c%) // Click at the top of the column again to deposit the previously bottommost item
. . Next // Repeat for next column
. Gui() // Close inventory
.
.
. For(#hotbar,1,9) // For each slot in the hotbar
. . Slot(%#hotbar%) // Select that slot
. . Key(attack) //Doubleclick attack, 1 tick delay
. . Wait(1t)
. . Key(attack)
. Next // repeat for next slot
.
. Wait(1) // A little delay to be safe
Next
}$$
copyable version:
It's way more annoying to write, but you can use SlotClick() to manually define your crafting movements and delays
It should still work though, not seeing the crafting take place is normal, and at least on a vanilla server it still works fine
'Cause tomorrow spring is here
This still does not work. All it logs is - 2013-05-13 13:17:40: CHAT
You're calling it from inside the onChat event, right? (or ChatFilter)
'Cause tomorrow spring is here
Those variables are only available in onChat, are you sure you're not using an EXEC or something else that will switch the context in some way?
It won't work on servers with nocheat plus or other anti-cheat plugins. The reason it works so fast is that there currently isn't any way to inhibit user input in the gui, so it has to do entire sequences of clicks each tick to prevent accidental mouse movements from screwing it up. Until I can design some way to "lock out" the user whilst it's crafting then it has to craft at that speed, it's just not feasible any other way:
The reason is, when crafting I have to find an item in the inventory, drag it to the crafting grid, find the next item, etc. repeat, until the recipe is complete, THEN check that the output slot contains the thing we want, THEN check that the inventory isn't full and that crafting is possible. If I don't do this all in "one hit" then there's too many things that can go wrong.
I will add a slow crafting capability in the future but because it's so complex to achieve I won't be adding it any time soon. Basically if auto-crafting is blocked by an anti-cheat plugin then you will have to rely on creating SLOTCLICK macros with waits, which isn't ideal but is at least faster than crafting by hand. Sorry about that.
Are you using EXEC?
Yes I am using it on onChat and it triess to log chat but only logs the word CHAT or CHATCLEAN or CLEANCHAT. It doesnot actually log what is being said in chat. This is what I have in the script -
$${
STRIP(&chat, %CHAT%)
LOGTO("chatlog.txt",%DATE% %TIME%: %CHAT%);
}$$
If this is incorrect please revise it. I really wish to get this to work correctly. I need the correct chat format to make my other scripts work correctly. Thanks in advance.
Is that directly in the macro or is it in a file, how are you invoking the file. Are you using EXEC? (for the third time)