• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

You see a gold nugget.

Status
Not open for further replies.

Teddy

SweStream.se
Joined
Oct 2, 2008
Messages
3,797
Reaction score
10
Location
Sweden 172
Can i make a Gold Nugget to a unlimited donate bolt? for crossbow?
 
items.xml
Code:
	<item id="2157" article="a" name="gold nugget" plural="gold nuggets">
		<attribute key="weight" value="10"/>
[B][COLOR="Red"]		<attribute key="slotType" value="ammo"/>
		<attribute key="attack" value="50"/>
		<attribute key="maxHitChance" value="100"/>
		<attribute key="weaponType" value="ammunition"/>
		<attribute key="ammoType" value="bolt"/>
		<attribute key="shootType" value="smallholy"/>
		<attribute key="ammoAction" value="moveback"/>[/COLOR][/B]
	</item>
 
ok, lets see, i think you use "removeWeaponAmmunition = true" and you want make the nugget for special players, im not sure if now there is any "items.xml" value to prevent remove ammo, in case there is no one you should make a weapon script, and if there is one then all ok 8)
 
ok, lets see, i think you use "removeWeaponAmmunition = true" and you want make the nugget for special players, im not sure if now there is any "items.xml" value to prevent remove ammo, in case there is no one you should make a weapon script, and if there is one then all ok 8)
actually what i posted works correctly and doesn't remove nuggets.
No i have
removeWeaponAmmunition = false
will
Cykotitan
script work ? :)
tested and working, altough i can't find an appropriate shooteffect for it.
 
holy:
2duwht2.png

smallholy:
20f7xg6.png


:D:D
 
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	local cfg = {
		[XXXX] = { effect = CONST_ME_HOLY },
		[XXXX] = { effect = CONST_ME_SMALLHOLY }
	}
	local v = cfg[item.itemid]
	if(item.itemid = v) then
		doSendMagicEffect(getCreaturePosition(cid), v.effect)
		return true
	end
end
 
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	local cfg = {
		[XXXX] = { effect = CONST_ME_HOLY },
		[XXXX] = { effect = CONST_ME_SMALLHOLY }
	}
	local v = cfg[item.itemid]
	if(item.itemid = v) then
		doSendMagicEffect(getCreaturePosition(cid), v.effect)
		return true
	end
end
And where do i put this (A)
 
data/actions/scripts/script_name.lua

actions.xml
<action itemid="ID HERE" event="script" value="script_name.lua"/>
<action itemid="ID HERE" event="script" value="script_name.lua"/>
 
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	local cfg = {
		[XXXX] = { effect = [B][COLOR="Red"]CONST_ME_HOLY[/COLOR][/B] },
		[XXXX] = { effect = [B][COLOR="Red"]CONST_ME_SMALLHOLY[/COLOR][/B] }
	}
	local v = cfg[item.itemid]
	if(item.itemid = v) then
		doSendMagicEffect(getCreaturePosition(cid), v.effect)
		return true
	end
end
Those are shootTypes (also you would need to replace ME with ANI)
so how do i make a effect for this gold nugget ?
What kind of an effect?
 
If you add:
Code:
<attribute key="ammoAction" value="moveback"/>
to your "nugget-bolt" in items.xml I don't think it will disappear when you use it. then you can have removeAmmuntion = true ~~~
 
Status
Not open for further replies.
Back
Top