View Single Post
  #3  
Old 03-28-2019, 10:21 AM
rudeboy88's Avatar
rudeboy88
Sarnak
 
Join Date: Oct 2007
Location: West Freeport
Posts: 46
Default

Just noticed the revised script is having issues with naming the variables c, d, and e, replaced with OP function_trade

Code:
function event_trade(e)
	local item_lib = require("items");
	if(e.trade.platinum ~= 0 and e.trade.platinum ~= nil) then
		local c2 = e.trade.platinum;
		local c3 = eq.get_data(e.other:AccountID() .. "_Casino");
		local c4 = c2 + c3;
		eq.set_data(e.other:AccountID() .. "_Casino", tostring(c4));
		e.other:Message(315,"Your platinum has been credited to your account.  Your current balance is: " .. eq.get_data(e.other:AccountID() .. "_Casino") .. ".");
	end
	item_lib.return_items(e.self, e.other, e.trade);
end
__________________
Discord: 1augher | Dev, Darkonites
Reply With Quote