Nightmare
Nightmare
Rroblox-ts
Created by Nightmare on 4/20/2025 in #help
I am so confused about the type, it should be "string" but it says it can't be any
public getHashCode(): number {
const { X, Y, Z } = this.position;
const positionString: string = `${X}${Y}${Z}`;

if (typeIs(positionString, "string")) {
return Crc32(positionString);
}
return 0;
}
public getHashCode(): number {
const { X, Y, Z } = this.position;
const positionString: string = `${X}${Y}${Z}`;

if (typeIs(positionString, "string")) {
return Crc32(positionString);
}
return 0;
}
the Crc32 is from @rblxts/crypto
18 replies
Rroblox-ts
Created by Nightmare on 4/16/2025 in #help
tables cannot be cyclic
Hello, I got this error and I am not really sure about how to fix it
private pickItem(item: Instance | undefined) {
print("ppick up hell yea");
if (item !== undefined) {
print("item defined");
const selectedSlot: number | undefined = this.UIstateHandle.getSelectedSlot();
if (selectedSlot !== undefined) {
print("slot defined");
const itemID: number | undefined = item.GetAttribute("ItemID") as number;
if (itemID !== undefined) {
print("itemID defined");
const itemClass = getItemRegistry(itemID);
if (itemClass !== undefined) {
print("itemClass defined");
Functions.pickUp.invoke(selectedSlot, itemClass).then((success) => {
print("no more go 3:");
if (success) {
print("sucess? ", success);
Functions.getItemsInfo.invoke().then((itemData: ItemData[]) => {
print("meow");
itemData.forEach((SlotData, _) => {
const Icon = SlotData.Icons[0];
this.UIstateHandle.setItemsInfo(Icon, undefined);
});
});
}
});
}
}
}
}
}
private pickItem(item: Instance | undefined) {
print("ppick up hell yea");
if (item !== undefined) {
print("item defined");
const selectedSlot: number | undefined = this.UIstateHandle.getSelectedSlot();
if (selectedSlot !== undefined) {
print("slot defined");
const itemID: number | undefined = item.GetAttribute("ItemID") as number;
if (itemID !== undefined) {
print("itemID defined");
const itemClass = getItemRegistry(itemID);
if (itemClass !== undefined) {
print("itemClass defined");
Functions.pickUp.invoke(selectedSlot, itemClass).then((success) => {
print("no more go 3:");
if (success) {
print("sucess? ", success);
Functions.getItemsInfo.invoke().then((itemData: ItemData[]) => {
print("meow");
itemData.forEach((SlotData, _) => {
const Icon = SlotData.Icons[0];
this.UIstateHandle.setItemsInfo(Icon, undefined);
});
});
}
});
}
}
}
}
}
(ignore the print statements, I am debugging) only thing I discovered is it's about this line:
Functions.getItemsInfo.invoke().then((itemData: ItemData[]) => {
Functions.getItemsInfo.invoke().then((itemData: ItemData[]) => {
8 replies
Rroblox-ts
Created by Nightmare on 4/15/2025 in #help
Asphalt can't upload asset
[WARN asphalt::sync::perform] Failed to sync asset assets/UI/SlotPart.svg: Failed to upload asset
Caused by: Failed to get image ID
Caused by: Failed to parse asset delivery response
Caused by: error decoding response body
Caused by: missing field `location` at line 1 column 45
[WARN asphalt::sync::perform] Failed to sync asset assets/UI/SlotPart.svg: Failed to upload asset
Caused by: Failed to get image ID
Caused by: Failed to parse asset delivery response
Caused by: error decoding response body
Caused by: missing field `location` at line 1 column 45
I am too stupid to tell if it's because of me or software error so yeah
7 replies
Rroblox-ts
Created by Nightmare on 4/12/2025 in #help
[SOLVED] Confused about OOP
I have method like this which works weirdly
addItem(Item: new (...args: never[]) => Item) {
if (this.item === undefined) {
this.item = new Item();
print(Item);
print(this.item);
print("Item Added into the slot!");
}
}
addItem(Item: new (...args: never[]) => Item) {
if (this.item === undefined) {
this.item = new Item();
print(Item);
print(this.item);
print("Item Added into the slot!");
}
}
1st print prints Class name, that's correct 2nd print for some reason prints just empty table which is really weird the class in question:
export class Box extends Item {
constructor() {
if (ItemsFolder && ItemsFolder.IsA("Folder")) {
const model = ItemsFolder.FindFirstChild("Box");
if (model && model.IsA("Model")) {
super("Box", model, "Very cool box!");
this.id = 2;
}
}
}

use(): void {
print("dumbass, box has no use");
}
}
export class Box extends Item {
constructor() {
if (ItemsFolder && ItemsFolder.IsA("Folder")) {
const model = ItemsFolder.FindFirstChild("Box");
if (model && model.IsA("Model")) {
super("Box", model, "Very cool box!");
this.id = 2;
}
}
}

use(): void {
print("dumbass, box has no use");
}
}
48 replies
Rroblox-ts
Created by Nightmare on 4/10/2025 in #help
I just ran my project and, got a lot of errors and I have no idea what happened
38 replies