Dear forum users! In compliance with the new European GDPR regulations, we'd just like to inform you that if you have an account, your email address is stored in our database. We do not share your information with third parties, and your email address and password are encrypted for security reasons.

New to the forum? Say hello in this topic! Also make sure to read the rules.

Broken Map Script Thing

Did you encounter a problem, exploit, glitch or bug while playing the game or running the dedicated server software? Tell us about it here.
Forum rules
By using the forum you agree to the following rules. For this forum you also need to follow these additional rules.
Post Reply
User avatar
Proxmin-O
Meatbag
Posts: 5
Joined: Fri Jul 27, 2018 5:07 am
SFD Account: Proxmin
Started SFD: August 2016

Broken Map Script Thing

Post by Proxmin-O » Fri Jul 27, 2018 5:13 am

As the title says,when i open a map with script on it (some maps works) and open the Script API and then close it. this error occurs:Superfighters Deluxe has not responding,is there any way to fix it,i tried uninstall but never work.
thanks anyways.
0 x
"You never know whats coming in your way"

User avatar
Gurt
Lead Programmer
Lead Programmer
Posts: 1277
Joined: Sun Feb 28, 2016 3:22 pm
Title: Lead programmer
Started SFD: Made it!
Location: Sweden
Gender:
Age: 28

Post by Gurt » Sun Jul 29, 2018 5:53 pm

If the bug is related to custom map-making then include a download link to the map illustrating the problem.
The map should be bare-bone - only include what's necessary in the map to illustrate the problem.

If the problem is not related to a specific map please provide some more details what you mean.
1 x
Gurt

User avatar
Proxmin-O
Meatbag
Posts: 5
Joined: Fri Jul 27, 2018 5:07 am
SFD Account: Proxmin
Started SFD: August 2016

Post by Proxmin-O » Wed Aug 08, 2018 6:23 am

btw i know whats the problem,The problem is this script:
Public void cot1(TriggerArgs args)
{
IPlayer immabutcher = (IPlayer)args.Sender;
immaButcher.SetProfile(((IObjectPlayerProfileInfo)Game.GetSingleObjectByCustomId(“cot1”)).GetProfile());
}
im sure that all maps containing this script is a problem.
btw its a custom map(or versus maps if available)
tried copy through microsoft word and paste it to script tab but problem occurs.
thanks anyways.

btw its a profile change script (when press or trigger the script,it changes your profile body)

and btw when i use this alternative script:
public void pro13(TriggerArgs args){
IPlayer ply = (IPlayer)args.Sender;
ply.SetProfile(((IObjectPlayerProfileInfo)Game.GetSingleObjectByCustomId("pro13")).GetProfile());
}
i dont have problem with this one
Last edited by KliPeH on Wed Aug 08, 2018 2:42 pm, edited 1 time in total.
Reason: Merged a triple-post.
0 x
"You never know whats coming in your way"

User avatar
Gurt
Lead Programmer
Lead Programmer
Posts: 1277
Joined: Sun Feb 28, 2016 3:22 pm
Title: Lead programmer
Started SFD: Made it!
Location: Sweden
Gender:
Age: 28

Post by Gurt » Wed Aug 08, 2018 3:14 pm

The first code contains syntax errors. Ask the author of the code to fix said problems. I would have written it something like this:

Code: Select all

public void cot1(TriggerArgs args) 
{
   if (args.Sender is IPlayer) {
      IPlayer plr = (IPlayer)args.Sender;
      IObjectPlayerProfileInfo objProfileInfo = Game.GetSingleObjectByCustomID<IObjectPlayerProfileInfo>("cot1");
      if (objProfileInfo != null) {
         plr.SetProfile(objProfileInfo.GetProfile());
      }
   }
}
0 x
Gurt

User avatar
Sree
Superfighter
Superfighter
Posts: 283
Joined: Sun May 08, 2016 8:19 pm
Title: PhasmicAF
SFD Account: Sree
Gender:
Age: 18

Post by Sree » Wed Aug 08, 2018 4:03 pm

C# is case sensitive.

if you are wondering what the errors are in your script
Proxmin-O wrote:
Wed Aug 08, 2018 6:23 am
Public void cot1(TriggerArgs args)
Proxmin-O wrote:
Wed Aug 08, 2018 6:23 am
IPlayer immabutcher = (IPlayer)args.Sender;
immaButcher.SetProfile(((IObjectPlayerProfileInfo)Game.GetSingleObjectByCustomId(“cot1”)).GetProfile());
Proxmin-O wrote:
Wed Aug 08, 2018 6:23 am
immaButcher.SetProfile(((IObjectPlayerProfileInfo)Game.GetSingleObjectByCustomId(“cot1”)).GetProfile());
0 x

User avatar
Proxmin-O
Meatbag
Posts: 5
Joined: Fri Jul 27, 2018 5:07 am
SFD Account: Proxmin
Started SFD: August 2016

Post by Proxmin-O » Thu Aug 09, 2018 11:59 am

Thanks for all your comments
0 x
"You never know whats coming in your way"

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests