Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Donate
Collapse

Plutonium

  1. Home
  2. BO2 Modding Support & Discussion
  3. [Support] Help Fixing Code

[Support] Help Fixing Code

Scheduled Pinned Locked Moved BO2 Modding Support & Discussion
17 Posts 2 Posters 197 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • ThrzModdingRMTundefined Offline
    ThrzModdingRMTundefined Offline
    ThrzModdingRMT
    wrote on last edited by
    #1
    	else if(option == 9)
    	{
    		if(stoggle(9))
    		{
    			self thread loop_handler(9);
    			break;
    		}
    		if(isdefined(self.healthbarhudelems))
    		{
    			return;
    		}
    		for(i == 0; i < self.healthbarkeys.size; i++)
    		{
    			self.healthbarhudelems[self.healthbarkeys[i]].bgbar destroy();
    			self.healthbarhudelems[self.healthbarkeys[i]].bar destroy();
    			self.healthbarhudelems[self.healthbarkeys[i]].destroy();
    		}
    	}
    

    Please Im almost on deepweb to find how to fix

    https://prnt.sc/1eud2f1

    1 Reply Last reply
    0
    • Sorexundefined Offline
      Sorexundefined Offline
      Sorex Contributor
      wrote on last edited by
      #2

      JARDASs Can you explain more? What is your issue? Also you can send images without link 🙂

      ThrzModdingRMTundefined 1 Reply Last reply
      0
      • ThrzModdingRMTundefined Offline
        ThrzModdingRMTundefined Offline
        ThrzModdingRMT
        replied to Sorex on last edited by
        #3

        Sorex
        Im trying to compile Sentinel Mod Menu to Play on my dedicated server and it gives syntax errors cause it cant decompile in 100% i think
        Btw i cant send images here idk why

        Capturar.PNG

        If u want source code to help me id love to learn:

        https://pastebin.com/ZEyu5Rkk

        1 Reply Last reply
        0
        • Sorexundefined Offline
          Sorexundefined Offline
          Sorex Contributor
          wrote on last edited by
          #4

          JARDASs said in [Support] Help Fixing Code:

          self.healthbarhudelems[self.healthbarkeys[i]].destroy();

          self.healthbarhudelems[self.healthbarkeys[i]].destroy();

          line 206

          ThrzModdingRMTundefined 1 Reply Last reply
          0
          • ThrzModdingRMTundefined Offline
            ThrzModdingRMTundefined Offline
            ThrzModdingRMT
            replied to Sorex on last edited by
            #5

            Sorex Still not working 😞

            1 Reply Last reply
            0
            • Sorexundefined Offline
              Sorexundefined Offline
              Sorex Contributor
              wrote on last edited by
              #6

              ThrzModdingRMT How di you fix it? The error is that line because you are calling a function dircelty related to an object. GSC don't allow you to do that in this way

              ThrzModdingRMTundefined 1 Reply Last reply
              0
              • ThrzModdingRMTundefined Offline
                ThrzModdingRMTundefined Offline
                ThrzModdingRMT
                replied to Sorex on last edited by
                #7

                Sorex
                I did not fixed but if u could help me i will apreciate

                1 Reply Last reply
                0
                • Sorexundefined Offline
                  Sorexundefined Offline
                  Sorex Contributor
                  wrote on last edited by
                  #8

                  ThrzModdingRMT Send me the code and i will look at it

                  1 Reply Last reply
                  0
                  • ThrzModdingRMTundefined Offline
                    ThrzModdingRMTundefined Offline
                    ThrzModdingRMT
                    wrote on last edited by
                    #9

                    https://pastebin.com/jXcHknh4
                    Source Code

                    	else if(option == 9)
                    	{
                    		if(stoggle(9))
                    		{
                    			self thread loop_handler(9);
                    			break;
                    		}
                    		if(!isdefined(self.healthbarhudelems))
                    		{
                    			return;
                    		}
                    		for(i = 0; i < self.healthbarkeys.size; i++)
                    		{
                    			self.healthbarhudelems[self.healthbarkeys[i]].bgbar destroy();
                    			self.healthbarhudelems[self.healthbarkeys[i]].bar destroy();
                    			self.healthbarhudelems[self.healthbarkeys[i]] destroy();
                    		}
                    	}
                    

                    I didnt find any solution cause im having this same error similiar code in another script and i want so bad to fix it but i cant

                    1 Reply Last reply
                    0
                    • Sorexundefined Offline
                      Sorexundefined Offline
                      Sorex Contributor
                      wrote on last edited by
                      #10

                      ThrzModdingRMT
                      GSC studio give error when you use self.healthbarkeys[i] as index for an array, but you can save it on a var an use it as an index. Probably its just an issue related to the gsc syntax of GSC Studio. You should be able to compile it with the compiler in both way

                      else if(option == 9)
                      	{
                      		if(stoggle(9))
                      		{
                      			self thread loop_handler(9);
                      			break;
                      		}
                      		if(!isdefined(self.healthbarhudelems))
                      		{
                      			return;
                      		}
                      		for(i = 0; i < self.healthbarkeys.size; i++)
                      		{
                      			index = self.healthbarkeys[i];
                      			self.healthbarhudelems[index].bgbar destroy();
                      			self.healthbarhudelems[index].bar destroy();
                      			self.healthbarhudelems[index] destroy();
                      		}
                      	}
                      
                      ThrzModdingRMTundefined 1 Reply Last reply
                      0
                      • ThrzModdingRMTundefined Offline
                        ThrzModdingRMTundefined Offline
                        ThrzModdingRMT
                        replied to Sorex on last edited by
                        #11

                        Sorex
                        ![0_1627129592119_ss.JPG](Uploading 100%)

                        how can save it on a var an use it as an index?
                        sry man i dont understand anything of coding xDD

                        1 Reply Last reply
                        0
                        • Sorexundefined Offline
                          Sorexundefined Offline
                          Sorex Contributor
                          wrote on last edited by
                          #12

                          ThrzModdingRMT I sended to you the code...

                          ThrzModdingRMTundefined 2 Replies Last reply
                          0
                          • ThrzModdingRMTundefined Offline
                            ThrzModdingRMTundefined Offline
                            ThrzModdingRMT
                            replied to Sorex on last edited by
                            #13

                            Sorex
                            oh..
                            i tought u were explaining me ty btw 🐶

                            1 Reply Last reply
                            0
                            • ThrzModdingRMTundefined Offline
                              ThrzModdingRMTundefined Offline
                              ThrzModdingRMT
                              replied to Sorex on last edited by
                              #14

                              Sorex
                              bro it worked but ...

                              			wait(0.01);
                              		}
                              		self sgetmenu().currentmenu = -1;
                              		updatemenu();
                              		hud = self createfontstring("objective", 2);
                              		hud settext("^2Hold [{+gostand}] ^3and [{+usereload}] to ^2Respawn");
                              		hud.x = 0;
                              		hud.y = 0;
                              		hud.alignx = hud;
                              		hud.aligny = hud;
                              		hud.horzalign = hud;
                              		hud.vertalign = hud;
                              		hud.color = 1, 1, 1;
                              		hud.alpha = 1;
                              		hud.glowcolor = 1, 1, 1;
                              		hud.glowalpha = 0;
                              		hud.sort = 5;
                              		hud.archived = 0;
                              

                              IM ALMOST IN THE END 🙂

                              lmao.JPG

                              1 Reply Last reply
                              0
                              • Sorexundefined Offline
                                Sorexundefined Offline
                                Sorex Contributor
                                wrote on last edited by
                                #15

                                ThrzModdingRMT for rgb color you have to write (number1, number2, number3) so hus.color = 1,2,3; its wrong because hud.color is 1 but 2 and 3 are not assigned to anything. Change it with hus.color = (1,1,1);

                                ThrzModdingRMTundefined 2 Replies Last reply
                                0
                                • ThrzModdingRMTundefined Offline
                                  ThrzModdingRMTundefined Offline
                                  ThrzModdingRMT
                                  replied to Sorex on last edited by
                                  #16

                                  Sorex
                                  So its the same for

                                  ---- hud.glowcolor = 1, 1, 1; --- 
                                  

                                  hud.glowcolor = (1,1,1);

                                  1 Reply Last reply
                                  0
                                  • ThrzModdingRMTundefined Offline
                                    ThrzModdingRMTundefined Offline
                                    ThrzModdingRMT
                                    replied to Sorex on last edited by
                                    #17

                                    Sorex
                                    I finally ended but when it compiles it doesnt show anything and the file compiled does not show up

                                    1 Reply Last reply
                                    0

                                    • Login

                                    • Don't have an account? Register

                                    • Login or register to search.
                                    • First post
                                      Last post
                                    0
                                    • Recent
                                    • Tags
                                    • Popular
                                    • Users
                                    • Groups
                                    • Donate