lhu123 Posted July 2, 2013 Share Posted July 2, 2013 I found two interesting things when I am modifying the subclass of a vehicle. I was trying to incorporate the request evaluating logic in the vehicle subclass processes rather than model processes, for ease of transplant and multiple uses. But when the token return value is 0 in subclass, no matter what add-on-process returns, vehicle still picks up entities. What's the logic behind this? How should I make it work? Anybody knows? Another problem is I added breakpoint in the subclass, it does not stop, but I use some assign step to detect it, these assign step works, which means token is executing the process, anybody knows why the breakpoint does not work? Attachment is the model, Assign step assign token return value 'False' in evaluating request in subclass of vehicle. Everytime process runs, It could be seen weight of vehicle +0.5 Anybody knows why? SimplestTuggerWithTwoCycle.spfx Link to comment Share on other sites More sharing options...
dsturrock Posted July 2, 2013 Share Posted July 2, 2013 "Decision processes" like the evaluating ... ones require an instantaneous decision with no possibility for delay or interruption. For this reason breaks inside a decision process will not work. Link to comment Share on other sites More sharing options...
MEagar Posted July 4, 2013 Share Posted July 4, 2013 I had a similiar problem with the transporter not listening what you tell it to do.... Solution... Delete the on visiting Node process and rewrite the logic....There are setNode,s statements in the Onvisitingnode process which overwrites the user assignments as the process is the first and last process which executes during run time as a transporter moves through a node.... Link to comment Share on other sites More sharing options...
ASagan Posted July 7, 2013 Share Posted July 7, 2013 lhu123, Your model is working -- transport requests are rejected. However, pickup requests (at the node itself) are not, so the vehicle picks entities up. This is because you have not modified the vehicles 'OnEvaluatingRiderAtPickup' process. The standard library vehicle calls the 'Evaluating Transport Request' add on from both the OnEvaluatingTransportRequest and OnEvaluatingRiderAtPickup processes. To bring this logic into the vehicle, you will need to subclass both processes. Link to comment Share on other sites More sharing options...
lhu123 Posted July 8, 2013 Author Share Posted July 8, 2013 Yes! I found it! lhu123, Your model is working -- transport requests are rejected. However, pickup requests (at the node itself) are not, so the vehicle picks entities up. This is because you have not modified the vehicles 'OnEvaluatingRiderAtPickup' process. The standard library vehicle calls the 'Evaluating Transport Request' add on from both the OnEvaluatingTransportRequest and OnEvaluatingRiderAtPickup processes. To bring this logic into the vehicle, you will need to subclass both processes. Link to comment Share on other sites More sharing options...
Recommended Posts