Jump to content
  • 0

Card Trader Redeemer


Radian

Question


  • Group:  Members
  • Topic Count:  162
  • Topics Per Day:  0.05
  • Content Count:  1546
  • Reputation:   192
  • Joined:  07/23/14
  • Last Seen:  

Hello Everyone can someone help me with this one?

	set .Points$,"#Card_Points";	// Variable to store points.
	set .PAmount, 1000;		// Not Sure with this

and this

	case 3:
		if(.Points$ < .@PAmount) {
		mes "[Card Trader]";
		mes "Come again when you got " + callfunc("F_InsertComma",.PAmount$) + " Points to redeem your points...";
		end;
		} else {
		mes "Always remember that I need " + callfunc("F_InsertComma",.PAmount$) + " Points so take this prize for the points you got...";
		set .Points$,.Points$ - .PAmount;
		end;
		}

and Errors show that

[Error]: script:op_2: invalid data for operator C_LT
[Debug]: Data: string value="#Card_Points"
[Debug]: Data: number value=0
[Debug]: Source (NPC): Card Trader at trinity (132,113)

can someone tell me what's wrong with the scripts?

Link to comment
Share on other sites

2 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  317
  • Reputation:   63
  • Joined:  11/13/11
  • Last Seen:  

This part isn't possible;

if(.Points$ < .@PAmount) {

You're comparing a string to an int. Besides, shouldn't .@PAmount be .PAmount? You can try;

if (#Card_Points < .PAmount) {
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  162
  • Topics Per Day:  0.05
  • Content Count:  1546
  • Reputation:   192
  • Joined:  07/23/14
  • Last Seen:  

Oh. thanks! 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...