Raised This Month: $ Target: $400
 0% 

Solved possibly unintended assignment


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
kww
Senior Member
Join Date: Feb 2021
Location: Russia
Old 04-25-2022 , 13:51   possibly unintended assignment
Reply With Quote #1

I have this piece of code
PHP Code:
static anim

if(anim g_models[index][draw2])
{
    switch(
random_num(1DRAW2_CHANCE))
    {
        case 
DRAW2_CHANCEplay_anim(idanim)
        default: 
play_anim(id3)
    }

I like how it looks. It even compiles but compile.exe throws me a warn 211: possibly unintended assignment.
Do I have to change it (to code below) or not?
PHP Code:
static animanim g_models[index][draw2]

if(
anim)
{
    switch(
random_num(1DRAW2_CHANCE))
    {
        case 
DRAW2_CHANCEplay_anim(idanim)
        default: 
play_anim(id3)
    }

__________________
Now working on: Side Weapons (Very lazy, tbh)
Avatar source: https://bit.ly/3BAk19g
Discord: kww#9951

Last edited by kww; 04-26-2022 at 01:42.
kww is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 21:22.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode