UOGamers Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

  • To obtain new Razor updates, please reinstall Razor from our new website.

Crafting macro help.

silvertiger

Knight
So I made a macro for making weapons along these same lines, but I can't seem to be able to make armor this way.

Code:
setalias 'trashbarrelluna' 0x4000b9c0
usetype 0x13e3 'any''backpack'
replygump 0x38920abd 21
waitforgump 0x38920abd 15000
while @findtype 0x277d 'any' 'backpack'
  waitforproperties 'found' 2500
  @unsetalias 'move'
  // Check item properties
  if @property 'self repair''found'
    @setalias 'found'
  elseif @property 'lower reagent cost''found'
    @setalias 'found'
  elseif @property 'stamina regeneration' 'found'
    @setalias 'found'
  elseif @property 'hit point regeneration''found'
    @setalias 'found'
  elseif @property 'reflect physical damage''found
    @setalias 'found'
  endif
  // Move the item
  if @findalias 'move'
    moveitem 'found' 'bank'
    pause 800
  else if findalias 'found'
    moveitem 'found' 'trashbarrelluna'
    pause 800
  endif
  ignoreobject 'found'
endwhile
Unless I maybe switch the if found move moveitem found bank to moveitem trash instead and then switch trash barrel luna to bank.



Also I don't seem to be able to get more than two mods to work example:

Code:
elseif @property 'hit mana leech''found' and @property 'hit life leech''found' and @property 'hit stamina leech''found'
@setalias 'move''found'
//this is from my weapons script, but the it just takes out any double leeches instead of only looking for triple leeches...
 
You can only have two conditions per if statement, so to find a triple leach you would need a nested if:

Code:
elseif @property 'hit mana leech''found' and @property 'hit life leech''found'
  if @property 'hit stamina leech''found'
    @setalias 'move''found'
  endif
endif

As far as the other part, it looks like you are never setting 'move' so it will never go to your bank?
 

silvertiger

Knight
As far as the other part, it looks like you are never setting 'move' so it will never go to your bank?
I fixed it with my own suggestion, haha. I'm like house sometimes I just need to bounce ideas. Haha. So, it now says if property 'lrc' found
Setalias movefound
If findalias move
Moveitem found trashbarrelluna
Else findalias found
Moveitem found bank
Endif.

Works perfectly for making perfect samp pieces on TC. :p

Also, thank you for the triple leech advice. Someone had mentioned that before and I had forgotten or didn't understand what they were saying.
 
Last edited:
Top