[ 3 / biz / cgl / ck / diy / fa / ic / jp / lit / sci / vr / vt ] [ index / top / reports ] [ become a patron ] [ status ]
2023-11: Warosu is now out of extended maintenance.

/vr/ - Retro Games

Search:


View post   

>> No.3916445 [View]
File: 33 KB, 480x300, 4g1t4t10n.gif [View same] [iqdb] [saucenao] [google]
3916445

So what am I doing wrong with this?

if((input & BT_FORWARD)&&(CheckInventory("PlayerStamina")>=1))
{
GiveInventory("SprintingPlayer",1);
while((input & BT_FORWARD)&&(CheckInventory("PlayerStamina")>=1))
{
Delay(1);
}
TakeInventory("SprintingPlayer",1);
Delay(const:SD_DASHDELAY);
}

If you release the forward key, it doesn't take away the 'SprintingPlayer' item.

Navigation
View posts[+24][+48][+96]