Post: Freezing with Ferris Wheel and others
02-11-2017, 10:58 AM #1
Saber_JZY
Bounty hunter
(adsbygoogle = window.adsbygoogle || []).push({}); Hello Ngu Smile
When I add the Ferris wheel code to my source and inject I freeze, if I remove the code from my menu source I have no issue.
I also tried compiling my source and injecting via development.dvar with no success, but if I use the code in a clean base the menu does not freeze?
(adsbygoogle = window.adsbygoogle || []).push({});
02-11-2017, 11:07 AM #2
Kronos
Former Staff
Originally posted by JZY View Post
Hello Ngu Smile
When I add the Ferris wheel code to my source and inject I freeze, if I remove the code from my menu source I have no issue.
I also tried compiling my source and injecting via development.dvar with no success, but if I use the code in a clean base the menu does not freeze?


do u wanna link your code? might help some people determine the problem.
02-11-2017, 11:11 AM #3
Saber_JZY
Bounty hunter
Originally posted by Kronos View Post
do u wanna link your code? might help some people determine the problem.


It's the exact same code from the official thread, I haven't edited the code at all, just copied and added it to my source.
I'm confused why it works in a clean base and not my menu ( which uses the same base )
Could I have another code in the source that maybe conflicting with it?
02-11-2017, 11:12 AM #4
Patrick
League Champion
Originally posted by JZY View Post
Hello Ngu Smile
When I add the Ferris wheel code to my source and inject I freeze, if I remove the code from my menu source I have no issue.
I also tried compiling my source and injecting via development.dvar with no success, but if I use the code in a clean base the menu does not freeze?


Firstly make sure you have all the required functions needed for the ferris wheel and the other scripts, secondly make sure you don't have other functions called as the ferris wheel needed functions for example:

Original code for model spawner:
    modelSpawner(origin, model, angles)
{
obj = spawn("script_model", origin);
obj setModel(model);
if(isDefined(angles))
obj.angles = angles;
return obj;
}


My edited version of model spawner:
    modelSpawner(origin, model, angles, time)
{
if(isDefined(time))
wait time;
obj = spawn("script_model", origin);
obj setModel(model);
if(isDefined(angles))
obj.angles = angles;
if(getentarray().size >= 590)
{
self iprintln("^1Error^7: Please delete some other structures");
obj delete();
}
return obj;
}


It uses 4 parameters when the original only uses 3 so if you're using the ferris wheel with the old model spawner you'll freeze because you have too many parameters ofc.
From that example you should find out whats freezing if not go more in depth with your thread so get better guidance/help/

The following user thanked Patrick for this useful post:

Kronos
02-11-2017, 11:12 AM #5
Kronos
Former Staff
Originally posted by JZY View Post
It's the exact same code from the official thread, I haven't edited the code at all, just copied and added it to my source.
I'm confused why it works in a clean base and not my menu ( which uses the same base )
Could I have another code in the source that maybe conflicting with it?


no it may be possible u dont have enough required code for the function to work, i would link ur menu code so people can pin point problems easier.
02-11-2017, 11:23 AM #6
Saber_JZY
Bounty hunter
Originally posted by Patrick View Post
Firstly make sure you have all the required functions needed for the ferris wheel and the other scripts, secondly make sure you don't have other functions called as the ferris wheel needed functions for example:

Original code for model spawner:
    modelSpawner(origin, model, angles)
{
obj = spawn("script_model", origin);
obj setModel(model);
if(isDefined(angles))
obj.angles = angles;
return obj;
}


My edited version of model spawner:
    modelSpawner(origin, model, angles, time)
{
if(isDefined(time))
wait time;
obj = spawn("script_model", origin);
obj setModel(model);
if(isDefined(angles))
obj.angles = angles;
if(getentarray().size >= 590)
{
self iprintln("^1Error^7: Please delete some other structures");
obj delete();
}
return obj;
}


It uses 4 parameters when the original only uses 3 so if you're using the ferris wheel with the old model spawner you'll freeze because you have too many parameters ofc.
From that example you should find out whats freezing if not go more in depth with your thread so get better guidance/help/


Oh ok, I was still using the modelspawner code from the original claw ( I think it was) I will remove the old model spawner and try the new one and report back with feedback.
02-11-2017, 11:27 AM #7
Saber_JZY
Bounty hunter
Yes, it works, thanks for that, Kronos you can close the thread due to the issue being solved Smile
02-11-2017, 11:33 AM #8
Kronos
Former Staff
Cool Man, Glad ur issue was resolved, thanks to Patrick

Thread Closed.

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo