Be a Supporter!

Inventory help

  • 404 Views
  • 3 Replies
New Topic Respond to this Topic
Sam
Sam
  • Member since: Oct. 1, 2005
  • Offline.
Forum Stats
Moderator
Level 19
Programmer
Inventory help 2005-10-14 08:15:14 Reply

Sorry about this, but im eager to get my inventory system working, before I can move on in my game.

This is what I have so far for one of the items.

onClipEvent(mouseMove){
}
on (press) {
startDrag(this);
}
on (release) {
stopDrag();
if(this.hitTest(_root.rec)){
this._x = _root.slot._x;
this._y = _root.slot._y;
}else{
this._x = lolX;
this._y = lolY;

}
}

onClipEvent(mouseMove){
if(clutch){
this._x = _root._xmouse;
this._y = _root._ymouse;
}
}

"Rec" is the WHOLE bg, so on click of teh item, it automatically goes to slot1, the drag part of its so, you can drag it from the inventory to NPCS or what not, to complete quests. Heres my problem, when I go to the next area (next frame) any items you have picked up dissapear. I have tried teh scrolling screen, but that wont work because when you pick it up, it keeps scrolling anyway.

Hope someone can help!

Sam
Sam
  • Member since: Oct. 1, 2005
  • Offline.
Forum Stats
Moderator
Level 19
Programmer
Response to Inventory help 2005-10-14 09:17:31 Reply

Anyone got any idea on whats wrong?

P1E-T1ME
P1E-T1ME
  • Member since: Sep. 21, 2005
  • Offline.
Forum Stats
Member
Level 04
Blank Slate
Response to Inventory help 2005-10-14 09:37:57 Reply

At 10/14/05 09:17 AM, Saza066 wrote: Anyone got any idea on whats wrong?

Nope. But you double posted.

Toast
Toast
  • Member since: Apr. 2, 2005
  • Offline.
Forum Stats
Member
Level 09
Blank Slate
Response to Inventory help 2005-10-14 11:03:24 Reply

At 10/14/05 09:37 AM, Mongolian_Rooster wrote:
At 10/14/05 09:17 AM, Saza066 wrote: Anyone got any idea on whats wrong?
Nope. But you double posted.

Shut up, he waited 1 hour before posting, so think a bit before posting stupid comments.

What Button/ MovieClip do you have that code on?


BBS Signature