mirror of
https://github.com/collinsmith/riiablo.git
synced 2025-02-01 10:24:30 +07:00
Renamed item pickup and drop functions to more closely match other item functions
pickup -> groundToCursor drop -> cursorToGround
This commit is contained in:
parent
24d0a07cea
commit
46581d11e1
@ -102,7 +102,7 @@ public class CursorMovementSystem extends BaseSystem {
|
||||
Vector2 position = mPosition.get(src).position;
|
||||
iso.toTile(tmpVec2.set(position));
|
||||
|
||||
Riiablo.charData.dropCursor();
|
||||
Riiablo.charData.cursorToGround();
|
||||
if (socket == null) {
|
||||
factory.createItem(cursor, tmpVec2);
|
||||
} else {
|
||||
|
@ -11,7 +11,7 @@ public class ItemInteractor extends PassiveSystem implements Interactable.Intera
|
||||
|
||||
@Override
|
||||
public void interact(int src, int entity) {
|
||||
items.pickupToCursor(src, entity);
|
||||
items.groundToCursor(src, entity);
|
||||
world.delete(entity);
|
||||
}
|
||||
}
|
||||
|
@ -16,13 +16,13 @@ public class ItemManager extends PassiveSystem {
|
||||
protected ComponentMapper<Player> mPlayer;
|
||||
protected ComponentMapper<Item> mItem;
|
||||
|
||||
public void pickupToCursor(int entityId, int dst) {
|
||||
public void groundToCursor(int entityId, int dst) {
|
||||
com.riiablo.item.Item item = mItem.get(dst).item;
|
||||
mPlayer.get(entityId).data.pickupToCursor(item);
|
||||
mPlayer.get(entityId).data.groundToCursor(item);
|
||||
}
|
||||
|
||||
public void dropCursor(int entityId) {
|
||||
mPlayer.get(entityId).data.dropCursor();
|
||||
public void cursorToGround(int entityId) {
|
||||
mPlayer.get(entityId).data.cursorToGround();
|
||||
}
|
||||
|
||||
public void storeToCursor(int entityId, int i) {
|
||||
|
@ -380,11 +380,11 @@ public class CharData implements ItemData.UpdateListener, Pool.Poolable {
|
||||
return itemData;
|
||||
}
|
||||
|
||||
public void pickupToCursor(Item item) {
|
||||
public void groundToCursor(Item item) {
|
||||
itemData.pickup(item);
|
||||
}
|
||||
|
||||
public void dropCursor() {
|
||||
public void cursorToGround() {
|
||||
itemData.drop();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user